From 41e55025e17b2f8e17294bc8cff7b47e8f6af1f7 Mon Sep 17 00:00:00 2001 From: David Faure Date: Wed, 1 Jan 2014 11:35:56 +0100 Subject: Generate forward headers. Install them in the proper directory. Let cmake find them. Had to rename conversion_check.h to conversioncheck.h Had to improve the scripts to support multiple libs in one framework :) --- src/gui/CMakeLists.txt | 31 +++++++++++++++++-------------- 1 file changed, 17 insertions(+), 14 deletions(-) (limited to 'src/gui') diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt index 974b05cc..eef8c2a8 100644 --- a/src/gui/CMakeLists.txt +++ b/src/gui/CMakeLists.txt @@ -15,27 +15,30 @@ add_library(KF5ConfigGui ${libkconfiggui_SRCS}) generate_export_header(KF5ConfigGui BASE_NAME KConfigGui) add_library(KF5::ConfigGui ALIAS KF5ConfigGui) -target_link_libraries(KF5ConfigGui PUBLIC Qt5::Gui Qt5::Xml KF5::ConfigCore) +target_include_directories(KF5ConfigGui INTERFACE "$" "$") -if(IS_ABSOLUTE "${INCLUDE_INSTALL_DIR}") - target_include_directories(KF5ConfigGui INTERFACE "$" ) -else() - target_include_directories(KF5ConfigGui INTERFACE "$" ) -endif() +target_link_libraries(KF5ConfigGui PUBLIC Qt5::Gui Qt5::Xml KF5::ConfigCore) set_target_properties(KF5ConfigGui PROPERTIES VERSION ${KCONFIG_VERSION_STRING} SOVERSION ${KCONFIG_SOVERSION} EXPORT_NAME ConfigGui ) +ecm_generate_headers( + KConfigGui + KConfigLoader + KConfigSkeleton + KStandardShortcut + KWindowConfig + + MODULE_NAME KConfigGui REQUIRED_HEADERS KConfigGui_HEADERS +) +install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/KConfigGui DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel) + install(TARGETS KF5ConfigGui EXPORT KF5ConfigTargets ${INSTALL_TARGETS_DEFAULT_ARGS}) -install( FILES - ${CMAKE_CURRENT_BINARY_DIR}/kconfiggui_export.h - kconfiggui.h - kconfigloader.h - kconfigskeleton.h - kstandardshortcut.h - kwindowconfig.h - DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel +install(FILES + ${CMAKE_CURRENT_BINARY_DIR}/kconfiggui_export.h + ${KConfigGui_HEADERS} + DESTINATION ${INCLUDE_INSTALL_DIR}/kconfiggui COMPONENT Devel ) -- cgit v1.2.1