CMakeLists.txt 1.51 KB
Newer Older
1
2
cmake_minimum_required(VERSION 2.6)

Pierre Kraemer's avatar
Pierre Kraemer committed
3
4
project(CGoGN_ThirdParty)

5
SET(CGoGN_ROOT_DIR ${CMAKE_SOURCE_DIR}/..)
unknown's avatar
unknown committed
6
7
8
9
10

IF(WIN32)
	set(CMAKE_PREFIX_PATH ${CGoGN_ROOT_DIR}/windows_dependencies CACHE STRING "path to dependencies")
ENDIF(WIN32)

11
SET(CMAKE_BUILD_TYPE Release)
thery's avatar
thery committed
12

unknown's avatar
unknown committed
13
14
15
16
17
18
19
20
21
22
23
24
IF (${CMAKE_CURRENT_BINARY_DIR} MATCHES "(.*)Debug")
	SET(CMAKE_BUILD_TYPE Debug)
ENDIF (${CMAKE_CURRENT_BINARY_DIR} MATCHES "(.*)Debug")

IF(WIN32)
	SET(LIBRARY_OUTPUT_PATH ${CGoGN_ROOT_DIR}/lib)#release added by visual
	INCLUDE_DIRECTORIES(${CGoGN_ROOT_DIR}/windows_dependencies/include/)
ELSE(WIN32)
	SET(LIBRARY_OUTPUT_PATH ${CGoGN_ROOT_DIR}/lib/${CMAKE_BUILD_TYPE})
ENDIF(WIN32)


Sylvain Thery's avatar
Sylvain Thery committed
25
26
27
# for shared or not shared
SET (BUILD_SHARED_LIBS OFF CACHE BOOL 
	"if used all library are build as shared type (.so /dylib/dll).")
Sylvain Thery's avatar
Sylvain Thery committed
28

29
30
31
SET (WITH_ASSIMP ON CACHE BOOL "build with Assimp")
SET (WITH_NUMERICAL ON CACHE BOOL "build with numerical libs")
SET (WITH_ZINRI ON CACHE BOOL "build with Zinri libs")
Sylvain Thery's avatar
Sylvain Thery committed
32

33
34
35
IF (APPLE)
	SET(CMAKE_OSX_ARCHITECTURES x86_64)
ENDIF(APPLE)
36

Pierre Kraemer's avatar
Pierre Kraemer committed
37

38

39
40
add_subdirectory(Tools Tools/build)

41
42
43
44
IF (WITH_ZINRI)
	add_subdirectory(Zinri Zinri/build)
ENDIF(WITH_ZINRI)

Sylvain Thery's avatar
Sylvain Thery committed
45
IF (WITH_ASSIMP)
46
	add_subdirectory(Assimp Assimp/build)
Sylvain Thery's avatar
Sylvain Thery committed
47
ENDIF (WITH_ASSIMP)
48

Sylvain Thery's avatar
Sylvain Thery committed
49
IF (WITH_NUMERICAL)
50
	add_subdirectory(Numerical Numerical/build)
Sylvain Thery's avatar
Sylvain Thery committed
51
ENDIF (WITH_NUMERICAL)
52

Pierre Kraemer's avatar
Pierre Kraemer committed
53

Pierre Kraemer's avatar
Pierre Kraemer committed
54
55
56
add_subdirectory(PythonQt PythonQt/build)


unknown's avatar
unknown committed
57
58
59
60
61
IF(WIN32)
	SET(CMAKE_CONFIGURATION_TYPES ${CMAKE_BUILD_TYPE})
	SET(CMAKE_CONFIGURATION_TYPES "${CMAKE_CONFIGURATION_TYPES}" CACHE STRING "" FORCE)
	MARK_AS_ADVANCED(CMAKE_CONFIGURATION_TYPES)
ENDIF(WIN32)