GerHobbelt / pthread-win32

clone of pthread-win32 (a.k.a. pthreads4w) + local tweaks (including MSVC2008 - MSVC2022 project files)
Other
350 stars 166 forks source link

Fix dll compilation issue for Visual Studio using makefile #8

Closed sproberts92 closed 9 years ago

sproberts92 commented 9 years ago

The compilation sanity checks in dll.c are expecting _WINDLL to be defined. In the Visual Studio project this definition is inherited but is not present when building using the makefile. As _WINDLL is referenced no where in the project other than the sanity checks it seems safe to define it via the makefile.

I have tested building with nmake and Visual Studio 2015 for x86 and x64.

All non-static build options (vc, vc-debug, vce, etc) work (with the second error fix mentioned in the second half of my comment on #5 employed also (although that looks like a separate issue)).

The resultant dll works (only tested vc, thats all I have a project to test with, sorry).

Note: this is for non-static builds only, I have neither touched nor tested the static builds . This resolves #5.