Changeset 57889 in vbox
- Timestamp:
- Sep 25, 2015 11:53:24 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/configure
r57866 r57889 327 327 test_execute_path() 328 328 { 329 ## LD_LIBRARY_PATH to set. 330 local_path="${1}" 331 ## Set this to non-empty to make this test non-fatal. 332 local_nofail="${2}" 329 333 echo "executing the binary (LD_LIBRARY_PATH=$1)" >> $LOG 330 LD_LIBRARY_PATH= $1$ODIR.tmp_out > $ODIR.test_execute.log334 LD_LIBRARY_PATH="${local_path}" $ODIR.tmp_out > $ODIR.test_execute.log 331 335 rc=$? 332 336 cat $ODIR.test_execute.log | tee -a $LOG 333 337 if [ $rc -ne 0 ]; then 334 fail 338 test -z "${local_nofail}" && fail 339 echo >> $LOG 340 echo >> $LOG 335 341 return 1 336 342 fi … … 1460 1466 foundqt4= 1461 1467 test_header Qt4 1468 cat > $ODIR.tmp_src.cc << EOF 1469 #include <QtGlobal> 1470 extern "C" int main(void) 1471 { 1472 #if QT_VERSION >= 0x040800 1473 return 0; 1474 #else 1475 return 1; 1476 #endif 1477 } 1478 EOF 1462 1479 if [ "$OS" = "darwin" ]; then 1463 1480 # First check if there is the internal version of Qt. If yes nothing else … … 1490 1507 fi 1491 1508 else 1492 if ! test -d "$PWD/tools/linux.$TARGET_MACHINE/qt" && 1493 test $QT4DIR_PKGCONFIG -eq 1; then 1509 if test $QT4DIR_PKGCONFIG -eq 1; then 1494 1510 # default is to use pkg-config 1495 1511 if which_wrapper pkg-config > /dev/null; then … … 1510 1526 PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \ 1511 1527 pkg-config QtCore --libs` 1512 foundqt4=1 1528 test_compile "$LIBQT4 $LIBPTHREAD $I_INCQT4 $FLGQT4" qt4 qt4 nofatal && 1529 test_execute_path "`strip_L "$LIBQT4"`" nofatal && foundqt4=1 1513 1530 fi 1514 1531 else … … 1516 1533 fail 1517 1534 fi 1518 else 1535 fi 1536 if ! test -n "${foundqt4}"; then 1519 1537 # do it the old way (e.g. user has specified QT4DIR) 1520 cat > $ODIR.tmp_src.cc << EOF 1521 #include <cstdio> 1522 #include <QtGlobal> 1523 extern "C" int main(void) 1524 { 1525 printf("found version %s", QT_VERSION_STR); 1526 #if QT_VERSION >= 0x040800 1527 printf(", OK.\n"); 1528 return 0; 1529 #else 1530 printf(", expected version 4.8.0 or higher\n"); 1531 return 1; 1532 #endif 1533 } 1534 EOF 1535 for q in "$PWD/tools/linux.$TARGET_MACHINE"/qt/v4.8.* $QT4DIR; do 1538 for q in $QT4DIR "$PWD/tools/linux.$TARGET_MACHINE"/qt/v4.8.*; do 1536 1539 INCQT4="$q/include $q/include/QtCore" 1537 1540 FLGQT4="-DQT_SHARED" 1538 1541 I_INCQT4=`prefix_I "$INCQT4"` 1539 1542 LIBQT4="-L$q/lib -lQtCoreVBox" 1540 if test_compile "$LIBQT4 $LIBPTHREAD $I_INCQT4 $FLGQT4" qt4 qt4 nofatal; then 1543 if test_compile "$LIBQT4 $LIBPTHREAD $I_INCQT4 $FLGQT4" qt4 qt4 nofatal && 1544 test_execute_path "`strip_L "$LIBQT4"`" nofatal; then 1541 1545 foundqt4=2 1542 1546 break; 1543 1547 fi 1544 1548 LIBQT4="-L$q/lib -lQtCore" 1545 if test_compile "$LIBQT4 $LIBPTHREAD $I_INCQT4 $FLGQT4" qt4 qt4 nofatal; then 1549 if test_compile "$LIBQT4 $LIBPTHREAD $I_INCQT4 $FLGQT4" qt4 qt4 nofatal && 1550 test_execute_path "`strip_L "$LIBQT4"`" nofatal; then 1546 1551 foundqt4=1 1547 1552 break; … … 1598 1603 fi 1599 1604 test_header "Qt4 devtools" 1600 for q in "$PWD/tools/linux.$TARGET_MACHINE"/qt/v4.8.* $QT4DIR; do1605 for q in $QT4DIR "$PWD/tools/linux.$TARGET_MACHINE"/qt/v4.8.*; do 1601 1606 # first try it with a suffix, some platforms use that 1602 1607 if which_wrapper "$q/bin/moc-qt4" > /dev/null; then
Note:
See TracChangeset
for help on using the changeset viewer.