-lzlib doesn't work - have to use -lz when linking (Bug #1101)
Description
zlib's .so is named libz.so, so even though CMake correctly finds zlib.h, it doesn't link the library correctly.
If I add a softlink to libzlib.so to /usr/lib/, it compiles just fine.
This is on a recent (upgraded a week ago) archlinux.
My svn revision:
atom@kamichan ~/work/ijs/ocv/build/opencv $ svn update
Updated to revision 5250
Regards,
Gašper
Associated revisions
Merge pull request #1101 from jet47:cudev-stub-lib
History
Updated by Alexander Shishkov over 13 years ago
Maybe you should use newer version of CMake.
I tried to reproduce your problem on Ubuntu 9.10 with CMake 2.8. It finds zlib correctly.
In /usr/share/cmake-2.8/Modules/FindZLIB.cmake it tries different names for zlib including z (libz.so):
SET
FIND_LIBRARY(ZLIB_LIBRARY NAMES ${ZLIB_NAMES} )
- Status changed from Open to Done
- (deleted custom field) set to wontfix