summaryrefslogtreecommitdiffstats
path: root/qmake
Commit message (Collapse)AuthorAgeFilesLines
* Make Qt relocatableAlexandru Croitor2019-09-071-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][QtCore] Qt installations on the host system can now be relocated, i.e. moved to other directories. Add a new feature 'relocatable' that's by default enabled for non-static builds - on platforms where libdl is available, - on macOS when configured with -framework, - on Windows. If the feature is enabled, the directory where plugins, translations and other assets are loaded from is determined by the location of libQt5Core.so and the lib dir (bin dir on Windows) relative to the prefix. For static builds, the feature 'relocatable' is off by default. It can be turned on manually by passing -feature-relocatable to configure. In that case, QLibraryInfo::location(QLibraryInfo::TranslationsPaths) and friends will return paths rooted in the user application's directory. The installed and relocated qmake determines properties like QT_INSTALL_PREFIX and QT_HOST_PREFIX from the location of the qmake executable and the host bin dir relative to the host prefix. This is now always done, independent of the 'relocatable' feature. Note that qmake is currently only relocatable within an environment that has the same layout as the original build machine due to absolute paths to the original prefix in .prl, .pc and .la files. This will be addressed in a separate patch. Task-number: QTBUG-15234 Change-Id: I7319e2856d8fe17f277082d71216442f52580633 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-09-044-24/+44
|\ | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/codecs/qicucodec.cpp src/dbus/qdbusserver.cpp src/gui/painting/qbezier.cpp src/plugins/platforms/eglfs/deviceintegration/eglfs_kms/qeglfskmsgbmscreen.cpp src/plugins/printsupport/cups/qppdprintdevice.cpp Change-Id: I2703128bb64baf5580fbc2c2061b55b0f0611d2a
| * Merge remote-tracking branch 'origin/5.12' into 5.13Allan Sandfeld Jensen2019-08-273-18/+8
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/painting/qdrawhelper.cpp src/gui/painting/qdrawhelper_p.h src/gui/painting/qdrawhelper_sse2.cpp src/gui/painting/qdrawhelper_x86_p.h Change-Id: I83256bb38ab3a705776e353bc0629315b6c59a0f
| | * Remove broken wild card list from QMake's help outputJoerg Bornemann2019-08-242-6/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The description of the project mode looked like this: -project Put qmake into project file generation mode In this mode qmake interprets files as files to be built, defaults to *; *; *; *.ts; *.xlf; *.qrc The list of wildcards is incomplete. Unfortunately the file extensions are defined in QMAKE_EXT_* variables in mkspecs, and the help display code has no access to that data. This went unnoticed for quite some time, and fixing this is too involved considering the gain. Replace the text above with the static text below: -project Put qmake into project file generation mode In this mode qmake interprets [files] as files to be added to the .pro file. By default, all files with known source extensions are added. Change-Id: I815a50957c05dccc45e1cd6657f568599d1911f6 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| | * Fix classical strcmp misuse in VS project generatorJoerg Bornemann2019-08-241-12/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | The conditions were wrong, they must compare against zero. Also, use qstricmp to avoid the platform #ifdef. Change-Id: I7e5ef1b9ae8e2e1d3d9ce90a645ee568b370ab57 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| * | Merge remote-tracking branch 'qt/5.12' into 5.13Paul Olav Tvete2019-08-201-6/+36
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/configure.json src/gui/util/qtexturefilereader.cpp src/gui/util/util.pri tests/auto/gui/util/qtexturefilereader/tst_qtexturefilereader.cpp Change-Id: I2bc4f84705b66099e97330cda68e0b816aceb9cc
| | * Fix qinstall on Windows for directories containing read-only filesJoerg Bornemann2019-08-151-6/+36
| | | | | | | | | | | | | | | | | | | | | | | | Initial patch by: Vlad Lipskiy <eswcvlad@yahoo.com> Fixes: QTBUG-77299 Change-Id: I803b809d1f23d844252b701cb070f6e4ba34eca1 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | Merge remote-tracking branch 'origin/dev' into 5.14Liang Qi2019-08-275-198/+26
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/widgets/kernel/qwidget.cpp src/widgets/kernel/qwidget_p.h src/widgets/kernel/qwidgetrepaintmanager.cpp src/widgets/kernel/qwidgetwindow.cpp tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp Change-Id: Ifae457d0427be8e2465e474b055722e11b3b1e5c
| * | | Improve readability of commands in VS project filesJoerg Bornemann2019-08-221-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The commands are separated by "if errorlevel 1 goto VCEnd" lines to make sure we abort on the first failure. However, we also insert magic comments starting with "Rem" for IncrediBuild. These do not need error checking. Also, the last command does not need error checking. The XML line ending entities are also unneeded. By using proper line endings we ensure that commands appear on separate lines in Visual Studio's property editor. Change-Id: Ifbf7525281e892c820034fafc64b555fff3dc756 Reviewed-by: Miguel Costa <miguel.costa@qt.io>
| * | | Fix "conflicting targets" warning when generating VS projectsJoerg Bornemann2019-08-221-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The VS project generator never calls the Win32MakefileGenerator code that sets up DEST_TARGET which is used for checking for conflicting DESTDIR/TARGET combinations on Windows. Replicate the setup in VcprojGenerator::initProject(). This amends commit e75aed1a. Change-Id: I4238eb2f57615095c372cee9ada9fc961cc36133 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
| * | | Fix .sln generation for sub-projects with same TARGETJoerg Bornemann2019-08-201-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sub-projects in VS solutions must have unique project names. If there are multiple projects with the same TARGET then QMAKE_PROJECT_NAME must be set to different values. The .sln generation code did not use QMAKE_PROJECT_NAME and produced .sln files with equally named sub-projects. Replace the 'orig_target' member of VcsolutionDepend with a 'projectName' member and use it when writing the .sln file and for the misnamed "GUID map" that's supposed to have unique keys. This commit amends 9e750d34 (qt/qt.git). Fixes: QTBUG-77639 Change-Id: I81c64f8bc6baeb6d99e9d5808fb73dfd7aaaeeb8 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Kai Koehne <kai.koehne@qt.io>
| * | | Remove dead QMakeSourceFileInfo caching feature from QMakeJoerg Bornemann2019-08-203-187/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since its introduction in commit 65bb1a25419210e6097cad973fb847aa3719c09b (old internal history, 2005) with the commit message "optimizations I've been sitting on here" we're dragging along this dead code. It is time for removal. Change-Id: Ic7902ebb8c402734974ad6651a1371d1e5bf93c5 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | | Add support for calendars beside GregorianSoroush Rabiei2019-08-203-0/+24
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add QCalendarBackend as a base class for calendar implementations and QCalendar as a facade via which to access it. QDate's implicit implementation of the Gregorian calendar becomes QGregorianCalendar and QDate methods now support choice of calendar. Convert QLocale's CLDR data for month names to a locale-data component of each supported calendar and relevant QLocale methods now support choice of calendar. Adapt Python scripts for locale data generation to extract month name data from CLDR (keeping on version v35.1) into the new calendar-locale files. The locale data for the Gregorian calendar is held in a Roman calendar base, for sharing with other calendars. Add tests for basic uses of the new API. [ChangeLog][QtCore][QCalendar] Added QCalendar to support diverse calendars, supported by implementing QCalendarBackend. [ChangeLog][QtCore][QDate] Allow choice of calendar in various operations, with Gregorian remaining the default. Done-with: Lars Knoll <lars.knoll@qt.io> Done-with: Edward Welbourne <edward.welbourne@qt.io> Fixes: QTBUG-17110 Fixes: QTBUG-950 Change-Id: I9d6278f394269a183aee8156e990cec4d5198ab8 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-08-161-3/+7
|\| | | | | | | | | | | Change-Id: Ia3645f92b9debf3e1fe2d972300c7d0dbd649268
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-08-151-3/+7
| |\| | | | | | | | | | Change-Id: Id7954ada1f8658d3b1da5e8241a09f2d201a7c56
| | * Fix escaping of < and > in QMake's XML generatorJoerg Bornemann2019-08-121-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | Having those characters in QMAKE_EXTRA_COMPILERS broke the generated VS project file. They must be replaced by XML entities. Fixes: QTBUG-1935 Change-Id: Iff1edbeabec4cedef777071682412970b7769f19 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev"Liang Qi2019-08-132-10/+38
|\ \ \
| * | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-08-132-10/+38
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/win32-clang-msvc/qmake.conf src/corelib/tools/qlist.h src/gui/painting/qcompositionfunctions.cpp src/gui/painting/qtriangulator_p.h src/gui/text/qfontengine_p.h src/network/kernel/qhostinfo_p.h src/platformsupport/fontdatabases/freetype/qfontengine_ft.cpp Done-With: Allan Sandfeld Jensen <allan.jensen@qt.io> Change-Id: Ib8a0308cf77224c4fbdcf56778fdac4a43e37798
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-08-121-5/+5
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config.tests/arch/write_info.pri Repair architecture config test for the WASM_OBJECT_FILES=1 build mode configure.pri tests/auto/gui/text/qtextdocument/tst_qtextdocument.cpp Done-With: Jörg Bornemann <joerg.bornemann@qt.io> Change-Id: I9e12088356eb5bc65b53211cd7a8e330cccd1bb4
| | | * Doc: Extend QMake's documentation of RC_FILE and RES_FILEJoerg Bornemann2019-08-121-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RC_FILE is not an internal variable that "rarely needs to be modified". Mention that it's about Windows resources and link to the corresponding section. RES_FILE: Add link to RC_FILE and the more general section. Also rephrase "compiled Windows resource file" to "Windows resource compiler's output file" which is more precise. Fixes: QTBUG-8709 Change-Id: I19c61e6a9505d45fc13fefbcd0ba9441191aa42e Reviewed-by: Kai Koehne <kai.koehne@qt.io> Reviewed-by: Kavindra Palaraja <kpalaraja@luxoft.com>
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-08-051-5/+33
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: qmake/generators/unix/unixmake2.cpp src/plugins/platforms/cocoa/qcocoawindow.mm Change-Id: Iba7aa7324f35543e0297a3680956420058cd3630
| | | * Fix dependency_libs entry of .la filesJoerg Bornemann2019-08-031-5/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Libtool cannot cope with absolute paths in the dependency_libs entry. We split absolute paths into -L and -l here. Change-Id: I30bf11e490d1993d2a4d88c114e07bbae12def6d Fixes: QTBUG-76625 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | | Determine dependencies of Windows resource filesJoerg Bornemann2019-08-132-2/+10
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Windows resource files support a subset of C preprocessor directives. Among others they can have #include directives. Use QMake's own scanner to retrieve the files that are included by a Windows resource file and add them to its dependencies. For the test case the TestCompiler class had to be extended: runCommand is now public, and commandOutput is less peculiar. Fixes: QTBUG-3859 Change-Id: I138703352c37c98297c0574a9a440510c1c494b8 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Do not use QList<QMakeLocalFileName>Joerg Bornemann2019-08-126-20/+18
| | | | | | | | | | | | | | | | | | | | | QMakeLocalFileName is not suitable for QList. Use QVector instead. Change-Id: I5a3c4c8da14c0a920b5a57cba148ad68ac0f85a2 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Warn about conflicting DESTDIR/TARGET combination in debug_and_releaseJoerg Bornemann2019-08-095-0/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a project has DESTDIR and TARGET set to fixed values, then the target paths conflict when doing debug_and_release builds. With this change we're detecting this situation and yield a warning. Fixes: QTBUG-2736 Change-Id: Ib163db3463322792ab9fa5b997285ac9fc9819ab Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | QMakeLocalFileName: remove mutable specifier from real_nameJoerg Bornemann2019-08-081-1/+2
| | | | | | | | | | | | | | | | | | | | | There is no need to have both QString member mutable. Change-Id: I592963b7c66e564b918d750fb47e903df0b0f9bc Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Remove special handling of DLLDESTDIR on WindowsJoerg Bornemann2019-08-031-8/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In MakefileGenerator::initOutPaths() we ensure that directory variables end with a directory separator, except for DLLDESTDIR. There doesn't seem to be a valid reason for this exception. Remove it for the sake of simplifying the code base. Change-Id: I60eb01b410161e6e1d147d76f044f5140a7573bd Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Remove QMake's -createstub optionJoerg Bornemann2019-08-038-39/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | This undocumented option was introduced in 69c22301806b56d56cbe5f5076b889ba98e41a2b (old internal history, 2006) to prepare some unspecified change to configure that was never done. Change-Id: I60de731ac9bc6f6424c57574e59e9f6b4f6c5eb3 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Fix Makefile re-generation for debug_and_release buildsJoerg Bornemann2019-08-021-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Re-generation of the Makefile depends on a correctly set up QMAKE_INTERNAL_INCLUDED_FILES variable. In debug_and_release builds this variable is set up for Makefile.Debug and Makefile.Release, but not for the meta Makefile. However, that's where the Makefile re-generation target is located. We now collect the contents of QMAKE_INTERNAL_INCLUDED_FILES for Makefile.Debug/Release and use that for the meta Makefile. Fixes: QTBUG-13334 Change-Id: I6124a91447d5c54d51680e23570c4e97f44e6a73 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Rename MakefileGenerator::build_args() to ...::fullBuildArgs()Joerg Bornemann2019-07-312-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ...because - it calls the properly camel-cased member function buildArgs(bool), which is slightly confusing - it returns buildArgs(true) plus input and output We also let it return only the arguments, excluding the qmake executable. This is consistent with the function's name and saves us a string replacement stunt at one call site. Change-Id: I8bea65900bd51962962e4cfd425ffbc26e3a52fe Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Remove dead code from metamakefile.cppJoerg Bornemann2019-07-311-14/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove usage of the 'if (0 && ...)' pattern that was presumably used to temporarily disable code paths. The disabling of the two code paths was introduced in 356a677b386648710efc4db9a8a1b4a975f95c48 (old internal history, 2004) and 0326e3511928d90329152b9b0493da76e9caa442 (old internal history, 2006). It can be deduced that it's pretty safe to remove both. Change-Id: I88aee65b1286701241b5b80fbac0c65cd99ecd5e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-07-302-37/+18
|\| | | | | | | | | | | | | | | | | | | | Conflicts: qmake/generators/win32/mingw_make.cpp Change-Id: I2f790bc8572bd22fea01edf7ca74595b29f063eb
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-07-301-10/+9
| |\| | | | | | | | | | Change-Id: Ibdbd88e11cd03d5ce558e67ad8e9a21436e7ef89
| | * qmake: Keep -force_load with library when merging linker flagsTor Arne Vestbø2019-07-291-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without treating -force_load as an option with an argument, we end up leaving stray -force_loads in the linker line, resulting in build failures when the following option is a random library then treated as a file path. Task-number: QTBUG-66091 Change-Id: I352c50ab67e32ef6b2b5c6a4f90455b20034e207 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
| | * qmake: Don't allow -framework without second argument when merging flagsTor Arne Vestbø2019-07-291-8/+4
| | | | | | | | | | | | | | | | | | | | | | | | The linker doesn't support -framworkFoo, so neither should we. The correct syntax is -framework Foo. Change-Id: I3f39ffc067871ce058542bf0068274b35f7b51f6 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
| * | qmake: Use a simple response file for ar on mingwOrgad Shaneh2019-07-291-27/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change allows using custom flags for ar. For instance, it is now possible to create a thin archive by setting QMAKE_LIB += -T. This uses and extends commit d92c25b1b4ac0423a824715a08b2db2def4b6e25 which served a similar purpose for the linker. Change-Id: Ie1d6a0b957dc4809957726de00911c8d91647fab Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-07-222-5/+6
|\| | | | | | | | | | | | | | | | | | | | Conflicts: qmake/generators/makefile.cpp Change-Id: Ib3715e626f2fd32804c75c16ea9aa06a1216e76d
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-07-202-5/+6
| |\| | | | | | | | | | Change-Id: Ic34021fbb87d689ee23a5d1b3f50617ada9ec9b9
| | * qmake: fix variable naming conflicts with C++20 keywordYulong Bai2019-07-191-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | It conflicts with 'requires' keyword. Fixes: QTBUG-77093 Change-Id: I85e8f530dd1e2bf9a31906dd6c5123b947235b01 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| | * qmake: fix move semanticsGiuseppe D'Angelo2019-07-181-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ProFunctionDef is move-enabled, meaning its `m_pro` field can become nullptr. Its usage in the assignment operator and the dtor must therefore be protected with a check. Amends 9c63ad562bf0a44807f41ce49e4fe1b5ff181a63. Change-Id: I0c77b07dc83969565480bbb9d9fc80751d4246b1 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-07-171-26/+13
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qlogging.cpp src/gui/painting/qtextureglyphcache_p.h src/gui/text/qfontengine.cpp src/widgets/widgets/qlineedit.cpp Change-Id: Ic8798538df466b7141caa8bbf1fb7605eb56be37
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-07-121-26/+13
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure.pri Also required s/solid\.color/solidColor/ in a couple of places in: src/gui/painting/qpaintengine_raster.cpp Change-Id: I29937f63e9779deb6dac7ae77e2948d06ebc0319
| | * Revert "Fix determination of source and build roots"Jörg Bornemann2019-07-041-26/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 224a60989ed95e8b91ac88a12666af6e5a66e619. Turns out that we cannot just untangle the determination of source root and build root, because this breaks the assumption that every .qmake.conf results in a separate .qmake.cache in the build tree. QTBUG-76140 must be fixed differently. Fixes: QTBUG-76907 Change-Id: I5c0a3719d5e00a0f1cacad51651b47c1f284d22d Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | | QMake: fix GCC 9 -Wdeprecated-copy warningsMarc Mutz2019-07-152-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Not visible in QMake, because of too old C++ standard used to compile it, but in the qttools copy. Fix here, as the authorative source, first. Change-Id: I2552eccfaab2cef0863686dcd888f2a5f25ca29f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | | QMake: be less laissez-faire with implicit conversions to QCharMarc Mutz2019-07-153-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QChar currently is convertible from nearly every integral type. This is bad code hygiene and should be fixed come Qt 6. The present patch is the result of compile fixes from marking these constructors explicit. Amends 60ca2f5f7c38178cfe62d3dbe1b8dacfe43cbac9. Change-Id: I06887104d42f8327eb6196afcde5f942a74a6a78 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | | Move text-related code out of corelib/tools/ to corelib/text/Edward Welbourne2019-07-102-20/+23
| | | | | | | | | | | | | | | | | | | | | | | | This includes byte array, string, char, unicode, locale, collation and regular expressions. Change-Id: I8b125fa52c8c513eb57a0f1298b91910e5a0d786 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-07-051-0/+8
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf qmake/generators/makefile.cpp Change-Id: Ifb2633a69d0bf8cdf12d799c6259beefc279c49e
| * | CMake: Fix handling of static dependencies that have spaces in pathAlexandru Croitor2019-07-051-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The absolute paths of certain static dependencies can have spaces in them. The _qt5_$${CMAKE_MODULE_NAME}_process_prl_file fails to handle this, and simply replaces all spaces with semicolons, which obviously breaks the list of dependencies, and a consuming application fails to link with a message like: LINK : fatal error LNK1181: cannot open input file 'C:\Program.obj' This change partially restores the functionality that was added in 102e1822ffcdc9954d3c698f863734a8083e349c specifically the part that changes qmake to export an additional variable QMAKE_PRL_LIBS_FOR_CMAKE. This variable has the same content as QMAKE_PRL_LIBS except it uses a semicolon as a separator, so that CMake can correctly parse the separate lib entries. This is much cleaner than trying to parse the original QMAKE_PRL_LIBS variable with a complicated regular expression. Amends eda28621f6c1a68774719f382be53ec109123b18. Task-number: QTBUG-38913 Change-Id: I1d18fb779606505bc92320d8ce13232c7022e212 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* | | Do not ignore exit codes when installing meta filesJoerg Bornemann2019-07-011-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since commit 20e9422e we don't ignore exit codes when installing files anymore. This patch does the same for meta file installation. We really should be notified properly if something goes wrong here. Task-number: QTBUG-18870 Change-Id: Ib6a20293380f400379b10ec767bf38dc74d5beeb Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* | | Introduce Q_NAMESPACE_EXPORTGiuseppe D'Angelo2019-06-281-3/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A recurring problem with the Q_NAMESPACE macro is that it declares an object (staticMetaObject) in the surrounding namespace. That object lacks any export/import qualification to make it usable with shared libraries. Introduce therefore another macro to work around this issue, allowing the user to prefix the object with an exporting macro, f.i. like this: Q_NAMESPACE_EXPORT(Q_CORE_EXPORT) The old macro can simply then be rewritten in terms of this new one, supplying an empty export macro. Note that NOT passing an argument to a macro expecting one is well defined behavior in C99 -- the macro will expand an empty token. Of course, MSVC doesn't like this and emits warnings. As a workaround, use a variadic macro. [ChangeLog][QtCore] Added the new Q_NAMESPACE_EXPORT macro. It can be used just like Q_NAMESPACE to add meta-object information to a namespace; however it also supports exporting of such information from shared libraries. [ChangeLog][Potentially Source-Incompatible Changes] Prefixing Q_NAMESPACE with an export macro may no longer work. Use the new Q_NAMESPACE_EXPORT macro for that use case. Fixes: QTBUG-68014 Change-Id: Ib044a555ace1f77ae8e0244d824ec473550f3d8e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: BogDan Vatra <bogdan@kdab.com>