base-files: move xor() from caldata extraction to functions.sh