Rework os.h to get rid of redundant code

for the costs of dropping the clean structure LINUX/APPLE/WIN32 in
favour of INCLUDES/SHARED POSIX/LINUX ONLY/APPLE ONLY/WIN32 ONLY/COMMON
Silence a number of unused parameter warnings
More works on Windows port

First version that compiles, but still some nasty linker errors remain