Commit f2272c3d authored by Andreas Pakulat's avatar Andreas Pakulat

Move the code into a subdirectory suitable for importing into kdevelop

This moves the code into a subdirectory so it can be imported into
kdevelop without loosing the history. Also needed to adjust references to
CMAKE_(SOURCE|BINARY)_DIR to point to the project dir to make it build.
parent 1ff0aaed
project(kdevelop4-custom-buildsystem)
set(KDE4_BUILD_TESTS "ON" CACHE "BOOL" "Enable building of tests" FORCE )
find_package(KDE4 4.5.0 REQUIRED)
include(KDE4Defaults)
include(MacroLibrary)
find_package(KDevPlatform 1.4.60 REQUIRED)
if(KDevPlatform_VERSION VERSION_GREATER 1.5.59)
MESSAGE(FATAL_ERROR "This version of the plugin doesn't work with KDevPlatform 1.6, version 1.5 is required")
endif(KDevPlatform_VERSION VERSION_GREATER 1.5.59)
set(CUSTOM_BUILDSYSTEM_VERSION 1.2.3)
include_directories( ${KDE4_INCLUDES} ${KDEVPLATFORM_INCLUDE_DIR})
add_definitions( ${QT_DEFINITIONS} ${KDE4_DEFINITIONS} -DCUSTOM_BUILDSYSTEM_VERSION=\\\"${CUSTOM_BUILDSYSTEM_VERSION}\\\" )
## Unittests
add_subdirectory( tests )
## KDevelop Plugin
set( custom_SRCS custombuildsystemplugin.cpp custombuildjob.cpp )
kde4_add_plugin( kdevcustombuildsystem ${custom_SRCS} )
target_link_libraries( kdevcustombuildsystem
${KDEVPLATFORM_PROJECT_LIBRARIES}
${KDEVPLATFORM_INTERFACES_LIBRARIES}
${KDEVPLATFORM_UTIL_LIBRARIES}
${KDEVPLATFORM_OUTPUTVIEW_LIBRARIES}
)
## KCM for the Plugin
set( custom_kcm_SRCS
projectpathsmodel.cpp
definesmodel.cpp
includesmodel.cpp
configwidget.cpp
custombuildsystemconfigwidget.cpp
kcm_custombuildsystem.cpp
)
kde4_add_ui_files( custom_kcm_SRCS configwidget.ui custombuildsystemconfigwidget.ui )
kde4_add_kcfg_files( custom_kcm_SRCS kcfg_custombuildsystemconfig.kcfgc )
kde4_add_plugin( kcm_kdevcustombuildsystem ${custom_kcm_SRCS} )
target_link_libraries( kcm_kdevcustombuildsystem ${KDE4_KIO_LIBS} ${KDEVPLATFORM_INTERFACES_LIBRARIES} ${KDEVPLATFORM_LANGUAGE_LIBRARIES} ${KDEVPLATFORM_PROJECT_LIBRARIES} ${KDEVPLATFORM_UTIL_LIBRARIES} )
## Installation
install( TARGETS kcm_kdevcustombuildsystem
kdevcustombuildsystem
DESTINATION ${PLUGIN_INSTALL_DIR} )
install( FILES kdevcustombuildsystem.desktop
kcm_kdevcustombuildsystem.desktop
DESTINATION ${SERVICES_INSTALL_DIR} )
include(CTest)
# CTestCustom.cmake has to be in the CTEST_BINARY_DIR.
# in the KDE build system, this is the same as CMAKE_BINARY_DIR.
configure_file(${CMAKE_SOURCE_DIR}/CTestCustom.cmake ${CMAKE_BINARY_DIR}/CTestCustom.cmake)
add_subdirectory(projectmanagers)
add_subdirectory(custom-buildsystem)
project(kdevelop4-custom-buildsystem)
set(KDE4_BUILD_TESTS "ON" CACHE "BOOL" "Enable building of tests" FORCE )
find_package(KDE4 4.5.0 REQUIRED)
include(KDE4Defaults)
include(MacroLibrary)
find_package(KDevPlatform 1.4.60 REQUIRED)
if(KDevPlatform_VERSION VERSION_GREATER 1.5.59)
MESSAGE(FATAL_ERROR "This version of the plugin doesn't work with KDevPlatform 1.6, version 1.5 is required")
endif(KDevPlatform_VERSION VERSION_GREATER 1.5.59)
set(CUSTOM_BUILDSYSTEM_VERSION 1.2.3)
include_directories( ${KDE4_INCLUDES} ${KDEVPLATFORM_INCLUDE_DIR})
add_definitions( ${QT_DEFINITIONS} ${KDE4_DEFINITIONS} -DCUSTOM_BUILDSYSTEM_VERSION=\\\"${CUSTOM_BUILDSYSTEM_VERSION}\\\" )
## Unittests
add_subdirectory( tests )
## KDevelop Plugin
set( custom_SRCS custombuildsystemplugin.cpp custombuildjob.cpp )
kde4_add_plugin( kdevcustombuildsystem ${custom_SRCS} )
target_link_libraries( kdevcustombuildsystem
${KDEVPLATFORM_PROJECT_LIBRARIES}
${KDEVPLATFORM_INTERFACES_LIBRARIES}
${KDEVPLATFORM_UTIL_LIBRARIES}
${KDEVPLATFORM_OUTPUTVIEW_LIBRARIES}
)
## KCM for the Plugin
set( custom_kcm_SRCS
projectpathsmodel.cpp
definesmodel.cpp
includesmodel.cpp
configwidget.cpp
custombuildsystemconfigwidget.cpp
kcm_custombuildsystem.cpp
)
kde4_add_ui_files( custom_kcm_SRCS configwidget.ui custombuildsystemconfigwidget.ui )
kde4_add_kcfg_files( custom_kcm_SRCS kcfg_custombuildsystemconfig.kcfgc )
kde4_add_plugin( kcm_kdevcustombuildsystem ${custom_kcm_SRCS} )
target_link_libraries( kcm_kdevcustombuildsystem ${KDE4_KIO_LIBS} ${KDEVPLATFORM_INTERFACES_LIBRARIES} ${KDEVPLATFORM_LANGUAGE_LIBRARIES} ${KDEVPLATFORM_PROJECT_LIBRARIES} ${KDEVPLATFORM_UTIL_LIBRARIES} )
## Installation
install( TARGETS kcm_kdevcustombuildsystem
kdevcustombuildsystem
DESTINATION ${PLUGIN_INSTALL_DIR} )
install( FILES kdevcustombuildsystem.desktop
kcm_kdevcustombuildsystem.desktop
DESTINATION ${SERVICES_INSTALL_DIR} )
include(CTest)
# CTestCustom.cmake has to be in the CTEST_BINARY_DIR.
# in the KDE build system, this is the same as kdevelop4-custom-buildsystem_BINARY_DIR.
configure_file(${kdevelop4-custom-buildsystem_SOURCE_DIR}/CTestCustom.cmake ${kdevelop4-custom-buildsystem_BINARY_DIR}/CTestCustom.cmake)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment