2023-01-09 23:15:51 +01:00
|
|
|
vcpkg_minimum_required(VERSION 2022-10-12) # for ${VERSION}
|
2019-10-07 19:35:13 +02:00
|
|
|
|
2022-05-06 11:20:25 -07:00
|
|
|
vcpkg_from_gitlab(
|
|
|
|
GITLAB_URL https://gitlab.gnome.org/
|
2019-09-18 02:34:55 +08:00
|
|
|
OUT_SOURCE_PATH SOURCE_PATH
|
2022-05-06 11:20:25 -07:00
|
|
|
REPO GNOME/atk
|
2023-01-09 23:15:51 +01:00
|
|
|
REF "${VERSION}"
|
2022-05-06 11:20:25 -07:00
|
|
|
HEAD_REF master
|
|
|
|
SHA512 f31951ecbdace6a18fb9f772616137cb8732163b37448fef4daf1af60ba8479c94d498dcdaf4880468c80012c77a446da585926a99704a9a940b80e546080cf3
|
2019-09-18 02:34:55 +08:00
|
|
|
)
|
2019-05-02 22:57:43 -07:00
|
|
|
|
2023-01-17 19:44:20 +00:00
|
|
|
if("introspection" IN_LIST FEATURES)
|
|
|
|
list(APPEND OPTIONS_DEBUG -Dintrospection=false)
|
|
|
|
list(APPEND OPTIONS_RELEASE -Dintrospection=true)
|
|
|
|
else()
|
|
|
|
list(APPEND OPTIONS -Dintrospection=false)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
if(CMAKE_HOST_WIN32 AND VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
|
|
|
|
set(GIR_TOOL_DIR ${CURRENT_INSTALLED_DIR})
|
|
|
|
else()
|
|
|
|
set(GIR_TOOL_DIR ${CURRENT_HOST_INSTALLED_DIR})
|
|
|
|
endif()
|
|
|
|
|
2021-04-26 19:28:21 +02:00
|
|
|
vcpkg_configure_meson(
|
2022-05-06 11:20:25 -07:00
|
|
|
SOURCE_PATH "${SOURCE_PATH}"
|
2023-01-09 23:15:51 +01:00
|
|
|
OPTIONS
|
2023-01-17 19:44:20 +00:00
|
|
|
${OPTIONS}
|
|
|
|
OPTIONS_DEBUG
|
|
|
|
${OPTIONS_DEBUG}
|
|
|
|
OPTIONS_RELEASE
|
|
|
|
${OPTIONS_RELEASE}
|
2023-01-09 23:15:51 +01:00
|
|
|
ADDITIONAL_BINARIES
|
|
|
|
"glib-genmarshal='${CURRENT_HOST_INSTALLED_DIR}/tools/glib/glib-genmarshal'"
|
|
|
|
"glib-mkenums='${CURRENT_HOST_INSTALLED_DIR}/tools/glib/glib-mkenums'"
|
2023-01-17 19:44:20 +00:00
|
|
|
"g-ir-compiler='${CURRENT_HOST_INSTALLED_DIR}/tools/gobject-introspection/g-ir-compiler${VCPKG_HOST_EXECUTABLE_SUFFIX}'"
|
|
|
|
"g-ir-scanner='${GIR_TOOL_DIR}/tools/gobject-introspection/g-ir-scanner'"
|
2021-04-26 19:28:21 +02:00
|
|
|
)
|
2023-01-17 19:44:20 +00:00
|
|
|
vcpkg_install_meson(ADD_BIN_TO_PATH)
|
2019-05-02 22:57:43 -07:00
|
|
|
|
|
|
|
vcpkg_copy_pdbs()
|
|
|
|
|
2020-12-07 19:27:33 +03:00
|
|
|
vcpkg_fixup_pkgconfig()
|
2023-01-09 23:15:51 +01:00
|
|
|
|
|
|
|
if(VCPKG_LIBRARY_LINKAGE STREQUAL "static")
|
|
|
|
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/atk-1.0/atk/atkmisc.h" "ifdef ATK_STATIC_COMPILATION" "if 1")
|
|
|
|
endif()
|
|
|
|
|
2021-04-26 19:28:21 +02:00
|
|
|
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
|
2023-07-17 22:02:56 +02:00
|
|
|
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")
|