CMakeLists.txt 2.38 KB
Newer Older
Sylvain Thery's avatar
Sylvain Thery committed
1
cmake_minimum_required(VERSION 2.8)
Pierre Kraemer's avatar
Pierre Kraemer committed
2 3 4 5 6

project(CGoGNDebug)

SET(CMAKE_BUILD_TYPE Debug)

thery's avatar
thery committed
7 8 9 10 11 12 13
IF(WIN32)
	SET(LIBRARY_OUTPUT_PATH ${CGoGN_ROOT_DIR}/lib)
ELSE(WIN32)
	SET(LIBRARY_OUTPUT_PATH ${CGoGN_ROOT_DIR}/lib/Debug)
ENDIF(WIN32)

#SET(BUILD_SHARED_LIBS,FALSE)
Pierre Kraemer's avatar
Pierre Kraemer committed
14

Sylvain Thery's avatar
Sylvain Thery committed
15 16 17 18 19 20
# FOR Qt4
SET(QT_USE_QTOPENGL TRUE)
INCLUDE(${QT_USE_FILE})
ADD_DEFINITIONS(${QT_DEFINITIONS})


Pierre Kraemer's avatar
Pierre Kraemer committed
21
include_directories(
22
	${CMAKE_CURRENT_BINARY_DIR}
Pierre Kraemer's avatar
Pierre Kraemer committed
23 24 25 26 27 28
	/usr/include/libxml2
	${CGoGN_ROOT_DIR}/include
	${CGoGN_ROOT_DIR}/ThirdParty/Numerical
	${CGoGN_ROOT_DIR}/ThirdParty/AntTweakBar/include
	${CGoGN_ROOT_DIR}/ThirdParty/gzstream
	${CGoGN_ROOT_DIR}/ThirdParty/Assimp/include
29
	${CGoGN_ROOT_DIR}/ThirdParty/glm
Sylvain Thery's avatar
Sylvain Thery committed
30
	${Boost_INCLUDE_DIRS}
Pierre Kraemer's avatar
Pierre Kraemer committed
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70

)

file(
	GLOB_RECURSE
	files_topology
	${CGoGN_ROOT_DIR}/src/Topology/*.cpp
	${CGoGN_ROOT_DIR}/include/Topology/*.hpp
	${CGoGN_ROOT_DIR}/include/Topology/*.h
)
add_library(
	topologyD
	${files_topology}
)

file(
	GLOB_RECURSE
	files_container
	${CGoGN_ROOT_DIR}/src/Container/*.cpp
	${CGoGN_ROOT_DIR}/include/Container/*.hpp
	${CGoGN_ROOT_DIR}/include/Container/*.h
)
add_library(
	containerD
	${files_container}
)

file(
	GLOB_RECURSE
	files_algo
	${CGoGN_ROOT_DIR}/src/Algo/*.cpp
	${CGoGN_ROOT_DIR}/src/Algo/*.c
	${CGoGN_ROOT_DIR}/include/Algo/*.hpp
	${CGoGN_ROOT_DIR}/include/Algo/*.h
)
add_library(
	algoD
	${files_algo}
)

71 72 73 74 75 76 77 78 79 80 81 82

file(
	GLOB_RECURSE
	shaders_srcD
	${CGoGN_ROOT_DIR}/include/Utils/*.frag
	${CGoGN_ROOT_DIR}/include/Utils/*.vert
	${CGoGN_ROOT_DIR}/include/Utils/*.geom	
	${CGoGN_ROOT_DIR}/include/Utils/Shaders*.frag
	${CGoGN_ROOT_DIR}/include/Utils/Shaders*.vert
	${CGoGN_ROOT_DIR}/include/Utils/Shaders*.geom
)

83 84 85 86 87 88
IF(WIN32)
add_custom_target(shader_targetD ${CGoGN_ROOT_DIR}/ThirdParty/Tools/Release/shader_to_h ${shaders_srcD}
	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
	SOURCES ${shaders_srcD} 
)
ELSE(WIN32)
89 90 91 92
add_custom_target(shader_targetD ${CGoGN_ROOT_DIR}/ThirdParty/Tools/shader_to_h ${shaders_srcD}
	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
	SOURCES ${shaders_srcD} 
)
93 94 95 96 97
ENDIF(WIN32)




Pierre Kraemer's avatar
Pierre Kraemer committed
98 99 100 101 102 103 104 105 106


file(
	GLOB_RECURSE
	files_utils
	${CGoGN_ROOT_DIR}/src/Utils/*.cpp
	${CGoGN_ROOT_DIR}/include/Utils/*.hpp
	${CGoGN_ROOT_DIR}/include/Utils/*.h
)
Sylvain Thery's avatar
Sylvain Thery committed
107 108 109 110 111 112 113 114 115 116 117

file(
	GLOB_RECURSE
	utils_qt_headers
	${CGoGN_ROOT_DIR}/include/Utils/qt*.h
)
	
QT4_WRAP_CPP(UTILS_QT_HEADERS_MOC ${utils_qt_headers})

SET (files_utils_withQt ${files_utils} ${UTILS_QT_HEADERS_MOC})

Pierre Kraemer's avatar
Pierre Kraemer committed
118 119
add_library(
	utilsD
Sylvain Thery's avatar
Sylvain Thery committed
120
	${files_utils_withQt}
Pierre Kraemer's avatar
Pierre Kraemer committed
121 122
)

123
add_dependencies(utilsD shader_targetD )
Sylvain Thery's avatar
Sylvain Thery committed
124