Warning, /graphics/glaxnimate/external/Qt-Color-Widgets/cmake/install.cmake is written in an unsupported language. File is not indexed.
0001 # SPDX-FileCopyrightText: 2013-2023 Mattia Basaglia <dev@dragon.best> 0002 # SPDX-License-Identifier: BSD-2-Clause 0003 0004 function (install_project 0005 PROJECT_NAME i_project_name 0006 TARGET_NAME i_target_name 0007 TARGET_OUTPUT_SUFFIX i_target_output_suffix 0008 EXPORT_HEADER i_export_header 0009 INCLUDE_PREFIX i_include_prefix 0010 HEADER_MATCHING_REGEX i_header_matching_regex 0011 VERSION_HEADER i_version_header 0012 NAMESPACE i_namespace) 0013 0014 include(GNUInstallDirs) 0015 0016 install (TARGETS ${i_target_name} 0017 EXPORT ${i_target_name} 0018 RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} 0019 INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} 0020 ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} 0021 LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}) 0022 0023 install (DIRECTORY include/ 0024 DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} 0025 FILES_MATCHING 0026 REGEX ${i_header_matching_regex} 0027 REGEX "CMakeLists\.txt" EXCLUDE) 0028 0029 install (FILES ${i_version_header} 0030 DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${i_include_prefix} 0031 COMPONENT Devel) 0032 0033 install (FILES include/${i_export_header} 0034 DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${i_include_prefix} 0035 COMPONENT Devel) 0036 0037 install( 0038 EXPORT ${i_target_name} 0039 DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${i_target_name}${i_target_output_suffix} 0040 FILE "${i_target_name}${i_target_output_suffix}.cmake" 0041 COMPONENT Devel) 0042 0043 0044 include(CMakePackageConfigHelpers) 0045 0046 string (TOLOWER ${i_target_name} CMAKE_BASE_FILE_NAME) 0047 string (TOLOWER "${i_target_output_suffix}" CMAKE_FILE_OUTPUT_SUFFIX) 0048 0049 write_basic_package_version_file( 0050 "${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}/${CMAKE_BASE_FILE_NAME}${CMAKE_FILE_OUTPUT_SUFFIX}-config-version.cmake" 0051 VERSION ${${i_project_name}_VERSION} 0052 COMPATIBILITY SameMajorVersion 0053 ) 0054 0055 export(EXPORT ${i_target_name} 0056 FILE "${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}/${CMAKE_BASE_FILE_NAME}${CMAKE_FILE_OUTPUT_SUFFIX}-targets.cmake" 0057 ) 0058 0059 configure_file("cmake/${i_project_name}-config.cmake" 0060 "${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}/${CMAKE_BASE_FILE_NAME}${CMAKE_FILE_OUTPUT_SUFFIX}-config.cmake" 0061 @ONLY 0062 ) 0063 0064 set(ConfigPackageLocation "${CMAKE_INSTALL_LIBDIR}/cmake/${i_target_name}${i_target_output_suffix}") 0065 install(EXPORT ${i_target_name} 0066 FILE 0067 "${CMAKE_BASE_FILE_NAME}${CMAKE_FILE_OUTPUT_SUFFIX}-targets.cmake" 0068 NAMESPACE 0069 "${i_namespace}" 0070 DESTINATION 0071 ${ConfigPackageLocation} 0072 ) 0073 install( 0074 FILES 0075 "${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}/${CMAKE_BASE_FILE_NAME}${CMAKE_FILE_OUTPUT_SUFFIX}-config.cmake" 0076 "${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}/${CMAKE_BASE_FILE_NAME}${CMAKE_FILE_OUTPUT_SUFFIX}-config-version.cmake" 0077 DESTINATION 0078 ${ConfigPackageLocation} 0079 COMPONENT 0080 Devel 0081 ) 0082 0083 configure_file( 0084 ${CMAKE_CURRENT_SOURCE_DIR}/${i_project_name}.pc.in 0085 ${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}${i_target_output_suffix}.pc 0086 @ONLY 0087 ) 0088 0089 install(FILES 0090 ${CMAKE_CURRENT_BINARY_DIR}/${i_target_name}${i_target_output_suffix}.pc 0091 DESTINATION 0092 ${CMAKE_INSTALL_LIBDIR}/pkgconfig 0093 ) 0094 endfunction (install_project)