Fix error in ZLIB detection
commit65dc201acdbf543e8c17a7313a874be8b2c061fb
authorCarlo Bramini <30959007+carlo-bramini@users.noreply.github.com>
Tue, 30 Jun 2020 07:37:54 +0000 (30 09:37 +0200)
committerHans Petter Selasky <hps@selasky.org>
Sat, 1 Aug 2020 07:59:59 +0000 (1 09:59 +0200)
tree93b10ce78fcb935edb56684fde9e6345dc3afcf2
parent8c5883e8a6339cee0851fed1adafd4f2fbedfe0b
Fix error in ZLIB detection

I'm getting this message on screen when CMake configures the project:

  The package name passed to `find_package_handle_standard_args` ;(ZLIB) does
  not match the name of the calling package ;(zlib).  This can lead to
  problems in calling ;code that expects `find_package` result variables
  (e.g., `_FOUND`) ;to follow a certain pattern.
Call Stack (most recent call first):
  /home/carlo/inst_cmake/share/cmake-3.17.3/Modules/FindPackageHandleStandardArgs.cmake:272 (message)
  cmake/Findzlib.cmake:39 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  src/CMakeLists.txt:13 (find_package)

This happens because the target must be "ZLIB", with capital letters, and not "zlib":

https://cmake.org/cmake/help/git-master/module/FindZLIB.html
src/CMakeLists.txt