diff options
author | Hugo Lima <hugo.lima@openbossa.org> | 2009-08-17 17:36:11 -0300 |
---|---|---|
committer | Hugo Lima <hugo.lima@openbossa.org> | 2009-08-17 17:36:11 -0300 |
commit | cbac30b07bae6c72be5eefd5e47fe83650a16acd (patch) | |
tree | 5fa8211c6f880c6777188934bd994d1f4359fe5c /CMakeLists.txt |
The genesis...
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 000000000..6c9c3098e --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,54 @@ +project(boostpythongenerator) + +cmake_minimum_required(VERSION 2.6) + +find_package(Qt4 4.5.0 REQUIRED) +find_package(ApiExtractor REQUIRED) + +add_definitions(${QT_DEFINITIONS}) + +set(boostpythongenerator_VERSION 0.1) +configure_file(boostpythongeneratorversion.h.in ${CMAKE_CURRENT_BINARY_DIR}/boostpythongeneratorversion.h @ONLY) +set(CMAKE_BUILD_TYPE Debug) + +set(boostpythongenerator_SRC +boostpythongenerator.cpp +convertergenerator.cpp +docgenerator.cpp +hppgenerator.cpp +cppgenerator.cpp +) + +include_directories(${CMAKE_CURRENT_SOURCE_DIR} + ${CMAKE_CURRENT_BINARY_DIR} + ${APIEXTRACTOR_INCLUDE_DIR} + ${APIEXTRACTOR_INCLUDE_DIR}/.. + ${QT_INCLUDE_DIR} + ${QT_QTCORE_INCLUDE_DIR}) + +add_library(libboostpythongenerator STATIC ${boostpythongenerator_SRC}) +target_link_libraries(libboostpythongenerator + ${APIEXTRACTOR_LIBRARY} + ${QT_QTCORE_LIBRARY} + ${QT_QTXML_LIBRARY}) +add_executable(boostpythongenerator main.cpp) +target_link_libraries(boostpythongenerator libboostpythongenerator) + +# uninstall target +configure_file("${CMAKE_CURRENT_SOURCE_DIR}/cmake_uninstall.cmake" + "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake" + IMMEDIATE @ONLY) +add_custom_target(uninstall "${CMAKE_COMMAND}" + -P "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake") + + +# "make dist", in fact "make package_source" +set(CPACK_SOURCE_PACKAGE_FILE_NAME "boostpythongenerator-${boostpythongenerator_VERSION}") +set(CPACK_SOURCE_GENERATOR TGZ) +set(CPACK_SOURCE_IGNORE_FILES "~$" ".svn" "debian/" "build/" ".swp$" "*.kdev4") +include(CPack) + +install(TARGETS boostpythongenerator DESTINATION bin) + +enable_testing() +add_subdirectory(tests) |