230 ;; |
232 ;; |
231 esac |
233 esac |
232 shift |
234 shift |
233 done |
235 done |
234 |
236 |
|
237 checkostype() |
|
238 { |
|
239 match="darwin" |
|
240 if [ "$OSTYPE" = "${match}"* ]; then |
|
241 OS="darwin" |
|
242 QMKSPEC="-spec macx-g++" |
|
243 echo "QMAKESPEC = "$QMKSPEC >> "$CONFIG_IN" |
|
244 fi |
|
245 } |
|
246 |
235 findframeworks() |
247 findframeworks() |
236 { |
248 { |
237 # figure out if Qt was built with frameworks |
249 # figure out if Qt was built with frameworks |
238 # if so, install in the correct place. |
250 # if so, install in the correct place. |
239 # and fix rpath |
251 # and fix rpath |
240 echo "contains(QT_CONFIG,qt_framework):message(1)" > 1.pro |
252 echo "contains(QT_CONFIG,qt_framework):message(1)" > 1.pro |
241 SOMETHING=`qmake 1.pro 2>&1` |
253 SOMETHING=`qmake -spec macx-g++ 1.pro 2>&1` |
242 if [ "$SOMETHING" = "Project MESSAGE: 1" ]; then |
254 if [ "$SOMETHING" = "Project MESSAGE: 1" ]; then |
243 LIB_PATH="Library/Frameworks" |
255 LIB_PATH="Library/Frameworks" |
244 BIN_PATH="Applications" |
256 BIN_PATH="Applications" |
245 fi |
257 fi |
246 rm 1.pro |
258 rm 1.pro |
247 } |
259 } |
248 |
260 |
249 findframeworks |
|
250 |
261 |
251 findUniversal() |
262 findUniversal() |
252 { |
263 { |
253 if [ -e "mac.inc" ]; then |
264 if [ -e "mac.inc" ]; then |
254 rm mac.inc |
265 rm mac.inc |
255 fi |
266 fi |
256 echo "contains(QT_CONFIG,x86): system(echo CONFIG+=x86 >> mac.inc)" > 2.pro |
267 echo "contains(QT_CONFIG,x86): system(echo CONFIG+=x86 >> mac.inc)" > 2.pro |
257 echo "contains(QT_CONFIG,ppc): system(echo CONFIG+=ppc >> mac.inc)" >> 2.pro |
268 echo "contains(QT_CONFIG,ppc): system(echo CONFIG+=ppc >> mac.inc)" >> 2.pro |
258 echo "contains(QT_CONFIG,ppc64): system(echo CONFIG+=ppc64 >> mac.inc)" >> 2.pro |
269 echo "contains(QT_CONFIG,ppc64): system(echo CONFIG+=ppc64 >> mac.inc)" >> 2.pro |
259 echo "contains(QT_CONFIG,x86_64): system(echo CONFIG+=x86_64 >> mac.inc)" >> 2.pro |
270 echo "contains(QT_CONFIG,x86_64): system(echo CONFIG+=x86_64 >> mac.inc)" >> 2.pro |
260 SOMETIME=`qmake 2.pro 2>&1` |
271 SOMETIME=`qmake -spec macx-g++ 2.pro 2>&1` |
261 rm 2.pro |
272 rm 2.pro |
262 if [ -e "mac.inc" ]; then |
273 if [ -e "mac.inc" ]; then |
263 echo "exists(mac.inc): include(mac.inc)" >> "$CONFIG_IN" |
274 echo "exists(mac.inc): include(mac.inc)" >> "$CONFIG_IN" |
264 fi |
275 fi |
265 } |
276 } |
266 |
277 |
|
278 checkostype |
|
279 |
|
280 if [ "$OS" = "darwin" ] ; then |
|
281 findframeworks |
|
282 fi |
267 |
283 |
268 if [ -n "$BUILD_SILENT" ]; then |
284 if [ -n "$BUILD_SILENT" ]; then |
269 echo "CONFIG += silent" > "$CONFIG_IN" |
285 echo "CONFIG += silent" > "$CONFIG_IN" |
270 fi |
286 fi |
271 |
287 |
272 findUniversal |
288 if [ "$OS" = "darwin" ] ; then |
|
289 findUniversal |
|
290 fi |
273 |
291 |
274 if [ -z "$RELEASEMODE" ]; then |
292 if [ -z "$RELEASEMODE" ]; then |
275 RELEASEMODE="debug" |
293 RELEASEMODE="debug" |
276 fi |
294 fi |
277 echo "CONFIG += $RELEASEMODE" >> "$CONFIG_IN" |
295 echo "CONFIG += $RELEASEMODE" >> "$CONFIG_IN" |
428 compileTest QMF qmf |
446 compileTest QMF qmf |
429 compileTest NetworkManager networkmanager |
447 compileTest NetworkManager networkmanager |
430 compileTest "CoreWLAN (MacOS 10.6)" corewlan |
448 compileTest "CoreWLAN (MacOS 10.6)" corewlan |
431 compileTest "Maemo ICD" maemo-icd |
449 compileTest "Maemo ICD" maemo-icd |
432 compileTest "Maemo ICD WLAN" maemo-icd-network-wlan |
450 compileTest "Maemo ICD WLAN" maemo-icd-network-wlan |
|
451 if [ "$LINUX_TARGET" = maemo6 ]; then |
|
452 compileTest sensord sensord |
|
453 else |
|
454 echo "sensord_enabled = no" >> "$CONFIG_IN" |
|
455 fi |
433 |
456 |
434 # Now module selection |
457 # Now module selection |
435 # using 'expr match ....' should help a bit |
458 # using 'expr match ....' should help a bit |
436 #if [ -n "$MOBILITY_MODULES_UNPARSED" ]; then |
459 #if [ -n "$MOBILITY_MODULES_UNPARSED" ]; then |
437 # In theory we should do some sanity checking here. |
460 # In theory we should do some sanity checking here. |
453 rm -rf $shadowpath/include |
476 rm -rf $shadowpath/include |
454 mkdir $shadowpath/include |
477 mkdir $shadowpath/include |
455 for module in $MOBILITY_MODULES; do |
478 for module in $MOBILITY_MODULES; do |
456 case "$module" in |
479 case "$module" in |
457 bearer) |
480 bearer) |
458 $relpath/bin/syncheaders $shadowpath/include $relpath/src/bearer |
481 $relpath/bin/syncheaders $shadowpath/include/QtmBearer $relpath/src/bearer |
459 ;; |
482 ;; |
460 publishsubscribe) |
483 publishsubscribe) |
461 $relpath/bin/syncheaders $shadowpath/include $relpath/src/publishsubscribe |
484 $relpath/bin/syncheaders $shadowpath/include/QtmPubSub $relpath/src/publishsubscribe |
462 ;; |
485 ;; |
463 location) |
486 location) |
464 $relpath/bin/syncheaders $shadowpath/include $relpath/src/location |
487 $relpath/bin/syncheaders $shadowpath/include/QtmLocation $relpath/src/location |
465 ;; |
488 ;; |
466 serviceframework) |
489 serviceframework) |
467 $relpath/bin/syncheaders $shadowpath/include $relpath/src/serviceframework |
490 $relpath/bin/syncheaders $shadowpath/include/QtmServiceFramework $relpath/src/serviceframework |
468 ;; |
491 ;; |
469 systeminfo) |
492 systeminfo) |
470 $relpath/bin/syncheaders $shadowpath/include $relpath/src/systeminfo |
493 $relpath/bin/syncheaders $shadowpath/include/QtmSystemInfo $relpath/src/systeminfo |
471 ;; |
494 ;; |
472 contacts) |
495 contacts) |
473 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts |
496 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts |
474 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts/details |
497 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts/details |
475 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts/requests |
498 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts/requests |
476 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts/filters |
499 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts/filters |
477 ;; |
500 ;; |
478 multimedia) |
501 multimedia) |
479 $relpath/bin/syncheaders $shadowpath/include $relpath/src/multimedia |
502 $relpath/bin/syncheaders $shadowpath/include/QtmMedia $relpath/src/multimedia |
480 ;; |
503 ;; |
481 messaging) |
504 messaging) |
482 $relpath/bin/syncheaders $shadowpath/include $relpath/src/messaging |
505 $relpath/bin/syncheaders $shadowpath/include/QtmMessaging $relpath/src/messaging |
483 ;; |
506 ;; |
484 versit) |
507 versit) |
485 #versit implies contacts |
508 #versit implies contacts |
486 $relpath/bin/syncheaders $shadowpath/include $relpath/src/versit |
509 $relpath/bin/syncheaders $shadowpath/include/QtmVersit $relpath/src/versit |
487 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts |
510 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts |
488 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts/details |
511 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts/details |
489 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts/requests |
512 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts/requests |
490 $relpath/bin/syncheaders $shadowpath/include $relpath/src/contacts/filters |
513 $relpath/bin/syncheaders $shadowpath/include/QtmContacts $relpath/src/contacts/filters |
491 ;; |
514 ;; |
492 sensors) |
515 sensors) |
493 $relpath/bin/syncheaders $shadowpath/include $relpath/src/sensors |
516 $relpath/bin/syncheaders $shadowpath/include/QtmSensors $relpath/src/sensors |
494 ;; |
517 ;; |
495 *) |
518 *) |
496 echo "Cannot generate headers for $module" |
519 echo "Cannot generate headers for $module" |
497 ;; |
520 ;; |
498 esac |
521 esac |
503 if [ "$shadowpath" != "$relpath" ]; then |
526 if [ "$shadowpath" != "$relpath" ]; then |
504 cp -f "$relpath/features/strict_flags.prf" "$shadowpath/features" |
527 cp -f "$relpath/features/strict_flags.prf" "$shadowpath/features" |
505 fi |
528 fi |
506 |
529 |
507 echo "Running qmake..." |
530 echo "Running qmake..." |
508 if qmake -recursive "$relpath/qtmobility.pro"; then |
531 if qmake -makefile $QMKSPEC -recursive "$relpath/qtmobility.pro"; then |
509 echo "" |
532 echo "" |
510 echo "configure has finished. You may run make or gmake to build the project now." |
533 echo "configure has finished. You may run make or gmake to build the project now." |
511 else |
534 else |
512 echo "" |
535 echo "" |
513 echo "configure failed." |
536 echo "configure failed." |