summaryrefslogtreecommitdiff
path: root/automake.head.mk
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2016-03-04 13:20:55 -0500
committerLuke Shumaker <lukeshu@sbcglobal.net>2016-03-04 13:20:55 -0500
commit37ef1295bf8885876df8de989569a2233f97583f (patch)
tree5af9a3fb27541ed42734198240cca05b4c0906bb /automake.head.mk
parent45d77264cab813a4465116a3ac33a0a44a1389e7 (diff)
Have the caller be responsible for setting topoutdir
Diffstat (limited to 'automake.head.mk')
-rw-r--r--automake.head.mk11
1 files changed, 4 insertions, 7 deletions
diff --git a/automake.head.mk b/automake.head.mk
index c79da83..37d3b07 100644
--- a/automake.head.mk
+++ b/automake.head.mk
@@ -30,13 +30,10 @@ am_path = $(foreach p,$1,$(call _am_relto,$p))
all: build
.PHONY: all
-## Set topoutdir, outdir, and srcdir (assumes that topsrcdir is
-## already set, and that $(topoutdir)/config.mk has been included)
-ifeq ($(topoutdir),)
-topoutdir := $(call _am_path,$(dir $(lastword $(filter %/config.mk config.mk,$(MAKEFILE_LIST)))))
-endif
- outdir := $(call _am_path,$(dir $(lastword $(filter-out %.mk,$(MAKEFILE_LIST)))))
- srcdir := $(call _am_path,$(topsrcdir)/$(call _am_relto,$(topoutdir),$(outdir)))
+## Set outdir and srcdir (assumes that topoutdir and topsrcdir are
+## already set)
+outdir := $(call _am_path,$(dir $(lastword $(filter-out %.mk,$(MAKEFILE_LIST)))))
+srcdir := $(call _am_path,$(topsrcdir)/$(call _am_relto,$(topoutdir),$(outdir)))
_am_included_makefiles := $(_am_included_makefiles) $(call _am_path,$(outdir)/Makefile)