[zlib] zlib/1.2.12: Compilation with Clang on Windows produces the wrong library name (z.lib instead of zlib.lib)
See original GitHub issueDescription
To elaborate on the title:
-
When building
zlib
on Windows with MSVC, the produced library is namedzlib.lib
, as intended by all generators which try to locate a file with basenamezlib
. -
If
zlib
is built with Conan 15 on Windows, the produced library is namesz.lib
instead, which breaks downstreams because they expectzlib
basename.
Package and Environment Details
- Package Name/Version: libpng/1.6.38
- Operating System+version: Windows 10
- Compiler+version: Clang 15 (
scoop install llvm
) - Conan version: conan 1.53.0
Conan profile
[settings] arch=x86_64 arch_build=x86_64 build_type=Debug compiler=clang compiler.cppstd=20 compiler.version=15 os=Windows os_build=Windows [options] [build_requires] *: cmake/3.24.1 [env] CONAN_CMAKE_GENERATOR=Unix Makefiles [conf] tools.cmake.cmaketoolchain:generator=Unix Makefiles
Steps to reproduce
Build zlib:
conan install -pr:h clang15-win-dev -pr:b build/Windows zlib/1.2.12@
Then locate the build package in the filesystem, and take a look under lib/
folder. It will contain z.lib
for Clang builds, and zlib.lib
for MSVC builds.
Logs
Click to expand log
It is more of filename issue than a log error per se.
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:18 (11 by maintainers)
Here is a proposal: https://github.com/conan-io/conan-center-index/pull/13597
I’ve opened https://github.com/conan-io/conan/issues/12336. I believe that we can’t do anything robust currently without such method.