fix build on osx, remove win32 dependencies