CMake: Also set VCPKG_HOST_TRIPLET to the dynamic triplet
This avoids Fedora 41 x86_64 machines using the x64-linux triplet when building pkg-config. Doing so without our custom linker flags causes the build to fail.
This commit is contained in:
parent
37f7f02d69
commit
2a16c58114
Notes:
github-actions[bot]
2024-12-31 20:43:57 +00:00
Author: https://github.com/ADKaster Commit: https://github.com/LadybirdBrowser/ladybird/commit/2a16c58114e Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3086
1 changed files with 2 additions and 1 deletions
|
@ -22,7 +22,7 @@ file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/build-vcpkg-variables.cmake" "${EXTRA_VC
|
|||
# Munge the VCPKG_TRIPLET to correspond to the right one for our presets
|
||||
# Just make sure not to override if the developer is trying to cross-compile
|
||||
# or the developer set it manually, or if this is not the first run of CMake
|
||||
if (NOT DEFINED CACHE{VCPKG_TARGET_TRIPLET} AND NOT DEFINED VCPKG_CHAINLOAD_TOOLCHAIN_FILE)
|
||||
if (NOT DEFINED CACHE{VCPKG_TARGET_TRIPLET} AND NOT DEFINED CACHE{VCPKG_HOST_TRIPLET} AND NOT DEFINED VCPKG_CHAINLOAD_TOOLCHAIN_FILE)
|
||||
# Only tweak settings if there's custom triplets defined
|
||||
if (NOT DEFINED CACHE{VCPKG_OVERLAY_TRIPLETS})
|
||||
return()
|
||||
|
@ -68,4 +68,5 @@ if (NOT DEFINED CACHE{VCPKG_TARGET_TRIPLET} AND NOT DEFINED VCPKG_CHAINLOAD_TOOL
|
|||
|
||||
message(STATUS "Determined host VCPKG_TARGET_TRIPLET: ${full_triplet}")
|
||||
set(VCPKG_TARGET_TRIPLET ${full_triplet} CACHE STRING "")
|
||||
set(VCPKG_HOST_TRIPLET ${full_triplet} CACHE STRING "")
|
||||
endif()
|
||||
|
|
Loading…
Add table
Reference in a new issue