summaryrefslogtreecommitdiff
path: root/Rules.make
authorkergoth <kergoth>2003-04-22 20:10:51 (UTC)
committer kergoth <kergoth>2003-04-22 20:10:51 (UTC)
commit463d8aa56d888710cc2507310e8dd348dac6e455 (patch) (unidiff)
tree4ef688344cd488b8504a0127e018f3702d5d9afb /Rules.make
parenta4cbad5c0dece9af449a5a881973ce272208c1ba (diff)
downloadopie-463d8aa56d888710cc2507310e8dd348dac6e455.zip
opie-463d8aa56d888710cc2507310e8dd348dac6e455.tar.gz
opie-463d8aa56d888710cc2507310e8dd348dac6e455.tar.bz2
Add ipk creation rules
Diffstat (limited to 'Rules.make') (more/less context) (ignore whitespace changes)
-rw-r--r--Rules.make20
1 files changed, 20 insertions, 0 deletions
diff --git a/Rules.make b/Rules.make
index a707751..85d7d87 100644
--- a/Rules.make
+++ b/Rules.make
@@ -1,12 +1,14 @@
1.PHONY: FORCE
2
1$(configs) : 3$(configs) :
2 $(call makecfg,$@) 4 $(call makecfg,$@)
3 5
4$(TOPDIR)/gen.pro : $(TOPDIR)/.config 6$(TOPDIR)/gen.pro : $(TOPDIR)/.config
5 echo > $@ 7 echo > $@
6ifneq ($(CONFIG_DEBUG),) 8ifneq ($(CONFIG_DEBUG),)
7 echo CONFIG += debug >> $@ 9 echo CONFIG += debug >> $@
8 echo CONFIG -= release >> $@ 10 echo CONFIG -= release >> $@
9else 11else
10 echo CONFIG -= debug >> $@ 12 echo CONFIG -= debug >> $@
11 echo CONFIG += release >> $@ 13 echo CONFIG += release >> $@
12endif 14endif
@@ -89,24 +91,42 @@ $(TOPDIR)/library/custom.h : $(TOPDIR)/.config
89 @$(if $(patsubst "%",%,$(CONFIG_CUSTOMFILE)),\ 91 @$(if $(patsubst "%",%,$(CONFIG_CUSTOMFILE)),\
90 ln -sf $(patsubst "%",%,$(CONFIG_CUSTOMFILE)) $@) 92 ln -sf $(patsubst "%",%,$(CONFIG_CUSTOMFILE)) $@)
91 @touch $@ 93 @touch $@
92 94
93$(TOPDIR)/scripts/lxdialog/lxdialog $(TOPDIR)/scripts/kconfig/conf scripts/kconfig/conf $(TOPDIR)/scripts/kconfig/mconf scripts/kconfig/mconf $(TOPDIR)/scripts/kconfig/qconf scripts/kconfig/qconf $(TOPDIR)/qmake/qmake : 95$(TOPDIR)/scripts/lxdialog/lxdialog $(TOPDIR)/scripts/kconfig/conf scripts/kconfig/conf $(TOPDIR)/scripts/kconfig/mconf scripts/kconfig/mconf $(TOPDIR)/scripts/kconfig/qconf scripts/kconfig/qconf $(TOPDIR)/qmake/qmake :
94 $(call descend,$(shell dirname $@),$(shell basename $@)) 96 $(call descend,$(shell dirname $@),$(shell basename $@))
95 97
96$(TOPDIR)/qmake/qmake : $(TOPDIR)/mkspecs/default 98$(TOPDIR)/qmake/qmake : $(TOPDIR)/mkspecs/default
97 99
98$(TOPDIR)/mkspecs/default : 100$(TOPDIR)/mkspecs/default :
99 ln -sf linux-g++ $@ 101 ln -sf linux-g++ $@
100 102
103$(TOPDIR)/scripts/subst : FORCE
104 @( \
105 echo 's,\$$QPE_VERSION,$(QPE_VERSION),g'; \
106 echo 's,\$$QTE_VERSION,$(QTE_VERSION),g'; \
107 echo 's,\$$QTE_REVISION,$(QTE_REVISION),g'; \
108 echo 's,\$$SUB_VERSION,$(SUB_VERSION),g'; \
109 echo 's,\$$QTE_BASEVERSION,$(QTE_BASEVERSION),g'; \
110 ) > $@ || ( rm -f $@; exit 1 )
111
112$(TOPDIR)/scripts/filesubst : FORCE
113 @( \
114 echo 's,\$$OPIEDIR,$(prefix),g'; \
115 echo 's,\$$QTDIR,$(prefix),g'; \
116 echo 's,^root/,/,g'; \
117 echo 's,^etc/,/etc/,g'; \
118 echo 's,^lib/,$(prefix)/lib/,g'; \
119 ) > $@ || ( rm -f $@; exit 1 )
120
101## general rules ## 121## general rules ##
102 122
103define descend 123define descend
104 $(MAKE) $(if $(QMAKE),QMAKE=$(QMAKE)) -C $(1) $(2) 124 $(MAKE) $(if $(QMAKE),QMAKE=$(QMAKE)) -C $(1) $(2)
105endef 125endef
106 126
107define makefilegen 127define makefilegen
108 cd $(if $(1),$(shell dirname $(1))); $(TOPDIR)/qmake/qmake $(3) -o $(if $(1),$(shell basename $(1))) `cat $(OPIEDIR)/packages | grep " \`echo $(1)|sed -e 's,/Makefile$$,,'\`" | \ 128 cd $(if $(1),$(shell dirname $(1))); $(TOPDIR)/qmake/qmake $(3) -o $(if $(1),$(shell basename $(1))) `cat $(OPIEDIR)/packages | grep " \`echo $(1)|sed -e 's,/Makefile$$,,'\`" | \
109 head -1 | awk '{print $$3}'` 129 head -1 | awk '{print $$3}'`
110endef 130endef
111 131
112define makecfg 132define makecfg