Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Prefer documented zlib library names #2354
As promised on mailing list "Building on Windows: zlib library names in winbuild/MakeBuild.vc" this PR means can build on Windows with zlib without needing to modify zlib library names.
Check for existence of import and static libraries with documented names and use them if they do. Fallback to previous names.
According to https://github.com/madler/zlib/blob/master/win32/README-WIN32.txt on Windows, the names of the import library is "zdll.lib" and static library is "zlib.lib".
I can make not comment on the static side but it seems OK to me if the names are OK. I note that in the static leg it looks for zlib.lib, but the default lib is zlib_a.lib
I have done a build using my usual build process and it shows no regressions. But that build, while using MakeFileBuiild.vc is nonstandard and so shouldn't be relied upon.
So in gerrit-speak "looks OJK to me, but some wlse must confirm"
To be fair, I haven't checked the static branch either, but the names are consistent with my reading of https://github.com/madler/zlib/blob/master/win32/README-WIN32.txt - I don't see any mention of zlib_a.lib there. For builds that are using zlib_a.lib it should continue to work same as before.
I used nmake on https://github.com/madler/zlib/blob/master/win32/Makefile.msc
I had seen reference to zlibwapi as well - a bit more reading suggests there are 2 "official" builds - according to https://github.com/madler/zlib/blob/master/contrib/vstudio/readme.txt
"There is also an official DLL build of zlib, named zlib1.dll"
What about adding another exists check on the library name?