summaryrefslogtreecommitdiffstats
path: root/util
Commit message (Collapse)AuthorAgeFilesLines
* Simplify add_qml_module codeLeander Beernaert2019-07-221-25/+11
| | | | | | | | | | | | | | | | Reduce the amount of code required to add a qml plugin to cmake by making add_qml_module wrap the add_qt_plugin code where required. add_qml_module will also create a dummy target so that qml files will appear as source files in an IDE when no cpp files are present. CXX_MODULE qmake parameter has been dropped in favor of an explicit IMPORT_VERSION parameter, since it was only used to determine the version when the IMPORT_VERSION was not specified. Change-Id: I4a4b626566720d04c62d246ca521db8c4a95b10f Reviewed-by: Qt CMake Build Bot Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Process private libraries set in QT_PRIVATELeander Beernaert2019-07-221-1/+1
| | | | | | | | The pro2cmake conversion was not processing private libraries specified with the QT_PRIVATE variable. Change-Id: I0c44595bb8e1ed9a748af51a2a859bee62e7d264 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Fix mapping of features to private featuresSimon Hausmann2019-07-221-3/+10
| | | | | | | | | | | | | | | | | | | | When a feature generates a private feature, we should not just repeat the condition but also make it depend on the original feature. In qmake features had different outputs, while we have a 1:1 mapping. For example the developer_build feature had "private_tests" as an output feature. There's no condition attached to the feature and auto-detect is off, so we'd generate qt_feature("developer_build" AUTODETECT OFF) qt_feature("private_tests" AUTODETECT OFF) and that's wrong, because when the user enables the visible feature (developer_build) we want it to propagate to the private_tests feature. Change-Id: Id8408864802fa1e1ed9e67a5f47d1d2fde38d321 Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Qt CMake Build Bot Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Add special case handling for corelib mimetypes resourcesLeander Beernaert2019-07-181-6/+6
| | | | | | | | | | | | | We have to treat the resources from mimetypes in corelibs specially as they are reused for two test cases. Since we no longer use the qrc files, we have wrapped the relevant code in a function that can be called for every target that depends on it. This change also corrects formatting for the generate CMake code regarding resource commands. Change-Id: I50a05c81151d75aefc9ca165f5ffeb9f5cd77162 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Enable recursive expansion of simple qmake variablesLeander Beernaert2019-07-182-12/+24
| | | | | | | | | | | | | | | | | | | | | Allow _expand_value to expand variables that may have more than one level of expansion when the regular expression covers all of the input. E.g.: A = Foo B = $$A/Bar scope.expand('$$B') While the original code was able to expand the string '$$B/source.cpp' to 'Foo/Bar/source.cpp', it could not expand the string '$$B' completely. The latter would always return '$$A/Bar' instead of the expected 'Foo/Bar' string. A test case has been added which coveres the above example. Change-Id: Ie3b5739c24ecbeb67d408dd204b0f54bab1d0f3f Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Handle TESTDATA for Qt TestsLeander Beernaert2019-07-161-0/+20
| | | | | | | | | | | | | | | | These changes enable the support to handle test data and install or package them as resources when appropriate. This change does not handle the GENERATED_TESTDATA or TEST_HELPER_INSTALLS since there are very few occurrences of these and we can handle those as special cases. Finally, in add_qt_test, only append CMAKE_CURRENT_SOURCE_DIR if the path is not absolute. Change-Id: Ic20b9749d10e2a09916f2797606116471c64850b Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add support for QML pluginsLeander Beernaert2019-07-152-2/+53
| | | | | | | | | | | | | | | | | | Add the necessary code to both the QtBuild and pro2cmake to be able to handle qml plugins in qt declarative. Add condition replacement for QTDIR_build to QT_BUILDING_QT so that certain qml examples work correctly when being built in the build directory. Fix add_qt_resources not being updated during build after changes were made. Files list used as dependencies were not populated. Add missing module mappings for qtdeclarative. Change-Id: I0f71d0a3a0e7e97ba96807950d11cffaee04d9b2 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Qt CMake Build Bot
* Add missing expansion for $$_PRO_FILE_PWD_Leander Beernaert2019-07-151-1/+1
| | | | | | | | | | | Tests in qtdeclarative were failing because the above variable was expanded to an empty string. This causes the tests to be unable to locate their test data when executed. Change-Id: Ibc3c094123f25d688a73c11886ac1673b6930c54 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io> Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Merge remote-tracking branch 'origin/wip/qt6' into wip/cmakeAlexandru Croitor2019-07-1110-192/+386
|\ | | | | | | Change-Id: I715b1d743d5f11560e7b3fbeb8fd64a5e5ddb277
| * Add data for Windows Time-Zone IDs added in the last two yearsEdward Welbourne2019-07-011-0/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We've not run util/locale_database/cldr2qtimezone.py for a while, so CLDR has had time to add several more zones. Catch up, inserting the new entries in order. Change-Id: I8625548b0f7775958230eccbd89b897d7afed9e9 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Tidy up in cldr2qtimezone.py and document the need to run itEdward Welbourne2019-07-012-12/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It wasn't mentioned in cldr2qlocalexml.py's instructions, so I didn't know to run it. The data it used in an illustration was out of date. Two tests could be combined with no loss. Change-Id: I26e619e6210ea5b1258326fc4bc2b6aee9d6a999 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| * cldr2qtimezone.py: report all missing zones, rather than just the firstEdward Welbourne2019-07-011-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When scanning the CLDR data, the script raised an exception if it didn't recognize a zone ID. Instead, collect up such unrecognized IDs in a list and report them all at the end, so that whoever runs this can do them all in one go, rather than doing one, running the script, doing the next, running the script, ad nauseam. Change-Id: Ia659f1d1c7e1c1b4ccb87cc23828a0588a5bf958 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| * Use simpler data structures in cldr2qtimezone.pyEdward Welbourne2019-07-011-169/+165
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use tuples for the fixed data. The numbering of rows in the data tables isn't part of any public API, so we can change it freely; it is thus unnecessary, as we can just enumerate a tuple of the data values to generate sequential indices on the fly. (Updates to the data shall no longer need to renumber in order to insert entries.) Restore ordering of the data tables, and remove wanton spacing from inside parens, in the process. Change-Id: I59956cfb6191fe729300b57070671b7e66bd0379 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Remove usages of deprecated APIs from QtAlgorithmsSona Kurazyan2019-06-296-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-76491 Change-Id: I9dab736a0cbd2e86588919640c26e8ce6b3674d0 Reviewed-by: Alex Blasche <alexander.blasche@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
| * gen_qfloat16_tables: add a comment explaining what the tool isThiago Macieira2019-06-031-1/+13
| | | | | | | | | | | | | | | | For our future selves. Change-Id: I2b1955a995ad40f3b89afffd15a4c127686662bc Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
| * qfloat16: Check in the tables to GitThiago Macieira2019-06-032-0/+153
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's a 38k source file, which makes it MUCH smaller than other generated files like qlocale_data_p.h (982k) and qunicodetables.cpp (718k). The constants are platform-independent, since they are defined by IEEE 754, so they will never change. The generator tool is moved to util/ and removed from the build. That's one fewer bootstrapped tool to have to worry about. The output file is committed as .cpp so it won't get installed. Fixes: QTBUG-76165 Change-Id: I2b1955a995ad40f3b89afffd15a3ded58dc3e35f Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | Fix XCB feature detectionSimon Hausmann2019-06-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The xcb feature controls whether to build the xcb platform plugin. The feature depends among other things on qt_find_package(XCB 1.9 PROVIDED_TARGETS XCB::XCB) to succeed. This means at the moment setting XCB_FOUND to true, that's what the condition checks. Later on, in configure.cmake, we also check for other components in the XCB package, for example: qt_find_package(XCB COMPONENTS XINPUT PROVIDED_TARGETS XCB::XINPUT) If this component is not available, the xcb platform plugin has perhaps reduce functionality, but it should be built and the feature should be abled. However it isn't, because when that find_package call fails, XCB_FOUND will be set to false. And that in turn will disable the feature as the condition fails. Therefore this patch changes the condition to check for the presence of the XCB::XCB target instead. Change-Id: I534087d8c3b7ff5edf81a5ffcf16cc0bb78b9fb7 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Android: Final changes for APK generationLeander Beernaert2019-06-261-1/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Generate the ${MODULE}-android-dependencies.xml for the androiddeployqt tool. This will ensure all the right plugins and dependencies are packaged when generating the apk. This change also changes the visibility for executable to default/public. Not having this will cause the application to crash as we can't locate main() in the executable (shared library). Additionally pro2cmake conversion script has been updated to perform the required conversions for the Android settings. Finally, the 6 projects in QtBase that have Android dependencies have been updated with the new script and the step that produces the xml files in run at the end in QtPostProcess.cmake. Change-Id: I9774ba1b123bc11cae972fa37054ef2c51988498 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Merge remote-tracking branch 'origin/wip/qt6' into wip/cmakeAlexandru Croitor2019-06-142-121/+121
|\| | | | | | | | | | | | | | | | | | | This changes many different CMake places to mention Qt6 instead of Qt5. Note that some old qt5 cmake config files in corelib are probably not needed anymore, but I still renamed and kept them for now. Change-Id: Ie69e81540386a5af153f76c0242e18d48211bec4
| * Separate out the time, zone, date code from corelib/tools/Edward Welbourne2019-06-061-2/+2
| | | | | | | | | | | | | | | | | | | | We'll be adding calendar code here as well, and tools/ was getting rather crowded, so it looks like time to move out a reasonably coherent sub-bundle of it all. Change-Id: I7e8030f38c31aa307f519dd918a43fc44baa6aa1 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | Fix compiling of examples on AndroidSimon Hausmann2019-06-121-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Simplify add_qt_gui_executable() to not require WIN32/MACOSX_BUNDLE but provide it implicitly. It's redundant :) * When on Android, build a module (shared library), just like qmake. This requires an additional library destination in the install() call, but that's ignored on other platforms. * Fix typos in the android deployment generation settings function * Use the correct cache variable to determine whether we're inside a Qt build or not. Right now this only works inside Qt builds anyway as QtPlatformAndroid.cmake is not publically accessible. Change-Id: If1c763c31a7a83d0e0d854362ba7901657f63eb5 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Qt CMake Build Bot
* | Fix linking of examplesSimon Hausmann2019-06-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provide add_qt_gui_executable() as function in our public API that takes care of automaticWinMain linkage. We can use this in the future to encapsulate similarplatform-specific behavior and adjustments, such as module generation onAndroid. In order for the examples to see the function in Qt5CoreMacros, three more additional fixes were required: * Do the build_repo_end() call _before_ attempting to build the examples, as we need the build_repo_end() to include QtPostProcess and complete the creation of all the target config files. Otherwise the find_package() calls in the examples see something incomplete. * Add more QT_NO_CREATE_TARGET guards * Always call find_dependency on the dependencies, regardless of the target creation mode. This way a find_package(Qt5 COMPONENTS Widgets) will still load Qt5CoreMacros. Change-Id: I03ce856e2f4312a050fe8043b8331cbe8a6c93e6 Reviewed-by: Qt CMake Build Bot Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Improve special case handler to work on WindowsAlexandru Croitor2019-06-111-4/+20
| | | | | | | | | | | | | | | | | | There were some issues with not finding the git executable and trying to remove read-only files / files that are still held by a process. Change-Id: I7f587c4e96cff763cc0b3438d9ed2249da8f122f Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Improve pro2cmake.py moreAlexandru Croitor2019-06-081-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | Fix incorrect usage of CMAKE_CURRENT_BUILD_DIR, there is no such CMake variable, it's actually CMAKE_CURRENT_BINARY_DIR. Also if the host_build option is set when building a module, the library should be a static library. Change-Id: I9fb39905118dbd7f33d9821960eaed11f20b30c6 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Handle minimal_syncqt as not running syncqt for nowAlexandru Croitor2019-06-071-0/+2
| | | | | | | | | | | | | | | | This is needed for QmlDevTools in qtdeclarative. Change-Id: I41adec15f292c91192e171b45d1e5d48764c37c4 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Fix comment fixup in pro2cmakeAlexandru Croitor2019-06-062-1/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | Comments should be removed before line continuations, otherwise the semantics of an assignment change. Found this during reconversion of qtimageformats. Adjust test to specifically test for all the expected values. Amends 76f5b784ce54730ed8d6ad4bb9c39c9a05c5d81d. Change-Id: Iaa46bbc9cbd7b2390fe9b5f0078ac33d225a9258 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Fix some configure.json conditions for qtimageformatsAlexandru Croitor2019-06-061-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | The auto-generated add_subdirectory conditions in qtimageformats use QT_FEATURE_foo and not QT_FEATURE_system_foo. But the non-system ones don't actually check if the respective qt_find_package(TIFF) got found. Fix the conditions of the non system features to be the same as the system ones. Change-Id: I96f889cf7061721b829d562707c42aa0e29720df Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Add support for private module .pri filesSimon Hausmann2019-06-051-0/+2
| | | | | | | | | | | | | | | | | | Generate a pri file for public and private interfaces, but map CONFIG += internal_module to a cmake option and skip the former if set. Task-number: QTBUG-75666 Change-Id: I3f4baf1277094f4c22149a9e8769734baf9a235f Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | CMake: Add WrapPCRE2 packageCristian Adam2019-06-051-1/+1
| | | | | | | | | | | | | | | | The WrapPCRE2 package handles the PCRE2 packages that have targets, and reuse them. Change-Id: I24b0b51f507703cd8287f845f7e425f62dd2c3d6 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | Map module.gui to if TARGET Qt::Gui in configure.cmakeAlexandru Croitor2019-06-051-0/+2
| | | | | | | | | | | | | | | | | | | | Some features check for module / target existence. Adapt conversion script to handle that. Reland after fixing it. Change-Id: If4fb942c2e0d16e76a0b9b767bf478527851b0f7 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | cmake: build with exceptions disabled by defaultAlbert Astals Cid2019-06-051-0/+3
| | | | | | | | | | | | | | | | | | Only re-enable exceptions for the modules that do CONFIG+=exceptions in qmake Change-Id: I9f19078adbdc1b8fa3d4102fb51a099e7e35522e Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Fix write_all_source_file_lists type annotationAlexandru Croitor2019-06-051-1/+1
| | | | | | | | | | Change-Id: I6e22d21562a0923079b90cf9b3e6d15dfe16ff29 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | Revert "Map module.gui to if TARGET Qt::Gui in configure.cmake"Alexandru Croitor2019-06-051-2/+0
| | | | | | | | | | | | | | | | | | | | It breaks some conditions, and then the build fails not finding some private header files in qpa, etc. This reverts commit 35dc8f496dc324a816dc17e80b744bfe864ec261. Change-Id: I1b51eac06fe9186181d3f0a7c78f22da7be534e2 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* | Map module.gui to if TARGET Qt::Gui in configure.cmakeAlexandru Croitor2019-06-051-0/+2
| | | | | | | | | | | | | | | | Some features check for module existence. Adapt conversion script and QtBuild feature condition parser to handle that. Change-Id: I063e49a6fe9f8e9cf3aec985fd78ed4430398586 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Improve run_pro2cmake.pyAlexandru Croitor2019-06-051-33/+104
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add two new options: If you pass --only-existing, the pro2cmake script will only be executed on .pro files that already have a CMakeLists.txt next to them. This is useful if you modify pro2cmake, and only want to regenerate existing files. If you pass --only-qtbase-main-modules, the script will be executed on the main modules in qtbase/src. This is useful if you want to check if your pro2cmake modification works correctly on the more complicated projects. Change-Id: I5228411a252dbef6d77f01ca742a7b98583c5a75 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Qt CMake Build Bot
* | Fix extra_keys in write_all_source_file_lists to be optionalAlexandru Croitor2019-06-051-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | Initially it was added as a required argument, but not all usages of the function where adjusted, so the script failed. Make it optional. Also change the styling of the argument to be snake cased. Amends 8fea3ec4e77dfebe2e84e10ae0f014d03b9098b3. Change-Id: I568800401bb5af153b7bb5229f134c2f74b87468 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Qt CMake Build Bot
* | Fix special_case_handler to handle git add prev_CMakeLists.txt betterAlexandru Croitor2019-06-041-2/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using run_pro2cmake.py, it spawns multiple instances of pro2cmake.py. If more than 1 of the instances need to git add prev_CMakeLists.txt at the same time, git add might fail due to the acquired index.lock. The cleaner solution would be to use a file lock as a mutex, but that requires an external pypi package. Use a poor man solution of retrying the git add with a time delay for a finite amount of times. Change-Id: I2031f6e29ae499526cb4f1753e4387e7f4fab0ab Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Improve special_case_helper.pyAlexandru Croitor2019-06-041-3/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Make sure to set the author user and email for the temporary git repo, so that the commits succeed on systems that don't have a global git author. Also fix run_process_quiet to print stderr and stdout in case if the execution failed for some reason. Change-Id: I0ddb61730114b3e9c59e2d23480df0ced8d6e772 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | pro2cmake: Add PUBLIC to target_include_directoriesKevin Funk2019-06-041-1/+1
| | | | | | | | | | Change-Id: Ie4e882a5713022bfaec7182172be69616ff8b91c Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | pro2cmake: Always add a newline after func callsKevin Funk2019-06-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Fixes the situation where we end up with e.g.: ``` target_link_libraries(... )target_link_libraries(... ) ``` Change-Id: I455563b24850db7f389746385af53cd606343274 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | pro2cmake: A couple more fixes regarding examplesKevin Funk2019-06-041-8/+8
| | | | | | | | | | | | | | | | | | | | Changes: - Make sure the footer is passed along to callees - Make sure RESOURCES are part of add_executable(...) for AUTORCC Change-Id: I4546bacd2e41ca8acc1a9351af54d325afb715ab Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | cmake: register plug-ins, create dependencies fileJean-Michaël Celerier2019-06-041-6/+15
| | | | | | | | | | | | | | | | This commit introduces infrastructure work to allow static builds of Qt to handle importing of plug-ins. Change-Id: Ife0ca3ca7276ea8ec96fe0eb6adf934fad7620ec Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* | cmake: Fix xcb buildAlbert Astals Cid2019-06-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Need qt_find_package(X11_XCB) in src/gui/configure.cmake since we're using it in the file qt_feature("xcb_xlib" PRIVATE LABEL "XCB Xlib" CONDITION QT_FEATURE_xlib AND X11_XCB_FOUND ) Need qt_find_package(XRender PROVIDED_TARGETS PkgConfig::xrender) in src/plugins/platforms/xcb/CMakeLists.tx since we're using it in the file extend_target(XcbQpa CONDITION QT_FEATURE_xcb_native_painting AND QT_FEATURE_xrender PUBLIC_LIBRARIES PkgConfig::xrender ) Use capital XRender in pkgconfig to be more consistent on how XRender is called everywhere else Change-Id: I403ead2cc123b08f741c5142f20db88987657ba8 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Handle a few more condition types in pro2cmakeAlexandru Croitor2019-06-041-0/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qtdeclarative has a few conditions that check the gcc version via variables like QT_GCC_MAJOR_VERSION. To handle that, parse the CMake compiler version using qt_parse_version_string() into separate variables like QT_COMPILER_VERSION_MAJOR, QT_COMPILER_VERSION_MINOR and QT_COMPILER_VERSION_PATCH. We can then map the conditions appropriately. Also, handle isEqual(foo, bar), which is equivalent equals(foo,bar). Change-Id: I74575c733b44f1f42451e00038b3f113fd353915 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | More fixes to conversion script while porting qtdeclarativeAlexandru Croitor2019-06-032-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hardcode a few cases regarding scopes containing "qtConfig(opengl)". These arew few, and contain regular expressions, to just manually check and replace them. Add a new entry to _qt_library_map for handling QmlModels module. Fix Scope.children property to recursively access the .children property on included scopes (instead of just ._children) so that we get the full list of scopes from included children that include other scopes. This is needed for nested .pri files. Fix mapping of "win*" to WIN32. Change-Id: If949a8051f517683e56cda605733719daadb384a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Qt CMake Build Bot
* | Generate the c++xx standard features instead of skipping themAlexandru Croitor2019-06-032-7/+4
| | | | | | | | | | | | | | | | | | | | | | The features are reused in qtdeclarative (and maybe somewhere else too), so they should be present. We can still map the conditions to proper CMake compile feature tests. Change-Id: I4d307d29d4d293cc23ab005b195ea346087c7162 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io> Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Merge remote-tracking branch 'origin/dev' into wip/cmakeAlexandru Croitor2019-06-0317-34/+116
|\| | | | | | | | | | | Take 5. Change-Id: Ifb2d20e95ba824e45e667fba6c2ba45389991cc3
| * Add locale support for Cebuano and Erzya languages (new in CLDR v35.1)Edward Welbourne2019-05-201-0/+2
| | | | | | | | | | | | | | Change-Id: I5d0ee7bc27eeca1c046d442b0410128ea5abbdb3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
| * Suggest name, when available, for unknown codesEdward Welbourne2019-05-202-5/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When parsing the CLDR data, we only handle language, script and territory (which we call country) codes if they are known to our enumdata.py tables. When reporting the rest as unknown, in the content of an actual locale definition (not the likely subtag data), check whether en.xml can resolve the code for us; if it can, report the full name it provides, as a hint to whoever's running the script that an update to enumdata.py may be in order. Change-Id: I9ca1d6922a91d45bc436f4b622e5557261897d7f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
| * Rename util/locale_database/ to include the e that was missingEdward Welbourne2019-05-2016-3/+7
| | | | | | | | | | | | | | | | | | It was misnamed local_database, quite missing the point of its name. Change-Id: I73a4fdf24f53daac12304de1f443636d89afacb2 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>