Make building minizip optional, if your linux distro supplies a minizip binary (e.g. in the zlib-bin package on debian) you might as well use it instead of building this one.

Note that this isn't implemented in the minizip CMakeLists.txt, but at the higher level (kicad) that includes the minizip subdirectory, so that the whole minizip directory can be dropped from the shipped source tree if it isn't needed on your distro. This makes the source package a fraction smaller and removes possible complications of having a different license on the minizip code to the rest of kicad.
This commit is contained in:
raburton 2008-01-05 19:16:30 +00:00
parent 548fb9152f
commit 32b4d32bef
2 changed files with 7 additions and 2 deletions

View File

@ -1,4 +1,4 @@
# Our project is called 'kicad'.This is how it will be called in
# Our project is called 'kicad'. This is what it will be called in
# Visual Studio and in our makefiles.
PROJECT(kicad)
@ -7,6 +7,9 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.4.6 FATAL_ERROR)
# Uncomment this line if you want verbose build messages.
#SET(CMAKE_VERBOSE_MAKEFILE ON)
# Comment this out if you don't want to build minizip.
SET(BUILD_MINIZIP ON CACHE BOOL "Build minizip?")
# Set default flags for Debug build.
SET(CMAKE_C_FLAGS_DEBUG "-Wall -g3 -ggdb3 -DDEBUG")
SET(CMAKE_CXX_FLAGS_DEBUG "-Wall -g3 -ggdb3 -DDEBUG")

View File

@ -38,4 +38,6 @@ TARGET_LINK_LIBRARIES(kicad common ${wxWidgets_LIBRARIES})
INSTALL(TARGETS kicad RUNTIME DESTINATION ${KICAD_BIN})
ADD_SUBDIRECTORY(minizip)
IF(BUILD_MINIZIP)
ADD_SUBDIRECTORY(minizip)
ENDIF(BUILD_MINIZIP)