Skip to content
This repository has been archived by the owner on Jun 24, 2022. It is now read-only.

Commit

Permalink
Set PATH for make $(shell calls. Fixes bin/gub's environment check fa…
Browse files Browse the repository at this point in the history
…ilures.

When using make, together with:

   sourcefiles/gub.sh as ~/bin/gub

and the local.make snippet

   ifneq ($(findstring xbin:,x$(PATH)),xbin:)
   PATH := bin:$(HOME)/vc/gub/bin:$(PATH)
   endif

you can simply call "gub" and still use the "make" fontend.
  • Loading branch information
janneke committed Jan 5, 2010
1 parent aaa3311 commit 0a94d58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion compilers.make
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ DISTCC_DIRS=target/cross-distcc/bin target/cross-distccd/bin target/native-distc
#gcc_or_glibc = $(shell $(GUB) -p $(1) --inspect=version glibc > /dev/null 2>/dev/null && echo glibc || echo cross/gcc)
gcc_or_glibc = $(shell if echo $(1) | grep linux > /dev/null 2>/dev/null; then echo glibc; else echo cross/gcc; fi)

tools = $(shell $(GUB) --show-dependencies $(foreach p, $(PLATFORMS), $(p)::$(call gcc_or_glibc,$(p))) 2>&1 | grep ^dependencies | tr ' ' '\n' | grep 'tools::')
tools = $(shell PATH=$(PATH) $(GUB) --show-dependencies $(foreach p, $(PLATFORMS), $(p)::$(call gcc_or_glibc,$(p))) 2>&1 | grep ^dependencies | tr ' ' '\n' | grep 'tools::')

compilers: cross-compilers

Expand Down
2 changes: 1 addition & 1 deletion lilypond.make
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ realclean:
################################################################
# compilers and tools

tools := $(shell $(GUB) --show-dependencies $(foreach p, $(PLATFORMS), $(p)::lilypond $(p)::lilypond-doc $(p)::lilypond-installer) 2>&1 | grep ^dependencies | tr ' ' '\n' | grep 'tools::')
tools := $(shell PATH=$(PATH) $(GUB) --show-dependencies $(foreach p, $(PLATFORMS), $(p)::lilypond $(p)::lilypond-doc $(p)::lilypond-installer) 2>&1 | grep ^dependencies | tr ' ' '\n' | grep 'tools::')

ptools:
$(GUB) --show-dependencies $(foreach p, $(PLATFORMS), $(p)::lilypond $(p)::lilypond-doc $(p)::lilypond-installer) 2>&1 | grep ^dependencies | tr ' ' '\n' | grep 'tools::'
Expand Down

0 comments on commit 0a94d58

Please sign in to comment.