|
|
|
@@ -1,122 +1,124 @@ |
1 | .phony: force |
1 | .phony: force |
2 | force: |
2 | force: |
3 | |
3 | |
4 | $(configs) : |
4 | $(configs) : |
5 | $(call makecfg,$@) |
5 | $(call makecfg,$@) |
6 | |
6 | |
7 | $(TOPDIR)/gen.pro : $(TOPDIR)/.config |
7 | $(TOPDIR)/gen.pro : $(TOPDIR)/.config |
8 | echo > $@ |
8 | echo > $@ |
9 | # added for threaded version |
9 | # added for threaded version |
10 | ifneq ($(CONFIG_THREADED),) |
10 | ifneq ($(CONFIG_THREADED),) |
11 | echo CONFIG += thread >> $@ |
11 | echo CONFIG += thread >> $@ |
12 | else |
12 | else |
13 | echo CONFIG -= thread >> $@ |
13 | echo CONFIG -= thread >> $@ |
14 | endif |
14 | endif |
15 | ifneq ($(CONFIG_DEBUG),) |
15 | ifneq ($(CONFIG_DEBUG),) |
16 | echo CONFIG += debug >> $@ |
16 | echo CONFIG += debug >> $@ |
17 | echo CONFIG -= release >> $@ |
17 | echo CONFIG -= release >> $@ |
18 | echo DEFINES += "QT_COMPONENT_DEBUG=2" >> $@ |
18 | echo DEFINES += "QT_COMPONENT_DEBUG=2" >> $@ |
19 | echo DEFINES += QT_DEBUG >> $@ |
19 | echo DEFINES += QT_DEBUG >> $@ |
20 | else |
20 | else |
21 | echo CONFIG -= debug >> $@ |
21 | echo CONFIG -= debug >> $@ |
22 | echo CONFIG += release >> $@ |
22 | echo CONFIG += release >> $@ |
23 | echo DEFINES += "OPIE_NO_DEBUG" >> $@ |
23 | echo DEFINES += "OPIE_NO_DEBUG" >> $@ |
24 | endif |
24 | endif |
25 | ifeq ($(CONFIG_STATIC),y) |
25 | ifeq ($(CONFIG_STATIC),y) |
| |
26 | echo !contains\( TARGET,qpe \) \{ >> $@ |
26 | echo CONFIG += staticlib >> $@ |
27 | echo CONFIG += staticlib >> $@ |
| |
28 | echo \} >> $@ |
27 | endif |
29 | endif |
28 | ifeq ($(filter 3.%,$(QTE_VERSION)),) # not qt3 |
30 | ifeq ($(filter 3.%,$(QTE_VERSION)),) # not qt3 |
29 | echo CONFIG -= qt3 >> $@ |
31 | echo CONFIG -= qt3 >> $@ |
30 | else |
32 | else |
31 | echo CONFIG += qt3 >> $@ |
33 | echo CONFIG += qt3 >> $@ |
32 | endif |
34 | endif |
33 | ifneq ($(CONFIG_QUICK_LAUNCH),) |
35 | ifneq ($(CONFIG_QUICK_LAUNCH),) |
34 | echo contains\( CONFIG, quick-app \) \{ >> $@ |
36 | echo contains\( CONFIG, quick-app \) \{ >> $@ |
35 | echo CONFIG -= staticlib >> $@ |
37 | echo CONFIG -= staticlib >> $@ |
36 | echo CONFIG -= quick-app >> $@ |
38 | echo CONFIG -= quick-app >> $@ |
37 | echo CONFIG += quick-app-lib >> $@ |
39 | echo CONFIG += quick-app-lib >> $@ |
38 | echo QUICKLAUNCH_PATH = $(CONFIG_QUICKLAUNCH_PATH) >> $@ |
40 | echo QUICKLAUNCH_PATH = $(CONFIG_QUICKLAUNCH_PATH) >> $@ |
39 | echo \} >> $@ |
41 | echo \} >> $@ |
40 | else |
42 | else |
41 | echo contains\( CONFIG, quick-app \) \{ >> $@ |
43 | echo contains\( CONFIG, quick-app \) \{ >> $@ |
42 | echo CONFIG -= quick-app >> $@ |
44 | echo CONFIG -= quick-app >> $@ |
43 | echo CONFIG += quick-app-bin >> $@ |
45 | echo CONFIG += quick-app-bin >> $@ |
44 | echo \} >> $@ |
46 | echo \} >> $@ |
45 | endif |
47 | endif |
46 | ifeq ($(CONFIG_SQL_PIM_BACKEND),y) |
48 | ifeq ($(CONFIG_SQL_PIM_BACKEND),y) |
47 | echo ENABLE_SQL_PIM_BACKEND=$(CONFIG_SQL_PIM_BACKEND) >> $@ |
49 | echo ENABLE_SQL_PIM_BACKEND=$(CONFIG_SQL_PIM_BACKEND) >> $@ |
48 | else |
50 | else |
49 | echo ENABLE_SQL_PIM_BACKEND=n >> $@ |
51 | echo ENABLE_SQL_PIM_BACKEND=n >> $@ |
50 | endif |
52 | endif |
51 | ifeq ($(CONFIG_OPIE_NO_OVERRIDE_QT),y) |
53 | ifeq ($(CONFIG_OPIE_NO_OVERRIDE_QT),y) |
52 | echo CONFIG += no-override >> $@ |
54 | echo CONFIG += no-override >> $@ |
53 | endif |
55 | endif |
54 | ifeq ($(CONFIG_OPIE_NO_ERASERECT_FIX),y) |
56 | ifeq ($(CONFIG_OPIE_NO_ERASERECT_FIX),y) |
55 | echo DEFINES += OPIE_NO_ERASE_RECT_HACKFIX >> $@ |
57 | echo DEFINES += OPIE_NO_ERASE_RECT_HACKFIX >> $@ |
56 | endif |
58 | endif |
57 | ifeq ($(CONFIG_OPIE_NO_BUILTIN_SHUTDOWN),y) |
59 | ifeq ($(CONFIG_OPIE_NO_BUILTIN_SHUTDOWN),y) |
58 | echo DEFINES += OPIE_NO_BUILTIN_SHUTDOWN >> $@ |
60 | echo DEFINES += OPIE_NO_BUILTIN_SHUTDOWN >> $@ |
59 | endif |
61 | endif |
60 | ifeq ($(CONFIG_OPIE_NO_BUILTIN_CALIBRATE),y) |
62 | ifeq ($(CONFIG_OPIE_NO_BUILTIN_CALIBRATE),y) |
61 | echo DEFINES += OPIE_NO_BUILTIN_CALIBRATE >> $@ |
63 | echo DEFINES += OPIE_NO_BUILTIN_CALIBRATE >> $@ |
62 | endif |
64 | endif |
63 | ifeq ($(CONFIG_USE_REALTIME_AUDIO_THREAD),y) |
65 | ifeq ($(CONFIG_USE_REALTIME_AUDIO_THREAD),y) |
64 | echo DEFINES += USE_REALTIME_AUDIO_THREAD >> $@ |
66 | echo DEFINES += USE_REALTIME_AUDIO_THREAD >> $@ |
65 | endif |
67 | endif |
66 | ifeq ($(CONFIG_USE_FILE_NOTIFICATION),y) |
68 | ifeq ($(CONFIG_USE_FILE_NOTIFICATION),y) |
67 | echo DEFINES += USE_FILE_NOTIFICATION >> $@ |
69 | echo DEFINES += USE_FILE_NOTIFICATION >> $@ |
68 | endif |
70 | endif |
69 | ifeq ($(CONFIG_QT_QWS_ALLOW_CLOCK),y) |
71 | ifeq ($(CONFIG_QT_QWS_ALLOW_CLOCK),y) |
70 | echo DEFINES += QT_QWS_ALLOW_OVERCLOCK >> $@ |
72 | echo DEFINES += QT_QWS_ALLOW_OVERCLOCK >> $@ |
71 | endif |
73 | endif |
72 | ifeq ($(CONFIG_OPIE_NEW_ALLOC),y) |
74 | ifeq ($(CONFIG_OPIE_NEW_ALLOC),y) |
73 | echo DEFINES += OPIE_NEW_MALLOC >> $@ |
75 | echo DEFINES += OPIE_NEW_MALLOC >> $@ |
74 | endif |
76 | endif |
75 | ifeq ($(CONFIG_OPIE_NO_SOUND_PCM_READ_BITS),y) |
77 | ifeq ($(CONFIG_OPIE_NO_SOUND_PCM_READ_BITS),y) |
76 | echo DEFINES += OPIE_NO_SOUND_PCM_READ_BITS >> $@ |
78 | echo DEFINES += OPIE_NO_SOUND_PCM_READ_BITS >> $@ |
77 | endif |
79 | endif |
78 | echo DEFINES += OPIE_SOUND_FRAGMENT_SHIFT=$(CONFIG_OPIE_SOUND_FRAGMENT_SHIFT) >> $@ |
80 | echo DEFINES += OPIE_SOUND_FRAGMENT_SHIFT=$(CONFIG_OPIE_SOUND_FRAGMENT_SHIFT) >> $@ |
79 | ifeq ($(CONFIG_OPIE_WE_VERSION_OVERRIDE),y) |
81 | ifeq ($(CONFIG_OPIE_WE_VERSION_OVERRIDE),y) |
80 | echo DEFINES += OPIE_WE_VERSION=$(CONFIG_OPIE_WE_VERSION) >> $@ |
82 | echo DEFINES += OPIE_WE_VERSION=$(CONFIG_OPIE_WE_VERSION) >> $@ |
81 | endif |
83 | endif |
82 | ifeq ($(CONFIG_OPIE_TASKBAR_LOCK_KEY_STATE),y) |
84 | ifeq ($(CONFIG_OPIE_TASKBAR_LOCK_KEY_STATE),y) |
83 | echo DEFINES += OPIE_TASKBAR_LOCK_KEY_STATE >> $@ |
85 | echo DEFINES += OPIE_TASKBAR_LOCK_KEY_STATE >> $@ |
84 | endif |
86 | endif |
85 | # Write LIB dirs and INC dirs... |
87 | # Write LIB dirs and INC dirs... |
86 | ifeq ($(CONFIG_LIBETPAN_DEP),y) |
88 | ifeq ($(CONFIG_LIBETPAN_DEP),y) |
87 | echo LIBETPAN_LIB_DIR = $(CONFIG_LIBETPAN_LIB_DIR) >> $@ |
89 | echo LIBETPAN_LIB_DIR = $(CONFIG_LIBETPAN_LIB_DIR) >> $@ |
88 | echo LIBETPAN_INC_DIR = $(CONFIG_LIBETPAN_INC_DIR) >> $@ |
90 | echo LIBETPAN_INC_DIR = $(CONFIG_LIBETPAN_INC_DIR) >> $@ |
89 | endif |
91 | endif |
90 | ifeq ($(CONFIG_LIBPCAP_DEP),y) |
92 | ifeq ($(CONFIG_LIBPCAP_DEP),y) |
91 | echo LIBPCAP_LIB_DIR = $(CONFIG_LIBPCAP_LIB_DIR) >> $@ |
93 | echo LIBPCAP_LIB_DIR = $(CONFIG_LIBPCAP_LIB_DIR) >> $@ |
92 | echo LIBPCAP_INC_DIR = $(CONFIG_LIBPCAP_INC_DIR) >> $@ |
94 | echo LIBPCAP_INC_DIR = $(CONFIG_LIBPCAP_INC_DIR) >> $@ |
93 | endif |
95 | endif |
94 | ifeq ($(CONFIG_LIBSQLITE_DEP),y) |
96 | ifeq ($(CONFIG_LIBSQLITE_DEP),y) |
95 | echo LIBSQLITE_LIB_DIR = $(CONFIG_LIBSQLITE_LIB_DIR) >> $@ |
97 | echo LIBSQLITE_LIB_DIR = $(CONFIG_LIBSQLITE_LIB_DIR) >> $@ |
96 | echo LIBSQLITE_INC_DIR = $(CONFIG_LIBSQLITE_INC_DIR) >> $@ |
98 | echo LIBSQLITE_INC_DIR = $(CONFIG_LIBSQLITE_INC_DIR) >> $@ |
97 | endif |
99 | endif |
98 | ifeq ($(CONFIG_LIBXINE_DEP),y) |
100 | ifeq ($(CONFIG_LIBXINE_DEP),y) |
99 | echo LIBXINE_LIB_DIR = $(CONFIG_LIBXINE_LIB_DIR) >> $@ |
101 | echo LIBXINE_LIB_DIR = $(CONFIG_LIBXINE_LIB_DIR) >> $@ |
100 | echo LIBXINE_INC_DIR = $(CONFIG_LIBXINE_INC_DIR) >> $@ |
102 | echo LIBXINE_INC_DIR = $(CONFIG_LIBXINE_INC_DIR) >> $@ |
101 | endif |
103 | endif |
102 | ifeq ($(CONFIG_LIBIPK_DEP),y) |
104 | ifeq ($(CONFIG_LIBIPK_DEP),y) |
103 | echo LIBIPK_LIB_DIR = $(CONFIG_LIBIPK_LIB_DIR) >> $@ |
105 | echo LIBIPK_LIB_DIR = $(CONFIG_LIBIPK_LIB_DIR) >> $@ |
104 | echo LIBIPK_INC_DIR = $(CONFIG_LIBIPK_INC_DIR) >> $@ |
106 | echo LIBIPK_INC_DIR = $(CONFIG_LIBIPK_INC_DIR) >> $@ |
105 | endif |
107 | endif |
106 | ifeq ($(CONFIG_LIBSDK_DEP),y) |
108 | ifeq ($(CONFIG_LIBSDK_DEP),y) |
107 | echo LIBSDL_LIB_DIR = $(CONFIG_LIBSDL_LIB_DIR) >> $@ |
109 | echo LIBSDL_LIB_DIR = $(CONFIG_LIBSDL_LIB_DIR) >> $@ |
108 | echo LIBSDL_INC_DIR = $(CONFIG_LIBSDL_INC_DIR) >> $@ |
110 | echo LIBSDL_INC_DIR = $(CONFIG_LIBSDL_INC_DIR) >> $@ |
109 | endif |
111 | endif |
110 | ifeq ($(CONFIG_LIBSWORD_DEP),y) |
112 | ifeq ($(CONFIG_LIBSWORD_DEP),y) |
111 | echo LIBSWORD_LIB_DIR = $(CONFIG_LIBSWORD_LIB_DIR) >> $@ |
113 | echo LIBSWORD_LIB_DIR = $(CONFIG_LIBSWORD_LIB_DIR) >> $@ |
112 | echo LIBSWORD_INC_DIR = $(CONFIG_LIBSWORD_INC_DIR) >> $@ |
114 | echo LIBSWORD_INC_DIR = $(CONFIG_LIBSWORD_INC_DIR) >> $@ |
113 | endif |
115 | endif |
114 | $(TOPDIR)/.depends : $(shell if [ -e $(TOPDIR)/config.in ]\; then echo $(TOPDIR)/config.in\; fi\;) $(TOPDIR)/.config $(TOPDIR)/packages |
116 | $(TOPDIR)/.depends : $(shell if [ -e $(TOPDIR)/config.in ]\; then echo $(TOPDIR)/config.in\; fi\;) $(TOPDIR)/.config $(TOPDIR)/packages |
115 | @echo Generating dependency information... |
117 | @echo Generating dependency information... |
116 | # add to subdir-y, and add descend rules |
118 | # add to subdir-y, and add descend rules |
117 | @cat $(TOPDIR)/packages | grep -v '^#' | \ |
119 | @cat $(TOPDIR)/packages | grep -v '^#' | \ |
118 | awk '{print \ |
120 | awk '{print \ |
119 | ".PHONY : " $$2 "\n" \ |
121 | ".PHONY : " $$2 "\n" \ |
120 | "subdir-$$(" $$1 ") += " $$2 "\n\n"; \ |
122 | "subdir-$$(" $$1 ") += " $$2 "\n\n"; \ |
121 | print $$2 " : " $$2 "/Makefile\n\t$$(call descend,$$@,$(filter-out $$@,$$(filter-out $$@,$$(MAKECMDGOALS))))\n"; }' > $(TOPDIR)/.depends |
123 | print $$2 " : " $$2 "/Makefile\n\t$$(call descend,$$@,$(filter-out $$@,$$(filter-out $$@,$$(MAKECMDGOALS))))\n"; }' > $(TOPDIR)/.depends |
122 | cat $(TOPDIR)/packages | grep -v '^#' | \ |
124 | cat $(TOPDIR)/packages | grep -v '^#' | \ |
|