← Back to team overview

kicad-developers team mailing list archive

Re: You missed a file in the zlib CMake script...


On 5/4/2012 5:48 AM, Lorenzo Marcantonio wrote:
By the way, was it really necessary to embed the whole zlib? It should be already provided with wx... (or is the wx one statically linked?)

=== modified file 'zlib/CMakeLists.txt'
--- zlib/CMakeLists.txt 2012-05-03 18:37:56 +0000
+++ zlib/CMakeLists.txt 2012-05-04 09:47:20 +0000
@@ -1,4 +1,5 @@
+    adler32.c

It's not necessary since zlib is provided by wxWidgets on Windows when libz cannot be found when configure is run. FindZLIB.cmake was removed when we stopped including minizip with the project. I see no advantage to including the zlib source files in the project. Use FindZLIB and set the cmake include(ZLIB_INCLUDE) and add ZLIB_LIBRARIES to the list of libraries to build the executables that require zlib.

FYI, I've been building wxWidgets as a DLLs on Windows for the last few years without any issues. This includes both the 2.8 and 2.9 versions. The only thing that you need to do is make sure the libraries are in your system PATH. By default, configure puts them in /prefix/lib (where I set --prefix=/mingw on MinGW/MSYS) which is not in the system PATH. Typically MinGW sets the system PATH to /mingw/bin so you can either copy them from /mingw/lib to /mingw/bin or I believe you can use the --libexecdir=/mingw/bin to install the DLLs in the bin directory automatically. The only disadvantage to using DLLs is that you have to remember to include them in the Window's installer.


Follow ups