138 QDir(buildPath).mkpath("bin"); |
138 QDir(buildPath).mkpath("bin"); |
139 |
139 |
140 { //duplicate qmake |
140 { //duplicate qmake |
141 QStack<QString> qmake_dirs; |
141 QStack<QString> qmake_dirs; |
142 qmake_dirs.push("qmake"); |
142 qmake_dirs.push("qmake"); |
143 while(!qmake_dirs.isEmpty()) { |
143 while (!qmake_dirs.isEmpty()) { |
144 QString dir = qmake_dirs.pop(); |
144 QString dir = qmake_dirs.pop(); |
145 QString od(buildPath + "/" + dir); |
145 QString od(buildPath + "/" + dir); |
146 QString id(sourcePath + "/" + dir); |
146 QString id(sourcePath + "/" + dir); |
147 QFileInfoList entries = QDir(id).entryInfoList(QDir::NoDotAndDotDot|QDir::AllEntries); |
147 QFileInfoList entries = QDir(id).entryInfoList(QDir::NoDotAndDotDot|QDir::AllEntries); |
148 for(int i = 0; i < entries.size(); ++i) { |
148 for (int i = 0; i < entries.size(); ++i) { |
149 QFileInfo fi(entries.at(i)); |
149 QFileInfo fi(entries.at(i)); |
150 if(fi.isDir()) { |
150 if (fi.isDir()) { |
151 qmake_dirs.push(dir + "/" + fi.fileName()); |
151 qmake_dirs.push(dir + "/" + fi.fileName()); |
152 QDir().mkpath(od + "/" + fi.fileName()); |
152 QDir().mkpath(od + "/" + fi.fileName()); |
153 } else { |
153 } else { |
154 QDir().mkpath(od ); |
154 QDir().mkpath(od); |
155 bool justCopy = true; |
155 bool justCopy = true; |
156 const QString fname = fi.fileName(); |
156 const QString fname = fi.fileName(); |
157 const QString outFile(od + "/" + fname), inFile(id + "/" + fname); |
157 const QString outFile(od + "/" + fname), inFile(id + "/" + fname); |
158 if(fi.fileName() == "Makefile") { //ignore |
158 if (fi.fileName() == "Makefile") { //ignore |
159 } else if(fi.suffix() == "h" || fi.suffix() == "cpp") { |
159 } else if (fi.suffix() == "h" || fi.suffix() == "cpp") { |
160 QTemporaryFile tmpFile; |
160 QTemporaryFile tmpFile; |
161 if(tmpFile.open()) { |
161 if (tmpFile.open()) { |
162 QTextStream stream(&tmpFile); |
162 QTextStream stream(&tmpFile); |
163 stream << "#include \"" << inFile << "\"" << endl; |
163 stream << "#include \"" << inFile << "\"" << endl; |
164 justCopy = false; |
164 justCopy = false; |
165 stream.flush(); |
165 stream.flush(); |
166 tmpFile.flush(); |
166 tmpFile.flush(); |
167 if(filesDiffer(tmpFile.fileName(), outFile)) { |
167 if (filesDiffer(tmpFile.fileName(), outFile)) { |
168 QFile::remove(outFile); |
168 QFile::remove(outFile); |
169 tmpFile.copy(outFile); |
169 tmpFile.copy(outFile); |
170 } |
170 } |
171 } |
171 } |
172 } |
172 } |
173 if(justCopy && filesDiffer(inFile, outFile)) |
173 if (justCopy && filesDiffer(inFile, outFile)) |
174 QFile::copy(inFile, outFile); |
174 QFile::copy(inFile, outFile); |
175 } |
175 } |
176 } |
176 } |
177 } |
177 } |
178 } |
178 } |
179 |
179 |
180 { //make a syncqt script(s) that can be used in the shadow |
180 { //make a syncqt script(s) that can be used in the shadow |
181 QFile syncqt(buildPath + "/bin/syncqt"); |
181 QFile syncqt(buildPath + "/bin/syncqt"); |
182 if(syncqt.open(QFile::WriteOnly)) { |
182 if (syncqt.open(QFile::WriteOnly)) { |
183 QTextStream stream(&syncqt); |
183 QTextStream stream(&syncqt); |
184 stream << "#!/usr/bin/perl -w" << endl |
184 stream << "#!/usr/bin/perl -w" << endl |
185 << "require \"" << sourcePath + "/bin/syncqt\";" << endl; |
185 << "require \"" << sourcePath + "/bin/syncqt\";" << endl; |
186 } |
186 } |
187 QFile syncqt_bat(buildPath + "/bin/syncqt.bat"); |
187 QFile syncqt_bat(buildPath + "/bin/syncqt.bat"); |
188 if(syncqt_bat.open(QFile::WriteOnly)) { |
188 if (syncqt_bat.open(QFile::WriteOnly)) { |
189 QTextStream stream(&syncqt_bat); |
189 QTextStream stream(&syncqt_bat); |
190 stream << "@echo off" << endl |
190 stream << "@echo off" << endl |
191 << "set QTDIR=" << QDir::toNativeSeparators(sourcePath) << endl |
191 << "set QTDIR=" << QDir::toNativeSeparators(sourcePath) << endl |
192 << "call " << fixSeparators(sourcePath) << fixSeparators("/bin/syncqt.bat -outdir \"") << fixSeparators(buildPath) << "\"" << endl |
192 << "call " << fixSeparators(sourcePath) << fixSeparators("/bin/syncqt.bat -outdir \"") << fixSeparators(buildPath) << "\"" << endl |
193 << "set QTDIR=" << QDir::toNativeSeparators(buildPath) << endl; |
193 << "set QTDIR=" << QDir::toNativeSeparators(buildPath) << endl; |
450 } |
458 } |
451 argCount = configCmdLine.size(); |
459 argCount = configCmdLine.size(); |
452 #endif |
460 #endif |
453 |
461 |
454 // Look first for XQMAKESPEC |
462 // Look first for XQMAKESPEC |
455 for(int j = 0 ; j < argCount; ++j) |
463 for (int j = 0 ; j < argCount; ++j) |
456 { |
464 { |
457 if( configCmdLine.at(j) == "-xplatform") { |
465 if (configCmdLine.at(j) == "-xplatform") { |
458 ++j; |
466 ++j; |
459 if (j == argCount) |
467 if (j == argCount) |
460 break; |
468 break; |
461 dictionary["XQMAKESPEC"] = configCmdLine.at(j); |
469 dictionary["XQMAKESPEC"] = configCmdLine.at(j); |
462 if (!dictionary[ "XQMAKESPEC" ].isEmpty()) |
470 if (!dictionary[ "XQMAKESPEC" ].isEmpty()) |
463 applySpecSpecifics(); |
471 applySpecSpecifics(); |
464 } |
472 } |
465 } |
473 } |
466 |
474 |
467 for( ; i<configCmdLine.size(); ++i ) { |
475 for (; i<configCmdLine.size(); ++i) { |
468 bool continueElse[] = {false, false}; |
476 bool continueElse[] = {false, false}; |
469 if( configCmdLine.at(i) == "-help" |
477 if (configCmdLine.at(i) == "-help" |
470 || configCmdLine.at(i) == "-h" |
478 || configCmdLine.at(i) == "-h" |
471 || configCmdLine.at(i) == "-?" ) |
479 || configCmdLine.at(i) == "-?") |
472 dictionary[ "HELP" ] = "yes"; |
480 dictionary[ "HELP" ] = "yes"; |
473 |
481 |
474 #if !defined(EVAL) |
482 #if !defined(EVAL) |
475 else if( configCmdLine.at(i) == "-qconfig" ) { |
483 else if (configCmdLine.at(i) == "-qconfig") { |
476 ++i; |
484 ++i; |
477 if (i==argCount) |
485 if (i == argCount) |
478 break; |
486 break; |
479 dictionary[ "QCONFIG" ] = configCmdLine.at(i); |
487 dictionary[ "QCONFIG" ] = configCmdLine.at(i); |
480 } |
488 } |
481 |
489 |
482 else if ( configCmdLine.at(i) == "-buildkey" ) { |
490 else if (configCmdLine.at(i) == "-buildkey") { |
483 ++i; |
491 ++i; |
484 if (i==argCount) |
492 if (i == argCount) |
485 break; |
493 break; |
486 dictionary[ "USER_BUILD_KEY" ] = configCmdLine.at(i); |
494 dictionary[ "USER_BUILD_KEY" ] = configCmdLine.at(i); |
487 } |
495 } |
488 |
496 |
489 else if( configCmdLine.at(i) == "-release" ) { |
497 else if (configCmdLine.at(i) == "-release") { |
490 dictionary[ "BUILD" ] = "release"; |
498 dictionary[ "BUILD" ] = "release"; |
491 if (dictionary[ "BUILDALL" ] == "auto") |
499 if (dictionary[ "BUILDALL" ] == "auto") |
492 dictionary[ "BUILDALL" ] = "no"; |
500 dictionary[ "BUILDALL" ] = "no"; |
493 } else if( configCmdLine.at(i) == "-debug" ) { |
501 } else if (configCmdLine.at(i) == "-debug") { |
494 dictionary[ "BUILD" ] = "debug"; |
502 dictionary[ "BUILD" ] = "debug"; |
495 if (dictionary[ "BUILDALL" ] == "auto") |
503 if (dictionary[ "BUILDALL" ] == "auto") |
496 dictionary[ "BUILDALL" ] = "no"; |
504 dictionary[ "BUILDALL" ] = "no"; |
497 } else if( configCmdLine.at(i) == "-debug-and-release" ) |
505 } else if (configCmdLine.at(i) == "-debug-and-release") |
498 dictionary[ "BUILDALL" ] = "yes"; |
506 dictionary[ "BUILDALL" ] = "yes"; |
499 |
507 |
500 else if( configCmdLine.at(i) == "-shared" ) |
508 else if (configCmdLine.at(i) == "-shared") |
501 dictionary[ "SHARED" ] = "yes"; |
509 dictionary[ "SHARED" ] = "yes"; |
502 else if( configCmdLine.at(i) == "-static" ) |
510 else if (configCmdLine.at(i) == "-static") |
503 dictionary[ "SHARED" ] = "no"; |
511 dictionary[ "SHARED" ] = "no"; |
504 else if( configCmdLine.at(i) == "-developer-build" ) |
512 else if (configCmdLine.at(i) == "-developer-build") |
505 dictionary[ "BUILDDEV" ] = "yes"; |
513 dictionary[ "BUILDDEV" ] = "yes"; |
506 else if( configCmdLine.at(i) == "-nokia-developer" ) { |
514 else if (configCmdLine.at(i) == "-nokia-developer") { |
507 cout << "Detected -nokia-developer option" << endl; |
515 cout << "Detected -nokia-developer option" << endl; |
508 cout << "Nokia employees and agents are allowed to use this software under" << endl; |
516 cout << "Nokia employees and agents are allowed to use this software under" << endl; |
509 cout << "the authority of Nokia Corporation and/or its subsidiary(-ies)" << endl; |
517 cout << "the authority of Nokia Corporation and/or its subsidiary(-ies)" << endl; |
510 dictionary[ "BUILDNOKIA" ] = "yes"; |
518 dictionary[ "BUILDNOKIA" ] = "yes"; |
511 dictionary[ "BUILDDEV" ] = "yes"; |
519 dictionary[ "BUILDDEV" ] = "yes"; |
512 dictionary["LICENSE_CONFIRMED"] = "yes"; |
520 dictionary["LICENSE_CONFIRMED"] = "yes"; |
513 if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { |
521 if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { |
514 dictionary[ "SYMBIAN_DEFFILES" ] = "no"; |
522 dictionary[ "SYMBIAN_DEFFILES" ] = "no"; |
515 } |
523 } |
516 } |
524 } |
517 else if( configCmdLine.at(i) == "-opensource" ) { |
525 else if (configCmdLine.at(i) == "-opensource") { |
518 dictionary[ "BUILDTYPE" ] = "opensource"; |
526 dictionary[ "BUILDTYPE" ] = "opensource"; |
519 } |
527 } |
520 else if( configCmdLine.at(i) == "-commercial" ) { |
528 else if (configCmdLine.at(i) == "-commercial") { |
521 dictionary[ "BUILDTYPE" ] = "commercial"; |
529 dictionary[ "BUILDTYPE" ] = "commercial"; |
522 } |
530 } |
523 else if( configCmdLine.at(i) == "-ltcg" ) { |
531 else if (configCmdLine.at(i) == "-ltcg") { |
524 dictionary[ "LTCG" ] = "yes"; |
532 dictionary[ "LTCG" ] = "yes"; |
525 } |
533 } |
526 else if( configCmdLine.at(i) == "-no-ltcg" ) { |
534 else if (configCmdLine.at(i) == "-no-ltcg") { |
527 dictionary[ "LTCG" ] = "no"; |
535 dictionary[ "LTCG" ] = "no"; |
528 } |
536 } |
529 #endif |
537 #endif |
530 |
538 |
531 else if( configCmdLine.at(i) == "-platform" ) { |
539 else if (configCmdLine.at(i) == "-platform") { |
532 ++i; |
540 ++i; |
533 if (i==argCount) |
541 if (i == argCount) |
534 break; |
542 break; |
535 dictionary[ "QMAKESPEC" ] = configCmdLine.at(i); |
543 dictionary[ "QMAKESPEC" ] = configCmdLine.at(i); |
536 dictionary[ "QMAKESPEC_FROM" ] = "commandline"; |
544 dictionary[ "QMAKESPEC_FROM" ] = "commandline"; |
537 } else if( configCmdLine.at(i) == "-arch" ) { |
545 } else if (configCmdLine.at(i) == "-arch") { |
538 ++i; |
546 ++i; |
539 if (i==argCount) |
547 if (i == argCount) |
540 break; |
548 break; |
541 dictionary[ "ARCHITECTURE" ] = configCmdLine.at(i); |
549 dictionary[ "ARCHITECTURE" ] = configCmdLine.at(i); |
542 if (configCmdLine.at(i) == "boundschecker") { |
550 if (configCmdLine.at(i) == "boundschecker") { |
543 dictionary[ "ARCHITECTURE" ] = "generic"; // Boundschecker uses the generic arch, |
551 dictionary[ "ARCHITECTURE" ] = "generic"; // Boundschecker uses the generic arch, |
544 qtConfig += "boundschecker"; // but also needs this CONFIG option |
552 qtConfig += "boundschecker"; // but also needs this CONFIG option |
545 } |
553 } |
546 } else if( configCmdLine.at(i) == "-embedded" ) { |
554 } else if (configCmdLine.at(i) == "-embedded") { |
547 dictionary[ "EMBEDDED" ] = "yes"; |
555 dictionary[ "EMBEDDED" ] = "yes"; |
548 } else if( configCmdLine.at(i) == "-xplatform") { |
556 } else if (configCmdLine.at(i) == "-xplatform") { |
549 ++i; |
557 ++i; |
550 // do nothing |
558 // do nothing |
551 } |
559 } |
552 |
560 |
553 |
561 |
554 #if !defined(EVAL) |
562 #if !defined(EVAL) |
555 else if( configCmdLine.at(i) == "-no-zlib" ) { |
563 else if (configCmdLine.at(i) == "-no-zlib") { |
556 // No longer supported since Qt 4.4.0 |
564 // No longer supported since Qt 4.4.0 |
557 // But save the information for later so that we can print a warning |
565 // But save the information for later so that we can print a warning |
558 // |
566 // |
559 // If you REALLY really need no zlib support, you can still disable |
567 // If you REALLY really need no zlib support, you can still disable |
560 // it by doing the following: |
568 // it by doing the following: |
562 // #define QT_NO_COMPRESS (probably by adding to src/corelib/global/qconfig.h) |
570 // #define QT_NO_COMPRESS (probably by adding to src/corelib/global/qconfig.h) |
563 // |
571 // |
564 // There's no guarantee that Qt will build under those conditions |
572 // There's no guarantee that Qt will build under those conditions |
565 |
573 |
566 dictionary[ "ZLIB_FORCED" ] = "yes"; |
574 dictionary[ "ZLIB_FORCED" ] = "yes"; |
567 } else if( configCmdLine.at(i) == "-qt-zlib" ) { |
575 } else if (configCmdLine.at(i) == "-qt-zlib") { |
568 dictionary[ "ZLIB" ] = "qt"; |
576 dictionary[ "ZLIB" ] = "qt"; |
569 } else if( configCmdLine.at(i) == "-system-zlib" ) { |
577 } else if (configCmdLine.at(i) == "-system-zlib") { |
570 dictionary[ "ZLIB" ] = "system"; |
578 dictionary[ "ZLIB" ] = "system"; |
571 } |
579 } |
572 |
580 |
573 // Image formats -------------------------------------------- |
581 // Image formats -------------------------------------------- |
574 else if( configCmdLine.at(i) == "-no-gif" ) |
582 else if (configCmdLine.at(i) == "-no-gif") |
575 dictionary[ "GIF" ] = "no"; |
583 dictionary[ "GIF" ] = "no"; |
576 else if( configCmdLine.at(i) == "-qt-gif" ) |
584 else if (configCmdLine.at(i) == "-qt-gif") |
577 dictionary[ "GIF" ] = "auto"; |
585 dictionary[ "GIF" ] = "plugin"; |
578 |
586 |
579 else if( configCmdLine.at(i) == "-no-libtiff" ) { |
587 else if (configCmdLine.at(i) == "-no-libtiff") { |
580 dictionary[ "TIFF"] = "no"; |
588 dictionary[ "TIFF"] = "no"; |
581 dictionary[ "LIBTIFF" ] = "no"; |
589 dictionary[ "LIBTIFF" ] = "no"; |
582 } else if( configCmdLine.at(i) == "-qt-libtiff" ) { |
590 } else if (configCmdLine.at(i) == "-qt-libtiff") { |
583 dictionary[ "TIFF" ] = "plugin"; |
|
584 dictionary[ "LIBTIFF" ] = "qt"; |
591 dictionary[ "LIBTIFF" ] = "qt"; |
585 } else if( configCmdLine.at(i) == "-system-libtiff" ) { |
592 } else if (configCmdLine.at(i) == "-system-libtiff") { |
586 dictionary[ "TIFF" ] = "plugin"; |
593 dictionary[ "LIBTIFF" ] = "system"; |
587 dictionary[ "LIBTIFF" ] = "system"; |
594 } |
588 } |
595 |
589 |
596 else if (configCmdLine.at(i) == "-no-libjpeg") { |
590 else if( configCmdLine.at(i) == "-no-libjpeg" ) { |
|
591 dictionary[ "JPEG" ] = "no"; |
597 dictionary[ "JPEG" ] = "no"; |
592 dictionary[ "LIBJPEG" ] = "no"; |
598 dictionary[ "LIBJPEG" ] = "no"; |
593 } else if( configCmdLine.at(i) == "-qt-libjpeg" ) { |
599 } else if (configCmdLine.at(i) == "-qt-libjpeg") { |
594 dictionary[ "JPEG" ] = "plugin"; |
|
595 dictionary[ "LIBJPEG" ] = "qt"; |
600 dictionary[ "LIBJPEG" ] = "qt"; |
596 } else if( configCmdLine.at(i) == "-system-libjpeg" ) { |
601 } else if (configCmdLine.at(i) == "-system-libjpeg") { |
597 dictionary[ "JPEG" ] = "plugin"; |
|
598 dictionary[ "LIBJPEG" ] = "system"; |
602 dictionary[ "LIBJPEG" ] = "system"; |
599 } |
603 } |
600 |
604 |
601 else if( configCmdLine.at(i) == "-no-libpng" ) { |
605 else if (configCmdLine.at(i) == "-no-libpng") { |
602 dictionary[ "PNG" ] = "no"; |
606 dictionary[ "PNG" ] = "no"; |
603 dictionary[ "LIBPNG" ] = "no"; |
607 dictionary[ "LIBPNG" ] = "no"; |
604 } else if( configCmdLine.at(i) == "-qt-libpng" ) { |
608 } else if (configCmdLine.at(i) == "-qt-libpng") { |
605 dictionary[ "PNG" ] = "qt"; |
|
606 dictionary[ "LIBPNG" ] = "qt"; |
609 dictionary[ "LIBPNG" ] = "qt"; |
607 } else if( configCmdLine.at(i) == "-system-libpng" ) { |
610 } else if (configCmdLine.at(i) == "-system-libpng") { |
608 dictionary[ "PNG" ] = "qt"; |
|
609 dictionary[ "LIBPNG" ] = "system"; |
611 dictionary[ "LIBPNG" ] = "system"; |
610 } |
612 } |
611 |
613 |
612 else if( configCmdLine.at(i) == "-no-libmng" ) { |
614 else if (configCmdLine.at(i) == "-no-libmng") { |
613 dictionary[ "MNG" ] = "no"; |
615 dictionary[ "MNG" ] = "no"; |
614 dictionary[ "LIBMNG" ] = "no"; |
616 dictionary[ "LIBMNG" ] = "no"; |
615 } else if( configCmdLine.at(i) == "-qt-libmng" ) { |
617 } else if (configCmdLine.at(i) == "-qt-libmng") { |
616 dictionary[ "MNG" ] = "qt"; |
|
617 dictionary[ "LIBMNG" ] = "qt"; |
618 dictionary[ "LIBMNG" ] = "qt"; |
618 } else if( configCmdLine.at(i) == "-system-libmng" ) { |
619 } else if (configCmdLine.at(i) == "-system-libmng") { |
619 dictionary[ "MNG" ] = "qt"; |
|
620 dictionary[ "LIBMNG" ] = "system"; |
620 dictionary[ "LIBMNG" ] = "system"; |
621 } |
621 } |
622 |
622 |
623 // Text Rendering -------------------------------------------- |
623 // Text Rendering -------------------------------------------- |
624 else if( configCmdLine.at(i) == "-no-freetype" ) |
624 else if (configCmdLine.at(i) == "-no-freetype") |
625 dictionary[ "FREETYPE" ] = "no"; |
625 dictionary[ "FREETYPE" ] = "no"; |
626 else if( configCmdLine.at(i) == "-qt-freetype" ) |
626 else if (configCmdLine.at(i) == "-qt-freetype") |
627 dictionary[ "FREETYPE" ] = "yes"; |
627 dictionary[ "FREETYPE" ] = "yes"; |
628 |
628 |
629 // CE- C runtime -------------------------------------------- |
629 // CE- C runtime -------------------------------------------- |
630 else if( configCmdLine.at(i) == "-crt" ) { |
630 else if (configCmdLine.at(i) == "-crt") { |
631 ++i; |
631 ++i; |
632 if (i==argCount) |
632 if (i == argCount) |
633 break; |
633 break; |
634 QDir cDir(configCmdLine.at(i)); |
634 QDir cDir(configCmdLine.at(i)); |
635 if (!cDir.exists()) |
635 if (!cDir.exists()) |
636 cout << "WARNING: Could not find directory (" << qPrintable(configCmdLine.at(i)) << ")for C runtime deployment" << endl; |
636 cout << "WARNING: Could not find directory (" << qPrintable(configCmdLine.at(i)) << ")for C runtime deployment" << endl; |
637 else |
637 else |
651 // we need for crosscompilation; but remember if we asked |
651 // we need for crosscompilation; but remember if we asked |
652 // for it. |
652 // for it. |
653 dictionary[ "CETEST_REQUESTED" ] = "yes"; |
653 dictionary[ "CETEST_REQUESTED" ] = "yes"; |
654 } |
654 } |
655 // Qt/CE - signing tool ------------------------------------- |
655 // Qt/CE - signing tool ------------------------------------- |
656 else if( configCmdLine.at(i) == "-signature") { |
656 else if (configCmdLine.at(i) == "-signature") { |
657 ++i; |
657 ++i; |
658 if (i==argCount) |
658 if (i == argCount) |
659 break; |
659 break; |
660 QFileInfo info(configCmdLine.at(i)); |
660 QFileInfo info(configCmdLine.at(i)); |
661 if (!info.exists()) |
661 if (!info.exists()) |
662 cout << "WARNING: Could not find signature file (" << qPrintable(configCmdLine.at(i)) << ")" << endl; |
662 cout << "WARNING: Could not find signature file (" << qPrintable(configCmdLine.at(i)) << ")" << endl; |
663 else |
663 else |
664 dictionary[ "CE_SIGNATURE" ] = QDir::toNativeSeparators(info.absoluteFilePath()); |
664 dictionary[ "CE_SIGNATURE" ] = QDir::toNativeSeparators(info.absoluteFilePath()); |
665 } |
665 } |
666 // Styles --------------------------------------------------- |
666 // Styles --------------------------------------------------- |
667 else if( configCmdLine.at(i) == "-qt-style-windows" ) |
667 else if (configCmdLine.at(i) == "-qt-style-windows") |
668 dictionary[ "STYLE_WINDOWS" ] = "yes"; |
668 dictionary[ "STYLE_WINDOWS" ] = "yes"; |
669 else if( configCmdLine.at(i) == "-no-style-windows" ) |
669 else if (configCmdLine.at(i) == "-no-style-windows") |
670 dictionary[ "STYLE_WINDOWS" ] = "no"; |
670 dictionary[ "STYLE_WINDOWS" ] = "no"; |
671 |
671 |
672 else if( configCmdLine.at(i) == "-qt-style-windowsce" ) |
672 else if (configCmdLine.at(i) == "-qt-style-windowsce") |
673 dictionary[ "STYLE_WINDOWSCE" ] = "yes"; |
673 dictionary[ "STYLE_WINDOWSCE" ] = "yes"; |
674 else if( configCmdLine.at(i) == "-no-style-windowsce" ) |
674 else if (configCmdLine.at(i) == "-no-style-windowsce") |
675 dictionary[ "STYLE_WINDOWSCE" ] = "no"; |
675 dictionary[ "STYLE_WINDOWSCE" ] = "no"; |
676 else if( configCmdLine.at(i) == "-qt-style-windowsmobile" ) |
676 else if (configCmdLine.at(i) == "-qt-style-windowsmobile") |
677 dictionary[ "STYLE_WINDOWSMOBILE" ] = "yes"; |
677 dictionary[ "STYLE_WINDOWSMOBILE" ] = "yes"; |
678 else if( configCmdLine.at(i) == "-no-style-windowsmobile" ) |
678 else if (configCmdLine.at(i) == "-no-style-windowsmobile") |
679 dictionary[ "STYLE_WINDOWSMOBILE" ] = "no"; |
679 dictionary[ "STYLE_WINDOWSMOBILE" ] = "no"; |
680 |
680 |
681 else if( configCmdLine.at(i) == "-qt-style-windowsxp" ) |
681 else if (configCmdLine.at(i) == "-qt-style-windowsxp") |
682 dictionary[ "STYLE_WINDOWSXP" ] = "yes"; |
682 dictionary[ "STYLE_WINDOWSXP" ] = "yes"; |
683 else if( configCmdLine.at(i) == "-no-style-windowsxp" ) |
683 else if (configCmdLine.at(i) == "-no-style-windowsxp") |
684 dictionary[ "STYLE_WINDOWSXP" ] = "no"; |
684 dictionary[ "STYLE_WINDOWSXP" ] = "no"; |
685 |
685 |
686 else if( configCmdLine.at(i) == "-qt-style-windowsvista" ) |
686 else if (configCmdLine.at(i) == "-qt-style-windowsvista") |
687 dictionary[ "STYLE_WINDOWSVISTA" ] = "yes"; |
687 dictionary[ "STYLE_WINDOWSVISTA" ] = "yes"; |
688 else if( configCmdLine.at(i) == "-no-style-windowsvista" ) |
688 else if (configCmdLine.at(i) == "-no-style-windowsvista") |
689 dictionary[ "STYLE_WINDOWSVISTA" ] = "no"; |
689 dictionary[ "STYLE_WINDOWSVISTA" ] = "no"; |
690 |
690 |
691 else if( configCmdLine.at(i) == "-qt-style-plastique" ) |
691 else if (configCmdLine.at(i) == "-qt-style-plastique") |
692 dictionary[ "STYLE_PLASTIQUE" ] = "yes"; |
692 dictionary[ "STYLE_PLASTIQUE" ] = "yes"; |
693 else if( configCmdLine.at(i) == "-no-style-plastique" ) |
693 else if (configCmdLine.at(i) == "-no-style-plastique") |
694 dictionary[ "STYLE_PLASTIQUE" ] = "no"; |
694 dictionary[ "STYLE_PLASTIQUE" ] = "no"; |
695 |
695 |
696 else if( configCmdLine.at(i) == "-qt-style-cleanlooks" ) |
696 else if (configCmdLine.at(i) == "-qt-style-cleanlooks") |
697 dictionary[ "STYLE_CLEANLOOKS" ] = "yes"; |
697 dictionary[ "STYLE_CLEANLOOKS" ] = "yes"; |
698 else if( configCmdLine.at(i) == "-no-style-cleanlooks" ) |
698 else if (configCmdLine.at(i) == "-no-style-cleanlooks") |
699 dictionary[ "STYLE_CLEANLOOKS" ] = "no"; |
699 dictionary[ "STYLE_CLEANLOOKS" ] = "no"; |
700 |
700 |
701 else if( configCmdLine.at(i) == "-qt-style-motif" ) |
701 else if (configCmdLine.at(i) == "-qt-style-motif") |
702 dictionary[ "STYLE_MOTIF" ] = "yes"; |
702 dictionary[ "STYLE_MOTIF" ] = "yes"; |
703 else if( configCmdLine.at(i) == "-no-style-motif" ) |
703 else if (configCmdLine.at(i) == "-no-style-motif") |
704 dictionary[ "STYLE_MOTIF" ] = "no"; |
704 dictionary[ "STYLE_MOTIF" ] = "no"; |
705 |
705 |
706 else if( configCmdLine.at(i) == "-qt-style-cde" ) |
706 else if (configCmdLine.at(i) == "-qt-style-cde") |
707 dictionary[ "STYLE_CDE" ] = "yes"; |
707 dictionary[ "STYLE_CDE" ] = "yes"; |
708 else if( configCmdLine.at(i) == "-no-style-cde" ) |
708 else if (configCmdLine.at(i) == "-no-style-cde") |
709 dictionary[ "STYLE_CDE" ] = "no"; |
709 dictionary[ "STYLE_CDE" ] = "no"; |
710 |
710 |
711 else if( configCmdLine.at(i) == "-qt-style-s60" ) |
711 else if (configCmdLine.at(i) == "-qt-style-s60") |
712 dictionary[ "STYLE_S60" ] = "yes"; |
712 dictionary[ "STYLE_S60" ] = "yes"; |
713 else if( configCmdLine.at(i) == "-no-style-s60" ) |
713 else if (configCmdLine.at(i) == "-no-style-s60") |
714 dictionary[ "STYLE_S60" ] = "no"; |
714 dictionary[ "STYLE_S60" ] = "no"; |
715 |
715 |
716 // Qt 3 Support --------------------------------------------- |
716 // Qt 3 Support --------------------------------------------- |
717 else if( configCmdLine.at(i) == "-no-qt3support" ) |
717 else if (configCmdLine.at(i) == "-no-qt3support") |
718 dictionary[ "QT3SUPPORT" ] = "no"; |
718 dictionary[ "QT3SUPPORT" ] = "no"; |
719 |
719 |
720 // Work around compiler nesting limitation |
720 // Work around compiler nesting limitation |
721 else |
721 else |
722 continueElse[1] = true; |
722 continueElse[1] = true; |
723 if (!continueElse[1]) { |
723 if (!continueElse[1]) { |
724 } |
724 } |
725 |
725 |
726 // OpenGL Support ------------------------------------------- |
726 // OpenGL Support ------------------------------------------- |
727 else if( configCmdLine.at(i) == "-no-opengl" ) { |
727 else if (configCmdLine.at(i) == "-no-opengl") { |
728 dictionary[ "OPENGL" ] = "no"; |
728 dictionary[ "OPENGL" ] = "no"; |
729 } else if ( configCmdLine.at(i) == "-opengl-es-cm" ) { |
729 } else if (configCmdLine.at(i) == "-opengl-es-cm") { |
730 dictionary[ "OPENGL" ] = "yes"; |
730 dictionary[ "OPENGL" ] = "yes"; |
731 dictionary[ "OPENGL_ES_CM" ] = "yes"; |
731 dictionary[ "OPENGL_ES_CM" ] = "yes"; |
732 } else if ( configCmdLine.at(i) == "-opengl-es-2" ) { |
732 } else if (configCmdLine.at(i) == "-opengl-es-2") { |
733 dictionary[ "OPENGL" ] = "yes"; |
733 dictionary[ "OPENGL" ] = "yes"; |
734 dictionary[ "OPENGL_ES_2" ] = "yes"; |
734 dictionary[ "OPENGL_ES_2" ] = "yes"; |
735 } |
735 } |
736 |
736 |
737 // OpenVG Support ------------------------------------------- |
737 // OpenVG Support ------------------------------------------- |
738 else if( configCmdLine.at(i) == "-openvg" ) { |
738 else if (configCmdLine.at(i) == "-openvg") { |
739 dictionary[ "OPENVG" ] = "yes"; |
739 dictionary[ "OPENVG" ] = "yes"; |
740 } else if( configCmdLine.at(i) == "-no-openvg" ) { |
740 } else if (configCmdLine.at(i) == "-no-openvg") { |
741 dictionary[ "OPENVG" ] = "no"; |
741 dictionary[ "OPENVG" ] = "no"; |
742 } |
742 } |
743 |
743 |
744 // Databases ------------------------------------------------ |
744 // Databases ------------------------------------------------ |
745 else if( configCmdLine.at(i) == "-qt-sql-mysql" ) |
745 else if (configCmdLine.at(i) == "-qt-sql-mysql") |
746 dictionary[ "SQL_MYSQL" ] = "yes"; |
746 dictionary[ "SQL_MYSQL" ] = "yes"; |
747 else if( configCmdLine.at(i) == "-plugin-sql-mysql" ) |
747 else if (configCmdLine.at(i) == "-plugin-sql-mysql") |
748 dictionary[ "SQL_MYSQL" ] = "plugin"; |
748 dictionary[ "SQL_MYSQL" ] = "plugin"; |
749 else if( configCmdLine.at(i) == "-no-sql-mysql" ) |
749 else if (configCmdLine.at(i) == "-no-sql-mysql") |
750 dictionary[ "SQL_MYSQL" ] = "no"; |
750 dictionary[ "SQL_MYSQL" ] = "no"; |
751 |
751 |
752 else if( configCmdLine.at(i) == "-qt-sql-odbc" ) |
752 else if (configCmdLine.at(i) == "-qt-sql-odbc") |
753 dictionary[ "SQL_ODBC" ] = "yes"; |
753 dictionary[ "SQL_ODBC" ] = "yes"; |
754 else if( configCmdLine.at(i) == "-plugin-sql-odbc" ) |
754 else if (configCmdLine.at(i) == "-plugin-sql-odbc") |
755 dictionary[ "SQL_ODBC" ] = "plugin"; |
755 dictionary[ "SQL_ODBC" ] = "plugin"; |
756 else if( configCmdLine.at(i) == "-no-sql-odbc" ) |
756 else if (configCmdLine.at(i) == "-no-sql-odbc") |
757 dictionary[ "SQL_ODBC" ] = "no"; |
757 dictionary[ "SQL_ODBC" ] = "no"; |
758 |
758 |
759 else if( configCmdLine.at(i) == "-qt-sql-oci" ) |
759 else if (configCmdLine.at(i) == "-qt-sql-oci") |
760 dictionary[ "SQL_OCI" ] = "yes"; |
760 dictionary[ "SQL_OCI" ] = "yes"; |
761 else if( configCmdLine.at(i) == "-plugin-sql-oci" ) |
761 else if (configCmdLine.at(i) == "-plugin-sql-oci") |
762 dictionary[ "SQL_OCI" ] = "plugin"; |
762 dictionary[ "SQL_OCI" ] = "plugin"; |
763 else if( configCmdLine.at(i) == "-no-sql-oci" ) |
763 else if (configCmdLine.at(i) == "-no-sql-oci") |
764 dictionary[ "SQL_OCI" ] = "no"; |
764 dictionary[ "SQL_OCI" ] = "no"; |
765 |
765 |
766 else if( configCmdLine.at(i) == "-qt-sql-psql" ) |
766 else if (configCmdLine.at(i) == "-qt-sql-psql") |
767 dictionary[ "SQL_PSQL" ] = "yes"; |
767 dictionary[ "SQL_PSQL" ] = "yes"; |
768 else if( configCmdLine.at(i) == "-plugin-sql-psql" ) |
768 else if (configCmdLine.at(i) == "-plugin-sql-psql") |
769 dictionary[ "SQL_PSQL" ] = "plugin"; |
769 dictionary[ "SQL_PSQL" ] = "plugin"; |
770 else if( configCmdLine.at(i) == "-no-sql-psql" ) |
770 else if (configCmdLine.at(i) == "-no-sql-psql") |
771 dictionary[ "SQL_PSQL" ] = "no"; |
771 dictionary[ "SQL_PSQL" ] = "no"; |
772 |
772 |
773 else if( configCmdLine.at(i) == "-qt-sql-tds" ) |
773 else if (configCmdLine.at(i) == "-qt-sql-tds") |
774 dictionary[ "SQL_TDS" ] = "yes"; |
774 dictionary[ "SQL_TDS" ] = "yes"; |
775 else if( configCmdLine.at(i) == "-plugin-sql-tds" ) |
775 else if (configCmdLine.at(i) == "-plugin-sql-tds") |
776 dictionary[ "SQL_TDS" ] = "plugin"; |
776 dictionary[ "SQL_TDS" ] = "plugin"; |
777 else if( configCmdLine.at(i) == "-no-sql-tds" ) |
777 else if (configCmdLine.at(i) == "-no-sql-tds") |
778 dictionary[ "SQL_TDS" ] = "no"; |
778 dictionary[ "SQL_TDS" ] = "no"; |
779 |
779 |
780 else if( configCmdLine.at(i) == "-qt-sql-db2" ) |
780 else if (configCmdLine.at(i) == "-qt-sql-db2") |
781 dictionary[ "SQL_DB2" ] = "yes"; |
781 dictionary[ "SQL_DB2" ] = "yes"; |
782 else if( configCmdLine.at(i) == "-plugin-sql-db2" ) |
782 else if (configCmdLine.at(i) == "-plugin-sql-db2") |
783 dictionary[ "SQL_DB2" ] = "plugin"; |
783 dictionary[ "SQL_DB2" ] = "plugin"; |
784 else if( configCmdLine.at(i) == "-no-sql-db2" ) |
784 else if (configCmdLine.at(i) == "-no-sql-db2") |
785 dictionary[ "SQL_DB2" ] = "no"; |
785 dictionary[ "SQL_DB2" ] = "no"; |
786 |
786 |
787 else if( configCmdLine.at(i) == "-qt-sql-sqlite" ) |
787 else if (configCmdLine.at(i) == "-qt-sql-sqlite") |
788 dictionary[ "SQL_SQLITE" ] = "yes"; |
788 dictionary[ "SQL_SQLITE" ] = "yes"; |
789 else if( configCmdLine.at(i) == "-plugin-sql-sqlite" ) |
789 else if (configCmdLine.at(i) == "-plugin-sql-sqlite") |
790 dictionary[ "SQL_SQLITE" ] = "plugin"; |
790 dictionary[ "SQL_SQLITE" ] = "plugin"; |
791 else if( configCmdLine.at(i) == "-no-sql-sqlite" ) |
791 else if (configCmdLine.at(i) == "-no-sql-sqlite") |
792 dictionary[ "SQL_SQLITE" ] = "no"; |
792 dictionary[ "SQL_SQLITE" ] = "no"; |
793 else if( configCmdLine.at(i) == "-system-sqlite" ) |
793 else if (configCmdLine.at(i) == "-system-sqlite") |
794 dictionary[ "SQL_SQLITE_LIB" ] = "system"; |
794 dictionary[ "SQL_SQLITE_LIB" ] = "system"; |
795 else if( configCmdLine.at(i) == "-qt-sql-sqlite2" ) |
795 else if (configCmdLine.at(i) == "-qt-sql-sqlite2") |
796 dictionary[ "SQL_SQLITE2" ] = "yes"; |
796 dictionary[ "SQL_SQLITE2" ] = "yes"; |
797 else if( configCmdLine.at(i) == "-plugin-sql-sqlite2" ) |
797 else if (configCmdLine.at(i) == "-plugin-sql-sqlite2") |
798 dictionary[ "SQL_SQLITE2" ] = "plugin"; |
798 dictionary[ "SQL_SQLITE2" ] = "plugin"; |
799 else if( configCmdLine.at(i) == "-no-sql-sqlite2" ) |
799 else if (configCmdLine.at(i) == "-no-sql-sqlite2") |
800 dictionary[ "SQL_SQLITE2" ] = "no"; |
800 dictionary[ "SQL_SQLITE2" ] = "no"; |
801 |
801 |
802 else if( configCmdLine.at(i) == "-qt-sql-ibase" ) |
802 else if (configCmdLine.at(i) == "-qt-sql-ibase") |
803 dictionary[ "SQL_IBASE" ] = "yes"; |
803 dictionary[ "SQL_IBASE" ] = "yes"; |
804 else if( configCmdLine.at(i) == "-plugin-sql-ibase" ) |
804 else if (configCmdLine.at(i) == "-plugin-sql-ibase") |
805 dictionary[ "SQL_IBASE" ] = "plugin"; |
805 dictionary[ "SQL_IBASE" ] = "plugin"; |
806 else if( configCmdLine.at(i) == "-no-sql-ibase" ) |
806 else if (configCmdLine.at(i) == "-no-sql-ibase") |
807 dictionary[ "SQL_IBASE" ] = "no"; |
807 dictionary[ "SQL_IBASE" ] = "no"; |
808 #endif |
808 #endif |
809 // IDE project generation ----------------------------------- |
809 // IDE project generation ----------------------------------- |
810 else if( configCmdLine.at(i) == "-no-dsp" ) |
810 else if (configCmdLine.at(i) == "-no-dsp") |
811 dictionary[ "DSPFILES" ] = "no"; |
811 dictionary[ "DSPFILES" ] = "no"; |
812 else if( configCmdLine.at(i) == "-dsp" ) |
812 else if (configCmdLine.at(i) == "-dsp") |
813 dictionary[ "DSPFILES" ] = "yes"; |
813 dictionary[ "DSPFILES" ] = "yes"; |
814 |
814 |
815 else if( configCmdLine.at(i) == "-no-vcp" ) |
815 else if (configCmdLine.at(i) == "-no-vcp") |
816 dictionary[ "VCPFILES" ] = "no"; |
816 dictionary[ "VCPFILES" ] = "no"; |
817 else if( configCmdLine.at(i) == "-vcp" ) |
817 else if (configCmdLine.at(i) == "-vcp") |
818 dictionary[ "VCPFILES" ] = "yes"; |
818 dictionary[ "VCPFILES" ] = "yes"; |
819 |
819 |
820 else if( configCmdLine.at(i) == "-no-vcproj" ) |
820 else if (configCmdLine.at(i) == "-no-vcproj") |
821 dictionary[ "VCPROJFILES" ] = "no"; |
821 dictionary[ "VCPROJFILES" ] = "no"; |
822 else if( configCmdLine.at(i) == "-vcproj" ) |
822 else if (configCmdLine.at(i) == "-vcproj") |
823 dictionary[ "VCPROJFILES" ] = "yes"; |
823 dictionary[ "VCPROJFILES" ] = "yes"; |
824 |
824 |
825 else if( configCmdLine.at(i) == "-no-incredibuild-xge" ) |
825 else if (configCmdLine.at(i) == "-no-incredibuild-xge") |
826 dictionary[ "INCREDIBUILD_XGE" ] = "no"; |
826 dictionary[ "INCREDIBUILD_XGE" ] = "no"; |
827 else if( configCmdLine.at(i) == "-incredibuild-xge" ) |
827 else if (configCmdLine.at(i) == "-incredibuild-xge") |
828 dictionary[ "INCREDIBUILD_XGE" ] = "yes"; |
828 dictionary[ "INCREDIBUILD_XGE" ] = "yes"; |
829 else if( configCmdLine.at(i) == "-native-gestures" ) |
829 else if (configCmdLine.at(i) == "-native-gestures") |
830 dictionary[ "NATIVE_GESTURES" ] = "yes"; |
830 dictionary[ "NATIVE_GESTURES" ] = "yes"; |
831 else if( configCmdLine.at(i) == "-no-native-gestures" ) |
831 else if (configCmdLine.at(i) == "-no-native-gestures") |
832 dictionary[ "NATIVE_GESTURES" ] = "no"; |
832 dictionary[ "NATIVE_GESTURES" ] = "no"; |
833 #if !defined(EVAL) |
833 #if !defined(EVAL) |
834 // Symbian Support ------------------------------------------- |
834 // Symbian Support ------------------------------------------- |
835 else if (configCmdLine.at(i) == "-fpu" ) |
835 else if (configCmdLine.at(i) == "-fpu") |
836 { |
836 { |
837 ++i; |
837 ++i; |
838 if(i==argCount) |
838 if (i == argCount) |
839 break; |
839 break; |
840 dictionary[ "ARM_FPU_TYPE" ] = configCmdLine.at(i); |
840 dictionary[ "ARM_FPU_TYPE" ] = configCmdLine.at(i); |
841 } |
841 } |
842 |
842 |
843 else if( configCmdLine.at(i) == "-s60" ) |
843 else if (configCmdLine.at(i) == "-s60") |
844 dictionary[ "S60" ] = "yes"; |
844 dictionary[ "S60" ] = "yes"; |
845 else if( configCmdLine.at(i) == "-no-s60" ) |
845 else if (configCmdLine.at(i) == "-no-s60") |
846 dictionary[ "S60" ] = "no"; |
846 dictionary[ "S60" ] = "no"; |
847 |
847 |
848 else if( configCmdLine.at(i) == "-usedeffiles" ) |
848 else if (configCmdLine.at(i) == "-usedeffiles") |
849 dictionary[ "SYMBIAN_DEFFILES" ] = "yes"; |
849 dictionary[ "SYMBIAN_DEFFILES" ] = "yes"; |
850 else if( configCmdLine.at(i) == "-no-usedeffiles" ) |
850 else if (configCmdLine.at(i) == "-no-usedeffiles") |
851 dictionary[ "SYMBIAN_DEFFILES" ] = "no"; |
851 dictionary[ "SYMBIAN_DEFFILES" ] = "no"; |
852 |
852 |
853 // Others --------------------------------------------------- |
853 // Others --------------------------------------------------- |
854 else if (configCmdLine.at(i) == "-fast" ) |
854 else if (configCmdLine.at(i) == "-fast") |
855 dictionary[ "FAST" ] = "yes"; |
855 dictionary[ "FAST" ] = "yes"; |
856 else if (configCmdLine.at(i) == "-no-fast" ) |
856 else if (configCmdLine.at(i) == "-no-fast") |
857 dictionary[ "FAST" ] = "no"; |
857 dictionary[ "FAST" ] = "no"; |
858 |
858 |
859 else if( configCmdLine.at(i) == "-stl" ) |
859 else if (configCmdLine.at(i) == "-stl") |
860 dictionary[ "STL" ] = "yes"; |
860 dictionary[ "STL" ] = "yes"; |
861 else if( configCmdLine.at(i) == "-no-stl" ) |
861 else if (configCmdLine.at(i) == "-no-stl") |
862 dictionary[ "STL" ] = "no"; |
862 dictionary[ "STL" ] = "no"; |
863 |
863 |
864 else if ( configCmdLine.at(i) == "-exceptions" ) |
864 else if (configCmdLine.at(i) == "-exceptions") |
865 dictionary[ "EXCEPTIONS" ] = "yes"; |
865 dictionary[ "EXCEPTIONS" ] = "yes"; |
866 else if ( configCmdLine.at(i) == "-no-exceptions" ) |
866 else if (configCmdLine.at(i) == "-no-exceptions") |
867 dictionary[ "EXCEPTIONS" ] = "no"; |
867 dictionary[ "EXCEPTIONS" ] = "no"; |
868 |
868 |
869 else if ( configCmdLine.at(i) == "-rtti" ) |
869 else if (configCmdLine.at(i) == "-rtti") |
870 dictionary[ "RTTI" ] = "yes"; |
870 dictionary[ "RTTI" ] = "yes"; |
871 else if ( configCmdLine.at(i) == "-no-rtti" ) |
871 else if (configCmdLine.at(i) == "-no-rtti") |
872 dictionary[ "RTTI" ] = "no"; |
872 dictionary[ "RTTI" ] = "no"; |
873 |
873 |
874 else if( configCmdLine.at(i) == "-accessibility" ) |
874 else if (configCmdLine.at(i) == "-accessibility") |
875 dictionary[ "ACCESSIBILITY" ] = "yes"; |
875 dictionary[ "ACCESSIBILITY" ] = "yes"; |
876 else if( configCmdLine.at(i) == "-no-accessibility" ) { |
876 else if (configCmdLine.at(i) == "-no-accessibility") { |
877 dictionary[ "ACCESSIBILITY" ] = "no"; |
877 dictionary[ "ACCESSIBILITY" ] = "no"; |
878 cout << "Setting accessibility to NO" << endl; |
878 cout << "Setting accessibility to NO" << endl; |
879 } |
879 } |
880 |
880 |
881 else if (configCmdLine.at(i) == "-no-mmx") |
881 else if (configCmdLine.at(i) == "-no-mmx") |
897 else if (configCmdLine.at(i) == "-no-iwmmxt") |
897 else if (configCmdLine.at(i) == "-no-iwmmxt") |
898 dictionary[ "IWMMXT" ] = "no"; |
898 dictionary[ "IWMMXT" ] = "no"; |
899 else if (configCmdLine.at(i) == "-iwmmxt") |
899 else if (configCmdLine.at(i) == "-iwmmxt") |
900 dictionary[ "IWMMXT" ] = "yes"; |
900 dictionary[ "IWMMXT" ] = "yes"; |
901 |
901 |
902 else if( configCmdLine.at(i) == "-no-openssl" ) { |
902 else if (configCmdLine.at(i) == "-no-openssl") { |
903 dictionary[ "OPENSSL"] = "no"; |
903 dictionary[ "OPENSSL"] = "no"; |
904 } else if( configCmdLine.at(i) == "-openssl" ) { |
904 } else if (configCmdLine.at(i) == "-openssl") { |
905 dictionary[ "OPENSSL" ] = "yes"; |
905 dictionary[ "OPENSSL" ] = "yes"; |
906 } else if( configCmdLine.at(i) == "-openssl-linked" ) { |
906 } else if (configCmdLine.at(i) == "-openssl-linked") { |
907 dictionary[ "OPENSSL" ] = "linked"; |
907 dictionary[ "OPENSSL" ] = "linked"; |
908 } else if( configCmdLine.at(i) == "-no-qdbus" ) { |
908 } else if (configCmdLine.at(i) == "-no-qdbus") { |
909 dictionary[ "DBUS" ] = "no"; |
909 dictionary[ "DBUS" ] = "no"; |
910 } else if( configCmdLine.at(i) == "-qdbus" ) { |
910 } else if (configCmdLine.at(i) == "-qdbus") { |
911 dictionary[ "DBUS" ] = "yes"; |
911 dictionary[ "DBUS" ] = "yes"; |
912 } else if( configCmdLine.at(i) == "-no-dbus" ) { |
912 } else if (configCmdLine.at(i) == "-no-dbus") { |
913 dictionary[ "DBUS" ] = "no"; |
913 dictionary[ "DBUS" ] = "no"; |
914 } else if( configCmdLine.at(i) == "-dbus" ) { |
914 } else if (configCmdLine.at(i) == "-dbus") { |
915 dictionary[ "DBUS" ] = "yes"; |
915 dictionary[ "DBUS" ] = "yes"; |
916 } else if( configCmdLine.at(i) == "-dbus-linked" ) { |
916 } else if (configCmdLine.at(i) == "-dbus-linked") { |
917 dictionary[ "DBUS" ] = "linked"; |
917 dictionary[ "DBUS" ] = "linked"; |
918 } else if( configCmdLine.at(i) == "-no-script" ) { |
918 } else if (configCmdLine.at(i) == "-no-script") { |
919 dictionary[ "SCRIPT" ] = "no"; |
919 dictionary[ "SCRIPT" ] = "no"; |
920 } else if( configCmdLine.at(i) == "-script" ) { |
920 } else if (configCmdLine.at(i) == "-script") { |
921 dictionary[ "SCRIPT" ] = "yes"; |
921 dictionary[ "SCRIPT" ] = "yes"; |
922 } else if( configCmdLine.at(i) == "-no-scripttools" ) { |
922 } else if (configCmdLine.at(i) == "-no-scripttools") { |
923 dictionary[ "SCRIPTTOOLS" ] = "no"; |
923 dictionary[ "SCRIPTTOOLS" ] = "no"; |
924 } else if( configCmdLine.at(i) == "-scripttools" ) { |
924 } else if (configCmdLine.at(i) == "-scripttools") { |
925 dictionary[ "SCRIPTTOOLS" ] = "yes"; |
925 dictionary[ "SCRIPTTOOLS" ] = "yes"; |
926 } else if( configCmdLine.at(i) == "-no-xmlpatterns" ) { |
926 } else if (configCmdLine.at(i) == "-no-xmlpatterns") { |
927 dictionary[ "XMLPATTERNS" ] = "no"; |
927 dictionary[ "XMLPATTERNS" ] = "no"; |
928 } else if( configCmdLine.at(i) == "-xmlpatterns" ) { |
928 } else if (configCmdLine.at(i) == "-xmlpatterns") { |
929 dictionary[ "XMLPATTERNS" ] = "yes"; |
929 dictionary[ "XMLPATTERNS" ] = "yes"; |
930 } else if( configCmdLine.at(i) == "-no-multimedia" ) { |
930 } else if (configCmdLine.at(i) == "-no-multimedia") { |
931 dictionary[ "MULTIMEDIA" ] = "no"; |
931 dictionary[ "MULTIMEDIA" ] = "no"; |
932 } else if( configCmdLine.at(i) == "-multimedia" ) { |
932 } else if (configCmdLine.at(i) == "-multimedia") { |
933 dictionary[ "MULTIMEDIA" ] = "yes"; |
933 dictionary[ "MULTIMEDIA" ] = "yes"; |
934 } else if( configCmdLine.at(i) == "-audio-backend" ) { |
934 } else if (configCmdLine.at(i) == "-audio-backend") { |
935 dictionary[ "AUDIO_BACKEND" ] = "yes"; |
935 dictionary[ "AUDIO_BACKEND" ] = "yes"; |
936 } else if( configCmdLine.at(i) == "-no-audio-backend" ) { |
936 } else if (configCmdLine.at(i) == "-no-audio-backend") { |
937 dictionary[ "AUDIO_BACKEND" ] = "no"; |
937 dictionary[ "AUDIO_BACKEND" ] = "no"; |
938 } else if( configCmdLine.at(i) == "-no-phonon" ) { |
938 } else if (configCmdLine.at(i) == "-no-phonon") { |
939 dictionary[ "PHONON" ] = "no"; |
939 dictionary[ "PHONON" ] = "no"; |
940 } else if( configCmdLine.at(i) == "-phonon" ) { |
940 } else if (configCmdLine.at(i) == "-phonon") { |
941 dictionary[ "PHONON" ] = "yes"; |
941 dictionary[ "PHONON" ] = "yes"; |
942 } else if( configCmdLine.at(i) == "-no-phonon-backend" ) { |
942 } else if (configCmdLine.at(i) == "-no-phonon-backend") { |
943 dictionary[ "PHONON_BACKEND" ] = "no"; |
943 dictionary[ "PHONON_BACKEND" ] = "no"; |
944 } else if( configCmdLine.at(i) == "-phonon-backend" ) { |
944 } else if (configCmdLine.at(i) == "-phonon-backend") { |
945 dictionary[ "PHONON_BACKEND" ] = "yes"; |
945 dictionary[ "PHONON_BACKEND" ] = "yes"; |
946 } else if( configCmdLine.at(i) == "-phonon-wince-ds9" ) { |
946 } else if (configCmdLine.at(i) == "-phonon-wince-ds9") { |
947 dictionary[ "DIRECTSHOW" ] = "yes"; |
947 dictionary[ "DIRECTSHOW" ] = "yes"; |
948 } else if( configCmdLine.at(i) == "-no-webkit" ) { |
948 } else if (configCmdLine.at(i) == "-no-webkit") { |
949 dictionary[ "WEBKIT" ] = "no"; |
949 dictionary[ "WEBKIT" ] = "no"; |
950 } else if( configCmdLine.at(i) == "-webkit" ) { |
950 } else if (configCmdLine.at(i) == "-webkit") { |
951 dictionary[ "WEBKIT" ] = "yes"; |
951 dictionary[ "WEBKIT" ] = "yes"; |
952 } else if( configCmdLine.at(i) == "-no-declarative" ) { |
952 } else if (configCmdLine.at(i) == "-no-declarative") { |
953 dictionary[ "DECLARATIVE" ] = "no"; |
953 dictionary[ "DECLARATIVE" ] = "no"; |
954 } else if( configCmdLine.at(i) == "-declarative" ) { |
954 } else if (configCmdLine.at(i) == "-declarative") { |
955 dictionary[ "DECLARATIVE" ] = "yes"; |
955 dictionary[ "DECLARATIVE" ] = "yes"; |
956 } else if( configCmdLine.at(i) == "-no-plugin-manifests" ) { |
956 } else if (configCmdLine.at(i) == "-no-plugin-manifests") { |
957 dictionary[ "PLUGIN_MANIFESTS" ] = "no"; |
957 dictionary[ "PLUGIN_MANIFESTS" ] = "no"; |
958 } else if( configCmdLine.at(i) == "-plugin-manifests" ) { |
958 } else if (configCmdLine.at(i) == "-plugin-manifests") { |
959 dictionary[ "PLUGIN_MANIFESTS" ] = "yes"; |
959 dictionary[ "PLUGIN_MANIFESTS" ] = "yes"; |
960 } |
960 } |
961 |
961 |
962 // Work around compiler nesting limitation |
962 // Work around compiler nesting limitation |
963 else |
963 else |
964 continueElse[0] = true; |
964 continueElse[0] = true; |
965 if (!continueElse[0]) { |
965 if (!continueElse[0]) { |
966 } |
966 } |
967 |
967 |
968 else if( configCmdLine.at(i) == "-internal" ) |
968 else if (configCmdLine.at(i) == "-internal") |
969 dictionary[ "QMAKE_INTERNAL" ] = "yes"; |
969 dictionary[ "QMAKE_INTERNAL" ] = "yes"; |
970 |
970 |
971 else if( configCmdLine.at(i) == "-no-qmake" ) |
971 else if (configCmdLine.at(i) == "-no-qmake") |
972 dictionary[ "BUILD_QMAKE" ] = "no"; |
972 dictionary[ "BUILD_QMAKE" ] = "no"; |
973 else if( configCmdLine.at(i) == "-qmake" ) |
973 else if (configCmdLine.at(i) == "-qmake") |
974 dictionary[ "BUILD_QMAKE" ] = "yes"; |
974 dictionary[ "BUILD_QMAKE" ] = "yes"; |
975 |
975 |
976 else if( configCmdLine.at(i) == "-dont-process" ) |
976 else if (configCmdLine.at(i) == "-dont-process") |
977 dictionary[ "NOPROCESS" ] = "yes"; |
977 dictionary[ "NOPROCESS" ] = "yes"; |
978 else if( configCmdLine.at(i) == "-process" ) |
978 else if (configCmdLine.at(i) == "-process") |
979 dictionary[ "NOPROCESS" ] = "no"; |
979 dictionary[ "NOPROCESS" ] = "no"; |
980 |
980 |
981 else if( configCmdLine.at(i) == "-no-qmake-deps" ) |
981 else if (configCmdLine.at(i) == "-no-qmake-deps") |
982 dictionary[ "DEPENDENCIES" ] = "no"; |
982 dictionary[ "DEPENDENCIES" ] = "no"; |
983 else if( configCmdLine.at(i) == "-qmake-deps" ) |
983 else if (configCmdLine.at(i) == "-qmake-deps") |
984 dictionary[ "DEPENDENCIES" ] = "yes"; |
984 dictionary[ "DEPENDENCIES" ] = "yes"; |
985 |
985 |
986 |
986 |
987 else if( configCmdLine.at(i) == "-qtnamespace" ) { |
987 else if (configCmdLine.at(i) == "-qtnamespace") { |
988 ++i; |
988 ++i; |
989 if(i==argCount) |
989 if (i == argCount) |
990 break; |
990 break; |
991 qmakeDefines += "QT_NAMESPACE="+configCmdLine.at(i); |
991 qmakeDefines += "QT_NAMESPACE="+configCmdLine.at(i); |
992 dictionary[ "QT_NAMESPACE" ] = configCmdLine.at(i); |
992 dictionary[ "QT_NAMESPACE" ] = configCmdLine.at(i); |
993 } else if( configCmdLine.at(i) == "-qtlibinfix" ) { |
993 } else if (configCmdLine.at(i) == "-qtlibinfix") { |
994 ++i; |
994 ++i; |
995 if(i==argCount) |
995 if (i == argCount) |
996 break; |
996 break; |
997 dictionary[ "QT_LIBINFIX" ] = configCmdLine.at(i); |
997 dictionary[ "QT_LIBINFIX" ] = configCmdLine.at(i); |
998 if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { |
998 if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { |
999 dictionary[ "QT_INSTALL_PLUGINS" ] = |
999 dictionary[ "QT_INSTALL_PLUGINS" ] = |
1000 QString("\\resource\\qt%1\\plugins").arg(dictionary[ "QT_LIBINFIX" ]); |
1000 QString("\\resource\\qt%1\\plugins").arg(dictionary[ "QT_LIBINFIX" ]); |
1001 } |
1001 } |
1002 } else if( configCmdLine.at(i) == "-D" ) { |
1002 } else if (configCmdLine.at(i) == "-D") { |
1003 ++i; |
1003 ++i; |
1004 if (i==argCount) |
1004 if (i == argCount) |
1005 break; |
1005 break; |
1006 qmakeDefines += configCmdLine.at(i); |
1006 qmakeDefines += configCmdLine.at(i); |
1007 } else if( configCmdLine.at(i) == "-I" ) { |
1007 } else if (configCmdLine.at(i) == "-I") { |
1008 ++i; |
1008 ++i; |
1009 if (i==argCount) |
1009 if (i == argCount) |
1010 break; |
1010 break; |
1011 qmakeIncludes += configCmdLine.at(i); |
1011 qmakeIncludes += configCmdLine.at(i); |
1012 } else if( configCmdLine.at(i) == "-L" ) { |
1012 } else if (configCmdLine.at(i) == "-L") { |
1013 ++i; |
1013 ++i; |
1014 if (i==argCount) |
1014 if (i == argCount) |
1015 break; |
1015 break; |
1016 QFileInfo check(configCmdLine.at(i)); |
1016 QFileInfo check(configCmdLine.at(i)); |
1017 if (!check.isDir()) { |
1017 if (!check.isDir()) { |
1018 cout << "Argument passed to -L option is not a directory path. Did you mean the -l option?" << endl; |
1018 cout << "Argument passed to -L option is not a directory path. Did you mean the -l option?" << endl; |
1019 dictionary[ "DONE" ] = "error"; |
1019 dictionary[ "DONE" ] = "error"; |
1020 break; |
1020 break; |
1021 } |
1021 } |
1022 qmakeLibs += QString("-L" + configCmdLine.at(i)); |
1022 qmakeLibs += QString("-L" + configCmdLine.at(i)); |
1023 } else if( configCmdLine.at(i) == "-l" ) { |
1023 } else if (configCmdLine.at(i) == "-l") { |
1024 ++i; |
1024 ++i; |
1025 if (i==argCount) |
1025 if (i == argCount) |
1026 break; |
1026 break; |
1027 qmakeLibs += QString("-l" + configCmdLine.at(i)); |
1027 qmakeLibs += QString("-l" + configCmdLine.at(i)); |
1028 } else if (configCmdLine.at(i).startsWith("OPENSSL_LIBS=")) { |
1028 } else if (configCmdLine.at(i).startsWith("OPENSSL_LIBS=")) { |
1029 opensslLibs = configCmdLine.at(i); |
1029 opensslLibs = configCmdLine.at(i); |
1030 } |
1030 } else if (configCmdLine.at(i).startsWith("PSQL_LIBS=")) { |
1031 |
1031 psqlLibs = configCmdLine.at(i); |
1032 else if( ( configCmdLine.at(i) == "-override-version" ) || ( configCmdLine.at(i) == "-version-override" ) ){ |
1032 } |
|
1033 |
|
1034 else if ((configCmdLine.at(i) == "-override-version") || (configCmdLine.at(i) == "-version-override")){ |
1033 ++i; |
1035 ++i; |
1034 if (i==argCount) |
1036 if (i == argCount) |
1035 break; |
1037 break; |
1036 dictionary[ "VERSION" ] = configCmdLine.at(i); |
1038 dictionary[ "VERSION" ] = configCmdLine.at(i); |
1037 } |
1039 } |
1038 |
1040 |
1039 else if( configCmdLine.at(i) == "-saveconfig" ) { |
1041 else if (configCmdLine.at(i) == "-saveconfig") { |
1040 ++i; |
1042 ++i; |
1041 if (i==argCount) |
1043 if (i == argCount) |
1042 break; |
1044 break; |
1043 dictionary[ "CUSTOMCONFIG" ] = "_" + configCmdLine.at(i); |
1045 dictionary[ "CUSTOMCONFIG" ] = "_" + configCmdLine.at(i); |
1044 } |
1046 } |
1045 |
1047 |
1046 else if (configCmdLine.at(i) == "-confirm-license") { |
1048 else if (configCmdLine.at(i) == "-confirm-license") { |
1047 dictionary["LICENSE_CONFIRMED"] = "yes"; |
1049 dictionary["LICENSE_CONFIRMED"] = "yes"; |
1048 } |
1050 } |
1049 |
1051 |
1050 else if (configCmdLine.at(i) == "-nomake") { |
1052 else if (configCmdLine.at(i) == "-nomake") { |
1051 ++i; |
1053 ++i; |
1052 if (i==argCount) |
1054 if (i == argCount) |
1053 break; |
1055 break; |
1054 disabledBuildParts += configCmdLine.at(i); |
1056 disabledBuildParts += configCmdLine.at(i); |
1055 } |
1057 } |
1056 |
1058 |
1057 // Directories ---------------------------------------------- |
1059 // Directories ---------------------------------------------- |
1058 else if( configCmdLine.at(i) == "-prefix" ) { |
1060 else if (configCmdLine.at(i) == "-prefix") { |
1059 ++i; |
1061 ++i; |
1060 if(i==argCount) |
1062 if (i == argCount) |
1061 break; |
1063 break; |
1062 dictionary[ "QT_INSTALL_PREFIX" ] = configCmdLine.at(i); |
1064 dictionary[ "QT_INSTALL_PREFIX" ] = configCmdLine.at(i); |
1063 } |
1065 } |
1064 |
1066 |
1065 else if( configCmdLine.at(i) == "-bindir" ) { |
1067 else if (configCmdLine.at(i) == "-bindir") { |
1066 ++i; |
1068 ++i; |
1067 if(i==argCount) |
1069 if (i == argCount) |
1068 break; |
1070 break; |
1069 dictionary[ "QT_INSTALL_BINS" ] = configCmdLine.at(i); |
1071 dictionary[ "QT_INSTALL_BINS" ] = configCmdLine.at(i); |
1070 } |
1072 } |
1071 |
1073 |
1072 else if( configCmdLine.at(i) == "-libdir" ) { |
1074 else if (configCmdLine.at(i) == "-libdir") { |
1073 ++i; |
1075 ++i; |
1074 if(i==argCount) |
1076 if (i == argCount) |
1075 break; |
1077 break; |
1076 dictionary[ "QT_INSTALL_LIBS" ] = configCmdLine.at(i); |
1078 dictionary[ "QT_INSTALL_LIBS" ] = configCmdLine.at(i); |
1077 } |
1079 } |
1078 |
1080 |
1079 else if( configCmdLine.at(i) == "-docdir" ) { |
1081 else if (configCmdLine.at(i) == "-docdir") { |
1080 ++i; |
1082 ++i; |
1081 if(i==argCount) |
1083 if (i == argCount) |
1082 break; |
1084 break; |
1083 dictionary[ "QT_INSTALL_DOCS" ] = configCmdLine.at(i); |
1085 dictionary[ "QT_INSTALL_DOCS" ] = configCmdLine.at(i); |
1084 } |
1086 } |
1085 |
1087 |
1086 else if( configCmdLine.at(i) == "-headerdir" ) { |
1088 else if (configCmdLine.at(i) == "-headerdir") { |
1087 ++i; |
1089 ++i; |
1088 if(i==argCount) |
1090 if (i == argCount) |
1089 break; |
1091 break; |
1090 dictionary[ "QT_INSTALL_HEADERS" ] = configCmdLine.at(i); |
1092 dictionary[ "QT_INSTALL_HEADERS" ] = configCmdLine.at(i); |
1091 } |
1093 } |
1092 |
1094 |
1093 else if( configCmdLine.at(i) == "-plugindir" ) { |
1095 else if (configCmdLine.at(i) == "-plugindir") { |
1094 ++i; |
1096 ++i; |
1095 if(i==argCount) |
1097 if (i == argCount) |
1096 break; |
1098 break; |
1097 dictionary[ "QT_INSTALL_PLUGINS" ] = configCmdLine.at(i); |
1099 dictionary[ "QT_INSTALL_PLUGINS" ] = configCmdLine.at(i); |
1098 } |
1100 } |
1099 |
1101 |
1100 else if( configCmdLine.at(i) == "-importdir" ) { |
1102 else if (configCmdLine.at(i) == "-importdir") { |
1101 ++i; |
1103 ++i; |
1102 if(i==argCount) |
1104 if (i == argCount) |
1103 break; |
1105 break; |
1104 dictionary[ "QT_INSTALL_IMPORTS" ] = configCmdLine.at(i); |
1106 dictionary[ "QT_INSTALL_IMPORTS" ] = configCmdLine.at(i); |
1105 } |
1107 } |
1106 else if( configCmdLine.at(i) == "-datadir" ) { |
1108 else if (configCmdLine.at(i) == "-datadir") { |
1107 ++i; |
1109 ++i; |
1108 if(i==argCount) |
1110 if (i == argCount) |
1109 break; |
1111 break; |
1110 dictionary[ "QT_INSTALL_DATA" ] = configCmdLine.at(i); |
1112 dictionary[ "QT_INSTALL_DATA" ] = configCmdLine.at(i); |
1111 } |
1113 } |
1112 |
1114 |
1113 else if( configCmdLine.at(i) == "-translationdir" ) { |
1115 else if (configCmdLine.at(i) == "-translationdir") { |
1114 ++i; |
1116 ++i; |
1115 if(i==argCount) |
1117 if (i == argCount) |
1116 break; |
1118 break; |
1117 dictionary[ "QT_INSTALL_TRANSLATIONS" ] = configCmdLine.at(i); |
1119 dictionary[ "QT_INSTALL_TRANSLATIONS" ] = configCmdLine.at(i); |
1118 } |
1120 } |
1119 |
1121 |
1120 else if( configCmdLine.at(i) == "-examplesdir" ) { |
1122 else if (configCmdLine.at(i) == "-examplesdir") { |
1121 ++i; |
1123 ++i; |
1122 if(i==argCount) |
1124 if (i == argCount) |
1123 break; |
1125 break; |
1124 dictionary[ "QT_INSTALL_EXAMPLES" ] = configCmdLine.at(i); |
1126 dictionary[ "QT_INSTALL_EXAMPLES" ] = configCmdLine.at(i); |
1125 } |
1127 } |
1126 |
1128 |
1127 else if( configCmdLine.at(i) == "-demosdir" ) { |
1129 else if (configCmdLine.at(i) == "-demosdir") { |
1128 ++i; |
1130 ++i; |
1129 if(i==argCount) |
1131 if (i == argCount) |
1130 break; |
1132 break; |
1131 dictionary[ "QT_INSTALL_DEMOS" ] = configCmdLine.at(i); |
1133 dictionary[ "QT_INSTALL_DEMOS" ] = configCmdLine.at(i); |
1132 } |
1134 } |
1133 |
1135 |
1134 else if( configCmdLine.at(i) == "-hostprefix" ) { |
1136 else if (configCmdLine.at(i) == "-hostprefix") { |
1135 ++i; |
1137 ++i; |
1136 if(i==argCount) |
1138 if (i == argCount) |
1137 break; |
1139 break; |
1138 dictionary[ "QT_HOST_PREFIX" ] = configCmdLine.at(i); |
1140 dictionary[ "QT_HOST_PREFIX" ] = configCmdLine.at(i); |
1139 } |
1141 } |
1140 |
1142 |
1141 else if( configCmdLine.at(i) == "-make" ) { |
1143 else if (configCmdLine.at(i) == "-make") { |
1142 ++i; |
1144 ++i; |
1143 if(i==argCount) |
1145 if (i == argCount) |
1144 break; |
1146 break; |
1145 dictionary[ "MAKE" ] = configCmdLine.at(i); |
1147 dictionary[ "MAKE" ] = configCmdLine.at(i); |
1146 } |
1148 } |
1147 |
1149 |
1148 else if (configCmdLine.at(i) == "-graphicssystem") { |
1150 else if (configCmdLine.at(i) == "-graphicssystem") { |
1739 desc("Third Party Libraries:\n\n"); |
1743 desc("Third Party Libraries:\n\n"); |
1740 |
1744 |
1741 desc("ZLIB", "qt", "-qt-zlib", "Use the zlib bundled with Qt."); |
1745 desc("ZLIB", "qt", "-qt-zlib", "Use the zlib bundled with Qt."); |
1742 desc("ZLIB", "system", "-system-zlib", "Use zlib from the operating system.\nSee http://www.gzip.org/zlib\n"); |
1746 desc("ZLIB", "system", "-system-zlib", "Use zlib from the operating system.\nSee http://www.gzip.org/zlib\n"); |
1743 |
1747 |
1744 desc("GIF", "no", "-no-gif", "Do not compile the plugin for GIF reading support."); |
1748 desc("GIF", "no", "-no-gif", "Do not compile GIF reading support."); |
1745 desc("GIF", "auto", "-qt-gif", "Compile the plugin for GIF reading support.\nSee also src/plugins/imageformats/gif/qgifhandler.h\n"); |
1749 desc("GIF", "auto", "-qt-gif", "Compile GIF reading support.\nSee also src/gui/image/qgifhandler_p.h\n"); |
1746 |
1750 |
1747 desc("LIBPNG", "no", "-no-libpng", "Do not compile in PNG support."); |
1751 desc("LIBPNG", "no", "-no-libpng", "Do not compile PNG support."); |
1748 desc("LIBPNG", "qt", "-qt-libpng", "Use the libpng bundled with Qt."); |
1752 desc("LIBPNG", "qt", "-qt-libpng", "Use the libpng bundled with Qt."); |
1749 desc("LIBPNG", "system","-system-libpng", "Use libpng from the operating system.\nSee http://www.libpng.org/pub/png\n"); |
1753 desc("LIBPNG", "system","-system-libpng", "Use libpng from the operating system.\nSee http://www.libpng.org/pub/png\n"); |
1750 |
1754 |
1751 desc("LIBMNG", "no", "-no-libmng", "Do not compile in MNG support."); |
1755 desc("LIBMNG", "no", "-no-libmng", "Do not compile MNG support."); |
1752 desc("LIBMNG", "qt", "-qt-libmng", "Use the libmng bundled with Qt."); |
1756 desc("LIBMNG", "qt", "-qt-libmng", "Use the libmng bundled with Qt."); |
1753 desc("LIBMNG", "system","-system-libmng", "Use libmng from the operating system.\nSee See http://www.libmng.com\n"); |
1757 desc("LIBMNG", "system","-system-libmng", "Use libmng from the operating system.\nSee See http://www.libmng.com\n"); |
1754 |
1758 |
1755 desc("LIBTIFF", "no", "-no-libtiff", "Do not compile the plugin for TIFF support."); |
1759 desc("LIBTIFF", "no", "-no-libtiff", "Do not compile TIFF support."); |
1756 desc("LIBTIFF", "qt", "-qt-libtiff", "Use the libtiff bundled with Qt."); |
1760 desc("LIBTIFF", "qt", "-qt-libtiff", "Use the libtiff bundled with Qt."); |
1757 desc("LIBTIFF", "system","-system-libtiff", "Use libtiff from the operating system.\nSee http://www.libtiff.org\n"); |
1761 desc("LIBTIFF", "system","-system-libtiff", "Use libtiff from the operating system.\nSee http://www.libtiff.org\n"); |
1758 |
1762 |
1759 desc("LIBJPEG", "no", "-no-libjpeg", "Do not compile the plugin for JPEG support."); |
1763 desc("LIBJPEG", "no", "-no-libjpeg", "Do not compile JPEG support."); |
1760 desc("LIBJPEG", "qt", "-qt-libjpeg", "Use the libjpeg bundled with Qt."); |
1764 desc("LIBJPEG", "qt", "-qt-libjpeg", "Use the libjpeg bundled with Qt."); |
1761 desc("LIBJPEG", "system","-system-libjpeg", "Use libjpeg from the operating system.\nSee http://www.ijg.org\n"); |
1765 desc("LIBJPEG", "system","-system-libjpeg", "Use libjpeg from the operating system.\nSee http://www.ijg.org\n"); |
1762 |
1766 |
1763 #endif |
1767 #endif |
1764 // Qt\Windows only options go below here -------------------------------------------------------------------------------- |
1768 // Qt\Windows only options go below here -------------------------------------------------------------------------------- |
2407 |
2411 |
2408 void Configure::generateOutputVars() |
2412 void Configure::generateOutputVars() |
2409 { |
2413 { |
2410 // Generate variables for output |
2414 // Generate variables for output |
2411 // Build key ---------------------------------------------------- |
2415 // Build key ---------------------------------------------------- |
2412 if ( dictionary.contains("BUILD_KEY") ) { |
2416 if (dictionary.contains("BUILD_KEY")) { |
2413 qmakeVars += dictionary.value("BUILD_KEY"); |
2417 qmakeVars += dictionary.value("BUILD_KEY"); |
2414 } |
2418 } |
2415 |
2419 |
2416 QString build = dictionary[ "BUILD" ]; |
2420 QString build = dictionary[ "BUILD" ]; |
2417 bool buildAll = (dictionary[ "BUILDALL" ] == "yes"); |
2421 bool buildAll = (dictionary[ "BUILDALL" ] == "yes"); |
2418 if ( build == "debug") { |
2422 if (build == "debug") { |
2419 if (buildAll) |
2423 if (buildAll) |
2420 qtConfig += "release"; |
2424 qtConfig += "release"; |
2421 qtConfig += "debug"; |
2425 qtConfig += "debug"; |
2422 } else if (build == "release") { |
2426 } else if (build == "release") { |
2423 if (buildAll) |
2427 if (buildAll) |
2424 qtConfig += "debug"; |
2428 qtConfig += "debug"; |
2425 qtConfig += "release"; |
2429 qtConfig += "release"; |
2426 } |
2430 } |
2427 |
2431 |
2428 // Compression -------------------------------------------------- |
2432 // Compression -------------------------------------------------- |
2429 if( dictionary[ "ZLIB" ] == "qt" ) |
2433 if (dictionary[ "ZLIB" ] == "qt") |
2430 qtConfig += "zlib"; |
2434 qtConfig += "zlib"; |
2431 else if( dictionary[ "ZLIB" ] == "system" ) |
2435 else if (dictionary[ "ZLIB" ] == "system") |
2432 qtConfig += "system-zlib"; |
2436 qtConfig += "system-zlib"; |
2433 |
2437 |
2434 // Image formates ----------------------------------------------- |
2438 // Image formates ----------------------------------------------- |
2435 if( dictionary[ "GIF" ] == "no" ) |
2439 if (dictionary[ "GIF" ] == "no") |
2436 qtConfig += "no-gif"; |
2440 qtConfig += "no-gif"; |
2437 else if( dictionary[ "GIF" ] == "yes" ) |
2441 else if (dictionary[ "GIF" ] == "yes") |
2438 qtConfig += "gif"; |
2442 qtConfig += "gif"; |
2439 else if( dictionary[ "GIF" ] == "plugin" ) |
2443 else if (dictionary[ "GIF" ] == "plugin") |
2440 qmakeFormatPlugins += "gif"; |
2444 qmakeFormatPlugins += "gif"; |
2441 |
2445 |
2442 if( dictionary[ "TIFF" ] == "no" ) |
2446 if (dictionary[ "TIFF" ] == "no") |
2443 qtConfig += "no-tiff"; |
2447 qtConfig += "no-tiff"; |
2444 else if( dictionary[ "TIFF" ] == "plugin" ) |
2448 else if (dictionary[ "TIFF" ] == "yes") |
|
2449 qtConfig += "tiff"; |
|
2450 else if (dictionary[ "TIFF" ] == "plugin") |
2445 qmakeFormatPlugins += "tiff"; |
2451 qmakeFormatPlugins += "tiff"; |
2446 if( dictionary[ "LIBTIFF" ] == "system" ) |
2452 if (dictionary[ "LIBTIFF" ] == "system") |
2447 qtConfig += "system-tiff"; |
2453 qtConfig += "system-tiff"; |
2448 |
2454 |
2449 if( dictionary[ "JPEG" ] == "no" ) |
2455 if (dictionary[ "JPEG" ] == "no") |
2450 qtConfig += "no-jpeg"; |
2456 qtConfig += "no-jpeg"; |
2451 else if( dictionary[ "JPEG" ] == "plugin" ) |
2457 else if (dictionary[ "JPEG" ] == "yes") |
|
2458 qtConfig += "jpeg"; |
|
2459 else if (dictionary[ "JPEG" ] == "plugin") |
2452 qmakeFormatPlugins += "jpeg"; |
2460 qmakeFormatPlugins += "jpeg"; |
2453 if( dictionary[ "LIBJPEG" ] == "system" ) |
2461 if (dictionary[ "LIBJPEG" ] == "system") |
2454 qtConfig += "system-jpeg"; |
2462 qtConfig += "system-jpeg"; |
2455 |
2463 |
2456 if( dictionary[ "PNG" ] == "no" ) |
2464 if (dictionary[ "PNG" ] == "no") |
2457 qtConfig += "no-png"; |
2465 qtConfig += "no-png"; |
2458 else if( dictionary[ "PNG" ] == "qt" ) |
2466 else if (dictionary[ "PNG" ] == "yes") |
2459 qtConfig += "png"; |
2467 qtConfig += "png"; |
2460 if( dictionary[ "LIBPNG" ] == "system" ) |
2468 if (dictionary[ "LIBPNG" ] == "system") |
2461 qtConfig += "system-png"; |
2469 qtConfig += "system-png"; |
2462 |
2470 |
2463 if( dictionary[ "MNG" ] == "no" ) |
2471 if (dictionary[ "MNG" ] == "no") |
2464 qtConfig += "no-mng"; |
2472 qtConfig += "no-mng"; |
2465 else if( dictionary[ "MNG" ] == "qt" ) |
2473 else if (dictionary[ "MNG" ] == "yes") |
2466 qtConfig += "mng"; |
2474 qtConfig += "mng"; |
2467 if( dictionary[ "LIBMNG" ] == "system" ) |
2475 if (dictionary[ "LIBMNG" ] == "system") |
2468 qtConfig += "system-mng"; |
2476 qtConfig += "system-mng"; |
2469 |
2477 |
2470 // Text rendering -------------------------------------------------- |
2478 // Text rendering -------------------------------------------------- |
2471 if( dictionary[ "FREETYPE" ] == "yes" ) |
2479 if (dictionary[ "FREETYPE" ] == "yes") |
2472 qtConfig += "freetype"; |
2480 qtConfig += "freetype"; |
2473 |
2481 |
2474 // Styles ------------------------------------------------------- |
2482 // Styles ------------------------------------------------------- |
2475 if ( dictionary[ "STYLE_WINDOWS" ] == "yes" ) |
2483 if (dictionary[ "STYLE_WINDOWS" ] == "yes") |
2476 qmakeStyles += "windows"; |
2484 qmakeStyles += "windows"; |
2477 |
2485 |
2478 if ( dictionary[ "STYLE_PLASTIQUE" ] == "yes" ) |
2486 if (dictionary[ "STYLE_PLASTIQUE" ] == "yes") |
2479 qmakeStyles += "plastique"; |
2487 qmakeStyles += "plastique"; |
2480 |
2488 |
2481 if ( dictionary[ "STYLE_CLEANLOOKS" ] == "yes" ) |
2489 if (dictionary[ "STYLE_CLEANLOOKS" ] == "yes") |
2482 qmakeStyles += "cleanlooks"; |
2490 qmakeStyles += "cleanlooks"; |
2483 |
2491 |
2484 if ( dictionary[ "STYLE_WINDOWSXP" ] == "yes" ) |
2492 if (dictionary[ "STYLE_WINDOWSXP" ] == "yes") |
2485 qmakeStyles += "windowsxp"; |
2493 qmakeStyles += "windowsxp"; |
2486 |
2494 |
2487 if ( dictionary[ "STYLE_WINDOWSVISTA" ] == "yes" ) |
2495 if (dictionary[ "STYLE_WINDOWSVISTA" ] == "yes") |
2488 qmakeStyles += "windowsvista"; |
2496 qmakeStyles += "windowsvista"; |
2489 |
2497 |
2490 if ( dictionary[ "STYLE_MOTIF" ] == "yes" ) |
2498 if (dictionary[ "STYLE_MOTIF" ] == "yes") |
2491 qmakeStyles += "motif"; |
2499 qmakeStyles += "motif"; |
2492 |
2500 |
2493 if ( dictionary[ "STYLE_SGI" ] == "yes" ) |
2501 if (dictionary[ "STYLE_SGI" ] == "yes") |
2494 qmakeStyles += "sgi"; |
2502 qmakeStyles += "sgi"; |
2495 |
2503 |
2496 if ( dictionary[ "STYLE_WINDOWSCE" ] == "yes" ) |
2504 if (dictionary[ "STYLE_WINDOWSCE" ] == "yes") |
2497 qmakeStyles += "windowsce"; |
2505 qmakeStyles += "windowsce"; |
2498 |
2506 |
2499 if ( dictionary[ "STYLE_WINDOWSMOBILE" ] == "yes" ) |
2507 if (dictionary[ "STYLE_WINDOWSMOBILE" ] == "yes") |
2500 qmakeStyles += "windowsmobile"; |
2508 qmakeStyles += "windowsmobile"; |
2501 |
2509 |
2502 if ( dictionary[ "STYLE_CDE" ] == "yes" ) |
2510 if (dictionary[ "STYLE_CDE" ] == "yes") |
2503 qmakeStyles += "cde"; |
2511 qmakeStyles += "cde"; |
2504 |
2512 |
2505 if ( dictionary[ "STYLE_S60" ] == "yes" ) |
2513 if (dictionary[ "STYLE_S60" ] == "yes") |
2506 qmakeStyles += "s60"; |
2514 qmakeStyles += "s60"; |
2507 |
2515 |
2508 // Databases ---------------------------------------------------- |
2516 // Databases ---------------------------------------------------- |
2509 if ( dictionary[ "SQL_MYSQL" ] == "yes" ) |
2517 if (dictionary[ "SQL_MYSQL" ] == "yes") |
2510 qmakeSql += "mysql"; |
2518 qmakeSql += "mysql"; |
2511 else if ( dictionary[ "SQL_MYSQL" ] == "plugin" ) |
2519 else if (dictionary[ "SQL_MYSQL" ] == "plugin") |
2512 qmakeSqlPlugins += "mysql"; |
2520 qmakeSqlPlugins += "mysql"; |
2513 |
2521 |
2514 if ( dictionary[ "SQL_ODBC" ] == "yes" ) |
2522 if (dictionary[ "SQL_ODBC" ] == "yes") |
2515 qmakeSql += "odbc"; |
2523 qmakeSql += "odbc"; |
2516 else if ( dictionary[ "SQL_ODBC" ] == "plugin" ) |
2524 else if (dictionary[ "SQL_ODBC" ] == "plugin") |
2517 qmakeSqlPlugins += "odbc"; |
2525 qmakeSqlPlugins += "odbc"; |
2518 |
2526 |
2519 if ( dictionary[ "SQL_OCI" ] == "yes" ) |
2527 if (dictionary[ "SQL_OCI" ] == "yes") |
2520 qmakeSql += "oci"; |
2528 qmakeSql += "oci"; |
2521 else if ( dictionary[ "SQL_OCI" ] == "plugin" ) |
2529 else if (dictionary[ "SQL_OCI" ] == "plugin") |
2522 qmakeSqlPlugins += "oci"; |
2530 qmakeSqlPlugins += "oci"; |
2523 |
2531 |
2524 if ( dictionary[ "SQL_PSQL" ] == "yes" ) |
2532 if (dictionary[ "SQL_PSQL" ] == "yes") |
2525 qmakeSql += "psql"; |
2533 qmakeSql += "psql"; |
2526 else if ( dictionary[ "SQL_PSQL" ] == "plugin" ) |
2534 else if (dictionary[ "SQL_PSQL" ] == "plugin") |
2527 qmakeSqlPlugins += "psql"; |
2535 qmakeSqlPlugins += "psql"; |
2528 |
2536 |
2529 if ( dictionary[ "SQL_TDS" ] == "yes" ) |
2537 if (dictionary[ "SQL_TDS" ] == "yes") |
2530 qmakeSql += "tds"; |
2538 qmakeSql += "tds"; |
2531 else if ( dictionary[ "SQL_TDS" ] == "plugin" ) |
2539 else if (dictionary[ "SQL_TDS" ] == "plugin") |
2532 qmakeSqlPlugins += "tds"; |
2540 qmakeSqlPlugins += "tds"; |
2533 |
2541 |
2534 if ( dictionary[ "SQL_DB2" ] == "yes" ) |
2542 if (dictionary[ "SQL_DB2" ] == "yes") |
2535 qmakeSql += "db2"; |
2543 qmakeSql += "db2"; |
2536 else if ( dictionary[ "SQL_DB2" ] == "plugin" ) |
2544 else if (dictionary[ "SQL_DB2" ] == "plugin") |
2537 qmakeSqlPlugins += "db2"; |
2545 qmakeSqlPlugins += "db2"; |
2538 |
2546 |
2539 if ( dictionary[ "SQL_SQLITE" ] == "yes" ) |
2547 if (dictionary[ "SQL_SQLITE" ] == "yes") |
2540 qmakeSql += "sqlite"; |
2548 qmakeSql += "sqlite"; |
2541 else if ( dictionary[ "SQL_SQLITE" ] == "plugin" ) |
2549 else if (dictionary[ "SQL_SQLITE" ] == "plugin") |
2542 qmakeSqlPlugins += "sqlite"; |
2550 qmakeSqlPlugins += "sqlite"; |
2543 |
2551 |
2544 if ( dictionary[ "SQL_SQLITE_LIB" ] == "system" ) |
2552 if (dictionary[ "SQL_SQLITE_LIB" ] == "system") |
2545 qmakeConfig += "system-sqlite"; |
2553 qmakeConfig += "system-sqlite"; |
2546 |
2554 |
2547 if ( dictionary[ "SQL_SQLITE2" ] == "yes" ) |
2555 if (dictionary[ "SQL_SQLITE2" ] == "yes") |
2548 qmakeSql += "sqlite2"; |
2556 qmakeSql += "sqlite2"; |
2549 else if ( dictionary[ "SQL_SQLITE2" ] == "plugin" ) |
2557 else if (dictionary[ "SQL_SQLITE2" ] == "plugin") |
2550 qmakeSqlPlugins += "sqlite2"; |
2558 qmakeSqlPlugins += "sqlite2"; |
2551 |
2559 |
2552 if ( dictionary[ "SQL_IBASE" ] == "yes" ) |
2560 if (dictionary[ "SQL_IBASE" ] == "yes") |
2553 qmakeSql += "ibase"; |
2561 qmakeSql += "ibase"; |
2554 else if ( dictionary[ "SQL_IBASE" ] == "plugin" ) |
2562 else if (dictionary[ "SQL_IBASE" ] == "plugin") |
2555 qmakeSqlPlugins += "ibase"; |
2563 qmakeSqlPlugins += "ibase"; |
2556 |
2564 |
2557 // Other options ------------------------------------------------ |
2565 // Other options ------------------------------------------------ |
2558 if( dictionary[ "BUILDALL" ] == "yes" ) { |
2566 if (dictionary[ "BUILDALL" ] == "yes") { |
2559 qmakeConfig += "build_all"; |
2567 qmakeConfig += "build_all"; |
2560 } |
2568 } |
2561 qmakeConfig += dictionary[ "BUILD" ]; |
2569 qmakeConfig += dictionary[ "BUILD" ]; |
2562 dictionary[ "QMAKE_OUTDIR" ] = dictionary[ "BUILD" ]; |
2570 dictionary[ "QMAKE_OUTDIR" ] = dictionary[ "BUILD" ]; |
2563 |
2571 |
2564 if ( dictionary[ "SHARED" ] == "yes" ) { |
2572 if (dictionary[ "SHARED" ] == "yes") { |
2565 QString version = dictionary[ "VERSION" ]; |
2573 QString version = dictionary[ "VERSION" ]; |
2566 if (!version.isEmpty()) { |
2574 if (!version.isEmpty()) { |
2567 qmakeVars += "QMAKE_QT_VERSION_OVERRIDE = " + version.left(version.indexOf(".")); |
2575 qmakeVars += "QMAKE_QT_VERSION_OVERRIDE = " + version.left(version.indexOf(".")); |
2568 version.remove(QLatin1Char('.')); |
2576 version.remove(QLatin1Char('.')); |
2569 } |
2577 } |
2570 dictionary[ "QMAKE_OUTDIR" ] += "_shared"; |
2578 dictionary[ "QMAKE_OUTDIR" ] += "_shared"; |
2571 } else { |
2579 } else { |
2572 dictionary[ "QMAKE_OUTDIR" ] += "_static"; |
2580 dictionary[ "QMAKE_OUTDIR" ] += "_static"; |
2573 } |
2581 } |
2574 |
2582 |
2575 if( dictionary[ "ACCESSIBILITY" ] == "yes" ) |
2583 if (dictionary[ "ACCESSIBILITY" ] == "yes") |
2576 qtConfig += "accessibility"; |
2584 qtConfig += "accessibility"; |
2577 |
2585 |
2578 if( !qmakeLibs.isEmpty() ) |
2586 if (!qmakeLibs.isEmpty()) |
2579 qmakeVars += "LIBS += " + qmakeLibs.join( " " ); |
2587 qmakeVars += "LIBS += " + escapeSeparators(qmakeLibs.join(" ")); |
2580 |
2588 |
2581 if( !dictionary["QT_LFLAGS_SQLITE"].isEmpty() ) |
2589 if (!dictionary["QT_LFLAGS_SQLITE"].isEmpty()) |
2582 qmakeVars += "QT_LFLAGS_SQLITE += " + dictionary["QT_LFLAGS_SQLITE"]; |
2590 qmakeVars += "QT_LFLAGS_SQLITE += " + escapeSeparators(dictionary["QT_LFLAGS_SQLITE"]); |
2583 |
2591 |
2584 if (dictionary[ "QT3SUPPORT" ] == "yes") |
2592 if (dictionary[ "QT3SUPPORT" ] == "yes") |
2585 qtConfig += "qt3support"; |
2593 qtConfig += "qt3support"; |
2586 |
2594 |
2587 if (dictionary[ "OPENGL" ] == "yes") |
2595 if (dictionary[ "OPENGL" ] == "yes") |
2588 qtConfig += "opengl"; |
2596 qtConfig += "opengl"; |
2589 |
2597 |
2590 if ( dictionary["OPENGL_ES_CM"] == "yes" ) { |
2598 if (dictionary["OPENGL_ES_CM"] == "yes") { |
2591 qtConfig += "opengles1"; |
2599 qtConfig += "opengles1"; |
2592 qtConfig += "egl"; |
2600 qtConfig += "egl"; |
2593 } |
2601 } |
2594 |
2602 |
2595 if ( dictionary["OPENGL_ES_2"] == "yes" ) { |
2603 if (dictionary["OPENGL_ES_2"] == "yes") { |
2596 qtConfig += "opengles2"; |
2604 qtConfig += "opengles2"; |
2597 qtConfig += "egl"; |
2605 qtConfig += "egl"; |
2598 } |
2606 } |
2599 |
2607 |
2600 if ( dictionary["OPENVG"] == "yes" ) { |
2608 if (dictionary["OPENVG"] == "yes") { |
2601 qtConfig += "openvg"; |
2609 qtConfig += "openvg"; |
2602 qtConfig += "egl"; |
2610 qtConfig += "egl"; |
2603 } |
2611 } |
2604 |
2612 |
2605 if ( dictionary["S60"] == "yes" ) { |
2613 if (dictionary["S60"] == "yes") { |
2606 qtConfig += "s60"; |
2614 qtConfig += "s60"; |
2607 } |
2615 } |
2608 |
2616 |
2609 if ( dictionary["DIRECTSHOW"] == "yes" ) |
2617 if (dictionary["DIRECTSHOW"] == "yes") |
2610 qtConfig += "directshow"; |
2618 qtConfig += "directshow"; |
2611 |
2619 |
2612 if (dictionary[ "OPENSSL" ] == "yes") |
2620 if (dictionary[ "OPENSSL" ] == "yes") |
2613 qtConfig += "openssl"; |
2621 qtConfig += "openssl"; |
2614 else if (dictionary[ "OPENSSL" ] == "linked") |
2622 else if (dictionary[ "OPENSSL" ] == "linked") |
2687 if (cfg == set_config) |
2695 if (cfg == set_config) |
2688 break; |
2696 break; |
2689 } |
2697 } |
2690 } |
2698 } |
2691 |
2699 |
2692 if (dictionary.contains("XQMAKESPEC") && ( dictionary["QMAKESPEC"] != dictionary["XQMAKESPEC"] ) ) |
2700 if (dictionary.contains("XQMAKESPEC") && (dictionary["QMAKESPEC"] != dictionary["XQMAKESPEC"])) |
2693 qmakeConfig += "cross_compile"; |
2701 qmakeConfig += "cross_compile"; |
2694 |
2702 |
2695 // Directories and settings for .qmake.cache -------------------- |
2703 // Directories and settings for .qmake.cache -------------------- |
2696 |
2704 |
2697 // if QT_INSTALL_* have not been specified on commandline, define them now from QT_INSTALL_PREFIX |
2705 // if QT_INSTALL_* have not been specified on commandline, define them now from QT_INSTALL_PREFIX |
2698 // if prefix is empty (WINCE), make all of them empty, if they aren't set |
2706 // if prefix is empty (WINCE), make all of them empty, if they aren't set |
2699 bool qipempty = false; |
2707 bool qipempty = false; |
2700 if(dictionary[ "QT_INSTALL_PREFIX" ].isEmpty()) |
2708 if (dictionary[ "QT_INSTALL_PREFIX" ].isEmpty()) |
2701 qipempty = true; |
2709 qipempty = true; |
2702 |
2710 |
2703 if( !dictionary[ "QT_INSTALL_DOCS" ].size() ) |
2711 if (!dictionary[ "QT_INSTALL_DOCS" ].size()) |
2704 dictionary[ "QT_INSTALL_DOCS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/doc" ); |
2712 dictionary[ "QT_INSTALL_DOCS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/doc"); |
2705 if( !dictionary[ "QT_INSTALL_HEADERS" ].size() ) |
2713 if (!dictionary[ "QT_INSTALL_HEADERS" ].size()) |
2706 dictionary[ "QT_INSTALL_HEADERS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/include" ); |
2714 dictionary[ "QT_INSTALL_HEADERS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/include"); |
2707 if( !dictionary[ "QT_INSTALL_LIBS" ].size() ) |
2715 if (!dictionary[ "QT_INSTALL_LIBS" ].size()) |
2708 dictionary[ "QT_INSTALL_LIBS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/lib" ); |
2716 dictionary[ "QT_INSTALL_LIBS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/lib"); |
2709 if( !dictionary[ "QT_INSTALL_BINS" ].size() ) |
2717 if (!dictionary[ "QT_INSTALL_BINS" ].size()) |
2710 dictionary[ "QT_INSTALL_BINS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/bin" ); |
2718 dictionary[ "QT_INSTALL_BINS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/bin"); |
2711 if( !dictionary[ "QT_INSTALL_PLUGINS" ].size() ) |
2719 if (!dictionary[ "QT_INSTALL_PLUGINS" ].size()) |
2712 dictionary[ "QT_INSTALL_PLUGINS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/plugins" ); |
2720 dictionary[ "QT_INSTALL_PLUGINS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/plugins"); |
2713 if( !dictionary[ "QT_INSTALL_IMPORTS" ].size() ) |
2721 if (!dictionary[ "QT_INSTALL_IMPORTS" ].size()) |
2714 dictionary[ "QT_INSTALL_IMPORTS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/imports" ); |
2722 dictionary[ "QT_INSTALL_IMPORTS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/imports"); |
2715 if( !dictionary[ "QT_INSTALL_DATA" ].size() ) |
2723 if (!dictionary[ "QT_INSTALL_DATA" ].size()) |
2716 dictionary[ "QT_INSTALL_DATA" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] ); |
2724 dictionary[ "QT_INSTALL_DATA" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ]); |
2717 if( !dictionary[ "QT_INSTALL_TRANSLATIONS" ].size() ) |
2725 if (!dictionary[ "QT_INSTALL_TRANSLATIONS" ].size()) |
2718 dictionary[ "QT_INSTALL_TRANSLATIONS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/translations" ); |
2726 dictionary[ "QT_INSTALL_TRANSLATIONS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/translations"); |
2719 if( !dictionary[ "QT_INSTALL_EXAMPLES" ].size() ) |
2727 if (!dictionary[ "QT_INSTALL_EXAMPLES" ].size()) |
2720 dictionary[ "QT_INSTALL_EXAMPLES" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/examples"); |
2728 dictionary[ "QT_INSTALL_EXAMPLES" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/examples"); |
2721 if( !dictionary[ "QT_INSTALL_DEMOS" ].size() ) |
2729 if (!dictionary[ "QT_INSTALL_DEMOS" ].size()) |
2722 dictionary[ "QT_INSTALL_DEMOS" ] = qipempty ? "" : fixSeparators( dictionary[ "QT_INSTALL_PREFIX" ] + "/demos" ); |
2730 dictionary[ "QT_INSTALL_DEMOS" ] = qipempty ? "" : fixSeparators(dictionary[ "QT_INSTALL_PREFIX" ] + "/demos"); |
2723 |
2731 |
2724 if(dictionary.contains("XQMAKESPEC") && dictionary[ "XQMAKESPEC" ].startsWith("linux")) |
2732 if (dictionary.contains("XQMAKESPEC") && dictionary[ "XQMAKESPEC" ].startsWith("linux")) |
2725 dictionary[ "QMAKE_RPATHDIR" ] = dictionary[ "QT_INSTALL_LIBS" ]; |
2733 dictionary[ "QMAKE_RPATHDIR" ] = dictionary[ "QT_INSTALL_LIBS" ]; |
2726 |
2734 |
2727 qmakeVars += QString("OBJECTS_DIR = ") + fixSeparators( "tmp/obj/" + dictionary[ "QMAKE_OUTDIR" ] ); |
2735 qmakeVars += QString("OBJECTS_DIR = ") + fixSeparators("tmp/obj/" + dictionary[ "QMAKE_OUTDIR" ], true); |
2728 qmakeVars += QString("MOC_DIR = ") + fixSeparators( "tmp/moc/" + dictionary[ "QMAKE_OUTDIR" ] ); |
2736 qmakeVars += QString("MOC_DIR = ") + fixSeparators("tmp/moc/" + dictionary[ "QMAKE_OUTDIR" ], true); |
2729 qmakeVars += QString("RCC_DIR = ") + fixSeparators("tmp/rcc/" + dictionary["QMAKE_OUTDIR"]); |
2737 qmakeVars += QString("RCC_DIR = ") + fixSeparators("tmp/rcc/" + dictionary["QMAKE_OUTDIR"], true); |
2730 |
2738 |
2731 if (!qmakeDefines.isEmpty()) |
2739 if (!qmakeDefines.isEmpty()) |
2732 qmakeVars += QString("DEFINES += ") + qmakeDefines.join( " " ); |
2740 qmakeVars += QString("DEFINES += ") + qmakeDefines.join(" "); |
2733 if (!qmakeIncludes.isEmpty()) |
2741 if (!qmakeIncludes.isEmpty()) |
2734 qmakeVars += QString("INCLUDEPATH += ") + qmakeIncludes.join( " " ); |
2742 qmakeVars += QString("INCLUDEPATH += ") + escapeSeparators(qmakeIncludes.join(" ")); |
2735 if (!opensslLibs.isEmpty()) |
2743 if (!opensslLibs.isEmpty()) |
2736 qmakeVars += opensslLibs; |
2744 qmakeVars += opensslLibs; |
2737 else if (dictionary[ "OPENSSL" ] == "linked") { |
2745 else if (dictionary[ "OPENSSL" ] == "linked") { |
2738 if(dictionary.contains("XQMAKESPEC") && dictionary[ "XQMAKESPEC" ].startsWith("symbian") ) |
2746 if (dictionary.contains("XQMAKESPEC") && dictionary[ "XQMAKESPEC" ].startsWith("symbian")) |
2739 qmakeVars += QString("OPENSSL_LIBS = -llibssl -llibcrypto"); |
2747 qmakeVars += QString("OPENSSL_LIBS = -llibssl -llibcrypto"); |
2740 else |
2748 else |
2741 qmakeVars += QString("OPENSSL_LIBS = -lssleay32 -llibeay32"); |
2749 qmakeVars += QString("OPENSSL_LIBS = -lssleay32 -llibeay32"); |
2742 } |
2750 } |
|
2751 if (!psqlLibs.isEmpty()) |
|
2752 qmakeVars += QString("QT_LFLAGS_PSQL=") + psqlLibs.section("=", 1); |
2743 if (!qmakeSql.isEmpty()) |
2753 if (!qmakeSql.isEmpty()) |
2744 qmakeVars += QString("sql-drivers += ") + qmakeSql.join( " " ); |
2754 qmakeVars += QString("sql-drivers += ") + qmakeSql.join(" "); |
2745 if (!qmakeSqlPlugins.isEmpty()) |
2755 if (!qmakeSqlPlugins.isEmpty()) |
2746 qmakeVars += QString("sql-plugins += ") + qmakeSqlPlugins.join( " " ); |
2756 qmakeVars += QString("sql-plugins += ") + qmakeSqlPlugins.join(" "); |
2747 if (!qmakeStyles.isEmpty()) |
2757 if (!qmakeStyles.isEmpty()) |
2748 qmakeVars += QString("styles += ") + qmakeStyles.join( " " ); |
2758 qmakeVars += QString("styles += ") + qmakeStyles.join(" "); |
2749 if (!qmakeStylePlugins.isEmpty()) |
2759 if (!qmakeStylePlugins.isEmpty()) |
2750 qmakeVars += QString("style-plugins += ") + qmakeStylePlugins.join( " " ); |
2760 qmakeVars += QString("style-plugins += ") + qmakeStylePlugins.join(" "); |
2751 if (!qmakeFormatPlugins.isEmpty()) |
2761 if (!qmakeFormatPlugins.isEmpty()) |
2752 qmakeVars += QString("imageformat-plugins += ") + qmakeFormatPlugins.join( " " ); |
2762 qmakeVars += QString("imageformat-plugins += ") + qmakeFormatPlugins.join(" "); |
2753 |
2763 |
2754 if (dictionary["QMAKESPEC"].endsWith("-g++")) { |
2764 if (dictionary["QMAKESPEC"].endsWith("-g++")) { |
2755 QString includepath = qgetenv("INCLUDE"); |
2765 QString includepath = qgetenv("INCLUDE"); |
2756 bool hasSh = Environment::detectExecutable("sh.exe"); |
2766 bool hasSh = Environment::detectExecutable("sh.exe"); |
2757 QChar separator = (!includepath.contains(":\\") && hasSh ? QChar(':') : QChar(';')); |
2767 QChar separator = (!includepath.contains(":\\") && hasSh ? QChar(':') : QChar(';')); |
2759 qmakeVars += QString("QMAKE_INCDIR_POST += $$split(TMPPATH,\"%1\")").arg(separator); |
2769 qmakeVars += QString("QMAKE_INCDIR_POST += $$split(TMPPATH,\"%1\")").arg(separator); |
2760 qmakeVars += QString("TMPPATH = $$quote($$(LIB))"); |
2770 qmakeVars += QString("TMPPATH = $$quote($$(LIB))"); |
2761 qmakeVars += QString("QMAKE_LIBDIR_POST += $$split(TMPPATH,\"%1\")").arg(separator); |
2771 qmakeVars += QString("QMAKE_LIBDIR_POST += $$split(TMPPATH,\"%1\")").arg(separator); |
2762 } |
2772 } |
2763 |
2773 |
2764 if( !dictionary[ "QMAKESPEC" ].length() ) { |
2774 if (!dictionary[ "QMAKESPEC" ].length()) { |
2765 cout << "Configure could not detect your compiler. QMAKESPEC must either" << endl |
2775 cout << "Configure could not detect your compiler. QMAKESPEC must either" << endl |
2766 << "be defined as an environment variable, or specified as an" << endl |
2776 << "be defined as an environment variable, or specified as an" << endl |
2767 << "argument with -platform" << endl; |
2777 << "argument with -platform" << endl; |
2768 dictionary[ "HELP" ] = "yes"; |
2778 dictionary[ "HELP" ] = "yes"; |
2769 |
2779 |
2770 QStringList winPlatforms; |
2780 QStringList winPlatforms; |
2771 QDir mkspecsDir( sourcePath + "/mkspecs" ); |
2781 QDir mkspecsDir(sourcePath + "/mkspecs"); |
2772 const QFileInfoList &specsList = mkspecsDir.entryInfoList(); |
2782 const QFileInfoList &specsList = mkspecsDir.entryInfoList(); |
2773 for(int i = 0; i < specsList.size(); ++i) { |
2783 for (int i = 0; i < specsList.size(); ++i) { |
2774 const QFileInfo &fi = specsList.at(i); |
2784 const QFileInfo &fi = specsList.at(i); |
2775 if( fi.fileName().left( 5 ) == "win32" ) { |
2785 if (fi.fileName().left(5) == "win32") { |
2776 winPlatforms += fi.fileName(); |
2786 winPlatforms += fi.fileName(); |
2777 } |
2787 } |
2778 } |
2788 } |
2779 cout << "Available platforms are: " << qPrintable(winPlatforms.join( ", " )) << endl; |
2789 cout << "Available platforms are: " << qPrintable(winPlatforms.join(", ")) << endl; |
2780 dictionary[ "DONE" ] = "error"; |
2790 dictionary[ "DONE" ] = "error"; |
2781 } |
2791 } |
2782 } |
2792 } |
2783 |
2793 |
2784 #if !defined(EVAL) |
2794 #if !defined(EVAL) |
2785 void Configure::generateCachefile() |
2795 void Configure::generateCachefile() |
2786 { |
2796 { |
2787 // Generate .qmake.cache |
2797 // Generate .qmake.cache |
2788 QFile cacheFile( buildPath + "/.qmake.cache" ); |
2798 QFile cacheFile(buildPath + "/.qmake.cache"); |
2789 if( cacheFile.open( QFile::WriteOnly | QFile::Text ) ) { // Truncates any existing file. |
2799 if (cacheFile.open(QFile::WriteOnly | QFile::Text)) { // Truncates any existing file. |
2790 QTextStream cacheStream( &cacheFile ); |
2800 QTextStream cacheStream(&cacheFile); |
2791 for( QStringList::Iterator var = qmakeVars.begin(); var != qmakeVars.end(); ++var ) { |
2801 for (QStringList::Iterator var = qmakeVars.begin(); var != qmakeVars.end(); ++var) { |
2792 cacheStream << (*var) << endl; |
2802 cacheStream << (*var) << endl; |
2793 } |
2803 } |
2794 cacheStream << "CONFIG += " << qmakeConfig.join( " " ) << " incremental create_prl link_prl depend_includepath QTDIR_build" << endl; |
2804 cacheStream << "CONFIG += " << qmakeConfig.join(" ") << " incremental create_prl link_prl depend_includepath QTDIR_build" << endl; |
2795 |
2805 |
2796 QStringList buildParts; |
2806 QStringList buildParts; |
2797 buildParts << "libs" << "tools" << "examples" << "demos" << "docs" << "translations"; |
2807 buildParts << "libs" << "tools" << "examples" << "demos" << "docs" << "translations"; |
2798 foreach(QString item, disabledBuildParts) { |
2808 foreach(QString item, disabledBuildParts) { |
2799 buildParts.removeAll(item); |
2809 buildParts.removeAll(item); |
2800 } |
2810 } |
2801 cacheStream << "QT_BUILD_PARTS = " << buildParts.join( " " ) << endl; |
2811 cacheStream << "QT_BUILD_PARTS = " << buildParts.join(" ") << endl; |
2802 |
2812 |
2803 QString targetSpec = dictionary.contains("XQMAKESPEC") ? dictionary[ "XQMAKESPEC" ] : dictionary[ "QMAKESPEC" ]; |
2813 QString targetSpec = dictionary.contains("XQMAKESPEC") ? dictionary[ "XQMAKESPEC" ] : dictionary[ "QMAKESPEC" ]; |
2804 QString mkspec_path = fixSeparators(sourcePath + "/mkspecs/" + targetSpec); |
2814 QString mkspec_path = fixSeparators(sourcePath + "/mkspecs/" + targetSpec); |
2805 if(QFile::exists(mkspec_path)) |
2815 if (QFile::exists(mkspec_path)) |
2806 cacheStream << "QMAKESPEC = " << mkspec_path << endl; |
2816 cacheStream << "QMAKESPEC = " << escapeSeparators(mkspec_path) << endl; |
2807 else |
2817 else |
2808 cacheStream << "QMAKESPEC = " << fixSeparators(targetSpec) << endl; |
2818 cacheStream << "QMAKESPEC = " << fixSeparators(targetSpec, true) << endl; |
2809 cacheStream << "ARCH = " << fixSeparators(dictionary[ "ARCHITECTURE" ]) << endl; |
2819 cacheStream << "ARCH = " << dictionary[ "ARCHITECTURE" ] << endl; |
2810 cacheStream << "QT_BUILD_TREE = " << fixSeparators(dictionary[ "QT_BUILD_TREE" ]) << endl; |
2820 cacheStream << "QT_BUILD_TREE = " << fixSeparators(dictionary[ "QT_BUILD_TREE" ], true) << endl; |
2811 cacheStream << "QT_SOURCE_TREE = " << fixSeparators(dictionary[ "QT_SOURCE_TREE" ]) << endl; |
2821 cacheStream << "QT_SOURCE_TREE = " << fixSeparators(dictionary[ "QT_SOURCE_TREE" ], true) << endl; |
2812 |
2822 |
2813 if (dictionary["QT_EDITION"] != "QT_EDITION_OPENSOURCE") |
2823 if (dictionary["QT_EDITION"] != "QT_EDITION_OPENSOURCE") |
2814 cacheStream << "DEFINES *= QT_EDITION=QT_EDITION_DESKTOP" << endl; |
2824 cacheStream << "DEFINES *= QT_EDITION=QT_EDITION_DESKTOP" << endl; |
2815 |
2825 |
2816 //so that we can build without an install first (which would be impossible) |
2826 //so that we can build without an install first (which would be impossible) |
2817 cacheStream << "QMAKE_MOC = $$QT_BUILD_TREE" << fixSeparators("/bin/moc.exe") << endl; |
2827 cacheStream << "QMAKE_MOC = $$QT_BUILD_TREE" << fixSeparators("/bin/moc.exe", true) << endl; |
2818 cacheStream << "QMAKE_UIC = $$QT_BUILD_TREE" << fixSeparators("/bin/uic.exe") << endl; |
2828 cacheStream << "QMAKE_UIC = $$QT_BUILD_TREE" << fixSeparators("/bin/uic.exe", true) << endl; |
2819 cacheStream << "QMAKE_UIC3 = $$QT_BUILD_TREE" << fixSeparators("/bin/uic3.exe") << endl; |
2829 cacheStream << "QMAKE_UIC3 = $$QT_BUILD_TREE" << fixSeparators("/bin/uic3.exe", true) << endl; |
2820 cacheStream << "QMAKE_RCC = $$QT_BUILD_TREE" << fixSeparators("/bin/rcc.exe") << endl; |
2830 cacheStream << "QMAKE_RCC = $$QT_BUILD_TREE" << fixSeparators("/bin/rcc.exe", true) << endl; |
2821 cacheStream << "QMAKE_DUMPCPP = $$QT_BUILD_TREE" << fixSeparators("/bin/dumpcpp.exe") << endl; |
2831 cacheStream << "QMAKE_DUMPCPP = $$QT_BUILD_TREE" << fixSeparators("/bin/dumpcpp.exe", true) << endl; |
2822 cacheStream << "QMAKE_INCDIR_QT = $$QT_BUILD_TREE" << fixSeparators("/include") << endl; |
2832 cacheStream << "QMAKE_INCDIR_QT = $$QT_BUILD_TREE" << fixSeparators("/include", true) << endl; |
2823 cacheStream << "QMAKE_LIBDIR_QT = $$QT_BUILD_TREE" << fixSeparators("/lib") << endl; |
2833 cacheStream << "QMAKE_LIBDIR_QT = $$QT_BUILD_TREE" << fixSeparators("/lib", true) << endl; |
2824 if (dictionary["CETEST"] == "yes") { |
2834 if (dictionary["CETEST"] == "yes") { |
2825 cacheStream << "QT_CE_RAPI_INC = " << fixSeparators(dictionary[ "QT_CE_RAPI_INC" ]) << endl; |
2835 cacheStream << "QT_CE_RAPI_INC = " << fixSeparators(dictionary[ "QT_CE_RAPI_INC" ], true) << endl; |
2826 cacheStream << "QT_CE_RAPI_LIB = " << fixSeparators(dictionary[ "QT_CE_RAPI_LIB" ]) << endl; |
2836 cacheStream << "QT_CE_RAPI_LIB = " << fixSeparators(dictionary[ "QT_CE_RAPI_LIB" ], true) << endl; |
2827 } |
2837 } |
2828 |
2838 |
2829 // embedded |
2839 // embedded |
2830 if( !dictionary["KBD_DRIVERS"].isEmpty()) |
2840 if (!dictionary["KBD_DRIVERS"].isEmpty()) |
2831 cacheStream << "kbd-drivers += "<< dictionary["KBD_DRIVERS"]<<endl; |
2841 cacheStream << "kbd-drivers += "<< dictionary["KBD_DRIVERS"]<<endl; |
2832 if( !dictionary["GFX_DRIVERS"].isEmpty()) |
2842 if (!dictionary["GFX_DRIVERS"].isEmpty()) |
2833 cacheStream << "gfx-drivers += "<< dictionary["GFX_DRIVERS"]<<endl; |
2843 cacheStream << "gfx-drivers += "<< dictionary["GFX_DRIVERS"]<<endl; |
2834 if( !dictionary["MOUSE_DRIVERS"].isEmpty()) |
2844 if (!dictionary["MOUSE_DRIVERS"].isEmpty()) |
2835 cacheStream << "mouse-drivers += "<< dictionary["MOUSE_DRIVERS"]<<endl; |
2845 cacheStream << "mouse-drivers += "<< dictionary["MOUSE_DRIVERS"]<<endl; |
2836 if( !dictionary["DECORATIONS"].isEmpty()) |
2846 if (!dictionary["DECORATIONS"].isEmpty()) |
2837 cacheStream << "decorations += "<<dictionary["DECORATIONS"]<<endl; |
2847 cacheStream << "decorations += "<<dictionary["DECORATIONS"]<<endl; |
2838 |
2848 |
2839 if( !dictionary["QMAKE_RPATHDIR"].isEmpty() ) |
2849 if (!dictionary["QMAKE_RPATHDIR"].isEmpty()) |
2840 cacheStream << "QMAKE_RPATHDIR += "<<dictionary["QMAKE_RPATHDIR"]; |
2850 cacheStream << "QMAKE_RPATHDIR += "<<dictionary["QMAKE_RPATHDIR"]; |
2841 |
2851 |
2842 cacheStream.flush(); |
2852 cacheStream.flush(); |
2843 cacheFile.close(); |
2853 cacheFile.close(); |
2844 } |
2854 } |
2845 QFile configFile( dictionary[ "QT_BUILD_TREE" ] + "/mkspecs/qconfig.pri" ); |
2855 QFile configFile(dictionary[ "QT_BUILD_TREE" ] + "/mkspecs/qconfig.pri"); |
2846 if( configFile.open( QFile::WriteOnly | QFile::Text ) ) { // Truncates any existing file. |
2856 if (configFile.open(QFile::WriteOnly | QFile::Text)) { // Truncates any existing file. |
2847 QTextStream configStream( &configFile ); |
2857 QTextStream configStream(&configFile); |
2848 configStream << "CONFIG+= "; |
2858 configStream << "CONFIG+= "; |
2849 configStream << dictionary[ "BUILD" ]; |
2859 configStream << dictionary[ "BUILD" ]; |
2850 if( dictionary[ "SHARED" ] == "yes" ) |
2860 if (dictionary[ "SHARED" ] == "yes") |
2851 configStream << " shared"; |
2861 configStream << " shared"; |
2852 else |
2862 else |
2853 configStream << " static"; |
2863 configStream << " static"; |
2854 |
2864 |
2855 if( dictionary[ "LTCG" ] == "yes" ) |
2865 if (dictionary[ "LTCG" ] == "yes") |
2856 configStream << " ltcg"; |
2866 configStream << " ltcg"; |
2857 if( dictionary[ "STL" ] == "yes" ) |
2867 if (dictionary[ "STL" ] == "yes") |
2858 configStream << " stl"; |
2868 configStream << " stl"; |
2859 if ( dictionary[ "EXCEPTIONS" ] == "yes" ) |
2869 if (dictionary[ "EXCEPTIONS" ] == "yes") |
2860 configStream << " exceptions"; |
2870 configStream << " exceptions"; |
2861 if ( dictionary[ "EXCEPTIONS" ] == "no" ) |
2871 if (dictionary[ "EXCEPTIONS" ] == "no") |
2862 configStream << " exceptions_off"; |
2872 configStream << " exceptions_off"; |
2863 if ( dictionary[ "RTTI" ] == "yes" ) |
2873 if (dictionary[ "RTTI" ] == "yes") |
2864 configStream << " rtti"; |
2874 configStream << " rtti"; |
2865 if ( dictionary[ "MMX" ] == "yes" ) |
2875 if (dictionary[ "MMX" ] == "yes") |
2866 configStream << " mmx"; |
2876 configStream << " mmx"; |
2867 if ( dictionary[ "3DNOW" ] == "yes" ) |
2877 if (dictionary[ "3DNOW" ] == "yes") |
2868 configStream << " 3dnow"; |
2878 configStream << " 3dnow"; |
2869 if ( dictionary[ "SSE" ] == "yes" ) |
2879 if (dictionary[ "SSE" ] == "yes") |
2870 configStream << " sse"; |
2880 configStream << " sse"; |
2871 if ( dictionary[ "SSE2" ] == "yes" ) |
2881 if (dictionary[ "SSE2" ] == "yes") |
2872 configStream << " sse2"; |
2882 configStream << " sse2"; |
2873 if ( dictionary[ "IWMMXT" ] == "yes" ) |
2883 if (dictionary[ "IWMMXT" ] == "yes") |
2874 configStream << " iwmmxt"; |
2884 configStream << " iwmmxt"; |
2875 if ( dictionary["INCREDIBUILD_XGE"] == "yes" ) |
2885 if (dictionary["INCREDIBUILD_XGE"] == "yes") |
2876 configStream << " incredibuild_xge"; |
2886 configStream << " incredibuild_xge"; |
2877 if ( dictionary["PLUGIN_MANIFESTS"] == "no" ) |
2887 if (dictionary["PLUGIN_MANIFESTS"] == "no") |
2878 configStream << " no_plugin_manifest"; |
2888 configStream << " no_plugin_manifest"; |
2879 |
2889 |
2880 if ( dictionary.contains("SYMBIAN_DEFFILES") ) { |
2890 if (dictionary.contains("SYMBIAN_DEFFILES")) { |
2881 if(dictionary["SYMBIAN_DEFFILES"] == "yes" ) { |
2891 if (dictionary["SYMBIAN_DEFFILES"] == "yes") { |
2882 configStream << " def_files"; |
2892 configStream << " def_files"; |
2883 } else if ( dictionary["SYMBIAN_DEFFILES"] == "no" ) { |
2893 } else if (dictionary["SYMBIAN_DEFFILES"] == "no") { |
2884 configStream << " def_files_disabled"; |
2894 configStream << " def_files_disabled"; |
2885 } |
2895 } |
2886 } |
2896 } |
2887 configStream << endl; |
2897 configStream << endl; |
2888 configStream << "QT_ARCH = " << dictionary[ "ARCHITECTURE" ] << endl; |
2898 configStream << "QT_ARCH = " << dictionary[ "ARCHITECTURE" ] << endl; |
3007 tmpStream << endl; |
3019 tmpStream << endl; |
3008 } |
3020 } |
3009 tmpStream << "/* Machine byte-order */" << endl; |
3021 tmpStream << "/* Machine byte-order */" << endl; |
3010 tmpStream << "#define Q_BIG_ENDIAN 4321" << endl; |
3022 tmpStream << "#define Q_BIG_ENDIAN 4321" << endl; |
3011 tmpStream << "#define Q_LITTLE_ENDIAN 1234" << endl; |
3023 tmpStream << "#define Q_LITTLE_ENDIAN 1234" << endl; |
3012 if ( QSysInfo::ByteOrder == QSysInfo::BigEndian ) |
3024 if (QSysInfo::ByteOrder == QSysInfo::BigEndian) |
3013 tmpStream << "#define Q_BYTE_ORDER Q_BIG_ENDIAN" << endl; |
3025 tmpStream << "#define Q_BYTE_ORDER Q_BIG_ENDIAN" << endl; |
3014 else |
3026 else |
3015 tmpStream << "#define Q_BYTE_ORDER Q_LITTLE_ENDIAN" << endl; |
3027 tmpStream << "#define Q_BYTE_ORDER Q_LITTLE_ENDIAN" << endl; |
3016 |
3028 |
3017 tmpStream << endl << "// Compile time features" << endl; |
3029 tmpStream << endl << "// Compile time features" << endl; |
3018 tmpStream << "#define QT_ARCH_" << dictionary["ARCHITECTURE"].toUpper() << endl; |
3030 tmpStream << "#define QT_ARCH_" << dictionary["ARCHITECTURE"].toUpper() << endl; |
3019 QStringList qconfigList; |
3031 QStringList qconfigList; |
3020 if(dictionary["STL"] == "no") qconfigList += "QT_NO_STL"; |
3032 if (dictionary["STL"] == "no") qconfigList += "QT_NO_STL"; |
3021 if(dictionary["STYLE_WINDOWS"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWS"; |
3033 if (dictionary["STYLE_WINDOWS"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWS"; |
3022 if(dictionary["STYLE_PLASTIQUE"] != "yes") qconfigList += "QT_NO_STYLE_PLASTIQUE"; |
3034 if (dictionary["STYLE_PLASTIQUE"] != "yes") qconfigList += "QT_NO_STYLE_PLASTIQUE"; |
3023 if(dictionary["STYLE_CLEANLOOKS"] != "yes") qconfigList += "QT_NO_STYLE_CLEANLOOKS"; |
3035 if (dictionary["STYLE_CLEANLOOKS"] != "yes") qconfigList += "QT_NO_STYLE_CLEANLOOKS"; |
3024 if(dictionary["STYLE_WINDOWSXP"] != "yes" && dictionary["STYLE_WINDOWSVISTA"] != "yes") |
3036 if (dictionary["STYLE_WINDOWSXP"] != "yes" && dictionary["STYLE_WINDOWSVISTA"] != "yes") |
3025 qconfigList += "QT_NO_STYLE_WINDOWSXP"; |
3037 qconfigList += "QT_NO_STYLE_WINDOWSXP"; |
3026 if(dictionary["STYLE_WINDOWSVISTA"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWSVISTA"; |
3038 if (dictionary["STYLE_WINDOWSVISTA"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWSVISTA"; |
3027 if(dictionary["STYLE_MOTIF"] != "yes") qconfigList += "QT_NO_STYLE_MOTIF"; |
3039 if (dictionary["STYLE_MOTIF"] != "yes") qconfigList += "QT_NO_STYLE_MOTIF"; |
3028 if(dictionary["STYLE_CDE"] != "yes") qconfigList += "QT_NO_STYLE_CDE"; |
3040 if (dictionary["STYLE_CDE"] != "yes") qconfigList += "QT_NO_STYLE_CDE"; |
3029 if(dictionary["STYLE_S60"] != "yes") qconfigList += "QT_NO_STYLE_S60"; |
3041 if (dictionary["STYLE_S60"] != "yes") qconfigList += "QT_NO_STYLE_S60"; |
3030 if(dictionary["STYLE_WINDOWSCE"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWSCE"; |
3042 if (dictionary["STYLE_WINDOWSCE"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWSCE"; |
3031 if(dictionary["STYLE_WINDOWSMOBILE"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWSMOBILE"; |
3043 if (dictionary["STYLE_WINDOWSMOBILE"] != "yes") qconfigList += "QT_NO_STYLE_WINDOWSMOBILE"; |
3032 if(dictionary["STYLE_GTK"] != "yes") qconfigList += "QT_NO_STYLE_GTK"; |
3044 if (dictionary["STYLE_GTK"] != "yes") qconfigList += "QT_NO_STYLE_GTK"; |
3033 |
3045 |
3034 if(dictionary["GIF"] == "yes") qconfigList += "QT_BUILTIN_GIF_READER=1"; |
3046 if (dictionary["GIF"] == "yes") qconfigList += "QT_BUILTIN_GIF_READER=1"; |
3035 if(dictionary["PNG"] == "no") qconfigList += "QT_NO_IMAGEFORMAT_PNG"; |
3047 if (dictionary["PNG"] != "yes") qconfigList += "QT_NO_IMAGEFORMAT_PNG"; |
3036 if(dictionary["MNG"] == "no") qconfigList += "QT_NO_IMAGEFORMAT_MNG"; |
3048 if (dictionary["MNG"] != "yes") qconfigList += "QT_NO_IMAGEFORMAT_MNG"; |
3037 if(dictionary["JPEG"] == "no") qconfigList += "QT_NO_IMAGEFORMAT_JPEG"; |
3049 if (dictionary["JPEG"] != "yes") qconfigList += "QT_NO_IMAGEFORMAT_JPEG"; |
3038 if(dictionary["TIFF"] == "no") qconfigList += "QT_NO_IMAGEFORMAT_TIFF"; |
3050 if (dictionary["TIFF"] != "yes") qconfigList += "QT_NO_IMAGEFORMAT_TIFF"; |
3039 if(dictionary["ZLIB"] == "no") { |
3051 if (dictionary["ZLIB"] == "no") { |
3040 qconfigList += "QT_NO_ZLIB"; |
3052 qconfigList += "QT_NO_ZLIB"; |
3041 qconfigList += "QT_NO_COMPRESS"; |
3053 qconfigList += "QT_NO_COMPRESS"; |
3042 } |
3054 } |
3043 |
3055 |
3044 if(dictionary["ACCESSIBILITY"] == "no") qconfigList += "QT_NO_ACCESSIBILITY"; |
3056 if (dictionary["ACCESSIBILITY"] == "no") qconfigList += "QT_NO_ACCESSIBILITY"; |
3045 if(dictionary["EXCEPTIONS"] == "no") qconfigList += "QT_NO_EXCEPTIONS"; |
3057 if (dictionary["EXCEPTIONS"] == "no") qconfigList += "QT_NO_EXCEPTIONS"; |
3046 if(dictionary["OPENGL"] == "no") qconfigList += "QT_NO_OPENGL"; |
3058 if (dictionary["OPENGL"] == "no") qconfigList += "QT_NO_OPENGL"; |
3047 if(dictionary["OPENVG"] == "no") qconfigList += "QT_NO_OPENVG"; |
3059 if (dictionary["OPENVG"] == "no") qconfigList += "QT_NO_OPENVG"; |
3048 if(dictionary["OPENSSL"] == "no") qconfigList += "QT_NO_OPENSSL"; |
3060 if (dictionary["OPENSSL"] == "no") qconfigList += "QT_NO_OPENSSL"; |
3049 if(dictionary["OPENSSL"] == "linked") qconfigList += "QT_LINKED_OPENSSL"; |
3061 if (dictionary["OPENSSL"] == "linked") qconfigList += "QT_LINKED_OPENSSL"; |
3050 if(dictionary["DBUS"] == "no") qconfigList += "QT_NO_DBUS"; |
3062 if (dictionary["DBUS"] == "no") qconfigList += "QT_NO_DBUS"; |
3051 if(dictionary["IPV6"] == "no") qconfigList += "QT_NO_IPV6"; |
3063 if (dictionary["IPV6"] == "no") qconfigList += "QT_NO_IPV6"; |
3052 if(dictionary["WEBKIT"] == "no") qconfigList += "QT_NO_WEBKIT"; |
3064 if (dictionary["WEBKIT"] == "no") qconfigList += "QT_NO_WEBKIT"; |
3053 if(dictionary["DECLARATIVE"] == "no") qconfigList += "QT_NO_DECLARATIVE"; |
3065 if (dictionary["DECLARATIVE"] == "no") qconfigList += "QT_NO_DECLARATIVE"; |
3054 if(dictionary["PHONON"] == "no") qconfigList += "QT_NO_PHONON"; |
3066 if (dictionary["PHONON"] == "no") qconfigList += "QT_NO_PHONON"; |
3055 if(dictionary["MULTIMEDIA"] == "no") qconfigList += "QT_NO_MULTIMEDIA"; |
3067 if (dictionary["MULTIMEDIA"] == "no") qconfigList += "QT_NO_MULTIMEDIA"; |
3056 if(dictionary["XMLPATTERNS"] == "no") qconfigList += "QT_NO_XMLPATTERNS"; |
3068 if (dictionary["XMLPATTERNS"] == "no") qconfigList += "QT_NO_XMLPATTERNS"; |
3057 if(dictionary["SCRIPT"] == "no") qconfigList += "QT_NO_SCRIPT"; |
3069 if (dictionary["SCRIPT"] == "no") qconfigList += "QT_NO_SCRIPT"; |
3058 if(dictionary["SCRIPTTOOLS"] == "no") qconfigList += "QT_NO_SCRIPTTOOLS"; |
3070 if (dictionary["SCRIPTTOOLS"] == "no") qconfigList += "QT_NO_SCRIPTTOOLS"; |
3059 if(dictionary["FREETYPE"] == "no") qconfigList += "QT_NO_FREETYPE"; |
3071 if (dictionary["FREETYPE"] == "no") qconfigList += "QT_NO_FREETYPE"; |
3060 if(dictionary["S60"] == "no") qconfigList += "QT_NO_S60"; |
3072 if (dictionary["S60"] == "no") qconfigList += "QT_NO_S60"; |
3061 if(dictionary["NATIVE_GESTURES"] == "no") qconfigList += "QT_NO_NATIVE_GESTURES"; |
3073 if (dictionary["NATIVE_GESTURES"] == "no") qconfigList += "QT_NO_NATIVE_GESTURES"; |
3062 |
3074 |
3063 if(dictionary["OPENGL_ES_CM"] == "no" && |
3075 if (dictionary["OPENGL_ES_CM"] == "no" && |
3064 dictionary["OPENGL_ES_2"] == "no" && |
3076 dictionary["OPENGL_ES_2"] == "no" && |
3065 dictionary["OPENVG"] == "no") qconfigList += "QT_NO_EGL"; |
3077 dictionary["OPENVG"] == "no") qconfigList += "QT_NO_EGL"; |
3066 |
3078 |
3067 if(dictionary["OPENGL_ES_CM"] == "yes" || |
3079 if (dictionary["OPENGL_ES_CM"] == "yes" || |
3068 dictionary["OPENGL_ES_2"] == "yes") qconfigList += "QT_OPENGL_ES"; |
3080 dictionary["OPENGL_ES_2"] == "yes") qconfigList += "QT_OPENGL_ES"; |
3069 |
3081 |
3070 if(dictionary["OPENGL_ES_CM"] == "yes") qconfigList += "QT_OPENGL_ES_1"; |
3082 if (dictionary["OPENGL_ES_CM"] == "yes") qconfigList += "QT_OPENGL_ES_1"; |
3071 if(dictionary["OPENGL_ES_2"] == "yes") qconfigList += "QT_OPENGL_ES_2"; |
3083 if (dictionary["OPENGL_ES_2"] == "yes") qconfigList += "QT_OPENGL_ES_2"; |
3072 if(dictionary["SQL_MYSQL"] == "yes") qconfigList += "QT_SQL_MYSQL"; |
3084 if (dictionary["SQL_MYSQL"] == "yes") qconfigList += "QT_SQL_MYSQL"; |
3073 if(dictionary["SQL_ODBC"] == "yes") qconfigList += "QT_SQL_ODBC"; |
3085 if (dictionary["SQL_ODBC"] == "yes") qconfigList += "QT_SQL_ODBC"; |
3074 if(dictionary["SQL_OCI"] == "yes") qconfigList += "QT_SQL_OCI"; |
3086 if (dictionary["SQL_OCI"] == "yes") qconfigList += "QT_SQL_OCI"; |
3075 if(dictionary["SQL_PSQL"] == "yes") qconfigList += "QT_SQL_PSQL"; |
3087 if (dictionary["SQL_PSQL"] == "yes") qconfigList += "QT_SQL_PSQL"; |
3076 if(dictionary["SQL_TDS"] == "yes") qconfigList += "QT_SQL_TDS"; |
3088 if (dictionary["SQL_TDS"] == "yes") qconfigList += "QT_SQL_TDS"; |
3077 if(dictionary["SQL_DB2"] == "yes") qconfigList += "QT_SQL_DB2"; |
3089 if (dictionary["SQL_DB2"] == "yes") qconfigList += "QT_SQL_DB2"; |
3078 if(dictionary["SQL_SQLITE"] == "yes") qconfigList += "QT_SQL_SQLITE"; |
3090 if (dictionary["SQL_SQLITE"] == "yes") qconfigList += "QT_SQL_SQLITE"; |
3079 if(dictionary["SQL_SQLITE2"] == "yes") qconfigList += "QT_SQL_SQLITE2"; |
3091 if (dictionary["SQL_SQLITE2"] == "yes") qconfigList += "QT_SQL_SQLITE2"; |
3080 if(dictionary["SQL_IBASE"] == "yes") qconfigList += "QT_SQL_IBASE"; |
3092 if (dictionary["SQL_IBASE"] == "yes") qconfigList += "QT_SQL_IBASE"; |
3081 |
3093 |
3082 if (dictionary["GRAPHICS_SYSTEM"] == "openvg") qconfigList += "QT_GRAPHICSSYSTEM_OPENVG"; |
3094 if (dictionary["GRAPHICS_SYSTEM"] == "openvg") qconfigList += "QT_GRAPHICSSYSTEM_OPENVG"; |
3083 if (dictionary["GRAPHICS_SYSTEM"] == "opengl") qconfigList += "QT_GRAPHICSSYSTEM_OPENGL"; |
3095 if (dictionary["GRAPHICS_SYSTEM"] == "opengl") qconfigList += "QT_GRAPHICSSYSTEM_OPENGL"; |
3084 if (dictionary["GRAPHICS_SYSTEM"] == "raster") qconfigList += "QT_GRAPHICSSYSTEM_RASTER"; |
3096 if (dictionary["GRAPHICS_SYSTEM"] == "raster") qconfigList += "QT_GRAPHICSSYSTEM_RASTER"; |
|
3097 if (dictionary["GRAPHICS_SYSTEM"] == "runtime") qconfigList += "QT_GRAPHICSSYSTEM_RUNTIME"; |
3085 |
3098 |
3086 if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { |
3099 if (dictionary.contains("XQMAKESPEC") && dictionary["XQMAKESPEC"].startsWith("symbian")) { |
3087 // These features are not ported to Symbian (yet) |
3100 // These features are not ported to Symbian (yet) |
3088 qconfigList += "QT_NO_CONCURRENT"; |
3101 qconfigList += "QT_NO_CONCURRENT"; |
3089 qconfigList += "QT_NO_QFUTURE"; |
3102 qconfigList += "QT_NO_QFUTURE"; |
3096 |
3109 |
3097 qconfigList.sort(); |
3110 qconfigList.sort(); |
3098 for (int i = 0; i < qconfigList.count(); ++i) |
3111 for (int i = 0; i < qconfigList.count(); ++i) |
3099 tmpStream << addDefine(qconfigList.at(i)); |
3112 tmpStream << addDefine(qconfigList.at(i)); |
3100 |
3113 |
3101 if(dictionary["EMBEDDED"] == "yes") |
3114 if (dictionary["EMBEDDED"] == "yes") |
3102 { |
3115 { |
3103 // Check for keyboard, mouse, gfx. |
3116 // Check for keyboard, mouse, gfx. |
3104 QStringList kbdDrivers = dictionary["KBD_DRIVERS"].split(" ");; |
3117 QStringList kbdDrivers = dictionary["KBD_DRIVERS"].split(" ");; |
3105 QStringList allKbdDrivers; |
3118 QStringList allKbdDrivers; |
3106 allKbdDrivers<<"tty"<<"usb"<<"sl5000"<<"yopy"<<"vr41xx"<<"qvfb"<<"um"; |
3119 allKbdDrivers<<"tty"<<"usb"<<"sl5000"<<"yopy"<<"vr41xx"<<"qvfb"<<"um"; |
3107 foreach(QString kbd, allKbdDrivers) { |
3120 foreach(QString kbd, allKbdDrivers) { |
3108 if( !kbdDrivers.contains(kbd)) |
3121 if (!kbdDrivers.contains(kbd)) |
3109 tmpStream<<"#define QT_NO_QWS_KBD_"<<kbd.toUpper()<<endl; |
3122 tmpStream<<"#define QT_NO_QWS_KBD_"<<kbd.toUpper()<<endl; |
3110 } |
3123 } |
3111 |
3124 |
3112 QStringList mouseDrivers = dictionary["MOUSE_DRIVERS"].split(" "); |
3125 QStringList mouseDrivers = dictionary["MOUSE_DRIVERS"].split(" "); |
3113 QStringList allMouseDrivers; |
3126 QStringList allMouseDrivers; |
3114 allMouseDrivers << "pc"<<"bus"<<"linuxtp"<<"yopy"<<"vr41xx"<<"tslib"<<"qvfb"; |
3127 allMouseDrivers << "pc"<<"bus"<<"linuxtp"<<"yopy"<<"vr41xx"<<"tslib"<<"qvfb"; |
3115 foreach(QString mouse, allMouseDrivers) { |
3128 foreach(QString mouse, allMouseDrivers) { |
3116 if( !mouseDrivers.contains(mouse) ) |
3129 if (!mouseDrivers.contains(mouse)) |
3117 tmpStream<<"#define QT_NO_QWS_MOUSE_"<<mouse.toUpper()<<endl; |
3130 tmpStream<<"#define QT_NO_QWS_MOUSE_"<<mouse.toUpper()<<endl; |
3118 } |
3131 } |
3119 |
3132 |
3120 QStringList gfxDrivers = dictionary["GFX_DRIVERS"].split(" "); |
3133 QStringList gfxDrivers = dictionary["GFX_DRIVERS"].split(" "); |
3121 QStringList allGfxDrivers; |
3134 QStringList allGfxDrivers; |
3122 allGfxDrivers<<"linuxfb"<<"transformed"<<"qvfb"<<"vnc"<<"multiscreen"<<"ahi"; |
3135 allGfxDrivers<<"linuxfb"<<"transformed"<<"qvfb"<<"vnc"<<"multiscreen"<<"ahi"; |
3123 foreach(QString gfx, allGfxDrivers) { |
3136 foreach(QString gfx, allGfxDrivers) { |
3124 if( !gfxDrivers.contains(gfx)) |
3137 if (!gfxDrivers.contains(gfx)) |
3125 tmpStream<<"#define QT_NO_QWS_"<<gfx.toUpper()<<endl; |
3138 tmpStream<<"#define QT_NO_QWS_"<<gfx.toUpper()<<endl; |
3126 } |
3139 } |
3127 |
3140 |
3128 tmpStream<<"#define Q_WS_QWS"<<endl; |
3141 tmpStream<<"#define Q_WS_QWS"<<endl; |
3129 |
3142 |
3130 QStringList depths = dictionary[ "QT_QWS_DEPTH" ].split(" "); |
3143 QStringList depths = dictionary[ "QT_QWS_DEPTH" ].split(" "); |
3131 foreach(QString depth, depths) |
3144 foreach(QString depth, depths) |
3132 tmpStream<<"#define QT_QWS_DEPTH_"+depth<<endl; |
3145 tmpStream<<"#define QT_QWS_DEPTH_"+depth<<endl; |
3133 } |
3146 } |
3134 |
3147 |
3135 if( dictionary[ "QT_CUPS" ] == "no") |
3148 if (dictionary[ "QT_CUPS" ] == "no") |
3136 tmpStream<<"#define QT_NO_CUPS"<<endl; |
3149 tmpStream<<"#define QT_NO_CUPS"<<endl; |
3137 |
3150 |
3138 if( dictionary[ "QT_ICONV" ] == "no") |
3151 if (dictionary[ "QT_ICONV" ] == "no") |
3139 tmpStream<<"#define QT_NO_ICONV"<<endl; |
3152 tmpStream<<"#define QT_NO_ICONV"<<endl; |
3140 |
3153 |
3141 if(dictionary[ "QT_GLIB" ] == "no") |
3154 if (dictionary[ "QT_GLIB" ] == "no") |
3142 tmpStream<<"#define QT_NO_GLIB"<<endl; |
3155 tmpStream<<"#define QT_NO_GLIB"<<endl; |
3143 |
3156 |
3144 if(dictionary[ "QT_LPR" ] == "no") |
3157 if (dictionary[ "QT_LPR" ] == "no") |
3145 tmpStream<<"#define QT_NO_LPR"<<endl; |
3158 tmpStream<<"#define QT_NO_LPR"<<endl; |
3146 |
3159 |
3147 if(dictionary[ "QT_INOTIFY" ] == "no" ) |
3160 if (dictionary[ "QT_INOTIFY" ] == "no") |
3148 tmpStream<<"#define QT_NO_INOTIFY"<<endl; |
3161 tmpStream<<"#define QT_NO_INOTIFY"<<endl; |
3149 |
3162 |
3150 if(dictionary[ "QT_SXE" ] == "no") |
3163 if (dictionary[ "QT_SXE" ] == "no") |
3151 tmpStream<<"#define QT_NO_SXE"<<endl; |
3164 tmpStream<<"#define QT_NO_SXE"<<endl; |
3152 |
3165 |
3153 tmpStream.flush(); |
3166 tmpStream.flush(); |
3154 tmpFile.flush(); |
3167 tmpFile.flush(); |
3155 |
3168 |
3156 // Replace old qconfig.h with new one |
3169 // Replace old qconfig.h with new one |
3157 ::SetFileAttributes((wchar_t*)outName.utf16(), FILE_ATTRIBUTE_NORMAL); |
3170 ::SetFileAttributes((wchar_t*)outName.utf16(), FILE_ATTRIBUTE_NORMAL); |
3158 QFile::remove(outName); |
3171 QFile::remove(outName); |
3159 tmpFile.copy(outName); |
3172 tmpFile.copy(outName); |
3160 tmpFile.close(); |
3173 tmpFile.close(); |
3161 |
|
3162 if(!QFile::exists(buildPath + "/include/QtCore/qconfig.h")) { |
|
3163 if (!writeToFile("#include \"../../src/corelib/global/qconfig.h\"\n", |
|
3164 buildPath + "/include/QtCore/qconfig.h") |
|
3165 || !writeToFile("#include \"../../src/corelib/global/qconfig.h\"\n", |
|
3166 buildPath + "/include/Qt/qconfig.h")) { |
|
3167 dictionary["DONE"] = "error"; |
|
3168 return; |
|
3169 } |
|
3170 } |
|
3171 } |
3174 } |
3172 |
3175 |
3173 // Copy configured mkspec to default directory, but remove the old one first, if there is any |
3176 // Copy configured mkspec to default directory, but remove the old one first, if there is any |
3174 QString defSpec = buildPath + "/mkspecs/default"; |
3177 QString defSpec = buildPath + "/mkspecs/default"; |
3175 QFileInfo defSpecInfo(defSpec); |
3178 QFileInfo defSpecInfo(defSpec); |
3212 << "static const char qt_configure_licensed_products_str [512 + 12] = \"qt_lcnsprod=" << dictionary["EDITION"] << "\";" << endl |
3215 << "static const char qt_configure_licensed_products_str [512 + 12] = \"qt_lcnsprod=" << dictionary["EDITION"] << "\";" << endl |
3213 << endl |
3216 << endl |
3214 << "/* Build date */" << endl |
3217 << "/* Build date */" << endl |
3215 << "static const char qt_configure_installation [11 + 12] = \"qt_instdate=" << QDate::currentDate().toString(Qt::ISODate) << "\";" << endl |
3218 << "static const char qt_configure_installation [11 + 12] = \"qt_instdate=" << QDate::currentDate().toString(Qt::ISODate) << "\";" << endl |
3216 << endl; |
3219 << endl; |
3217 if(!dictionary[ "QT_HOST_PREFIX" ].isNull()) |
3220 if (!dictionary[ "QT_HOST_PREFIX" ].isNull()) |
3218 tmpStream << "#if !defined(QT_BOOTSTRAPPED) && !defined(QT_BUILD_QMAKE)" << endl; |
3221 tmpStream << "#if !defined(QT_BOOTSTRAPPED) && !defined(QT_BUILD_QMAKE)" << endl; |
3219 tmpStream << "static const char qt_configure_prefix_path_str [512 + 12] = \"qt_prfxpath=" << QString(dictionary["QT_INSTALL_PREFIX"]).replace( "\\", "\\\\" ) << "\";" << endl |
3222 tmpStream << "static const char qt_configure_prefix_path_str [512 + 12] = \"qt_prfxpath=" << escapeSeparators(dictionary["QT_INSTALL_PREFIX"]) << "\";" << endl |
3220 << "static const char qt_configure_documentation_path_str[512 + 12] = \"qt_docspath=" << QString(dictionary["QT_INSTALL_DOCS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3223 << "static const char qt_configure_documentation_path_str[512 + 12] = \"qt_docspath=" << escapeSeparators(dictionary["QT_INSTALL_DOCS"]) << "\";" << endl |
3221 << "static const char qt_configure_headers_path_str [512 + 12] = \"qt_hdrspath=" << QString(dictionary["QT_INSTALL_HEADERS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3224 << "static const char qt_configure_headers_path_str [512 + 12] = \"qt_hdrspath=" << escapeSeparators(dictionary["QT_INSTALL_HEADERS"]) << "\";" << endl |
3222 << "static const char qt_configure_libraries_path_str [512 + 12] = \"qt_libspath=" << QString(dictionary["QT_INSTALL_LIBS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3225 << "static const char qt_configure_libraries_path_str [512 + 12] = \"qt_libspath=" << escapeSeparators(dictionary["QT_INSTALL_LIBS"]) << "\";" << endl |
3223 << "static const char qt_configure_binaries_path_str [512 + 12] = \"qt_binspath=" << QString(dictionary["QT_INSTALL_BINS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3226 << "static const char qt_configure_binaries_path_str [512 + 12] = \"qt_binspath=" << escapeSeparators(dictionary["QT_INSTALL_BINS"]) << "\";" << endl |
3224 << "static const char qt_configure_plugins_path_str [512 + 12] = \"qt_plugpath=" << QString(dictionary["QT_INSTALL_PLUGINS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3227 << "static const char qt_configure_plugins_path_str [512 + 12] = \"qt_plugpath=" << escapeSeparators(dictionary["QT_INSTALL_PLUGINS"]) << "\";" << endl |
3225 << "static const char qt_configure_imports_path_str [512 + 12] = \"qt_impspath=" << QString(dictionary["QT_INSTALL_IMPORTS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3228 << "static const char qt_configure_imports_path_str [512 + 12] = \"qt_impspath=" << escapeSeparators(dictionary["QT_INSTALL_IMPORTS"]) << "\";" << endl |
3226 << "static const char qt_configure_data_path_str [512 + 12] = \"qt_datapath=" << QString(dictionary["QT_INSTALL_DATA"]).replace( "\\", "\\\\" ) << "\";" << endl |
3229 << "static const char qt_configure_data_path_str [512 + 12] = \"qt_datapath=" << escapeSeparators(dictionary["QT_INSTALL_DATA"]) << "\";" << endl |
3227 << "static const char qt_configure_translations_path_str [512 + 12] = \"qt_trnspath=" << QString(dictionary["QT_INSTALL_TRANSLATIONS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3230 << "static const char qt_configure_translations_path_str [512 + 12] = \"qt_trnspath=" << escapeSeparators(dictionary["QT_INSTALL_TRANSLATIONS"]) << "\";" << endl |
3228 << "static const char qt_configure_examples_path_str [512 + 12] = \"qt_xmplpath=" << QString(dictionary["QT_INSTALL_EXAMPLES"]).replace( "\\", "\\\\" ) << "\";" << endl |
3231 << "static const char qt_configure_examples_path_str [512 + 12] = \"qt_xmplpath=" << escapeSeparators(dictionary["QT_INSTALL_EXAMPLES"]) << "\";" << endl |
3229 << "static const char qt_configure_demos_path_str [512 + 12] = \"qt_demopath=" << QString(dictionary["QT_INSTALL_DEMOS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3232 << "static const char qt_configure_demos_path_str [512 + 12] = \"qt_demopath=" << escapeSeparators(dictionary["QT_INSTALL_DEMOS"]) << "\";" << endl |
3230 //<< "static const char qt_configure_settings_path_str [256] = \"qt_stngpath=" << QString(dictionary["QT_INSTALL_SETTINGS"]).replace( "\\", "\\\\" ) << "\";" << endl |
3233 //<< "static const char qt_configure_settings_path_str [256] = \"qt_stngpath=" << escapeSeparators(dictionary["QT_INSTALL_SETTINGS"]) << "\";" << endl |
3231 ; |
3234 ; |
3232 if(!dictionary[ "QT_HOST_PREFIX" ].isNull()) { |
3235 if (!dictionary[ "QT_HOST_PREFIX" ].isNull()) { |
3233 tmpStream << "#else" << endl |
3236 tmpStream << "#else" << endl |
3234 << "static const char qt_configure_prefix_path_str [512 + 12] = \"qt_prfxpath=" << QString(dictionary[ "QT_HOST_PREFIX" ]).replace( "\\", "\\\\" ) << "\";" << endl |
3237 << "static const char qt_configure_prefix_path_str [512 + 12] = \"qt_prfxpath=" << escapeSeparators(dictionary[ "QT_HOST_PREFIX" ]) << "\";" << endl |
3235 << "static const char qt_configure_documentation_path_str[512 + 12] = \"qt_docspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/doc").replace( "\\", "\\\\" ) <<"\";" << endl |
3238 << "static const char qt_configure_documentation_path_str[512 + 12] = \"qt_docspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/doc", true) <<"\";" << endl |
3236 << "static const char qt_configure_headers_path_str [512 + 12] = \"qt_hdrspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/include").replace( "\\", "\\\\" ) <<"\";" << endl |
3239 << "static const char qt_configure_headers_path_str [512 + 12] = \"qt_hdrspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/include", true) <<"\";" << endl |
3237 << "static const char qt_configure_libraries_path_str [512 + 12] = \"qt_libspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/lib").replace( "\\", "\\\\" ) <<"\";" << endl |
3240 << "static const char qt_configure_libraries_path_str [512 + 12] = \"qt_libspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/lib", true) <<"\";" << endl |
3238 << "static const char qt_configure_binaries_path_str [512 + 12] = \"qt_binspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/bin").replace( "\\", "\\\\" ) <<"\";" << endl |
3241 << "static const char qt_configure_binaries_path_str [512 + 12] = \"qt_binspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/bin", true) <<"\";" << endl |
3239 << "static const char qt_configure_plugins_path_str [512 + 12] = \"qt_plugpath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/plugins").replace( "\\", "\\\\" ) <<"\";" << endl |
3242 << "static const char qt_configure_plugins_path_str [512 + 12] = \"qt_plugpath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/plugins", true) <<"\";" << endl |
3240 << "static const char qt_configure_imports_path_str [512 + 12] = \"qt_impspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/imports").replace( "\\", "\\\\" ) <<"\";" << endl |
3243 << "static const char qt_configure_imports_path_str [512 + 12] = \"qt_impspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/imports", true) <<"\";" << endl |
3241 << "static const char qt_configure_data_path_str [512 + 12] = \"qt_datapath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ]).replace( "\\", "\\\\" ) <<"\";" << endl |
3244 << "static const char qt_configure_data_path_str [512 + 12] = \"qt_datapath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ], true) <<"\";" << endl |
3242 << "static const char qt_configure_translations_path_str [512 + 12] = \"qt_trnspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/translations").replace( "\\", "\\\\" ) <<"\";" << endl |
3245 << "static const char qt_configure_translations_path_str [512 + 12] = \"qt_trnspath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/translations", true) <<"\";" << endl |
3243 << "static const char qt_configure_examples_path_str [512 + 12] = \"qt_xmplpath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/example").replace( "\\", "\\\\" ) <<"\";" << endl |
3246 << "static const char qt_configure_examples_path_str [512 + 12] = \"qt_xmplpath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/example", true) <<"\";" << endl |
3244 << "static const char qt_configure_demos_path_str [512 + 12] = \"qt_demopath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/demos").replace( "\\", "\\\\" ) <<"\";" << endl |
3247 << "static const char qt_configure_demos_path_str [512 + 12] = \"qt_demopath=" << fixSeparators(dictionary[ "QT_HOST_PREFIX" ] + "/demos", true) <<"\";" << endl |
3245 << "#endif //QT_BOOTSTRAPPED" << endl; |
3248 << "#endif //QT_BOOTSTRAPPED" << endl; |
3246 } |
3249 } |
3247 tmpStream << "/* strlen( \"qt_lcnsxxxx\" ) == 12 */" << endl |
3250 tmpStream << "/* strlen( \"qt_lcnsxxxx\") == 12 */" << endl |
3248 << "#define QT_CONFIGURE_LICENSEE qt_configure_licensee_str + 12;" << endl |
3251 << "#define QT_CONFIGURE_LICENSEE qt_configure_licensee_str + 12;" << endl |
3249 << "#define QT_CONFIGURE_LICENSED_PRODUCTS qt_configure_licensed_products_str + 12;" << endl |
3252 << "#define QT_CONFIGURE_LICENSED_PRODUCTS qt_configure_licensed_products_str + 12;" << endl |
3250 << "#define QT_CONFIGURE_PREFIX_PATH qt_configure_prefix_path_str + 12;" << endl |
3253 << "#define QT_CONFIGURE_PREFIX_PATH qt_configure_prefix_path_str + 12;" << endl |
3251 << "#define QT_CONFIGURE_DOCUMENTATION_PATH qt_configure_documentation_path_str + 12;" << endl |
3254 << "#define QT_CONFIGURE_DOCUMENTATION_PATH qt_configure_documentation_path_str + 12;" << endl |
3252 << "#define QT_CONFIGURE_HEADERS_PATH qt_configure_headers_path_str + 12;" << endl |
3255 << "#define QT_CONFIGURE_HEADERS_PATH qt_configure_headers_path_str + 12;" << endl |
3418 cout << "Support for S60............." << dictionary[ "S60" ] << endl; |
3421 cout << "Support for S60............." << dictionary[ "S60" ] << endl; |
3419 } |
3422 } |
3420 |
3423 |
3421 if (dictionary.contains("SYMBIAN_DEFFILES")) { |
3424 if (dictionary.contains("SYMBIAN_DEFFILES")) { |
3422 cout << "Symbian DEF files enabled..." << dictionary[ "SYMBIAN_DEFFILES" ] << endl; |
3425 cout << "Symbian DEF files enabled..." << dictionary[ "SYMBIAN_DEFFILES" ] << endl; |
3423 if(dictionary["SYMBIAN_DEFFILES"] == "no") { |
3426 if (dictionary["SYMBIAN_DEFFILES"] == "no") { |
3424 cout << "WARNING: Disabling DEF files will mean that Qt is NOT binary compatible with previous versions." << endl; |
3427 cout << "WARNING: Disabling DEF files will mean that Qt is NOT binary compatible with previous versions." << endl; |
3425 cout << " This feature is only intended for use during development, NEVER for release builds." << endl; |
3428 cout << " This feature is only intended for use during development, NEVER for release builds." << endl; |
3426 } |
3429 } |
3427 } |
3430 } |
3428 |
3431 |
3429 if(dictionary["ASSISTANT_WEBKIT"] == "yes") |
3432 if (dictionary["ASSISTANT_WEBKIT"] == "yes") |
3430 cout << "Using WebKit as html rendering engine in Qt Assistant." << endl; |
3433 cout << "Using WebKit as html rendering engine in Qt Assistant." << endl; |
3431 |
3434 |
3432 if(checkAvailability("INCREDIBUILD_XGE")) |
3435 if (checkAvailability("INCREDIBUILD_XGE")) |
3433 cout << "Using IncrediBuild XGE......" << dictionary["INCREDIBUILD_XGE"] << endl; |
3436 cout << "Using IncrediBuild XGE......" << dictionary["INCREDIBUILD_XGE"] << endl; |
3434 if( !qmakeDefines.isEmpty() ) { |
3437 if (!qmakeDefines.isEmpty()) { |
3435 cout << "Defines....................."; |
3438 cout << "Defines....................."; |
3436 for( QStringList::Iterator defs = qmakeDefines.begin(); defs != qmakeDefines.end(); ++defs ) |
3439 for (QStringList::Iterator defs = qmakeDefines.begin(); defs != qmakeDefines.end(); ++defs) |
3437 cout << (*defs) << " "; |
3440 cout << (*defs) << " "; |
3438 cout << endl; |
3441 cout << endl; |
3439 } |
3442 } |
3440 if( !qmakeIncludes.isEmpty() ) { |
3443 if (!qmakeIncludes.isEmpty()) { |
3441 cout << "Include paths..............."; |
3444 cout << "Include paths..............."; |
3442 for( QStringList::Iterator incs = qmakeIncludes.begin(); incs != qmakeIncludes.end(); ++incs ) |
3445 for (QStringList::Iterator incs = qmakeIncludes.begin(); incs != qmakeIncludes.end(); ++incs) |
3443 cout << (*incs) << " "; |
3446 cout << (*incs) << " "; |
3444 cout << endl; |
3447 cout << endl; |
3445 } |
3448 } |
3446 if( !qmakeLibs.isEmpty() ) { |
3449 if (!qmakeLibs.isEmpty()) { |
3447 cout << "Additional libraries........"; |
3450 cout << "Additional libraries........"; |
3448 for( QStringList::Iterator libs = qmakeLibs.begin(); libs != qmakeLibs.end(); ++libs ) |
3451 for (QStringList::Iterator libs = qmakeLibs.begin(); libs != qmakeLibs.end(); ++libs) |
3449 cout << (*libs) << " "; |
3452 cout << (*libs) << " "; |
3450 cout << endl; |
3453 cout << endl; |
3451 } |
3454 } |
3452 if( dictionary[ "QMAKE_INTERNAL" ] == "yes" ) { |
3455 if (dictionary[ "QMAKE_INTERNAL" ] == "yes") { |
3453 cout << "Using internal configuration." << endl; |
3456 cout << "Using internal configuration." << endl; |
3454 } |
3457 } |
3455 if( dictionary[ "SHARED" ] == "no" ) { |
3458 if (dictionary[ "SHARED" ] == "no") { |
3456 cout << "WARNING: Using static linking will disable the use of plugins." << endl; |
3459 cout << "WARNING: Using static linking will disable the use of plugins." << endl; |
3457 cout << " Make sure you compile ALL needed modules into the library." << endl; |
3460 cout << " Make sure you compile ALL needed modules into the library." << endl; |
3458 } |
3461 } |
3459 if( dictionary[ "OPENSSL" ] == "linked" && opensslLibs.isEmpty() ) { |
3462 if (dictionary[ "OPENSSL" ] == "linked" && opensslLibs.isEmpty()) { |
3460 cout << "NOTE: When linking against OpenSSL, you can override the default" << endl; |
3463 cout << "NOTE: When linking against OpenSSL, you can override the default" << endl; |
3461 cout << "library names through OPENSSL_LIBS." << endl; |
3464 cout << "library names through OPENSSL_LIBS." << endl; |
3462 cout << "For example:" << endl; |
3465 cout << "For example:" << endl; |
3463 cout << " configure -openssl-linked OPENSSL_LIBS=\"-lssleay32 -llibeay32\"" << endl; |
3466 cout << " configure -openssl-linked OPENSSL_LIBS=\"-lssleay32 -llibeay32\"" << endl; |
3464 } |
3467 } |
3465 if( dictionary[ "ZLIB_FORCED" ] == "yes" ) { |
3468 if (dictionary[ "ZLIB_FORCED" ] == "yes") { |
3466 QString which_zlib = "supplied"; |
3469 QString which_zlib = "supplied"; |
3467 if( dictionary[ "ZLIB" ] == "system") |
3470 if (dictionary[ "ZLIB" ] == "system") |
3468 which_zlib = "system"; |
3471 which_zlib = "system"; |
3469 |
3472 |
3470 cout << "NOTE: The -no-zlib option was supplied but is no longer supported." << endl |
3473 cout << "NOTE: The -no-zlib option was supplied but is no longer supported." << endl |
3471 << endl |
3474 << endl |
3472 << "Qt now requires zlib support in all builds, so the -no-zlib" << endl |
3475 << "Qt now requires zlib support in all builds, so the -no-zlib" << endl |