summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.in4
-rw-r--r--Rules.mak9
2 files changed, 8 insertions, 5 deletions
diff --git a/Makefile.in b/Makefile.in
index 3593fe130..0a62557de 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -16,10 +16,6 @@ noconfig_targets := menuconfig config oldconfig silentoldconfig randconfig \
include $(top_srcdir)Rules.mak
sub_headers := headers
-ifndef KCONFIG_CONFIG
-KCONFIG_CONFIG := $(top_builddir).config
-endif
-export KCONFIG_CONFIG
ifeq ($(HAVE_DOT_CONFIG),y)
diff --git a/Rules.mak b/Rules.mak
index b92b6ef0c..96871e1ae 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -74,9 +74,16 @@ BUILD_CFLAGS = -Os -Wall
qstrip = $(strip $(subst ",,$(1)))
#"))
+ifndef KCONFIG_CONFIG
+KCONFIG_CONFIG := $(top_builddir).config
+endif
+export KCONFIG_CONFIG
+
# Pull in the user's uClibc configuration
ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
--include $(top_builddir).config
+# Prevent make from searching
+__ABS_KCONFIG_CONFIG := $(abspath $(KCONFIG_CONFIG))
+-include $(__ABS_KCONFIG_CONFIG)
endif
TARGET_ARCH:=$(call qstrip,$(TARGET_ARCH))
ifeq ($(TARGET_ARCH),)