Skip to content
Newer
Older
100644 179 lines (158 sloc) 4.98 KB
07921e8 @hxw [grifo] updates from Symbio
hxw authored Sep 28, 2010
1 # Makefile
2 #
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
3 # Copyright (c) 2010 Openmoko Inc.
07921e8 @hxw [grifo] updates from Symbio
hxw authored Sep 28, 2010
4 #
5 # Authors Christopher Hall <hsw@openmoko.com>
6 #
7 # This program is free software: you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation, either version 3 of the License, or
10 # (at your option) any later version.
11 #
12 # This program is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with this program. If not, see <http://www.gnu.org/licenses/>.
19
0a6d0f3 @hxw [grifo/wiki] directory rearrangement
hxw authored Nov 3, 2010
20 # +++START_UPDATE_MAKEFILE: Start of auto included code
21 # The text between the +++ and --- tags is copied by the
22 # UpdateMakefiles script. Do not remove or change these tags.
23 # ---
24 # Autodetect root directory
25 define FIND_ROOT_DIR
26 while : ; do \
27 d=$$(pwd) ; \
28 [ -d "$${d}/samo-lib" ] && echo $${d} && exit 0 ; \
29 [ X"/" = X"$${d}" ] && echo ROOT_DIRECTORY_NOT_FOUND && exit 1 ; \
30 cd .. ; \
31 done
32 endef
33 ROOT_DIR := $(shell ${FIND_ROOT_DIR})
34 # Directory of Makefile includes
35 MK_DIR := ${ROOT_DIR}/samo-lib/Mk
36 # Include the initial Makefile setup
37 include ${MK_DIR}/definitions.mk
38 # ---END_UPDATE_MAKEFILE: End of auto included code
39
40
41 include ${GRIFO_APPLICATION_PRE}
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
42
43 PROGRAM = wiki
44 ICON = YES
45
0a6d0f3 @hxw [grifo/wiki] directory rearrangement
hxw authored Nov 3, 2010
46 # some configuration items
47 # enable the progress bar by adding:
48 # PROGRESS_BAR=yes to make command line
49 ifeq (YES,$(strip ${PROGRESS_BAR}))
50 ENABLE_PROGRESS := 1
51 endif
52 ifeq (yes,$(strip ${PROGRESS_BAR}))
53 ENABLE_PROGRESS := 1
54 endif
55
56 # default values are disabled
57 ENABLE_PROGRESS ?= 0
58
59 # optional items for compiler
60 CFLAGS += -DENABLE_PROGRESS="${ENABLE_PROGRESS}"
61
26d2c2b [wiki,grifo] temperature display
Robin Humble authored Jan 10, 2011
62 # enable the temperature display by adding:
63 # TEMPERATURE_DISPLAY=yes to make command line
64 ifeq (YES,$(strip ${TEMPERATURE_DISPLAY}))
65 ENABLE_TEMPERATURE := 1
66 endif
67 ifeq (yes,$(strip ${TEMPERATURE_DISPLAY}))
68 ENABLE_TEMPERATURE := 1
69 endif
70
71 # default values are disabled
72 ENABLE_TEMPERATURE ?= 0
73
74 # optional items for compiler
75 CFLAGS += -DENABLE_TEMPERATURE="${ENABLE_TEMPERATURE}"
76
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
77 # list of sources and headers
78 SOURCES += ${PROGRAM}.c
79 SOURCES += Alloc.c
80 SOURCES += bigram.c
81 SOURCES += bmf.c
82 SOURCES += Bra.c
83 SOURCES += btree.c
84 SOURCES += glyph.c
85 SOURCES += guilib.c
86 SOURCES += history.c
4ed8b9d @hxw [grifo] more fixes for simulator
hxw authored Oct 13, 2010
87 SOURCES += highlight.c
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
88 SOURCES += keyboard.c
89 SOURCES += languages.c
90 SOURCES += lcd_buf_draw.c
91 SOURCES += LzFind.c
92 SOURCES += LzmaDec.c
93 SOURCES += restricted.c
94 SOURCES += search.c
95 SOURCES += search_fnd.c
96 SOURCES += sha1.c
97 SOURCES += utf8.c
98 SOURCES += wiki_info.c
99 SOURCES += wikilib.c
100
101 HEADERS += Alloc.h
102 HEADERS += bigram.h
103 HEADERS += bmf.h
104 HEADERS += Bra.h
105 HEADERS += btree.h
106 HEADERS += general_header.h
107 HEADERS += glyph.h
108 HEADERS += guilib.h
4ed8b9d @hxw [grifo] more fixes for simulator
hxw authored Oct 13, 2010
109 HEADERS += highlight.c
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
110 HEADERS += history.h
111 HEADERS += keyboard.h
112 HEADERS += languages.h
113 HEADERS += lcd_buf_draw.h
114 HEADERS += LzFind.h
115 HEADERS += LzHash.h
116 HEADERS += LzmaDec.h
117 HEADERS += mapping_tables.h
118 HEADERS += restricted.h
119 HEADERS += search_fnd.h
120 HEADERS += search.h
121 HEADERS += sha1.h
122 HEADERS += Types.h
123 HEADERS += utf8.h
124 HEADERS += wiki_info.h
125 HEADERS += wikilib.h
126
127 IMAGES += keyboard_123.png
128 IMAGES += keyboard_abc2_jp.png
129 IMAGES += keyboard_abc2_ko.png
130 IMAGES += keyboard_abc_da.png
131 IMAGES += keyboard_abc_ko.png
132 IMAGES += keyboard_abc.png
133 IMAGES += keyboard_phone_jp_123.png
134 IMAGES += keyboard_phone_jp_abc.png
135 IMAGES += keyboard_phone_jp.png
136 IMAGES += keyboard_phone_tw_123.png
137 IMAGES += keyboard_phone_tw_abc.png
138 IMAGES += keyboard_phone_tw.png
139 IMAGES += nls.png
07921e8 @hxw [grifo] updates from Symbio
hxw authored Sep 28, 2010
140
141 ALL_IMAGES = $(addprefix ${BUILD_PREFIX},all_images.h)
b28e527 @hxw [wiki,grifo] prevent installation of header file in wrong directory
hxw authored Dec 22, 2010
142 PREBUILD_TARGETS += ${ALL_IMAGES}
07921e8 @hxw [grifo] updates from Symbio
hxw authored Sep 28, 2010
143
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
144 IMAGE_HEADERS = $(addsuffix .h,$(addprefix ${BUILD_PREFIX},$(basename ${IMAGES})))
145 CLEAN_TARGETS += ${IMAGE_HEADERS}
07921e8 @hxw [grifo] updates from Symbio
hxw authored Sep 28, 2010
146
147 ${ALL_IMAGES}: build ${IMAGE_HEADERS}
148 @${RM} "$@"
149 @for f in ${IMAGE_HEADERS}; \
150 do \
151 echo Keyboard: $$(basename "$${f}") ; \
152 echo '#include "'$$(basename "$${f}")'"' >> "$@"; \
153 done
154
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
155 SIMULATE_FILES += $(addprefix ../,${IMAGES})
156
157 qmake-project:
158 echo 'all_images.target = all_images.h' >> ${QMAKE_PROJECT}
159 echo 'all_images.commands = '"'"'@$${DEL_FILE} "$$@";'"'" >> ${QMAKE_PROJECT}
160 for h in $(notdir ${IMAGE_HEADERS}); \
161 do \
162 t="$${h%.h}"; \
163 png="$${t}.png"; \
164 echo "all_images.commands += 'echo Keyboard: $${h};'" >> ${QMAKE_PROJECT}; \
165 echo "all_images.commands += 'echo \'\$$\$${LITERAL_HASH}include \"$${h}\"\' >> \"\$$@\";'" >> ${QMAKE_PROJECT}; \
166 echo "all_images.depends += $${h}" >> ${QMAKE_PROJECT}; \
167 echo "$${t}.target = $${h}" >> ${QMAKE_PROJECT}; \
168 echo "$${t}.depends = $${png}" >> ${QMAKE_PROJECT}; \
169 echo "$${t}.commands = '${IMAGE2HEADER} --inverted --header=$${h} --variable=$${t}_image $${png}';" >> ${QMAKE_PROJECT}; \
170 echo "QMAKE_EXTRA_TARGETS += $${t}" >> ${QMAKE_PROJECT}; \
171 done
172 echo 'QMAKE_EXTRA_TARGETS += all_images' >> ${QMAKE_PROJECT}
3247526 [grifo,wiki] Fedora 14 x86_64 requires -lrt to link
Robin Humble authored Dec 28, 2010
173 echo 'QMAKE_LIBS += -lrt' >> ${QMAKE_PROJECT}
65f4d63 @hxw [grifo] make the wiki.app work on the grifo simulator
hxw authored Oct 12, 2010
174 echo 'QMAKE_CLEAN += $$$${all_images.target}' >> ${QMAKE_PROJECT}
175
176
0a6d0f3 @hxw [grifo/wiki] directory rearrangement
hxw authored Nov 3, 2010
177 # this must be at the end
178 include ${GRIFO_APPLICATION_POST}
Something went wrong with that request. Please try again.