From e3ef0f8587b10bf242d8077609988e06a37bcae5 Mon Sep 17 00:00:00 2001 From: kergoth Date: Tue, 22 Apr 2003 20:21:20 +0000 Subject: Set strip binary appropriately, based on target selection for ipk creation --- diff --git a/Makefile b/Makefile index 10df035..8551f28 100644 --- a/Makefile +++ b/Makefile @@ -21,9 +21,7 @@ configs += $(TOPDIR)/core/applets/config.in $(TOPDIR)/core/apps/config.in $(TOPD all : $(TOPDIR)/.config -STRIP=arm-linux-strip - -ipks: $(OPIEDIR)/scripts/subst $(OPIEDIR)/scripts/filesubst FORCE +ipks: $(OPIEDIR)/scripts/subst $(OPIEDIR)/scripts/filesubst FORCE $(TOPDIR)/.config @find $(OPIEDIR)/ -type f -name \*.control | ( for ctrl in `cat`; do \ prerm=`echo $$ctrl|sed -e 's,\.control$$,.prerm,'`; \ preinst=`echo $$ctrl|sed -e 's,\.control$$,.preinst,'`; \ @@ -107,13 +105,6 @@ endif SUBDIRS = $(subdir-y) -export QMAKESPEC=$(QMAKESPECSDIR)/$(patsubst "%",%,$(CONFIG_SPECFILE)) - -ifdef CONFIG_OPTIMIZATIONS -export CFLAGS_RELEASE=$(patsubst "%,%,$(CONFIG_OPTIMIZATIONS)) -export CFLAGS_RELEASE:=$(patsubst %",%,$(CFLAGS_RELEASE)) -endif - all clean install ipk: $(SUBDIRS) lupdate lrelease: diff --git a/Vars.make b/Vars.make index eac5cea..b1cdb28 100644 --- a/Vars.make +++ b/Vars.make @@ -11,6 +11,10 @@ ifeq ($(IPK_DIR),) export IPK_DIR:=$(OPIEDIR) endif +ifneq ($(wildcard $(TOPDIR)/.config),) + include $(TOPDIR)/.config +endif + export QMAKE:=$(OPIEDIR)/qmake/qmake export QMAKESPECSDIR=$(OPIEDIR)/mkspecs @@ -61,3 +65,21 @@ endif export QTE_VERSION export PATH:=$(OPIEDIR)/scripts:$(PATH) +export QMAKESPEC=$(QMAKESPECSDIR)/$(patsubst "%",%,$(CONFIG_SPECFILE)) + +ifdef CONFIG_OPTIMIZATIONS +export CFLAGS_RELEASE=$(patsubst "%,%,$(CONFIG_OPTIMIZATIONS)) +export CFLAGS_RELEASE:=$(patsubst %",%,$(CFLAGS_RELEASE)) +endif + +ifeq ($(STRIP),) + ifneq ($(CONFIG_TARGET_X86),) + STRIP=strip + endif + ifneq ($(CONFIG_TARGET_IPAQ),) + STRIP=arm-linux-strip + endif + ifneq ($(CONFIG_TARGET_SHARP),) + STRIP=arm-linux-strip + endif +endif -- cgit v0.9.0.2