Allow nodes in labels.json to be wildcards or regular expressions

(change from a while ago, needs more testing ...)
Basic support for building maps of cnames
Allow 'nil' to be false (and 0 for integers) when loading JSON