Changeset View
Changeset View
Standalone View
Standalone View
CMakeLists.txt
Show All 40 Lines | |||||
41 | include(KDECMakeSettings) | 41 | include(KDECMakeSettings) | ||
42 | 42 | | |||
43 | find_package(LibIntl) | 43 | find_package(LibIntl) | ||
44 | set_package_properties(LibIntl PROPERTIES TYPE REQUIRED | 44 | set_package_properties(LibIntl PROPERTIES TYPE REQUIRED | ||
45 | URL "http://gnuwin32.sourceforge.net/packages/libintl.htm" | 45 | URL "http://gnuwin32.sourceforge.net/packages/libintl.htm" | ||
46 | PURPOSE "Needed for building KI18n unless glibc is the system libc implementation" | 46 | PURPOSE "Needed for building KI18n unless glibc is the system libc implementation" | ||
47 | ) | 47 | ) | ||
48 | 48 | | |||
49 | # KF5I18NMacros.cmake only needs to know the python executable path. | ||||
50 | # Due to CMake caching the variables, and KF5I18NMacros being included by KF5I18nConfig, | ||||
51 | # we have to hardcode the PYTHON_EXECUTABLE path or anything depending on KF5I18n | ||||
52 | # would be unable to find another Python version. | ||||
53 | find_package(PythonInterp REQUIRED) | ||||
54 | configure_file(cmake/KF5I18NMacros.cmake.in ${KI18n_BINARY_DIR}/cmake/KF5I18NMacros.cmake @ONLY) | ||||
55 | | ||||
49 | # usually is called using find_package(KF5I18n), | 56 | # usually is called using find_package(KF5I18n), | ||
50 | # KF5I18NMacros.cmake needs to know the scripts directory | 57 | # KF5I18NMacros.cmake needs to know the scripts directory | ||
51 | set(KF5I18n_DIR ${CMAKE_CURRENT_LIST_DIR}/cmake) | 58 | set(KF5I18n_DIR ${CMAKE_CURRENT_LIST_DIR}/cmake) | ||
52 | include(cmake/KF5I18NMacros.cmake) | 59 | include(${KI18n_BINARY_DIR}/cmake/KF5I18NMacros.cmake) | ||
53 | 60 | | |||
54 | remove_definitions(-DQT_NO_CAST_FROM_BYTEARRAY) | 61 | remove_definitions(-DQT_NO_CAST_FROM_BYTEARRAY) | ||
55 | if(MSVC) | 62 | if(MSVC) | ||
56 | remove_definitions(-DQT_STRICT_ITERATORS) | 63 | remove_definitions(-DQT_STRICT_ITERATORS) | ||
57 | endif() | 64 | endif() | ||
58 | 65 | | |||
59 | option(BUILD_QCH "Build API documentation in QCH format (for e.g. Qt Assistant, Qt Creator & KDevelop)" OFF) | 66 | option(BUILD_QCH "Build API documentation in QCH format (for e.g. Qt Assistant, Qt Creator & KDevelop)" OFF) | ||
60 | add_feature_info(QCH ${BUILD_QCH} "API documentation in QCH format (for e.g. Qt Assistant, Qt Creator & KDevelop)") | 67 | add_feature_info(QCH ${BUILD_QCH} "API documentation in QCH format (for e.g. Qt Assistant, Qt Creator & KDevelop)") | ||
Show All 30 Lines | 95 | install(FILES "${CMAKE_CURRENT_BINARY_DIR}/KF5I18nConfig.cmake" | |||
91 | COMPONENT Devel) | 98 | COMPONENT Devel) | ||
92 | 99 | | |||
93 | install(EXPORT KF5I18nTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE KF5I18nTargets.cmake NAMESPACE KF5::) | 100 | install(EXPORT KF5I18nTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE KF5I18nTargets.cmake NAMESPACE KF5::) | ||
94 | 101 | | |||
95 | install(FILES ${CMAKE_CURRENT_BINARY_DIR}/ki18n_version.h | 102 | install(FILES ${CMAKE_CURRENT_BINARY_DIR}/ki18n_version.h | ||
96 | DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5} COMPONENT Devel) | 103 | DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF5} COMPONENT Devel) | ||
97 | 104 | | |||
98 | install( FILES | 105 | install( FILES | ||
99 | cmake/KF5I18NMacros.cmake | 106 | ${KI18n_BINARY_DIR}/cmake/KF5I18NMacros.cmake | ||
100 | cmake/kf5i18nuic.cmake | 107 | cmake/kf5i18nuic.cmake | ||
101 | cmake/build-pofiles.cmake | 108 | cmake/build-pofiles.cmake | ||
102 | cmake/build-tsfiles.cmake | 109 | cmake/build-tsfiles.cmake | ||
103 | cmake/ts-pmap-compile.py | 110 | cmake/ts-pmap-compile.py | ||
104 | DESTINATION ${CMAKECONFIG_INSTALL_DIR} COMPONENT Devel ) | 111 | DESTINATION ${CMAKECONFIG_INSTALL_DIR} COMPONENT Devel ) | ||
105 | 112 | | |||
106 | feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES) | 113 | feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES) |