[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kde4support] /: Generate forward headers.
From:       David Faure <faure () kde ! org>
Date:       2014-02-28 13:11:51
Message-ID: E1WJNEF-0002gJ-Uf () scm ! kde ! org
[Download RAW message or body]

Git commit 6e4d571a30fbaf876fb09092bcb7c6b368673e78 by David Faure.
Committed on 01/01/2014 at 21:00.
Pushed by alexmerry into branch 'master'.

Generate forward headers.

Install them in the proper directory.
Let cmake find them.

Perl rocks.

Add missing dependency

M  +2    -0    CMakeLists.txt
M  +17   -5    src/CMakeLists.txt

http://commits.kde.org/kde4support/6e4d571a30fbaf876fb09092bcb7c6b368673e78

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 40f7cfe..b195099 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -17,6 +17,7 @@ set(HAVE_X11 ${X11_FOUND})
 =

 include(FeatureSummary)
 include(ECMSetupVersion)
+include(ECMGenerateHeaders)
 =

 set(KF5_VERSION "5.0.0")
 ecm_setup_version(${KF5_VERSION} VARIABLE_PREFIX KPRINTUTILS
@@ -39,6 +40,7 @@ if ("${CMAKE_BINARY_DIR}" STREQUAL "${CMAKE_CURRENT_BINAR=
Y_DIR}")
   find_package(KF5TextWidgets ${KF5_VERSION} REQUIRED)
   find_package(KF5CoreAddons ${KF5_VERSION} REQUIRED)
   find_package(KF5Parts ${KF5_VERSION} REQUIRED)
+  find_package(KF5XmlGui ${KF5_VERSION} REQUIRED)
 endif()
 =

 add_subdirectory(src)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 6aa3279..3c49ea1 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -30,6 +30,8 @@ add_library(KF5PrintUtils ${kprintutils_LIB_SRCS})
 generate_export_header(KF5PrintUtils BASE_NAME KPrintUtils)
 add_library(KF5::PrintUtils ALIAS KF5PrintUtils)
 =

+target_include_directories(KF5PrintUtils INTERFACE "$<INSTALL_INTERFACE:${=
INCLUDE_INSTALL_DIR}/kprintutils>" "$<INSTALL_INTERFACE:${INCLUDE_INSTALL_D=
IR}/KPrintUtils>")
+
 target_link_libraries(KF5PrintUtils
   PUBLIC
     Qt5::Widgets
@@ -44,11 +46,21 @@ set_target_properties(KF5PrintUtils PROPERTIES
                       EXPORT_NAME PrintUtils
 )
 =

-install( FILES
- ${CMAKE_CURRENT_BINARY_DIR}/kprintutils_export.h
- kdeprintdialog.h
- kprintpreview.h
- DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel)
+ecm_generate_headers(
+  KPrintPreview
+  KDEPrintDialog
+
+  MODULE_NAME KPrintUtils
+  REQUIRED_HEADERS KPrintUtils_HEADERS
+)
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/KPrintUtils DESTINATION ${IN=
CLUDE_INSTALL_DIR} COMPONENT Devel)
+
+install(FILES
+  ${CMAKE_CURRENT_BINARY_DIR}/kprintutils_export.h
+  kdeprintdialog.h
+  ${KPrintUtils_HEADERS}
+  DESTINATION ${INCLUDE_INSTALL_DIR}/kprintutils COMPONENT Devel
+)
 =

 install(TARGETS KF5PrintUtils EXPORT KF5PrintUtilsTargets ${INSTALL_TARGET=
S_DEFAULT_ARGS})
 =


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic