summaryrefslogtreecommitdiffstats
path: root/util
Commit message (Collapse)AuthorAgeFilesLines
* Find mtdev and use itAlbert Astals Cid2019-02-121-0/+1
| | | | | Change-Id: I90db48efaa6a23add770fcf69b46c4f4c84866c1 Reviewed-by: Liang Qi <liang.qi@qt.io>
* configurejson2cmake.py: openssl -> OpenSSL mappingAlbert Astals Cid2019-02-121-0/+1
| | | | | Change-Id: I29480dfbd4f144e3d5620b43419ec46fb866cf4b Reviewed-by: Liang Qi <liang.qi@qt.io>
* CMake: Fix build of system jpeg is not availableKai Koehne2019-02-121-0/+3
| | | | | | Change-Id: Ie7462db556d0615e74755fa4fc3b51f625aade2f Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io>
* configurejson2cmake.py: Don't emit a fixme for C++11 configAlbert Astals Cid2019-02-121-0/+3
| | | | | Change-Id: I8408f6126115a0f76b0fed2cc42b54e5c148821d Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* configurejson2cmake.py: Support for the two cases that have LIBS +=Albert Astals Cid2019-02-121-2/+22
| | | | | | | | Since there's only two i hardcoded it for the moment instead of trying to parse the line Change-Id: I0da578af64ef9621cbbc78bf6ce15bf8a3f63f1c Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: also write FIXME on the configure.cmake for 'use'Albert Astals Cid2019-02-121-0/+2
| | | | | | | Since most of the times it means we need to link with some other stuff Change-Id: I06262d4403225bca7a5e68d47145fefcf6702e5a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: blacklist xlib test, we can just use X11_FOUNDAlbert Astals Cid2019-02-121-0/+2
| | | | | Change-Id: Ic733c42e11b00fa8bf107f460a0596aeb10ac37b Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: Find Cups and enable its pluginAlbert Astals Cid2019-02-121-0/+1
| | | | | Change-Id: I44bf176587331d86eb147d106f28deb0a6618ab4 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* cmake: Blacklist the libinput_axis_api testAlbert Astals Cid2019-02-121-0/+3
| | | | | | | We already have a cmake find module for libinput so we know it is there Change-Id: I153544c5c13cb57b1ce258243ede17f4be9507fd Reviewed-by: Liang Qi <liang.qi@qt.io>
* cmake: find gtk3 and build the gtk3 platformthemeAlbert Astals Cid2019-02-111-0/+1
| | | | | Change-Id: I7db7321a2fd5ea0eda1924f3dece3b1c86d87d10 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: pro2cmake.py: Simplify condition generationTobias Hunger2019-02-111-18/+2
| | | | | | | | There is no need to try and avoid extra () and NOTs: Those will be removed by sympy later anyway. Change-Id: I39d3e4d1d829579e532bfbbf6c69e0f1e06e9a22 Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
* cmake: Find tslib and build the tslib plugin if foundAlbert Astals Cid2019-02-111-0/+1
| | | | | Change-Id: I7119ddf473a3ede29bbfef23cffb08a4fcbd5681 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: pro2cmake.py: Treat ANDROID_EMBEDDED as ANDROIDTobias Hunger2019-02-111-0/+1
| | | | | | | Treat ANDROID_EMBEDDED as ANDROID when simplifying conditions. Change-Id: I2cf0ea1e1a3e882e3a7b7276867dcee452866ade Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
* CMake: pro2cmake.py: Do not go into infinite loopTobias Hunger2019-02-111-7/+14
| | | | | | | Do not go into an infinite loop when replacing a variable with itself. Change-Id: I2765b1c0c567753f26ca75e0533c1d193362b456 Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
* CMake: helper.py: Map harfbuzz libraryTobias Hunger2019-02-111-0/+1
| | | | | Change-Id: I71daa9acf391c70c6cba99609c1f67ca5eeaa220 Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
* CMake: pro2cmake.py: Handle equals(foo, bar) in conditionsTobias Hunger2019-02-111-0/+2
| | | | | | | | This adds an overly simplistic mapping -- just like it does for the rest of the qmake test functions. Change-Id: I0c9e3b70c1c3d0c68a245706a141aa7b7cb4d8bf Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* CMake: pro2cmake.py: Expand qmake values in file names, etc.Tobias Hunger2019-02-111-19/+45
| | | | | | | | | | | | | | | Expand qmake values when dealing with source file names, include directories and more. This handles cases where variables are used to refer to sources (e.g. $$VERSIONTAGGING_SOURCES in corelib) as well as things like $$QT_SOURCE_TREE and friends. Note that $$PWD and $$OUT_PWD are still need hand-holding since they refer to the scopes directory relative to the top level directory -- which pro2cmake.py does not know. Change-Id: I011ef55416ff820053d5f844b3008836849f5075 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Better mapping of complex conditionsTobias Hunger2019-02-111-5/+5
| | | | | | | | | | | | .pro-files support things like contains(Foo, bar), etc. Map that in such a way that only one identifier will be visible to CMake to unconfuse the logic handling on that side. These conditions will need manual fixup later! Change-Id: Id4946e694a9adccf9f54bcce26a6c227cd921007 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Remove some dead codeTobias Hunger2019-02-111-15/+0
| | | | | Change-Id: I8e3e7e4c4ef9747e0749734bdf875baccc4646bd Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* CMake: pro2cmake.py: Remove leading ./ in pathsTobias Hunger2019-02-111-1/+3
| | | | | | | | Remove leading './' from paths before writing them into CMakeLists.txt. Change-Id: I5680a3470cf491a8805b559197f94f8e6a6ce9b7 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake: Fix handling of chained scopes with else branchesTobias Hunger2019-02-111-1/+28
| | | | | | | | | | | | | | | | Fix handling of things like: foo:bar:buz: { do something } else: wat { do something else } The else relates to foo AND bar AND buz, not just to buz in this case. Change-Id: I40d1fa295b4d6dd95ae5e1ce2d58372edc807b86 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Map dlopen feature to 'ON'Tobias Hunger2019-02-112-1/+3
| | | | | | | | | | | | Map the dlopen feature to 'ON'. The effect is that cmake will figure out whether or not linking to 'dl' is necessary or not. The user-visible feature is 'library' anyway: That enables dynamic library loading -- and will link in 'dl' as needed. Change-Id: I0d68275a7234efba7f926150f120bb37b4a1163f Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Add XCB and X11 librariesTobias Hunger2019-02-111-2/+22
| | | | | | | | Add all the XCB and X11 libraries needed for the XCB plugin. Change-Id: I772b99c68521cd46cbba736912c8d8594d9d2ad8 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Small fix to type markupTobias Hunger2019-01-311-1/+1
| | | | | Change-Id: I2f7dc94f379d51c3816649849aa7365b17334ab5 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Add scope debugging supportTobias Hunger2019-01-311-0/+8
| | | | | | | | Dump scope trees for all scopes that contain a variable 'PRO2CMAKE_SCOPE_DEBUG' (set to any value). Change-Id: If17bb1697a32ccaa427a858c2330ab2b019d0fa8 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Assign a unique id to each scopeTobias Hunger2019-01-311-2/+7
| | | | | | | This makes scopes much simpler to destinguish from each other. Change-Id: I1af42f181b5899aba749bcf9267a345385149f90 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: report total condition when dumping a scopeTobias Hunger2019-01-311-0/+2
| | | | | | | Show the total_condition (if set) when dumping a scope. Change-Id: I9dfe98c2251f1d28881771042f17d723cedc8907 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Add a way to debug merges of scopesTobias Hunger2019-01-311-2/+20
| | | | | | | | Generate debug output whenever a qmake scope with a variable 'PRO2CMAKE_MERGE_DEBUG' is involved in a scope merge. Change-Id: I0ad94b881db9930de689c199adbac084efe6c03b Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Handle more librariesTobias Hunger2019-01-311-1/+9
| | | | | Change-Id: I561b619c4dbc56a1f6ad383a68ce4b82858a031c Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
* CMake: Add FindZSTD.cmake and wire it up in configurejson2cmake.pyTobias Hunger2019-01-311-0/+1
| | | | | | | Zstd is used in the dev branch, so prepare for it. Change-Id: I130d98e3888a1eb4c7444728fc5088c5dae9d911 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: Use FindGLIB2 from cmake-extra-modulesTobias Hunger2019-01-312-2/+3
| | | | | | | Use FindGLIB2 from cmake-extra-modules over hand-rolled own version. Change-Id: I1f8e055bc12dd728c033fd88480690643d90159a Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Pass QMAKE_MOC_OPTIONS on to CMakeTobias Hunger2019-01-311-0/+6
| | | | | Change-Id: I39c1b0aedbffaa29a34253e0c1c4bb4a4dddbe98 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* CMake: pro2cmake.py: Convert more settings from .pro-file to CMakeTobias Hunger2019-01-311-1/+13
| | | | | | | Convert QMAKE_USE, QMAKE_CXX_FLAGS and QMAKE_LFLAGS into CMake. Change-Id: I53a5b91664b6ab71892d4381c00f8d744d7d7abd Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* CMake: pro2cmake.py: Use propertiesTobias Hunger2019-01-312-71/+85
| | | | | | | Make use of @property to make code a bit nicer. Change-Id: Iff0bfed57874cf13b7e5f85acde2660a397933d7 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake: default QT_FEATURE_system_* to "ON"Tobias Hunger2019-01-311-1/+6
| | | | | | | | | Qt 6 will use external libraries for everything, so default all QT_FEATURE_system_foo to "ON". Change-Id: I884a4293c64487271be08de5fab82e6858d0a2ed Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Merge more scopesTobias Hunger2019-01-312-40/+328
| | | | | | | | | | | * Remove scopes with condition 'OFF' * Merge scopes with identical conditions This e.g. merges children with a condition that simplifies to 'ON' with their parent scope. Change-Id: Ieb3d60e1234f189ac45869853555ca8c0cfb5c76 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: configure2cmake.py: Handle Libproxy and corewlanTobias Hunger2019-01-301-1/+2
| | | | | | | Update to cover more libraries Change-Id: I32a26b0fa0a79531fcb55e7a4646a2e63fec1d5b Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Better printing of scopesTobias Hunger2019-01-291-9/+8
| | | | | Change-Id: Ibeb77a23c90d3a47c78d17c4683e4af3c64449fc Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Simplify conditionsTobias Hunger2019-01-293-8/+314
| | | | | | | | | Use pysym to simplify conditions in extend_target. Do some manual changes to the condition based on domain knowledge. Change-Id: I7fbb9ebc93b620a483c6a3a796d84c9bc0e36ef7 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: More mappings!Tobias Hunger2019-01-291-0/+7
| | | | | | | Add some more mappings from qmake to CMake equivalents conditions. Change-Id: I57b7bea9d6628e1c2b8d6ae88f799219942b571e Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Work on mapping of conditions to cmakeTobias Hunger2019-01-291-0/+8
| | | | | | | | | | | | Make sure complex things in qmake (e.g. function calls, etc.) are mapped better to cmake. When there is no way to properly map the qmake construct, then make sure to map everything into one identifier. This is to keep the structure of the condition simple. Change-Id: I6d88e0cb85fce1041bbfdc96604dab7bd4e65856 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Resolve file names for RESOURCESTobias Hunger2019-01-291-1/+1
| | | | | Change-Id: I821cdc88c7f45260997e118ab2abfd7ba6526b75 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Fix handling of complex else branchesTobias Hunger2019-01-291-2/+3
| | | | | | | | | | | Return the current scope's condition, not the total condition from recursive_evaluate_scope. That is the part the "else" referrs to. The parent_condition stays identical for all branches, so that should not get negated. Change-Id: I0da91483d4d748d01a29ac16890d709d8d659843 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: merge extend_targets with identical conditionsTobias Hunger2019-01-291-14/+62
| | | | | | | | This should somewhat simplify the generated CMakeLists.txt files, especially in complex cases like corelib or network. Change-Id: I208c8f99a64cbb6c97d51dd3ae428bb234982202 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Fix pyls warningsTobias Hunger2019-01-292-22/+48
| | | | | | | | Fix pyls warnings in pro2cmake.py as well as its tests. Change-Id: Ib8ee1daa9b97735d13c0fde43616daa46de9e171 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* CMake: pro2cmake.py: Better output in debug dumpsTobias Hunger2019-01-231-4/+18
| | | | | | | | | Report more error conditions in debug dump and make the output easier to read in the non-error case by wrapping all strings in "". Change-Id: I3c99deda3dfa27dcc0c9ce2800bfb891747e6934 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Give up on faithful representation of -=, +=, *= and =Tobias Hunger2019-01-231-43/+11
| | | | | | | | | | | | | | | Having a good representation is nice, but unfortunately very hard: pro2cmake.py sees just a small part of the entire qmake build system at a time, so the information it has is incomplete to start with. It is not worthwhile to pass the supposedly full information around -- which will then need to get de-duplicated again -- considering that the information is not complete in the first place. So go back to the simplistic approach we used earsier. That is good enough and does not suffer from the problem of having multi-part arguments getting messed up when the scopes get de-duplicated. Change-Id: I553329650d6b8046f7ad8b1282e3d0c961293a28 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Report keys that were not converted in each scopeTobias Hunger2019-01-231-10/+46
| | | | | | | This makes it easier to see what is still missing. Change-Id: I186abd609f20be680ac0943ac89068f764142a79 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Do not print trailing / in directory namesTobias Hunger2019-01-231-0/+1
| | | | | Change-Id: I3da83b8908791e033cf33221631d2fe988f83957 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* CMake: pro2cmake.py: Do not double-report include filesTobias Hunger2019-01-231-2/+2
| | | | | | | | | Do not add scopes that are going to get merged into their parent scope as a child of the parent scope. This leads to the information of the child scope being duplicated. Change-Id: If4d6a83b9c9eac477959e7774e9cf65fd4df98e6 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>