|
diff --git a/Makefile b/Makefile index 4d11615..f5c0dbd 100644 --- a/ Makefile+++ b/ Makefile |
|
@@ -1,69 +1,72 @@ |
1 | #!/usr/bin/make -f |
1 | #!/usr/bin/make -f |
2 | |
2 | |
3 | export TOPDIR:=$(shell pwd) |
3 | export TOPDIR:=$(shell pwd) |
4 | |
4 | |
5 | include $(TOPDIR)/Vars.make |
5 | include $(TOPDIR)/Vars.make |
| |
6 | ifneq ($(wildcard $(TOPDIR)/Vars.local),) |
| |
7 | include $(TOPDIR)/Vars.local |
| |
8 | endif |
6 | |
9 | |
7 | noconfig_targets := xconfig menuconfig config oldconfig randconfig \ |
10 | noconfig_targets := xconfig menuconfig config oldconfig randconfig \ |
8 | defconfig allyesconfig allnoconfig allmodconfig \ |
11 | defconfig allyesconfig allnoconfig allmodconfig \ |
9 | clean-configs $(TOPDIR)/scripts/subst $(TOPDIR)/scripts/filesubst \ |
12 | clean-configs $(TOPDIR)/scripts/subst $(TOPDIR)/scripts/filesubst \ |
10 | ipks |
13 | ipks |
11 | |
14 | |
12 | configs += $(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 |
15 | configs += $(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 |
13 | |
16 | |
14 | # $(TOPDIR)/.config depends on .depends.cfgs, as it depends on $(configs) |
17 | # $(TOPDIR)/.config depends on .depends.cfgs, as it depends on $(configs) |
15 | # in order to have a full set of config.in files. |
18 | # in order to have a full set of config.in files. |
16 | # .depends depends on $(TOPDIR)/.config |
19 | # .depends depends on $(TOPDIR)/.config |
17 | # everything else depends on .depends, to ensure the dependencies are |
20 | # everything else depends on .depends, to ensure the dependencies are |
18 | # intact. |
21 | # intact. |
19 | # |
22 | # |
20 | # NOTE: The order in which things happen in this makefile is |
23 | # NOTE: The order in which things happen in this makefile is |
21 | # -critical-. Do not rearrange this! |
24 | # -critical-. Do not rearrange this! |
22 | |
25 | |
23 | all : $(TOPDIR)/.config |
26 | all : $(TOPDIR)/.config |
24 | |
27 | |
25 | ipks: $(OPIEDIR)/scripts/subst $(OPIEDIR)/scripts/filesubst FORCE $(TOPDIR)/.config |
28 | ipks: $(OPIEDIR)/scripts/subst $(OPIEDIR)/scripts/filesubst FORCE $(TOPDIR)/.config |
26 | @find $(OPIEDIR)/ -type f -name \*.control | ( for ctrl in `cat`; do \ |
29 | @find $(OPIEDIR)/ -type f -name \*.control | ( for ctrl in `cat`; do \ |
27 | prerm=`echo $$ctrl|sed -e 's,\.control$$,.prerm,'`; \ |
30 | prerm=`echo $$ctrl|sed -e 's,\.control$$,.prerm,'`; \ |
28 | preinst=`echo $$ctrl|sed -e 's,\.control$$,.preinst,'`; \ |
31 | preinst=`echo $$ctrl|sed -e 's,\.control$$,.preinst,'`; \ |
29 | postrm=`echo $$ctrl|sed -e 's,\.control$$,.postrm,'`; \ |
32 | postrm=`echo $$ctrl|sed -e 's,\.control$$,.postrm,'`; \ |
30 | postinst=`echo $$ctrl|sed -e 's,\.control$$,.postinst,'`; \ |
33 | postinst=`echo $$ctrl|sed -e 's,\.control$$,.postinst,'`; \ |
31 | echo "Building ipk of $$ctrl"; \ |
34 | echo "Building ipk of $$ctrl"; \ |
32 | 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); \ |
35 | 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); \ |
33 | done ) |
36 | done ) |
34 | |
37 | |
35 | $(TOPDIR)/.config : $(TOPDIR)/.depends.cfgs |
38 | $(TOPDIR)/.config : $(TOPDIR)/.depends.cfgs |
36 | |
39 | |
37 | all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(TOPDIR)/.depends.cfgs |
40 | all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(TOPDIR)/.depends.cfgs |
38 | |
41 | |
39 | clean-configs : |
42 | clean-configs : |
40 | @echo "Wiping generated config.in files..." |
43 | @echo "Wiping generated config.in files..." |
41 | @-rm -f $(configs) |
44 | @-rm -f $(configs) |
42 | |
45 | |
43 | ifneq ($(wildcard $(TOPDIR)/.depends.cfgs),) |
46 | ifneq ($(wildcard $(TOPDIR)/.depends.cfgs),) |
44 | include $(TOPDIR)/.depends.cfgs |
47 | include $(TOPDIR)/.depends.cfgs |
45 | endif |
48 | endif |
46 | |
49 | |
47 | all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(configs) |
50 | all menuconfig xconfig oldconfig config randconfig allyesconfig allnoconfig defconfig : $(configs) |
48 | |
51 | |
49 | $(TOPDIR)/.config: $(TOPDIR)/.depends.cfgs $(configs) |
52 | $(TOPDIR)/.config: $(TOPDIR)/.depends.cfgs $(configs) |
50 | $(call descend,scripts/kconfig,conf) |
53 | $(call descend,scripts/kconfig,conf) |
51 | @if [ ! -e $@ ]; then \ |
54 | @if [ ! -e $@ ]; then \ |
52 | cp $(TOPDIR)/def-configs/opie $@; \ |
55 | cp $(TOPDIR)/def-configs/opie $@; \ |
53 | fi; |
56 | fi; |
54 | @$(MAKE) -C scripts/kconfig conf; |
57 | @$(MAKE) -C scripts/kconfig conf; |
55 | ./scripts/kconfig/conf -s ./config.in |
58 | ./scripts/kconfig/conf -s ./config.in |
56 | |
59 | |
57 | # config rules must have the $(configs) var defined |
60 | # config rules must have the $(configs) var defined |
58 | # at the time that they run. we must ensure that .depends.cfgs |
61 | # at the time that they run. we must ensure that .depends.cfgs |
59 | # is built and included by the time we reach this point. |
62 | # is built and included by the time we reach this point. |
60 | |
63 | |
61 | xconfig : |
64 | xconfig : |
62 | $(call descend,scripts/kconfig,qconf) |
65 | $(call descend,scripts/kconfig,qconf) |
63 | LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:$(TOPDIR)/scripts/kconfig \ |
66 | LD_LIBRARY_PATH=$$LD_LIBRARY_PATH:$(TOPDIR)/scripts/kconfig \ |
64 | ./scripts/kconfig/qconf ./config.in |
67 | ./scripts/kconfig/qconf ./config.in |
65 | |
68 | |
66 | menuconfig : scripts/lxdialog/lxdialog |
69 | menuconfig : scripts/lxdialog/lxdialog |
67 | $(call descend,scripts/kconfig,mconf) |
70 | $(call descend,scripts/kconfig,mconf) |
68 | ./scripts/kconfig/mconf ./config.in |
71 | ./scripts/kconfig/mconf ./config.in |
69 | |
72 | |
|