Skip to content

Commit

Permalink
merge bitcoin#24866: No longer need to hack the PATH variable in `con…
Browse files Browse the repository at this point in the history
…fig.site`

includes:
- f3af4f7
- efa3a80

continuation of 9e0b935 from dash#6384
  • Loading branch information
kwvg committed Dec 30, 2024
1 parent a5787c9 commit 416e154
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 4 deletions.
1 change: 1 addition & 0 deletions depends/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,7 @@ $(host_prefix)/share/config.site : config.site.in $(host_prefix)/.stamp_$(final_
-e 's|@NM@|$(host_NM)|' \
-e 's|@STRIP@|$(host_STRIP)|' \
-e 's|@OBJDUMP@|$(host_OBJDUMP)|' \
-e 's|@DSYMUTIL@|$(host_DSYMUTIL)|' \
-e 's|@build_os@|$(build_os)|' \
-e 's|@host_os@|$(host_os)|' \
-e 's|@CFLAGS@|$(strip $(host_CFLAGS) $(host_$(release_type)_CFLAGS))|' \
Expand Down
2 changes: 2 additions & 0 deletions depends/builders/darwin.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ build_darwin_RANLIB:=$(shell xcrun -f ranlib)
build_darwin_STRIP:=$(shell xcrun -f strip)
build_darwin_OBJDUMP:=$(shell xcrun -f objdump)
build_darwin_NM:=$(shell xcrun -f nm)
build_darwin_DSYMUTIL:=$(shell xcrun -f dsymutil)
build_darwin_SHA256SUM=shasum -a 256
build_darwin_DOWNLOAD=curl --location --fail --connect-timeout $(DOWNLOAD_CONNECT_TIMEOUT) --retry $(DOWNLOAD_RETRIES) -o

Expand All @@ -16,6 +17,7 @@ darwin_RANLIB:=$(shell xcrun -f ranlib)
darwin_STRIP:=$(shell xcrun -f strip)
darwin_OBJDUMP:=$(shell xcrun -f objdump)
darwin_NM:=$(shell xcrun -f nm)
darwin_DSYMUTIL:=$(shell xcrun -f dsymutil)
darwin_native_binutils=
darwin_native_toolchain=

Expand Down
2 changes: 1 addition & 1 deletion depends/builders/default.mk
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ build_$(build_os)_$1 ?= $$(default_build_$1)
build_$(build_arch)_$(build_os)_$1 ?= $$(build_$(build_os)_$1)
build_$1=$$(build_$(build_arch)_$(build_os)_$1)
endef
$(foreach var,CC CXX AR TAR RANLIB NM STRIP SHA256SUM DOWNLOAD OBJDUMP TOUCH,$(eval $(call add_build_tool_func,$(var))))
$(foreach var,CC CXX AR TAR RANLIB NM STRIP SHA256SUM DOWNLOAD OBJDUMP DSYMUTIL TOUCH,$(eval $(call add_build_tool_func,$(var))))
define add_build_flags_func
build_$(build_arch)_$(build_os)_$1 += $(build_$(build_os)_$1)
build_$1=$$(build_$(build_arch)_$(build_os)_$1)
Expand Down
6 changes: 5 additions & 1 deletion depends/config.site.in
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ if test "@host_os@" = darwin; then
BREW=no
fi

PATH="${depends_prefix}/native/bin:${PATH}"
PKG_CONFIG="$(which pkg-config) --static"

# These two need to remain exported because pkg-config does not see them
Expand Down Expand Up @@ -125,6 +124,11 @@ if test "@host_os@" = darwin; then
OBJDUMP="@OBJDUMP@"
ac_cv_path_ac_pt_OBJDUMP="${OBJDUMP}"
fi

if test -n "@DSYMUTIL@"; then
DSYMUTIL="@DSYMUTIL@"
ac_cv_path_ac_pt_DSYMUTIL="${DSYMUTIL}"
fi
fi

if test -n "@debug@"; then
Expand Down
2 changes: 1 addition & 1 deletion depends/hosts/darwin.mk
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ llvm_lib_dir=$(shell $(llvm_config_prog) --libdir)
darwin_OBJDUMP=$(shell $(SHELL) $(.SHELLFLAGS) "command -v llvm-objdump")
endif

cctools_TOOLS=AR RANLIB STRIP NM
cctools_TOOLS=AR RANLIB STRIP NM DSYMUTIL

# Make-only lowercase function
lc = $(subst A,a,$(subst B,b,$(subst C,c,$(subst D,d,$(subst E,e,$(subst F,f,$(subst G,g,$(subst H,h,$(subst I,i,$(subst J,j,$(subst K,k,$(subst L,l,$(subst M,m,$(subst N,n,$(subst O,o,$(subst P,p,$(subst Q,q,$(subst R,r,$(subst S,s,$(subst T,t,$(subst U,u,$(subst V,v,$(subst W,w,$(subst X,x,$(subst Y,y,$(subst Z,z,$1))))))))))))))))))))))))))
Expand Down
2 changes: 1 addition & 1 deletion depends/hosts/default.mk
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,5 @@ host_$1 = $$($(host_arch)_$(host_os)_$1)
host_$(release_type)_$1 = $$($(host_arch)_$(host_os)_$(release_type)_$1)
endef

$(foreach tool,CC CXX AR RANLIB STRIP NM OBJCOPY OBJDUMP,$(eval $(call add_host_tool_func,$(tool))))
$(foreach tool,CC CXX AR RANLIB STRIP NM OBJCOPY OBJDUMP DSYMUTIL,$(eval $(call add_host_tool_func,$(tool))))
$(foreach flags,CFLAGS CXXFLAGS CPPFLAGS LDFLAGS, $(eval $(call add_host_flags_func,$(flags))))

0 comments on commit 416e154

Please sign in to comment.