diff Makefile @ 2500:8db5a297f243

Add support for a local settings file settings.mk
author Volker Grabsch <vog@notjusthosting.com>
date Thu, 03 May 2012 22:57:19 +0200
parents 9e60296cb20d
children 422cb29ca669
line wrap: on
line diff
--- a/Makefile	Fri May 04 02:43:52 2012 +1000
+++ b/Makefile	Thu May 03 22:57:19 2012 +0200
@@ -68,6 +68,18 @@
         ) \
     > '$(PKG_DIR)/$($(1)_FILE)'
 
+ifeq ($(IGNORE_SETTINGS),yes)
+    $(info [ignore settings.mk])
+else ifeq ($(wildcard $(PWD)/settings.mk),$(PWD)/settings.mk)
+    include $(PWD)/settings.mk
+else
+    $(info [create settings.mk])
+    $(shell { \
+        echo '#JOBS = $(JOBS)'; \
+        echo '#PKGS ='; \
+    } >'$(PWD)/settings.mk')
+endif
+
 .PHONY: all
 all: $(PKGS)