Skip to content

Commit

Permalink
work with GNU Make 3.80
Browse files Browse the repository at this point in the history
  • Loading branch information
rsc committed Nov 11, 2009
1 parent 7932950 commit 3849325
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/Make.pkg
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@ all: package
package: _obj/$(TARG).a
testpackage: _test/$(TARG).a

elem=$(lastword $(subst /, ,$(TARG)))
# GNU Make 3.80 has a bug in lastword
# elem=$(lastword $(subst /, ,$(TARG)))
TARG_words=$(subst /, ,$(TARG))
elem=$(word $(words $(TARG_words)),$(TARG_words))

dir=$(patsubst %/$(elem),%,./$(TARG))
pkgdir=$(GOROOT)/pkg/$(GOOS)_$(GOARCH)

Expand Down

0 comments on commit 3849325

Please sign in to comment.