Or any include directory/library.
I use cmake gui tool so I run it and usually the gui will highlight the include or library it can't find and let you open a open dialog to set the path however it doesn't do that for this cmake cofig it tell you in red text in the output in the gui tool, so,
CMake Error at C:/Program Files/CMake/share/cmake-3.0/Modules/FindPackageHandleStandardArgs.cmake:136 (message):
Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.0/Modules/FindPackageHandleStandardArgs.cmake:343 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files/CMake/share/cmake-3.0/Modules/FindZLIB.cmake:101 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
src/CMakeLists.txt:7 (find_package)
So still using the gui how do I point cmake to the zlib include dir?
Quick solution: apt-get install zlib1g-dev
I'll first assume you have ZLib installed somewhere, and my guess is that it's in a non-standard location since CMake find it. If that's true, you can set the location in CMake-gui. You'll need to first click the 'Advanced' checkbox near the top, because the FindZLIB.cmake file has the following line "mark_as_advanced(ZLIB_LIBRARY ZLIB_INCLUDE_DIR)".
Now you should be able to see the ZLIB_LIBRARY ZLIB_INCLUDE_DIR options and set the correct path.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With