summaryrefslogtreecommitdiff
path: root/Makefile
authorkergoth <kergoth>2003-04-22 20:12:04 (UTC)
committer kergoth <kergoth>2003-04-22 20:12:04 (UTC)
commitccec87cf3e7192c0a3987aa3486668e89b1662a4 (patch) (unidiff)
tree2d1135ed639410fe1a75486bfdeae8083e1682a2 /Makefile
parent2134672b0a731415bfd50f2ff22de59b78709e5c (diff)
downloadopie-ccec87cf3e7192c0a3987aa3486668e89b1662a4.zip
opie-ccec87cf3e7192c0a3987aa3486668e89b1662a4.tar.gz
opie-ccec87cf3e7192c0a3987aa3486668e89b1662a4.tar.bz2
you can now 'make ipks' :)
Diffstat (limited to 'Makefile') (more/less context) (ignore whitespace changes)
-rw-r--r--Makefile26
1 files changed, 17 insertions, 9 deletions
diff --git a/Makefile b/Makefile
index 9169645..10df035 100644
--- a/Makefile
+++ b/Makefile
@@ -1,16 +1,11 @@
1#!/usr/bin/make -f 1#!/usr/bin/make -f
2ifndef QTDIR
3$(error QTDIR not set)
4endif
5 2
6export OPIEDIR:=$(shell pwd) 3export TOPDIR:=$(shell pwd)
7export TOPDIR:=$(OPIEDIR)
8export QMAKE:=$(OPIEDIR)/qmake/qmake
9 4
10export QMAKESPECSDIR=$(OPIEDIR)/mkspecs 5include $(TOPDIR)/Vars.make
11 6
12noconfig_targets := xconfig menuconfig config oldconfig randconfig \ 7noconfig_targets := xconfig menuconfig config oldconfig randconfig \
13 defconfig allyesconfig allnoconfig allmodconfig \ 8 defconfig allyesconfig allnoconfig allmodconfig \
14 clean-configs 9 clean-configs
15 10
16configs += $(TOPDIR)/core/applets/config.in $(TOPDIR)/core/apps/config.in $(TOPDIR)/core/multimedia/config.in $(TOPDIR)/core/pim/config.in $(TOPDIR)/core/pim/today/plugins/config.in $(TOPDIR)/core/settings/config.in $(TOPDIR)/development/config.in $(TOPDIR)/inputmethods/config.in $(TOPDIR)/libopie/ofileselector/config.in $(TOPDIR)/libopie/pim/config.in $(TOPDIR)/libsql/config.in $(TOPDIR)/noncore/applets/config.in $(TOPDIR)/noncore/apps/opie-console/test/config.in $(TOPDIR)/noncore/apps/config.in $(TOPDIR)/noncore/comm/config.in $(TOPDIR)/noncore/decorations/config.in $(TOPDIR)/noncore/games/config.in $(TOPDIR)/noncore/graphics/config.in $(TOPDIR)/noncore/multimedia/config.in $(TOPDIR)/noncore/net/config.in $(TOPDIR)/noncore/net/opietooth/config.in $(TOPDIR)/noncore/settings/config.in $(TOPDIR)/noncore/styles/config.in $(TOPDIR)/noncore/tools/calc2/config.in $(TOPDIR)/noncore/tools/config.in $(TOPDIR)/noncore/todayplugins/config.in 11configs += $(TOPDIR)/core/applets/config.in $(TOPDIR)/core/apps/config.in $(TOPDIR)/core/multimedia/config.in $(TOPDIR)/core/pim/config.in $(TOPDIR)/core/pim/today/plugins/config.in $(TOPDIR)/core/settings/config.in $(TOPDIR)/development/config.in $(TOPDIR)/inputmethods/config.in $(TOPDIR)/libopie/ofileselector/config.in $(TOPDIR)/libopie/pim/config.in $(TOPDIR)/libsql/config.in $(TOPDIR)/noncore/applets/config.in $(TOPDIR)/noncore/apps/opie-console/test/config.in $(TOPDIR)/noncore/apps/config.in $(TOPDIR)/noncore/comm/config.in $(TOPDIR)/noncore/decorations/config.in $(TOPDIR)/noncore/games/config.in $(TOPDIR)/noncore/graphics/config.in $(TOPDIR)/noncore/multimedia/config.in $(TOPDIR)/noncore/net/config.in $(TOPDIR)/noncore/net/opietooth/config.in $(TOPDIR)/noncore/settings/config.in $(TOPDIR)/noncore/styles/config.in $(TOPDIR)/noncore/tools/calc2/config.in $(TOPDIR)/noncore/tools/config.in $(TOPDIR)/noncore/todayplugins/config.in
@@ -23,21 +18,35 @@ configs += $(TOPDIR)/core/applets/config.in $(TOPDIR)/core/apps/config.in $(TOPD
23# 18#
24# NOTE: The order in which things happen in this makefile is 19# NOTE: The order in which things happen in this makefile is
25 # -critical-. Do not rearrange this! 20 # -critical-. Do not rearrange this!
26 21
27all : $(TOPDIR)/.config 22all : $(TOPDIR)/.config
28 23
24STRIP=arm-linux-strip
25
26ipks: $(OPIEDIR)/scripts/subst $(OPIEDIR)/scripts/filesubst FORCE
27 @find $(OPIEDIR)/ -type f -name \*.control | ( for ctrl in `cat`; do \
28 prerm=`echo $$ctrl|sed -e 's,\.control$$,.prerm,'`; \
29 preinst=`echo $$ctrl|sed -e 's,\.control$$,.preinst,'`; \
30 postrm=`echo $$ctrl|sed -e 's,\.control$$,.postrm,'`; \
31 postinst=`echo $$ctrl|sed -e 's,\.control$$,.postinst,'`; \
32 echo "Building ipk of $$ctrl"; \
33 cd $(OPIEDIR); $(OPIEDIR)/scripts/mkipkg --subst=$(OPIEDIR)/scripts/subst --filesubst=$(OPIEDIR)/scripts/filesubst --control=$$ctrl --prerm=$$prerm --preinst=$$preinst --postrm=$$postrm --postinst=$$postinst --strip=$(STRIP) $(OPIEDIR); \
34 done )
35
29$(TOPDIR)/.config : $(TOPDIR)/.depends.cfgs 36$(TOPDIR)/.config : $(TOPDIR)/.depends.cfgs
30 37
31all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(TOPDIR)/.depends.cfgs 38all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(TOPDIR)/.depends.cfgs
32 39
33clean-configs : 40clean-configs :
34 @echo "Wiping generated config.in files..." 41 @echo "Wiping generated config.in files..."
35 @-rm -f $(configs) 42 @-rm -f $(configs)
36 43
37-include $(TOPDIR)/.depends.cfgs 44ifneq ($(wildcard $(TOPDIR)/.depends.cfgs),)
45 include $(TOPDIR)/.depends.cfgs
46endif
38 47
39all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(configs) 48all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(configs)
40 49
41$(TOPDIR)/.config: $(TOPDIR)/.depends.cfgs $(configs) 50$(TOPDIR)/.config: $(TOPDIR)/.depends.cfgs $(configs)
42 $(call descend,scripts/kconfig,conf) 51 $(call descend,scripts/kconfig,conf)
43 @if [ ! -e $@ ]; then \ 52 @if [ ! -e $@ ]; then \
@@ -89,13 +98,12 @@ export
89ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),) 98ifeq ($(filter $(noconfig_targets),$(MAKECMDGOALS)),)
90 99
91export include-config := 1 100export include-config := 1
92 101
93-include $(TOPDIR)/.config 102-include $(TOPDIR)/.config
94-include $(TOPDIR)/.depends 103-include $(TOPDIR)/.depends
95
96endif 104endif
97 105
98-include $(TOPDIR)/.config.cmd 106-include $(TOPDIR)/.config.cmd
99 107
100SUBDIRS = $(subdir-y) 108SUBDIRS = $(subdir-y)
101 109