Skip to content

Tools changes for bare metal #9561

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

Merged
merged 33 commits into from
Feb 13, 2019
Merged

Conversation

theotherjimmy
Copy link
Contributor

@theotherjimmy theotherjimmy commented Jan 30, 2019

Description

This PR implements (and tests :D) the changes to the scanning rules
and configuration system for the requires key in mbed_app.json
and mbed_lib.json. Note: This is a 5.12 feature.

The requires key in mbed_lib.json lists the other libraries
that are required to build this library. When this library is
required by an application, the libraries it requires will be
included in the build.

The requires key in mbed_app.json lists the libraries (name
key from mbed_lib.json) required to build the application. This
causes mbed compile to filter the libraries included to those
listed in the application and those listed by the required
libraries.

Note: This pull request includes unit tests for this new feature.

Pull request type

[ ] Fix
[ ] Refactor
[ ] Target update
[x] Functionality change
[ ] Docs update
[ ] Test update
[ ] Breaking change

Reviewers

(following section required to auto-generate release notes)

Release notes

Mbed OS now supports the requires section in both
mbed_app.json and mbed_lib.json.

The requires key in mbed_lib.json lists the other libraries
that are required to build this library. When this library is
required by an application, the libraries it requires will be
included in the build.

The requires key in mbed_app.json lists the libraries (name
key from mbed_lib.json) required to build the application. This
causes mbed compile to filter the libraries included to those
listed in the application and those listed by the required
libraries.

No migration is required.

@theotherjimmy theotherjimmy changed the title Tools channges for bare metal Tools changes for bare metal Jan 30, 2019
@ciarmcom ciarmcom requested review from a team January 30, 2019 18:00
@ciarmcom
Copy link
Member

@theotherjimmy, thank you for your changes.
@ARMmbed/mbed-os-maintainers @ARMmbed/mbed-os-pan @ARMmbed/mbed-os-tools @ARMmbed/mbed-os-storage please review.

Copy link
Contributor

@bridadan bridadan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice so far!

@@ -269,7 +269,7 @@ def get_file_refs(self, file_type):
if not any(
path.startswith(dirname(e.path)) for e in self._excluded_libs
):
to_ret.append(ref)
to_ret.append(ref)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Woah

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I switched editors recently, until it decided to never insert spaces when I type <tab>. I have switch back because that's infuriating when working with python.

@0xc0170
Copy link
Contributor

0xc0170 commented Feb 11, 2019

Copy link
Contributor

@0xc0170 0xc0170 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Waiting for design doc, how this is supposed to be used? Release notes section might help there.

@@ -0,0 +1,136 @@
# mbed SDK
# Copyright (c) 2019 ARM Limited
#
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please also add SPDX identifier for new files

Copy link
Contributor

@donatieng donatieng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like to +1 the request for a design doc before we can review this efficiently!

@@ -6,6 +6,13 @@
"type": "string"
}
},
"requires_definition": {
"descirption": "Required libraries",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks.

@mikisch81
Copy link
Contributor

mikisch81 commented Feb 11, 2019

I'd like to +1 the request for a design doc before we can review this efficiently!

@donatieng
I sent offline link to confluence page about this, if possible to start look at the changes so @theotherjimmy can address any new issues (if any)?

@0xc0170 0xc0170 dismissed their stale review February 11, 2019 15:46

spdx added

@0xc0170
Copy link
Contributor

0xc0170 commented Feb 11, 2019

Should this PR include design doc? docs/design-documents is proper location

@donatieng
Copy link
Contributor

Is there a deprecation path for "features" (and components)? I feel like this requirement overlaps with this functionality. If so, it'd be worth adding an mbed_lib.json file for Bluetooth as well.

@theotherjimmy
Copy link
Contributor Author

@donatieng I'm not aware of a plan to deprecate features. I can understand the overlap you see. Adding an mbed_lib.json for Bluetooth could be something that is reasonable for the future. That can certainly be a follow on PR, as I would like to get this PR in soon.

Copy link
Contributor

@donatieng donatieng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the clarification @theotherjimmy ! Yes I think that the complexity of all these somewhat overlapping features ("features", "components" and now this) needs to be addressed otherwise this will hurt our UX.

@theotherjimmy
Copy link
Contributor Author

@donatieng I agree that no guidance on "features", "components", extra_labels, and requires in mbed_app.json and mbed_lib.json will only lead to more confusion long term. I think we could probably deprecate "features" and "components" in favor of requires.

@SeppoTakalo
Copy link
Contributor

I'm also in favour of deprecating features and components in favour of requires as those have working dependency system.

Components and features have pushed the integration pain towards the application developer, who need to be aware of what library requires what feature.

@orenc17
Copy link
Contributor

orenc17 commented Feb 12, 2019

@donatieng @theotherjimmy @SeppoTakalo i agree with you, but we need this for THIS release
in the one after that we could do whatever we want

Copy link
Contributor

@bridadan bridadan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed @orenc17, we need to

stay on target

😄

@orenc17
Copy link
Contributor

orenc17 commented Feb 13, 2019

can someone run CI on this please?

@NirSonnenschein
Copy link
Contributor

CI started

@mbed-ci
Copy link

mbed-ci commented Feb 13, 2019

Test run: FAILED

Summary: 1 of 11 test jobs failed
Build number : 2
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_greentea-test

@orenc17
Copy link
Contributor

orenc17 commented Feb 13, 2019

@ARMmbed/mbed-os-maintainers why was this build aborted?

@mbed-ci
Copy link

mbed-ci commented Feb 13, 2019

Test run: FAILED

Summary: 4 of 9 test jobs failed
Build number : 5
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_dynamic-memory-usage
  • jenkins-ci/mbed-os-ci_cloud-client-test
  • jenkins-ci/mbed-os-ci_exporter
  • jenkins-ci/mbed-os-ci_greentea-test

@alekla01
Copy link
Contributor

Restarted CI, was aborted & restarted due to CI related error.

@mbed-ci
Copy link

mbed-ci commented Feb 13, 2019

Test run: SUCCESS

Summary: 12 of 12 test jobs passed
Build number : 7
Build artifacts

@cmonr cmonr merged commit b820ec8 into ARMmbed:master Feb 13, 2019
@orenc17
Copy link
Contributor

orenc17 commented Feb 13, 2019

Hallelujah!!!!!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.