source: flair-src/trunk/tools/Dbt2csv/CMakeLists.txt@ 466

Last change on this file since 466 was 302, checked in by Sanahuja Guillaume, 6 years ago

modifs nouveau build system

File size: 1.5 KB
RevLine 
[40]1PROJECT(dbt2csv)
[12]2cmake_minimum_required(VERSION 2.8)
[302]3include($ENV{FLAIR_ROOT}/flair-src/cmake-modules/GlobalCmakeFlair.cmake)
[12]4
[107]5if("${CMAKE_SYSTEM_PROCESSOR}" MATCHES "i686" OR "${CMAKE_SYSTEM_PROCESSOR}" MATCHES "i586" OR "${CMAKE_SYSTEM_PROCESSOR}" MATCHES "x86_64")
[234]6warn("${PROJECT_NAME} is broken since changes in FlairGCS/src/file_ui.cpp")
7return()
[107]8
[12]9SET(PROJECT_SOURCE_FILES
10 src/main.cpp
11 ../FlairGCS/src/file_ui.cpp
12)
13
14SET(FILES_TO_MOC
15 ../FlairGCS/src/file_ui.h
16)
17
18FIND_PACKAGE(Qt4 REQUIRED)
19SET(QT_USE_QTGUI TRUE)
20SET(QT_USE_QTMAIN TRUE)
21INCLUDE(${QT_USE_FILE})
22
23QT4_WRAP_CPP(MOC_SOURCES ${FILES_TO_MOC})
24
25ADD_DEFINITIONS(${QT_DEFINITIONS})
26
27include_directories(
28 ${CMAKE_SOURCE_DIR}/src
29 ../FlairGCS/src/
30 ${QT_INCLUDE_DIR}
[302]31 ${CMAKE_BINARY_DIR}/generated/
[12]32)
33
34LINK_DIRECTORIES (
35 ${QT_LIBRARY_DIR}
36)
37
38ADD_EXECUTABLE(${PROJECT_NAME} ${PROJECT_SOURCE_FILES} ${MOC_SOURCES} ${RCC_SOURCES})
39TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${QT_LIBRARIES} FileLib)
40
41INSTALL(
42 TARGETS ${PROJECT_NAME}
[302]43 RUNTIME DESTINATION $ENV{FLAIR_ROOT}/flair-install/tools/${ARCH_DIR}
[12]44)
45
46add_custom_target(
[45]47 compile_info
[302]48 COMMAND $ENV{FLAIR_ROOT}/flair-src/scripts/compile_info.sh ${CMAKE_C_COMPILER} ${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_BINARY_DIR}/generated/compile_info.h
[12]49)
50
[45]51add_dependencies(${PROJECT_NAME} compile_info)
[12]52
53SET(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin)
[107]54
55else()
56warn("${PROJECT_NAME} will not be built for ${CMAKE_SYSTEM_PROCESSOR} architecture")
57endif()
Note: See TracBrowser for help on using the repository browser.