Unix & CCS compatibilty

Fix errors to be able to compile gen2 under Linux. Silence one warning.