Compilation fixes and warnings

These will correct compilation that broke some commits ago and also fix/supress some compiler warnings.