Building on Win32, MSYS2 (Step 1, cmake)

From time to time I try to compile swipl under MSYS2 and Windows. Today’s result:

  1. This doesn’t work (hangs eternally)

cd swipl-devel/build cmake …

But I am pretty sure this is because my own cmake is broken (it’s a Win32 computer). On Win64, I remember that cmake was running fine. Interestingly, the cmake installation from does not hang, so I’ll use that one.

  1. This raises an error:

$ /c/Program\ Files/CMake/bin/cmake.exe -G “MSYS Makefiles” …

(some lines omitted)
– Using unsigned short
– Check if the system is big endian - little endian
– Check floating point format
– Check floating point format - IEEE-754, little endian
CMake Error at C:/Program Files/CMake/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message):
Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version “1.2.11”)
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files/CMake/share/cmake-3.16/Modules/FindZLIB.cmake:115 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
cmake/Dependencies.cmake:1 (find_package)
CMakeLists.txt:70 (include)

  1. If I set zlib explicitly, I get through the cmake process

$ /c/Program\ Files/CMake/bin/cmake.exe -G “MSYS Makefiles” … -DZLIB_LIBRARY=/usr/lib/libz.a

Hope it is of any use.

Best regards,


1 Like

.. not ... (seems to be auto-corrected by the markdown renderer)