CMakeLists.txt 2.42 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 7

project(examples)

SET(CMAKE_BUILD_TYPE Release)
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DNOTOPOWARNING")

Sylvain Thery's avatar
Sylvain Thery committed
8

Pierre Kraemer's avatar
Pierre Kraemer committed
9 10
# define includes path
include_directories(
11
	${CMAKE_CURRENT_BINARY_DIR}
Pierre Kraemer's avatar
Pierre Kraemer committed
12
	${CGoGN_ROOT_DIR}/include
Sylvain Thery's avatar
Sylvain Thery committed
13
	${CGoGN_EXT_INCLUDES}
Pierre Kraemer's avatar
Pierre Kraemer committed
14 15 16
)

# define libs path
thery's avatar
thery committed
17
IF(WIN32)
18
	link_directories( ${CGoGN_ROOT_DIR}/lib/$(ConfigurationName)  ${Boost_LIBRARY_DIRS})
thery's avatar
thery committed
19 20 21 22
ELSE(WIN32)
	link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
ENDIF(WIN32)

Pierre Kraemer's avatar
Pierre Kraemer committed
23 24 25

#define exec to compile

26 27
QT4_WRAP_CPP(polyhedronsView_moc ../polyhedronsView.h)	
add_executable( polyhedronsView ../polyhedronsView.cpp ${polyhedronsView_moc})
28
target_link_libraries( polyhedronsView
Sylvain Thery's avatar
Sylvain Thery committed
29
		${CGoGN_LIBS_R} ${CGoGN_EXT_LIBS}  )
30

31 32 33
QT4_WRAP_CPP(frame_manip_moc ../frame_manip.h)	
add_executable( frame_manip ../frame_manip.cpp ${frame_manip_moc})
target_link_libraries( frame_manip
Sylvain Thery's avatar
Sylvain Thery committed
34
		${CGoGN_LIBS_R} ${CGoGN_EXT_LIBS}  )
35 36 37 38
		
QT4_WRAP_CPP(texturesExample_moc ../texturesExample.h)  
add_executable( texturesExample ../texturesExample.cpp ${texturesExample_moc} )
target_link_libraries( texturesExample
Sylvain Thery's avatar
Sylvain Thery committed
39
		${CGoGN_LIBS_R} ${CGoGN_EXT_LIBS} )
40

41 42 43
QT4_WRAP_CPP(simpleGMap2_moc ../simpleGMap2.h)  
add_executable( simpleGMap2 ../simpleGMap2.cpp ${simpleGMap2_moc} )
target_link_libraries( simpleGMap2
Sylvain Thery's avatar
Sylvain Thery committed
44
                ${CGoGN_LIBS_R} ${CGoGN_EXT_LIBS} )
45 46 47 48

QT4_WRAP_CPP(simpleGMap3_moc ../simpleGMap3.h)  
add_executable( simpleGMap3 ../simpleGMap3.cpp ${simpleGMap3_moc} )
target_link_libraries( simpleGMap3
Sylvain Thery's avatar
Sylvain Thery committed
49
                ${CGoGN_LIBS_R} ${CGoGN_EXT_LIBS} )
50
                
51 52
QT4_WRAP_CPP(extrusionView_moc ../extrusionView.h)	
add_executable( extrusionView ../extrusionView.cpp ${extrusionView_moc})
53
target_link_libraries( extrusionView
Sylvain Thery's avatar
Sylvain Thery committed
54
		${CGoGN_LIBS_R} ${CGoGN_EXT_LIBS}  )
Pierre Kraemer's avatar
Pierre Kraemer committed
55 56 57 58 59

QT4_WRAP_UI( viewer_ui ../viewer.ui )
QT4_WRAP_CPP( viewer_moc ../viewer.h )
add_executable( viewer ../viewer.cpp ${viewer_moc} ${viewer_ui})
target_link_libraries( viewer
Sylvain Thery's avatar
Sylvain Thery committed
60
	${CGoGN_LIBS_R} ${NUMERICAL_LIBS} ${CGoGN_EXT_LIBS} )
Pierre Kraemer's avatar
Pierre Kraemer committed
61

62 63 64 65
QT4_WRAP_UI( clipping_ui ../clipping.ui )
QT4_WRAP_CPP( clipping_moc ../clipping.h )
add_executable( clipping ../clipping.cpp ${clipping_ui} ${clipping_moc})
target_link_libraries( clipping
Sylvain Thery's avatar
Sylvain Thery committed
66
	${CGoGN_LIBS_R}  ${CGoGN_EXT_LIBS}  )
67 68 69 70 71 72 73

QT4_WRAP_UI( volumeExplorer_ui ../volumeExplorer.ui )
QT4_WRAP_CPP( volumeExplorer_moc ../volumeExplorer.h )
add_executable( volumeExplorer ../volumeExplorer.cpp ${volumeExplorer_ui} ${volumeExplorer_moc})
target_link_libraries( volumeExplorer
	${CGoGN_LIBS_R}  ${CGoGN_EXT_LIBS}  )