From 3e0d4f191535e95cf46eda876dca465dfcf657a5 Mon Sep 17 00:00:00 2001 From: Daniel Silverstone Date: Fri, 29 Jun 2012 18:17:04 +0000 Subject: Initial rework to have Makefile.tools find itself and set NSBUILD svn path=/trunk/tools/buildsystem/; revision=13996 --- makefiles/Makefile.tools | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'makefiles/Makefile.tools') diff --git a/makefiles/Makefile.tools b/makefiles/Makefile.tools index 7a5cc63..922e690 100644 --- a/makefiles/Makefile.tools +++ b/makefiles/Makefile.tools @@ -34,6 +34,12 @@ ifeq ($(BUILD),) BUILD := release endif +############################################################################### +# Determine path used to load us, so we can locate other makefiles +############################################################################### + +NSBUILD := $(dir $(lastword $(MAKEFILE_LIST))) + ############################################################################### # Host/target platform detection ############################################################################### @@ -415,7 +421,7 @@ ifeq ($(toolchain),) endif # TODO: It would be nice to avoid this hard-coded path -include build/makefiles/Makefile.$(toolchain) +include $(NSBUILD)/Makefile.$(toolchain) ############################################################################### # Default assembler/compiler/linker/archiver flags @@ -468,4 +474,4 @@ endif # Package config macros ################################################################################ -include build/makefiles/Makefile.pkgconfig +include $(NSBUILD)/Makefile.pkgconfig -- cgit v1.2.3