|
diff --git a/configure b/configure index 299e867..cfc4c39 100755 --- a/ configure+++ b/ configure |
|
@@ -109,143 +109,143 @@ if [ "$HELP" = "yes" ]; then |
109 | cat <<EOF |
109 | cat <<EOF |
110 | Usage: $0 [-debug] [-release] [-shared] [-static] [-qt3] [-platform ...] |
110 | Usage: $0 [-debug] [-release] [-shared] [-static] [-qt3] [-platform ...] |
111 | |
111 | |
112 | The defaults (*) are usually acceptable. Here is a short explanation of |
112 | The defaults (*) are usually acceptable. Here is a short explanation of |
113 | each option: |
113 | each option: |
114 | |
114 | |
115 | * -release ........... Compile and link Qt with debugging turned off. |
115 | * -release ........... Compile and link Qt with debugging turned off. |
116 | -debug ............. Compile and link Qt with debugging turned on. |
116 | -debug ............. Compile and link Qt with debugging turned on. |
117 | |
117 | |
118 | * -shared ............ Create and use a shared Qt library (libqt.so) |
118 | * -shared ............ Create and use a shared Qt library (libqt.so) |
119 | -static ............ Create and use a static Qt library (libqt.a) |
119 | -static ............ Create and use a static Qt library (libqt.a) |
120 | |
120 | |
121 | -qt3 ............... Configure for use with Qt 3.x |
121 | -qt3 ............... Configure for use with Qt 3.x |
122 | |
122 | |
123 | -platform target ... The platform you are building on ($PLATFORM) |
123 | -platform target ... The platform you are building on ($PLATFORM) |
124 | EOF |
124 | EOF |
125 | exit 0; |
125 | exit 0; |
126 | fi |
126 | fi |
127 | |
127 | |
128 | CUSTOM=`echo $PLATFORM | sed -n -e "s/.*-\(.*\)-.*/\1/p"` |
128 | CUSTOM=`echo $PLATFORM | sed -n -e "s/.*-\(.*\)-.*/\1/p"` |
129 | |
129 | |
130 | if [ -f library/custom-$CUSTOM.h ] |
130 | if [ -f library/custom-$CUSTOM.h ] |
131 | then |
131 | then |
132 | rm -f library/custom.h |
132 | rm -f library/custom.h |
133 | ln -s custom-$CUSTOM.h library/custom.h |
133 | ln -s custom-$CUSTOM.h library/custom.h |
134 | fi |
134 | fi |
135 | |
135 | |
136 | mkdir -p include/qpe |
136 | mkdir -p include/qpe |
137 | ( cd include/qpe && rm -f *.h; ln -s ../../library/*.h .; ln -s ../../library/backend/*.h .; rm -f *_p.h; ) |
137 | ( cd include/qpe && rm -f *.h; ln -s ../../library/*.h .; ln -s ../../library/backend/*.h .; rm -f *_p.h; ) |
138 | |
138 | |
139 | mkdir -p include/opie |
139 | mkdir -p include/opie |
140 | ( cd include/opie && rm -f *.h; ln -s ../../libopie/*.h .; rm -f *_p.h; ) |
140 | ( cd include/opie && rm -f *.h; ln -s ../../libopie/*.h .; rm -f *_p.h; ) |
141 | |
141 | |
142 | |
142 | |
143 | echo Creating makefiles... |
143 | echo Creating makefiles... |
144 | |
144 | |
145 | sed -e 's/^\(VERSION.*= \).*/\1'$VERSION_MAJ.$VERSION_MIN.$VERSION_PAT/ <library/library.pro >library/library.pro-v |
145 | sed -e 's/^\(VERSION.*= \).*/\1'$VERSION_MAJ.$VERSION_MIN.$VERSION_PAT/ <library/library.pro >library/library.pro-v |
146 | mv library/library.pro-v library/library.pro |
146 | mv library/library.pro-v library/library.pro |
147 | |
147 | |
148 | if [ "$QT3" = yes ] |
148 | if [ "$QT3" = yes ] |
149 | then |
149 | then |
150 | VCONFIG="CONFIG+=qt3" |
150 | VCONFIG="CONFIG+=qt3" |
151 | else |
151 | else |
152 | VCONFIG="CONFIG+=qt2" |
152 | VCONFIG="CONFIG+=qt2" |
153 | fi |
153 | fi |
154 | |
154 | |
155 | if [ -f $TMAKEPATH/tmake.conf ] |
155 | if [ -f $TMAKEPATH/tmake.conf ] |
156 | then |
156 | then |
157 | # You have tmake. We'll regenerate the file for you... |
157 | # You have tmake. We'll regenerate the file for you... |
158 | echo "Makefiles will be regenerated." |
158 | echo "Makefiles will be regenerated." |
159 | fi |
159 | fi |
160 | |
160 | |
161 | H=`pwd` |
161 | H=`pwd` |
162 | if [ -z "$TOMAKE" ] |
162 | if [ -z "$TOMAKE" ] |
163 | then |
163 | then |
164 | TOMAKE=`make showcomponents` |
164 | TOMAKE=`make showcomponents` |
165 | fi |
165 | fi |
166 | |
166 | |
167 | for a in $TOMAKE ; do |
167 | for a in $TOMAKE ; do |
168 | N=$a/Makefile |
168 | N=$a/Makefile |
169 | M=$a/Makefile.in |
169 | M=$a/Makefile.in |
170 | O=$a/Makefile.add |
170 | O=$a/Makefile.add |
171 | f=`basename $a` |
171 | f=`basename $a` |
172 | |
172 | |
173 | if [ -f $TMAKEPATH/tmake.conf -a -f $a/$f.pro ] |
173 | if [ -f "$TMAKEPATH/tmake.conf" -a -f "$a/$f.pro" ] |
174 | then |
174 | then |
175 | ( cd $a; |
175 | ( cd $a; |
176 | TMAKEPATH=$QTDIR/tmake:$TMAKEPATH \ |
176 | TMAKEPATH=$QTDIR/tmake:$TMAKEPATH \ |
177 | tmake $QCONFIGARG CONFIG+=embedded $VCONFIG \ |
177 | tmake $QCONFIGARG CONFIG+=embedded $VCONFIG \ |
178 | -t $H/qt/tmake/propagate.t $f.pro | |
178 | -t $H/qt/tmake/propagate.t $f.pro | |
179 | sed -e "s|$QTDIR|\$(QTDIR)|g" -e "s|$OPIEDIR|\$(OPIEDIR)|g" >Makefile.in; |
179 | sed -e "s|$QTDIR|\$(QTDIR)|g" -e "s|$OPIEDIR|\$(OPIEDIR)|g" >Makefile.in; |
180 | ) |
180 | ) |
181 | echo -n "." |
181 | echo -n "." |
182 | #echo Building $N.. |
182 | #echo Building $N.. |
183 | appname=`grep '^TARGET' $a/$f.pro | sed 's/^TARGET.*=//' | sed 's/ //g'` |
183 | appname=`grep '^TARGET' $a/$f.pro | sed 's/^TARGET.*=//' | sed 's/ //g'` |
184 | translation=`grep '^TRANSLATION.*[^+]=.*' $a/$f.pro | sed 's,^TRANSL.*=.*i18n\/.*\/,,' | sed 's/ //g' | sed 's,\.ts.*,,' | sed 's,^lib,,' ` |
184 | translation=`grep '^TRANSLATION.*[^+]=.*' $a/$f.pro | sed 's,^TRANSL.*=.*i18n\/.*\/,,' | sed 's/ //g' | sed 's,\.ts.*,,' | sed 's,^lib,,' ` |
185 | if [ -n "$translation" -a -n "$appname" ] |
185 | if [ -n "$translation" -a -n "$appname" ] |
186 | then |
186 | then |
187 | if [ $appname != $translation ] |
187 | if [ "$appname" != "$translation" ] |
188 | then |
188 | then |
189 | echo |
189 | echo |
190 | echo "Warning: translation and appname disagree in $a/$f.pro" |
190 | echo "Warning: translation and appname disagree in $a/$f.pro" |
191 | fi |
191 | fi |
192 | fi |
192 | fi |
193 | |
193 | |
194 | fi |
194 | fi |
195 | |
195 | |
196 | cat > $N <<EOF |
196 | cat > $N <<EOF |
197 | ############################################################################# |
197 | ############################################################################# |
198 | # Automatically generated from $M |
198 | # Automatically generated from $M |
199 | # Build options from $1 |
199 | # Build options from $1 |
200 | ############################################################################# |
200 | ############################################################################# |
201 | |
201 | |
202 | EOF |
202 | EOF |
203 | |
203 | |
204 | SED= |
204 | SED= |
205 | PLATFORM_CFLAGS= |
205 | PLATFORM_CFLAGS= |
206 | |
206 | |
207 | if [ "$f" = "embeddedkonsole" ] |
207 | if [ "$f" = "embeddedkonsole" ] |
208 | then |
208 | then |
209 | case $PLATFORM in |
209 | case $PLATFORM in |
210 | *x86*|*generic*|*ipaq*|*sharp*) |
210 | *x86*|*generic*|*ipaq*|*sharp*) |
211 | SED="$SED /^LIBS.*=/s/\$/ -lutil/;" |
211 | SED="$SED /^LIBS.*=/s/\$/ -lutil/;" |
212 | PLATFORM_CFLAGS="-DHAVE_OPENPTY" |
212 | PLATFORM_CFLAGS="-DHAVE_OPENPTY" |
213 | ;; *) |
213 | ;; *) |
214 | SED= |
214 | SED= |
215 | esac |
215 | esac |
216 | elif [ "$f" = "libmpeg3" ] |
216 | elif [ "$f" = "libmpeg3" ] |
217 | then |
217 | then |
218 | # Patch our Makefile.in file with the platform specifics for the libmpeg3 library |
218 | # Patch our Makefile.in file with the platform specifics for the libmpeg3 library |
219 | # Use the C++ compiler to compile the .c files (because the fixed-point classes are C++ code) |
219 | # Use the C++ compiler to compile the .c files (because the fixed-point classes are C++ code) |
220 | SED='s/\$(CC)/\$(CXX)/;' |
220 | SED='s/\$(CC)/\$(CXX)/;' |
221 | case $PLATFORM |
221 | case $PLATFORM |
222 | in |
222 | in |
223 | # For x86 turn on using floating point, compile mmx and css code |
223 | # For x86 turn on using floating point, compile mmx and css code |
224 | *x86*) |
224 | *x86*) |
225 | # "-funroll-loops -fomit-frame-pointer -malign-loops=2 -malign-jumps=2 -malign-functions=2 -march=i486" |
225 | # "-funroll-loops -fomit-frame-pointer -malign-loops=2 -malign-jumps=2 -malign-functions=2 -march=i486" |
226 | PLATFORM_CFLAGS="-DHAVE_MMX -DHAVE_CSS" |
226 | PLATFORM_CFLAGS="-DHAVE_MMX -DHAVE_CSS" |
227 | SED="$SED /SOURCES.*=/s/=/= video\\/mmxidct.S video\\/reconmmx.s\ /;" |
227 | SED="$SED /SOURCES.*=/s/=/= video\\/mmxidct.S video\\/reconmmx.s\ /;" |
228 | # For generic turn on using floating point |
228 | # For generic turn on using floating point |
229 | ;; *generic*) |
229 | ;; *generic*) |
230 | PLATFORM_CFLAGS="" |
230 | PLATFORM_CFLAGS="" |
231 | # For the ipaq use fixed point maths, don't compile the mmx or css code |
231 | # For the ipaq use fixed point maths, don't compile the mmx or css code |
232 | ;; *ipaq*|*sharp*) |
232 | ;; *ipaq*|*sharp*) |
233 | PLATFORM_CFLAGS="-DUSE_FIXED_POINT" |
233 | PLATFORM_CFLAGS="-DUSE_FIXED_POINT" |
234 | ;; *) |
234 | ;; *) |
235 | # For 'other platforms', turn off optimizations and use fixed point |
235 | # For 'other platforms', turn off optimizations and use fixed point |
236 | PLATFORM_CFLAGS="-O -DUSE_FIXED_POINT" |
236 | PLATFORM_CFLAGS="-O -DUSE_FIXED_POINT" |
237 | esac |
237 | esac |
238 | elif [ "$f" = "libmad" ] |
238 | elif [ "$f" = "libmad" ] |
239 | then |
239 | then |
240 | # Patch our Makefile.in file with the platform specifics for the libmad library |
240 | # Patch our Makefile.in file with the platform specifics for the libmad library |
241 | case $PLATFORM |
241 | case $PLATFORM |
242 | in |
242 | in |
243 | # For x86 use intel optimizations |
243 | # For x86 use intel optimizations |
244 | *x86*) |
244 | *x86*) |
245 | PLATFORM_CFLAGS="-DFPM_INTEL" |
245 | PLATFORM_CFLAGS="-DFPM_INTEL" |
246 | # For the ipaq use ARM asm optimizations |
246 | # For the ipaq use ARM asm optimizations |
247 | ;; *ipaq*|*sharp*) |
247 | ;; *ipaq*|*sharp*) |
248 | PLATFORM_CFLAGS="-DFPM_ARM" |
248 | PLATFORM_CFLAGS="-DFPM_ARM" |
249 | SED="$SED /SOURCES.*=/s/=/= idmt_arm.S /;" |
249 | SED="$SED /SOURCES.*=/s/=/= idmt_arm.S /;" |
250 | # For generic platforms use the C 64-bit implementation |
250 | # For generic platforms use the C 64-bit implementation |
251 | ;; *generic*) |
251 | ;; *generic*) |
|