add a gzipped uImage for ar71xx
[openwrt.git] / rules.mk
index 5b41118..e7a26fc 100644 (file)
--- a/rules.mk
+++ b/rules.mk
@@ -27,8 +27,9 @@ empty:=
 space:= $(empty) $(empty)
 merge=$(subst $(space),,$(1))
 confvar=$(call merge,$(foreach v,$(1),$(if $($(v)),y,n)))
+strip_last=$(patsubst %.$(lastword $(subst .,$(space),$(1))),%,$(1))
 
-_SINGLE=MAKEFLAGS=$(space)
+_SINGLE=export MAKEFLAGS=$(space);
 ARCH:=$(call qstrip,$(shell echo $(CONFIG_ARCH) | sed -e 's/i[3-9]86/i386/'))
 BOARD:=$(call qstrip,$(CONFIG_TARGET_BOARD))
 TARGET_OPTIMIZATION:=$(call qstrip,$(CONFIG_TARGET_OPTIMIZATION))
@@ -38,6 +39,12 @@ SUBDIR:=$(patsubst $(TOPDIR)/%,%,${CURDIR})
 
 OPTIMIZE_FOR_CPU=$(ARCH)
 
+ifeq ($(ARCH),powerpc)
+  FPIC:=-fPIC
+else
+  FPIC:=-fpic
+endif
+
 DL_DIR:=$(if $(call qstrip,$(CONFIG_DOWNLOAD_FOLDER)),$(call qstrip,$(CONFIG_DOWNLOAD_FOLDER)),$(TOPDIR)/dl)
 BIN_DIR:=$(TOPDIR)/bin
 INCLUDE_DIR:=$(TOPDIR)/include
This page took 0.019663 seconds and 4 git commands to generate.