Commit af1c1564 authored by f3nix's avatar f3nix

CMake:

* Change tabs to spaces.
* Make Boost required.
parent 9dcd7924
...@@ -83,6 +83,14 @@ ELSE(OPENGL_FOUND) ...@@ -83,6 +83,14 @@ ELSE(OPENGL_FOUND)
MESSAGE(FATAL_ERROR "OpenGL was not found - it is required to build KiCad") MESSAGE(FATAL_ERROR "OpenGL was not found - it is required to build KiCad")
ENDIF(OPENGL_FOUND) ENDIF(OPENGL_FOUND)
FIND_PACKAGE(Boost)
IF(Boost_FOUND)
MESSAGE(STATUS "Check for installed Boost -- found")
ELSE(Boost_FOUND)
MESSAGE(STATUS "Check for installed Boost -- not found")
MESSAGE(FATAL_ERROR "Boost was not found - it is required to build KiCad")
ENDIF(Boost_FOUND)
# Here you can define what libraries of wxWidgets you need for your # Here you can define what libraries of wxWidgets you need for your
# application. You can figure out what libraries you need here; # application. You can figure out what libraries you need here;
# http://www.wxwidgets.org/manuals/2.8/wx_librarieslist.html # http://www.wxwidgets.org/manuals/2.8/wx_librarieslist.html
......
...@@ -23,6 +23,7 @@ SET(COMMON_SRCS ...@@ -23,6 +23,7 @@ SET(COMMON_SRCS
get_component_dialog.cpp get_component_dialog.cpp
gr_basic.cpp gr_basic.cpp
hotkeys_basic.cpp hotkeys_basic.cpp
infospgm.cpp
msgpanel.cpp msgpanel.cpp
projet_config.cpp projet_config.cpp
# pyhandler.cpp # pyhandler.cpp
...@@ -31,7 +32,6 @@ SET(COMMON_SRCS ...@@ -31,7 +32,6 @@ SET(COMMON_SRCS
toolbars.cpp toolbars.cpp
trigo.cpp trigo.cpp
worksheet.cpp worksheet.cpp
wxwineda.cpp wxwineda.cpp)
infospgm.cpp)
ADD_LIBRARY(common ${COMMON_SRCS}) ADD_LIBRARY(common ${COMMON_SRCS})
FIND_PACKAGE(ZLIB) FIND_PACKAGE(ZLIB)
IF(ZLIB_FOUND) IF(ZLIB_FOUND)
MESSAGE(STATUS "Check for installed ZLIB -- found") MESSAGE(STATUS "Check for installed zlib -- found")
ELSE(ZLIB_FOUND) ELSE(ZLIB_FOUND)
MESSAGE(STATUS "Check for installed zlib -- not found") MESSAGE(STATUS "Check for installed zlib -- not found")
IF (NOT MINGW) IF(NOT MINGW)
MESSAGE(FATAL_ERROR MESSAGE(FATAL_ERROR
"zlib was not found - it is required to build KiCad") "zlib was not found - it is required to build KiCad")
ELSE (NOT MINGW) ELSE(NOT MINGW)
# zlib is not installed, and in this case wxWidgets creates its own zlib library # zlib is not installed, and in this case wxWidgets creates its own zlib library
# include files are in ${wxWidgets_ROOT_DIR}/src/zlib # include files are in ${wxWidgets_ROOT_DIR}/src/zlib
#and the corresponding library is libwxzlib-<version>.a ( like libwxzlib-2.8.a) # and the corresponding library is libwxzlib-<version>.a (like libwxzlib-2.8.a)
# and we try to use it # and we try to use it
INCLUDE_DIRECTORIES(${wxWidgets_ROOT_DIR}/src/zlib) INCLUDE_DIRECTORIES(${wxWidgets_ROOT_DIR}/src/zlib)
ENDIF (NOT MINGW) ENDIF(NOT MINGW)
ENDIF(ZLIB_FOUND) ENDIF(ZLIB_FOUND)
SET(MINIZIP_SRCS SET(MINIZIP_SRCS
...@@ -20,7 +20,7 @@ SET(MINIZIP_SRCS ...@@ -20,7 +20,7 @@ SET(MINIZIP_SRCS
minizip.c minizip.c
zip.c) zip.c)
ADD_EXECUTABLE(minizip ${MINIZIP_SRCS} ) ADD_EXECUTABLE(minizip ${MINIZIP_SRCS})
TARGET_LINK_LIBRARIES(minizip ${ZLIB_LIBRARIES} ${wxWidgets_LIBRARIES}) TARGET_LINK_LIBRARIES(minizip ${ZLIB_LIBRARIES} ${wxWidgets_LIBRARIES})
......
ADD_DEFINITIONS(-DPCBNEW) ADD_DEFINITIONS(-DPCBNEW)
FIND_PACKAGE(Boost)
INCLUDE_DIRECTORIES( INCLUDE_DIRECTORIES(
${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}
${Boost_INCLUDE_DIR} ${Boost_INCLUDE_DIR}
...@@ -172,7 +170,7 @@ ADD_EXECUTABLE(dsntest EXCLUDE_FROM_ALL dsn.cpp) ...@@ -172,7 +170,7 @@ ADD_EXECUTABLE(dsntest EXCLUDE_FROM_ALL dsn.cpp)
TARGET_LINK_LIBRARIES(dsntest common ${wxWidgets_LIBRARIES}) TARGET_LINK_LIBRARIES(dsntest common ${wxWidgets_LIBRARIES})
# This one gets made only when testing. # This one gets made only when testing.
ADD_EXECUTABLE(specctra_test EXCLUDE_FROM_ALL specctra.cpp dsn.cpp ) ADD_EXECUTABLE(specctra_test EXCLUDE_FROM_ALL specctra.cpp dsn.cpp)
TARGET_LINK_LIBRARIES(specctra_test common ${wxWidgets_LIBRARIES}) TARGET_LINK_LIBRARIES(specctra_test common ${wxWidgets_LIBRARIES})
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment