summaryrefslogtreecommitdiffstats
path: root/coin
Commit message (Collapse)AuthorAgeFilesLines
* Fix cross compilation builds with template v2Alexandru Croitor2020-02-072-0/+2
| | | | | | | | | | | Make sure to split the command arguments after variable substitution like it is done in call_cmake.yaml. Amends d445112cc03d730d659d1eeaa84d963f85731ac5 Change-Id: Id23fcfa5b58c33e05495413fb10349fbcff1bfac Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* cmake: upload artifact for qtbase android build and etcLiang Qi2020-02-078-30/+210
| | | | | | Task-number: QTBUG-78945 Change-Id: I3361e63ed4830ac0e1ebb9d4b9495df09c45f476 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Add initial support for CMake "Ninja Multi-Config" generatorAlexandru Croitor2020-01-271-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows doing debug_and_release builds with Ninja on all platforms. The "Ninja Multi-Config generator" is available starting with CMake 3.17. Desired configurations can be set via CMAKE_CONFIGURATION_TYPES. Possible values: "Release, Debug, RelWithDebInfo, MinRelSize". For example -DCMAKE_CONFIGURATION_TYPES="Release;Debug". The first configuration is the 'default' configuration which is built when calling ninja with no arguments. To build all targets of a certain configuration use "ninja all:Release" or "ninja all:Debug". To build all targets in all configurations use "ninja all:all". Note that the first configuration influences which configuration of tools will be used when building the libraries for all configurations. In simple terms, when configured with -DCMAKE_CONFIGURATION_TYPES="Release;Debug" the release version of moc is used by AUTOMOC. When configured with -DCMAKE_CONFIGURATION_TYPES="Debug;Release" the debug version of moc is used by AUTOMOC. Framework builds and Ninja Multi-Config don't currently work together due to multiple bugs in CMake, which ends up generating an invalid ninja file with duplicate rules. There are also issues with placement of the debug artifacts. This will be handled in a follow up patch after CMake is fixed. Task-number: QTBUG-76899 Change-Id: If224adc0b71b7d1d6606738101536146aa866cd7 Reviewed-by: Qt CMake Build Bot Reviewed-by: Leander Beernaert <leander.beernaert@qt.io> Reviewed-by: Cristian Adam <cristian.adam@qt.io>
* Make standalone tests build via top level repo projectAlexandru Croitor2019-11-082-16/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously repo/tests/CMakeLists.txt was a standalone project on which CMake could be called. This was useful for Coin to be able to build and package only tests, but was a bit troublesome because that means having to specify the usual boilerplate like minimum CMake version, which packages to find in every tests.pro project. Instead of having a separate standalone project, modify the top level project and associated CMake code to allow passing a special QT_BUILD_STANDALONE_TESTS variable, which causes the top level project to build only tests, and find Qt in the previously installed qt location. This also means that when building a repo, we generate a ${repo_name}TestsConfig.cmake file which does find_package on all the modules that have been built as part of that repo. So that when standalone tests bare built for that repo, the modules are automatically found. qt_set_up_standalone_tests_build() is modified to be a no-op because it is not needed anymore. Its usage should be removed from all the other repos, and then removed from qtbase. Non-adjusted tests/CMakeLists.txt projects in other repositories should still be buildable with the current code, until they are updated to the new format. Adjust the Coin build instructions to build the standalone tests in a separate directory. Adjust pro2cmake to generate new structure for the tests/tests.pro projects. Adjust the qtbase tests project. Fixes: QTBUG-79239 Change-Id: Ib4b66bc772d8876cdcbae1e90ce5a5a5234fa675 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Fix invalid condition for test executionToni Saario2019-10-251-1/+1
| | | | | | | | | | Equals_value check that if the property is same as given value. Equals_property compares properties in this case the OS of target and host. Change-Id: Ica42f0f99562911a97d2f6bd02bd8a6420c980ac Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* cmake: add Android buildLiang Qi2019-10-112-9/+94
| | | | | | | Task-number: QTBUG-78945 Change-Id: I0c9d3cc7de6d3bfb346a77d95a6bbcad6d707a74 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Qt CMake Build Bot
* instructions: executeCommandArgumentSplitingBehavior when calling qt-cmakeLiang Qi2019-09-261-0/+1
| | | | | | | Change-Id: Ibe589ee181a08df9ec999c9b769fa560b2716aac Reviewed-by: Toni Saario <toni.saario@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Qt CMake Build Bot
* instructions: start to use --parallel when cmake buildLiang Qi2019-09-253-3/+3
| | | | | | Change-Id: Ia67f0f9413c2f99dbc3b7e978256c0301502ea1d Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* coin: increase the timeout between output for allLiang Qi2019-09-034-10/+10
| | | | | | Change-Id: I3906a08f5e0cce9abeeafbb67a83d31fbf67c703 Reviewed-by: Toni Saario <toni.saario@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Share most common part of module_config.yamlLiang Qi2019-08-306-120/+176
| | | | | Change-Id: Ieea5b662e039cff24e26a127b4a3a8610ed588cc Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
* Split module_config.yamlJędrzej Nowacki2019-07-042-193/+203
| | | | | | | | | | | | | There are things that could be shared around all Qt submodules. In particular compiler specific configuration should not be repeated over and over. The new file can be included directly from all modules that uses QtBase. In longer term one would have a separate repository for such instructions as most of them are not QtBase specific. Change-Id: I0590b2a0c78b73e1b9dbb27cc1da6568cbe56563 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Remove debug printJędrzej Nowacki2019-07-021-8/+0
| | | | | | | | We do not need to print the whole cmake configuration anymore. Change-Id: I429e06f65258d0be0cf8b7c90e81c0593718e48c Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Qt CMake Build Bot
* Fix check for static buildsJędrzej Nowacki2019-07-021-1/+1
| | | | | | | | We should check if configureArgs has "-DBUILD_SHARED_LIBS=OFF", that means "contains_value" not "in_values". Change-Id: I6c0c3ac695fa439c68f3027e70adc389f6fb27c1 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Add proper test archive nameJędrzej Nowacki2019-07-021-1/+1
| | | | | | | | MODULE_ARTIFACTS_RELATIVE_STORAGE_PATH was pointing to a build artifact, instead of a path to a successful item. Change-Id: I01490e63e70beae2f613cda5451a9e2ddb5451fa Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Skip building tests for static buildsJędrzej Nowacki2019-07-021-12/+12
| | | | | | | | | | | | We do not run the test in such configuration. In theory the build should success (it doesn't for now) but it creates a lot of data. So the coverage gain vs cost ratio is not great. This workaround aims to unblock cmake builds. Change-Id: Icd730d88bf800ee2e7764704a92238ec147d47f9 Reviewed-by: Qt CMake Build Bot Reviewed-by: Liang Qi <liang.qi@qt.io>
* Handle CMAKE_C_COMPILER and CMAKE_CXX_COMPILER automaticallyJędrzej Nowacki2019-07-021-3/+33
| | | | | | | | | We do not need or should to define these variables in the product configuration file. It should be enough to just have the compiler name. Change-Id: I797958a2c35641f1b79e4e74f3feb49312f8b9c4 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Disable tests when building staticallySimon Hausmann2019-07-021-21/+40
| | | | | | | The resulting test artifacts are way to huge to upload. Change-Id: I6df1f1c4bdb0fe2cfb7f7baed8999a1ee24b879e Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Fix symmetry between test artifact handlingSimon Hausmann2019-07-011-0/+7
| | | | | | | | | | The module yaml file provides the instruction for creating and upload the test artifacts, it might as well provide the instruction for downloading it. Coin sets the corresponding environment variable for the storage path now. Change-Id: I4aabe60e28c0c1a6d5934b3b7b797835a793a7fe Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Run tests using ctestSimon Hausmann2019-07-011-0/+11
| | | | | | | | | As an initial way this allows running tests. Coin does not yet collect the results and the logic for re-running is inside ctest. Change-Id: Ieab619d5f8f4ebdd8cd1293489db36d0bbd7c74a Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io> Reviewed-by: Liang Qi <liang.qi@qt.io>
* Simplify test compilationSimon Hausmann2019-06-261-7/+25
| | | | | | | | | | We don't need the full cmake invocation as when configuring, instead we can use the qt-cmake wrapper script that uses the generated toolchain file. Change-Id: Ie0d554fbf8543d950112108d6a3f8a7c3a58a6a6 Reviewed-by: Qt CMake Build Bot Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Fix early warning systemSimon Hausmann2019-06-251-7/+0
| | | | | | | | Remove dummy test instructions that don't work right now and cause failures. Change-Id: I30195fe605419a8eb462e8315f71718dd86df412 Reviewed-by: Liang Qi <liang.qi@qt.io>
* SplitAfterVariableSubstitution is also needed for building testsLiang Qi2019-06-241-0/+1
| | | | | | | Just follow da7f40f7c2eb1a5928876de7b89abb55a2f8fdab. Change-Id: Iac0e96a42fa97bc002e3f11b6a6317ddc6e4187b Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Move ICC compiler name setup to instructions levelJędrzej Nowacki2019-06-241-0/+3
| | | | | | | | That way we can simplify product level configuration. Change-Id: I6825a10e4652dc7a730d23aaa7d4e7db9c079e50 Reviewed-by: Qt CMake Build Bot Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Update the instructions after CI changed way of splitting argumentsJędrzej Nowacki2019-06-241-0/+1
| | | | | | | | | | Now execute command can directly specified how the arguments should be divided. The default option doesn't work well for CONFIGURE_ARGS, because we want to pass it's result as a separate subprocess arguments. Change-Id: I6b7adb04164f5568d9ad2f45e3334d7a7a49bc79 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Change cmake generator selection mechanismSimon Hausmann2019-06-211-2/+5
| | | | | | | | | | By using the new environment variable for the generator selection introduced in 3.15, we can later select the visual studio generator once the qtbase build is fixed. This will simplify the VS selection code in this file and allow getting rid of the ENV_PREFIX and .bat file. Change-Id: I9f76b5714450ffa60b496aef0ce5a0c21e843bef Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Prepare for running tests with cmakeSimon Hausmann2019-06-211-5/+30
| | | | | | | | | | | | | | | | | This is just a small step towards the situation where we build the tests during the module build phase and later extract and merely run them. The general steps we need are: * build tests separately, which includes the cmake test plan * let coin archive the tests (build) directory * in the test VM unpack everything * run ctest on the test plan that was part of the tests archive This patch implements the first two steps. Change-Id: Ifb8321015d0d18ad20e8cf20bb8b746030202daf Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Port ICC specific instructionsJędrzej Nowacki2019-06-171-0/+15
| | | | | | | | | | | Coin implicitly was exporting some variables if ICC was used. This patch is just a first step to enable ICC in CI. To make it really working one would need to fix the QtBase code and enable ICC in qt5 repository. Change-Id: I2fca19ff10d7390fa013f511f167c0c1c2fba427 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Simple typo fixupJędrzej Nowacki2019-06-171-1/+1
| | | | | | Change-Id: Ifd2c6c3eef5aea4decdbe1fc6221139bf3447ba6 Reviewed-by: Qt CMake Build Bot Reviewed-by: Liang Qi <liang.qi@qt.io>
* Avoid hardcoding the underlying build toolSimon Hausmann2019-06-171-1/+7
| | | | | | | | | | | Since 3.15, not only --build can call the low-level build tool, --install can also be used to run the installation. There's also an environment variable that can be used to control the backend at cmake time, but that may only be useful later. Change-Id: I8c1ee48f946e110af3e824cf8980bbacbb94db99 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io> Reviewed-by: Qt CMake Build Bot
* Try to use %ProgramFiles(x86)% instead of custom codeJędrzej Nowacki2019-06-131-21/+6
| | | | | | | | | | | On Windows, we have a problem with locating MSVC. Depending on system version it can be installed in different directories. Currently we have a custom logic to handle it, but in theory we could just use "ProgramFiles(x86)" to abstract it. Change-Id: Ia94a41d9ef6229de712606f9a9d3d61a0abeb24f Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Remove double negationsJędrzej Nowacki2019-06-131-33/+33
| | | | | | | | | As now the configuration syntax supports enable_if, we can get rid of double negations. Change-Id: I5b8b695d4f7a72cd1a836b9b427096fb4e3b85a7 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Implement command prefixJędrzej Nowacki2019-06-121-2/+168
| | | | | | | | | | | | | | | | | | | | | The current CI magically add prefix to every executed command if target compiler is MSVC. The prefix just calls vcvarsall.bat. The script has to be called for every command, because of the CI agent runs every command as a subprocess. It means that script sourced environment is not passed to subsequent commands, therefore all changes are lost. The prefix, as a concept, has known performance issues (COIN-253), so in long term it would be nice to move to another solution. CustomModule doesn't support prefix. Therefore the proposed approach moves the ugliness from CI code to the yaml configuration file. It has two advantages; nothing needs to be implemented on the CI level and hopefully someone in future will clean it up as the problem is more visible and publicly fixable. Change-Id: Ice3cff89e3a59b2a57e675b7892fde0d04433ba8 Reviewed-by: Liang Qi <liang.qi@qt.io>
* Use ninja as default builderJędrzej Nowacki2019-06-121-17/+6
| | | | | | | | | | | | That allows us to skip all the madness of choosing between make/nmake/jom. In addition it is actually faster to build with ninja, then other tools. Change-Id: I31049a292495800606cede6f15011d97af7c3e41 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Qt CMake Build Bot
* Move some configure arguments from qt5 configuration fileJędrzej Nowacki2019-05-221-1/+1
| | | | | | | | | These arguments are specific to the build and changes to them are _not_ affecting configuration. Change-Id: I8c46a0dbea8978f13e78c5cb8f41987f4fde09c8 Reviewed-by: Qt CMake Build Bot Reviewed-by: Liang Qi <liang.qi@qt.io>
* Adjust timeouts in module_config.yamlJędrzej Nowacki2019-05-221-2/+4
| | | | | | | | | Signing package may take more then 10s while calling echo really should take less then 60s ;-) Change-Id: I1798981492d1467bb8b20099ea705b08ea9b0914 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Cleanup module_config.yamlJędrzej Nowacki2019-05-221-2/+2
| | | | | | | The number of CPUs is set implicitly by MAKEFLAGS and NIJAFLAGS. Change-Id: Ie9296f9a7872253c696536d7b3d6235c7881d42b Reviewed-by: Liang Qi <liang.qi@qt.io>
* Fix typo in module_config.yamlJędrzej Nowacki2019-05-201-1/+1
| | | | | | | The command executed is jom not nmake. Change-Id: Ieae487a3b50884d901ca2a431f3c3ea615a80e8b Reviewed-by: Liang Qi <liang.qi@qt.io>
* Move build and test instructions from coin to qtbaseLiang Qi2019-05-101-0/+56
That way we can update instructions without waiting for Coin update. The patch contains invalid test instructions, but as cmake port is not yet able to run tests it should not matter. Change-Id: I86088aefec49ded60af00243b0b8c60c8f16147a Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>