more tweaks to aid compilation
and some more - still not there