CMakeLists.txt 1.53 KB
Newer Older
1 2 3 4
cmake_minimum_required(VERSION 2.8)

INCLUDE_DIRECTORIES(
	${SCHNApps_ROOT_DIR}/include
5
	${SCHNApps_ROOT_DIR}/Plugins/importSurface
6 7 8 9
	${CMAKE_CURRENT_BINARY_DIR}
)

SET( PLUGIN_SRC
10
    ${SCHNApps_ROOT_DIR}/Plugins/importSurface/importSurface.cpp
11 12 13
)

SET( PLUGIN_H
14
    ${SCHNApps_ROOT_DIR}/Plugins/importSurface/importSurface.h
15 16 17 18 19 20 21 22 23 24 25 26
)

IF( ${CMAKE_BUILD_TYPE} STREQUAL Debug )

	ADD_DEFINITIONS(-DDEBUG)

	IF(WIN32)
		link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
	ELSE (WIN32)
		link_directories( ${CGoGN_ROOT_DIR}/lib/Debug ${CGoGN_ROOT_DIR}/lib/Release )
	ENDIF (WIN32)

Pierre Kraemer's avatar
Pierre Kraemer committed
27
#	QT4_WRAP_UI( PLUGIN_UI ${PLUGIN_FORM} )
28
	QT4_WRAP_CPP( PLUGIN_MOC ${PLUGIN_H} )
Pierre Kraemer's avatar
Pierre Kraemer committed
29
	
30
	ADD_LIBRARY( ImportSurfacePluginD SHARED
31 32 33 34 35
		${PLUGIN_SRC}
		${PLUGIN_UI}
		${PLUGIN_MOC}
	)

36
	TARGET_LINK_LIBRARIES( ImportSurfacePluginD
37 38 39 40 41
		${CGoGN_LIBS_D}
		${COMMON_LIBS}
		${QGLVIEWER_LIBRARIES}
	)

42
	ADD_DEPENDENCIES( ImportSurfacePluginD SCHNAppsD )
43

44
	SET_TARGET_PROPERTIES( ImportSurfacePluginD PROPERTIES COMPILE_DEFINITIONS "DEBUG" )
45 46 47 48 49 50 51 52 53
		
ELSE ( ${CMAKE_BUILD_TYPE} STREQUAL Debug )
	
	IF(WIN32)
	link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
	ELSE (WIN32)
		link_directories( ${CGoGN_ROOT_DIR}/lib/Release )
	ENDIF (WIN32)

Pierre Kraemer's avatar
Pierre Kraemer committed
54
#	QT4_WRAP_UI( PLUGIN_UI ${PLUGIN_FORM} )
55 56
	QT4_WRAP_CPP( PLUGIN_MOC ${PLUGIN_H} )

57
	ADD_LIBRARY( ImportSurfacePlugin SHARED
58 59 60 61 62
		${PLUGIN_SRC}
		${PLUGIN_UI}
		${PLUGIN_MOC}
	)

63
	TARGET_LINK_LIBRARIES( ImportSurfacePlugin
64 65 66 67 68
		${CGoGN_LIBS_R}
		${COMMON_LIBS}
		${QGLVIEWER_LIBRARIES}
	)

69
	ADD_DEPENDENCIES( ImportSurfacePlugin SCHNApps )
70 71
	
ENDIF ( ${CMAKE_BUILD_TYPE} STREQUAL Debug )