X-Git-Url: http://git.rohieb.name/openwrt.git/blobdiff_plain/3e8bff3590764c1f6f691db7c7fbb020e6113944..77d3905c01e0ed53c4edc62ba809b22efcfcdfb9:/include/toplevel.mk diff --git a/include/toplevel.mk b/include/toplevel.mk index 06b005568..6d46fe1ed 100644 --- a/include/toplevel.mk +++ b/include/toplevel.mk @@ -24,6 +24,9 @@ export REVISION export OPENWRTVERSION export IS_TTY=$(shell tty -s && echo 1 || echo 0) +# make sure that a predefined CFLAGS variable does not disturb packages +export CFLAGS= + ifeq ($(FORCE),) .config scripts/config/conf scripts/config/mconf: tmp/.prereq-build endif @@ -45,7 +48,7 @@ prepare-tmpinfo: FORCE touch $(TOPDIR)/tmp/.build .config: ./scripts/config/conf prepare-tmpinfo $(if $(CONFIG_HAVE_DOT_CONFIG),,FORCE) - @+if [ \! -f .config ] || ! grep CONFIG_HAVE_DOT_CONFIG .config >/dev/null; then \ + @+if [ \! -e .config ] || ! grep CONFIG_HAVE_DOT_CONFIG .config >/dev/null; then \ [ -e $(HOME)/.openwrt/defconfig ] && cp $(HOME)/.openwrt/defconfig .config; \ $(_SINGLE)$(NO_TRACE_MAKE) menuconfig $(PREP_MK); \ fi @@ -72,7 +75,7 @@ oldconfig: scripts/config/conf prepare-tmpinfo FORCE $< -$(if $(CONFDEFAULT),$(CONFDEFAULT),o) Config.in menuconfig: scripts/config/mconf prepare-tmpinfo FORCE - if [ \! -f .config -a -e $(HOME)/.openwrt/defconfig ]; then \ + if [ \! -e .config -a -e $(HOME)/.openwrt/defconfig ]; then \ cp $(HOME)/.openwrt/defconfig .config; \ fi $< Config.in