Skip to content

Commit 2aa7be1

Browse files
committed
Merge bitcoin#31358: depends: Avoid hardcoding host_prefix in toolchain file
d9c8aac depends, refactor: Avoid hardcoding `host_prefix` in toolchain file (Hennadii Stepanov) Pull request description: This PR allows the entire `depends/<host_prefix>` directory to be relocatable. Only `libevent` package configuration files are non-relocatable for the version `2.1.12-stable` we use now. However, this issue has been fixed upstream in libevent/libevent@1f1593f and friends. Fixes bitcoin#31050. ACKs for top commit: theuni: Neat. utACK d9c8aac ryanofsky: Code review ACK d9c8aac Tree-SHA512: c4c340722e63fc1da36fba2b15f025a6e1d477da1991194d678f546f2f3ea9454e2f0ff054aae6ae6c332a0781a597c3ce63b9018b46b8c258033f0d19efbef3
2 parents 94ca99a + d9c8aac commit 2aa7be1

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

depends/Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,6 @@ $(host_prefix)/toolchain.cmake : toolchain.cmake.in $(host_prefix)/.stamp_$(fina
217217
-e 's|@STRIP@|$(host_STRIP)|' \
218218
-e 's|@OBJCOPY@|$(host_OBJCOPY)|' \
219219
-e 's|@OBJDUMP@|$(host_OBJDUMP)|' \
220-
-e 's|@depends_prefix@|$(host_prefix)|' \
221220
-e 's|@CFLAGS@|$(strip $(host_CFLAGS))|' \
222221
-e 's|@CFLAGS_RELEASE@|$(strip $(host_release_CFLAGS))|' \
223222
-e 's|@CFLAGS_DEBUG@|$(strip $(host_debug_CFLAGS))|' \

depends/toolchain.cmake.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,12 +81,12 @@ set(CMAKE_OBJDUMP "@OBJDUMP@")
8181
# affected by a potentially random environment.
8282
set(CMAKE_FIND_USE_CMAKE_ENVIRONMENT_PATH OFF)
8383

84-
set(CMAKE_FIND_ROOT_PATH "@depends_prefix@")
84+
set(CMAKE_FIND_ROOT_PATH "${CMAKE_CURRENT_LIST_DIR}")
8585
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
8686
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
8787
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
8888
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
89-
set(QT_TRANSLATIONS_DIR "@depends_prefix@/translations")
89+
set(QT_TRANSLATIONS_DIR "${CMAKE_CURRENT_LIST_DIR}/translations")
9090

9191
if(CMAKE_SYSTEM_NAME STREQUAL "Darwin" AND NOT CMAKE_HOST_APPLE)
9292
# The find_package(Qt ...) function internally uses find_library()

0 commit comments

Comments
 (0)