2022-09-20 03:08:27 +08:00
set ( VCPKG_POLICY_EMPTY_INCLUDE_FOLDER enabled )
if ( NOT X_VCPKG_FORCE_VCPKG_X_LIBRARIES AND NOT VCPKG_TARGET_IS_WINDOWS )
message ( STATUS "Utils and libraries provided by '${PORT}' should be provided by your system! Install the required packages or force vcpkg libraries by setting X_VCPKG_FORCE_VCPKG_X_LIBRARIES in your triplet!" )
set ( VCPKG_POLICY_EMPTY_PACKAGE enabled )
else ( )
vcpkg_from_gitlab (
G I T L A B _ U R L h t t p s : / / g i t l a b . f r e e d e s k t o p . o r g / x o r g
O U T _ S O U R C E _ P A T H S O U R C E _ P A T H
R E P O f o n t / u t i l
2023-09-29 14:03:01 +08:00
R E F " f o n t - u t i l - $ { V E R S I O N } "
S H A 5 1 2 9 3 2 8 5 c 2 e 8 c 5 c 0 1 f 0 6 9 a 7 6 2 1 d b a 0 b b b 1 1 7 5 c 0 e b b e a 2 7 d 5 2 1 3 9 5 b 4 0 f 0 3 6 4 4 3 c 1 6 2 f c 1 9 4 8 c 4 d 3 c b 3 4 f e 6 c 5 0 9 d 1 8 1 8 d 9 5 e d 7 e 6 d 3 8 9 1 9 e 3 f 7 8 5 7 d f a 5 3 e 3 8 8 a a d b 9 1 2 8
2022-09-20 03:08:27 +08:00
H E A D _ R E F m a s t e r
P A T C H E S b u i l d . p a t c h
)
set ( ENV{ACLOCAL} "aclocal -I \" ${ CURRENT_INSTALLED_DIR } /share/xorg/aclocal/\ "" )
if ( VCPKG_TARGET_IS_WINDOWS )
list ( APPEND VCPKG_C_FLAGS " /DNEED_BASENAME" )
list ( APPEND VCPKG_CXX_FLAGS " /DNEED_BASENAME" )
endif ( )
vcpkg_configure_make (
S O U R C E _ P A T H " $ { S O U R C E _ P A T H } "
A U T O C O N F I G
)
vcpkg_install_make ( )
vcpkg_fixup_pkgconfig ( )
file ( REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include" )
file ( REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share" )
file ( MAKE_DIRECTORY "${CURRENT_PACKAGES_DIR}/share/xorg/" )
file ( RENAME "${CURRENT_PACKAGES_DIR}/share/${PORT}/aclocal/" "${CURRENT_PACKAGES_DIR}/share/xorg/aclocal" )
file ( RENAME "${CURRENT_PACKAGES_DIR}/share/${PORT}/fonts/" "${CURRENT_PACKAGES_DIR}/share/xorg/fonts" )
file ( REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/debug" )
set ( _file "${CURRENT_PACKAGES_DIR}/lib/pkgconfig/fontutil.pc" )
file ( READ "${_file}" _contents )
string ( REPLACE "datarootdir=\${prefix}/share/${PORT}" "datarootdir=\${prefix}/share/xorg" _contents "${_contents}" )
string ( REPLACE "exec_prefix=\${prefix}" "exec_prefix=\${prefix}/tools/${PORT}" _contents "${_contents}" )
file ( WRITE "${_file}" "${_contents}" )
2022-10-21 01:52:23 +08:00
if ( NOT VCPKG_BUILD_TYPE )
set ( _file "${CURRENT_PACKAGES_DIR}/debug/lib/pkgconfig/fontutil.pc" )
file ( READ "${_file}" _contents )
string ( REPLACE "datarootdir=\${prefix}/share/${PORT}" "datarootdir=\${prefix}/../share/xorg" _contents "${_contents}" )
string ( REPLACE "exec_prefix=\${prefix}" "exec_prefix=\${prefix}/../tools/${PORT}" _contents "${_contents}" )
file ( WRITE "${_file}" "${_contents}" )
endif ( )
2022-09-20 03:08:27 +08:00
# Handle copyright
file ( INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME "copyright" )
2022-10-21 01:52:23 +08:00
endif ( )