Warning, /pim/mimetreeparser/src/widgets/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 # SPDX-FileCopyrightText: 2023 g10 Code GmbH 0002 # SPDX-FileContributor: Carl Schwan <carlschwan@kde.org> 0003 # SPDX-License-Identifier: BSD-3-Clause 0004 0005 ecm_setup_version(PROJECT 0006 VARIABLE_PREFIX MIMETREEPARSER_WIDGETS 0007 VERSION_HEADER "${CMAKE_CURRENT_BINARY_DIR}/mimetreeparser_widgets_version.h" 0008 PACKAGE_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/KPim6MimeTreeParserWidgetsConfigVersion.cmake" 0009 SOVERSION 6 0010 ) 0011 0012 add_library(KPim6MimeTreeParserWidgets) 0013 add_library(KPim6::MimeTreeParserWidgets 0014 ALIAS KPim6MimeTreeParserWidgets) 0015 0016 target_sources(KPim6MimeTreeParserWidgets PRIVATE 0017 attachmentview_p.h 0018 attachmentview.cpp 0019 messagecontainerwidget_p.h 0020 messagecontainerwidget.cpp 0021 messageviewer.h 0022 messageviewer.cpp 0023 messageviewerdialog.h 0024 messageviewerdialog.cpp 0025 urlhandler_p.h 0026 urlhandler.cpp 0027 ) 0028 0029 ecm_qt_declare_logging_category(KPim6MimeTreeParserWidgets 0030 HEADER mimetreeparser_widgets_debug.h 0031 IDENTIFIER MIMETREEPARSER_WIDGET_LOG 0032 CATEGORY_NAME org.kde.pim.mimetreeparser.widgets 0033 DESCRIPTION "mimetreeparser (pim lib)" 0034 EXPORT MIMETREEPARSER 0035 ) 0036 0037 if (COMPILE_WITH_UNITY_CMAKE_SUPPORT) 0038 set_target_properties(KPim6MimeTreeParserWidgets PROPERTIES UNITY_BUILD ON) 0039 endif() 0040 generate_export_header(KPim6MimeTreeParserWidgets BASE_NAME mimetreeparser_widgets) 0041 0042 0043 target_include_directories(KPim6MimeTreeParserWidgets INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR}/KPim6/MimeTreeParserWidgets>") 0044 0045 target_link_libraries(KPim6MimeTreeParserWidgets 0046 PUBLIC 0047 Qt6::Widgets 0048 KPim6::MimeTreeParserCore 0049 PRIVATE 0050 Qt6::PrintSupport 0051 KF6::Codecs 0052 KF6::I18n 0053 KF6::CalendarCore 0054 KF6::WidgetsAddons 0055 KPim6::Libkleo 0056 Gpgmepp 0057 ) 0058 0059 set_target_properties(KPim6MimeTreeParserWidgets PROPERTIES 0060 VERSION ${MIMETREEPARSER_WIDGETS_VERSION} 0061 SOVERSION ${MIMETREEPARSER_WIDGETS_SOVERSION} 0062 EXPORT_NAME MimeTreeParserWidgets 0063 ) 0064 0065 ecm_generate_pri_file(BASE_NAME MimeTreeParserWidgets 0066 LIB_NAME KPim6MimeTreeParserWidgets 0067 DEPS "MimeTreeParserWidgets" 0068 FILENAME_VAR PRI_FILENAME 0069 ) 0070 0071 install(FILES ${PRI_FILENAME} DESTINATION ${ECM_MKSPECS_INSTALL_DIR}) 0072 0073 install(TARGETS 0074 KPim6MimeTreeParserWidgets 0075 EXPORT KPim6MimeTreeParserWidgetsTargets ${KDE_INSTALL_TARGETS_DEFAULT_ARGS} 0076 ) 0077 0078 ecm_generate_headers(MimeTreeParserWidgets_CamelCase_HEADERS 0079 HEADER_NAMES 0080 MessageViewer 0081 MessageViewerDialog 0082 REQUIRED_HEADERS MimeTreeParserWidgets_HEADERS 0083 PREFIX MimeTreeParserWidgets 0084 ) 0085 0086 install(FILES 0087 ${MimeTreeParserWidgets_CamelCase_HEADERS} 0088 DESTINATION ${KDE_INSTALL_INCLUDEDIR}/KPim6/MimeTreeParserWidgets/MimeTreeParserWidgets 0089 COMPONENT Devel 0090 ) 0091 install(FILES 0092 ${CMAKE_CURRENT_BINARY_DIR}/mimetreeparser_widgets_export.h 0093 ${MimeTreeParserWidgets_HEADERS} 0094 DESTINATION ${KDE_INSTALL_INCLUDEDIR}/KPim6/MimeTreeParserWidgets/mimetreeparserwidgets 0095 COMPONENT Devel 0096 ) 0097 0098 if (BUILD_QCH) 0099 ecm_add_qch( 0100 KPim6MimeTreeParserWidgets_QCH 0101 NAME MimeTreeParserWidgets 0102 BASE_NAME KPim6MimeTreeParserWidgets 0103 VERSION ${PIM_VERSION} 0104 ORG_DOMAIN org.kde 0105 # using only public headers, to cover only public API 0106 SOURCES ${MimeTreeParserWidgets_HEADERS} 0107 MD_MAINPAGE "${CMAKE_SOURCE_DIR}/README.md" 0108 LINK_QCHS 0109 Qt6Core_QCH 0110 INCLUDE_DIRS 0111 ${CMAKE_CURRENT_BINARY_DIR} 0112 BLANK_MACROS 0113 MIMETREEPARSER_WIDGETS_EXPORT 0114 TAGFILE_INSTALL_DESTINATION ${KDE_INSTALL_QTQCHDIR} 0115 QCH_INSTALL_DESTINATION ${KDE_INSTALL_QTQCHDIR} 0116 COMPONENT Devel 0117 ) 0118 endif() 0119 0120 ########### CMake Config Files ########### 0121 set(CMAKECONFIG_INSTALL_DIR "${KDE_INSTALL_CMAKEPACKAGEDIR}/KPim6MimeTreeParserWidgets") 0122 0123 if (BUILD_QCH) 0124 ecm_install_qch_export( 0125 TARGETS KPim6MimeTreeParserWidgets_QCH 0126 FILE KPim6MimeTreeParserWidgetsQchTargets.cmake 0127 DESTINATION "${CMAKECONFIG_INSTALL_DIR}" 0128 COMPONENT Devel 0129 ) 0130 set(PACKAGE_INCLUDE_QCHTARGETS "include(\"\${CMAKE_CURRENT_LIST_DIR}/KPim6MimeTreeParserWidgetsQchTargets.cmake\")") 0131 endif() 0132 0133 configure_package_config_file( 0134 "${CMAKE_CURRENT_SOURCE_DIR}/KPimMimeTreeParserWidgetsConfig.cmake.in" 0135 "${CMAKE_CURRENT_BINARY_DIR}/KPim6MimeTreeParserWidgetsConfig.cmake" 0136 INSTALL_DESTINATION ${CMAKECONFIG_INSTALL_DIR} 0137 ) 0138 0139 install(FILES 0140 "${CMAKE_CURRENT_BINARY_DIR}/KPim6MimeTreeParserWidgetsConfig.cmake" 0141 "${CMAKE_CURRENT_BINARY_DIR}/KPim6MimeTreeParserWidgetsConfigVersion.cmake" 0142 DESTINATION "${CMAKECONFIG_INSTALL_DIR}" 0143 COMPONENT Devel 0144 ) 0145 0146 install(EXPORT KPim6MimeTreeParserWidgetsTargets 0147 DESTINATION "${CMAKECONFIG_INSTALL_DIR}" 0148 FILE KPim6MimeTreeParserWidgetsTargets.cmake 0149 NAMESPACE KPim6:: 0150 ) 0151 0152 install(FILES 0153 ${CMAKE_CURRENT_BINARY_DIR}/mimetreeparser_widgets_version.h 0154 DESTINATION ${KDE_INSTALL_INCLUDEDIR}/KPim6/MimeTreeParserWidgets 0155 COMPONENT Devel 0156 )