diff options
Diffstat (limited to 'src/core')
| -rw-r--r-- | src/core/CMakeLists.txt | 42 | ||||
| -rw-r--r-- | src/core/conversioncheck.h (renamed from src/core/conversion_check.h) | 0 | ||||
| -rw-r--r-- | src/core/kconfiggroup.cpp | 4 | ||||
| -rw-r--r-- | src/core/kconfiggroup.h | 2 | 
4 files changed, 26 insertions, 22 deletions
| diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index ea272d31..8b6e52e8 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt @@ -19,35 +19,39 @@ add_library(KF5ConfigCore ${libkconfigcore_SRCS})  generate_export_header(KF5ConfigCore BASE_NAME KConfigCore)  add_library(KF5::ConfigCore ALIAS KF5ConfigCore) +target_include_directories(KF5ConfigCore INTERFACE "$<INSTALL_INTERFACE:${INCLUDE_INSTALL_DIR}/kconfigcore>" "$<INSTALL_INTERFACE:${INCLUDE_INSTALL_DIR}/KConfigCore>") +  target_link_libraries(KF5ConfigCore PUBLIC Qt5::Core)  if(WIN32)      target_link_libraries(KF5ConfigCore PRIVATE ${KDEWIN_LIBRARIES})  endif() -if(IS_ABSOLUTE "${INCLUDE_INSTALL_DIR}") -  target_include_directories(KF5ConfigCore INTERFACE "$<INSTALL_INTERFACE:${INCLUDE_INSTALL_DIR}>" ) -else() -  target_include_directories(KF5ConfigCore INTERFACE "$<INSTALL_INTERFACE:${CMAKE_INSTALL_PREFIX}/${INCLUDE_INSTALL_DIR}>" ) -endif() -  set_target_properties(KF5ConfigCore PROPERTIES VERSION   ${KCONFIG_VERSION_STRING}                                                 SOVERSION ${KCONFIG_SOVERSION}                                                 EXPORT_NAME ConfigCore  ) +ecm_generate_headers( +  KAuthorized +  KConfig +  KConfigBackend +  KConfigBase +  KConfigGroup +  KDesktopFile +  KSharedConfig +  KCoreConfigSkeleton +  KEMailSettings +  ConversionCheck + +  MODULE_NAME KConfigCore +  REQUIRED_HEADERS KConfigCore_HEADERS +) +install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/KConfigCore DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel) +  install(TARGETS KF5ConfigCore EXPORT KF5ConfigTargets ${INSTALL_TARGETS_DEFAULT_ARGS}) -install( FILES -   ${CMAKE_CURRENT_BINARY_DIR}/kconfigcore_export.h -   conversion_check.h -   kconfig.h -   #kconfigbackend.h re-enable post-API review and implementation (4.2?) -   kconfigbase.h -   kconfiggroup.h -   kdesktopfile.h -   ksharedconfig.h -   kcoreconfigskeleton.h -   kauthorized.h -   kemailsettings.h -   DESTINATION ${INCLUDE_INSTALL_DIR} COMPONENT Devel +install(FILES +  ${CMAKE_CURRENT_BINARY_DIR}/kconfigcore_export.h +  ${KConfigCore_HEADERS} +  DESTINATION ${INCLUDE_INSTALL_DIR}/kconfigcore COMPONENT Devel  ) diff --git a/src/core/conversion_check.h b/src/core/conversioncheck.h index 55bd8826..55bd8826 100644 --- a/src/core/conversion_check.h +++ b/src/core/conversioncheck.h diff --git a/src/core/kconfiggroup.cpp b/src/core/kconfiggroup.cpp index c720cc66..14d27f94 100644 --- a/src/core/kconfiggroup.cpp +++ b/src/core/kconfiggroup.cpp @@ -219,7 +219,7 @@ static QString formatError(int expected, int got)  QVariant KConfigGroup::convertToQVariant(const char *pKey, const QByteArray &value, const QVariant &aDefault)  {      // if a type handler is added here you must add a QVConversions definition -    // to conversion_check.h, or ConversionCheck::to_QVariant will not allow +    // to conversioncheck.h, or ConversionCheck::to_QVariant will not allow      // readEntry<T> to convert to QVariant.      switch (aDefault.type()) {      case QVariant::Invalid: @@ -938,7 +938,7 @@ void KConfigGroup::writeEntry(const char *key, const QVariant &value,      QByteArray data;      // if a type handler is added here you must add a QVConversions definition -    // to conversion_check.h, or ConversionCheck::to_QVariant will not allow +    // to conversioncheck.h, or ConversionCheck::to_QVariant will not allow      // writeEntry<T> to convert to QVariant.      switch (value.type()) {      case QVariant::Invalid: diff --git a/src/core/kconfiggroup.h b/src/core/kconfiggroup.h index cc8a51b1..1bcce58f 100644 --- a/src/core/kconfiggroup.h +++ b/src/core/kconfiggroup.h @@ -729,7 +729,7 @@ private:          group.writeEntry(key, QByteArray(M_enum.valueToKeys(value)), flags);        \      } -#include "conversion_check.h" +#include "conversioncheck.h"  template <typename T>  T KConfigGroup::readCheck(const char *key, const T &defaultValue) const | 
