Phase-locking millimetre-wave klystrons for the measurement of submillimetre laser frequencies