-
Notifications
You must be signed in to change notification settings - Fork 3k
CMake: add CI testing #13477
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CMake: add CI testing #13477
Conversation
@jamesbeyond, thank you for your changes. |
Jenkins CI Test : ✔️ SUCCESSBuild Number: 1 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
I've checked the logs, there are only unit tests. |
Hi @0xc0170 , this is just for demo purpose, in the PR, I want to show that we can customize our CI pipeline, to a different flow/testing set on a particular branch, which is totally different from the master branch one. |
Jenkins CI Test : ✔️ SUCCESSBuild Number: 2 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
129e697
to
ed797cf
Compare
This PR cannot be merged due to conflicts. Please rebase to resolve them. |
05cd574
to
fa7523f
Compare
1cd248e
to
0df7953
Compare
This PR cannot be merged due to conflicts. Please rebase to resolve them. |
85f836d
to
3329b51
Compare
d91c3d7
to
5e4ec53
Compare
This PR cannot be merged due to conflicts. Please rebase to resolve them. |
8e34f86
to
c7322d8
Compare
1d130e5
to
d2a8b8b
Compare
Jenkins CI Test : ✔️ SUCCESSBuild Number: 3 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Jenkins CI Test : ✔️ SUCCESSBuild Number: 4 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Jenkins CI Test : ✔️ SUCCESSBuild Number: 5 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Jenkins CI Test : ❌ FAILEDBuild Number: 6 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Jenkins CI Test : ❌ FAILEDBuild Number: 7 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
41dbb5b
to
4c292c2
Compare
@0xc0170 I haven't looked into your Travis CI configuration, but I was having the same issue with our custom CI using CMake and rebuilding everything from scratch (we're using Github Actions). We've added ccache to our build system and main CMakeLists.txt and now build that used to take ~10min on an old MacBook Pro 2015 take between 30seconds and 2minutes depending on how much there is to rebuild. Even changing target and running from scratch still benefits from ccache. EDIT: my bad, it's already active, should I've looked before :) Line 31 in 8d9dabe
|
@0xc0170 that being said, I can't find where it's called with cmake... am I missing something? we have the following at the top our main CMakeLists.txt: find_program(CCACHE_PROGRAM ccache)
if(CCACHE_PROGRAM)
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE "${CCACHE_PROGRAM}")
endif() All the commands run through ccache. |
@ladislas That is another thing to look at (we do not yet use ccache with CMake). Please send a PR adding it |
Jenkins CI Test : ❌ FAILEDBuild Number: 27 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Configuration error (python cant find a path for BLe example) ? Edit: found it, read below |
"BLE_GattClient", | ||
"BLE_GattServer", | ||
"BLE_HeartRate", | ||
"BLE_LED", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We currently support only BLE_LED, please remove the rest
Jenkins CI Test : ❌ FAILEDBuild Number: 28 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Another thing to consider - ARMCLang will fail for our examples if we use older CMake version than 3.19.0 (currently only rc2 is out). This was found during #13827. To unblock 13827, we need this PR first. Please install the latest CMake (3.19.0rc2, so ARMClang will compile). Also another fix landed to feature-cmake (previouso ARM failures), feature-cmake should work once the latest cmake is used. Let's update and restart CI. |
Jenkins CI Test : ✔️ SUCCESSBuild Number: 29 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Looks like its ready, shout now or will merge to the feature branch soon. |
Jenkins CI Test : ❌ FAILEDBuild Number: 30 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
GitHub hiccups , cause CI failed to clone repo. restart CI |
if profiles: | ||
for profile in profiles: | ||
build_command_seq[0] += " --profile {}".format(profile) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can also test all build profiles with mbed-tools
.
You can use the --build-type
optional argument of the build
sub-command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cheers, good to know that.
But I as mentioned in Jaeden's comment, we are not going to introduce build multiple profile at this PR, as this will evolve more CI side code changes. We'll do that as an improvement in near future. In this PR we are only build the default profile which is development
for now
Jenkins CI Test : ✔️ SUCCESSBuild Number: 31 | 🔒 Jenkins CI Job | 🌐 Logs & ArtifactsCLICK for Detailed Summary
|
Summary of changes
examples_cmake.json
for describing which example can build with cmake on which targetsexample.py
let it support both cmake build and legency tools buildImpact of changes
Migration actions required
Documentation
Pull request type
Test results
Reviewers