Skip to content

Don't set the build_dir to anything on export #3924

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 1 commit into from
Mar 22, 2017

Conversation

theotherjimmy
Copy link
Contributor

@theotherjimmy theotherjimmy commented Mar 10, 2017

When constructing a toolchain for export, we currently set the
build_dir to the export_dir. When exporting offline, the
export_dir is always set to the root of the project. The toolchains
ignore their build_dir when scanning for sorces, so when the exporters
use the toolchains to scan for their resources, they get nothing.

In this patch we set the build_dir of the toolchain that the exports
use to nothing. A path of nothing should not match anything, and will
therefore not ignore everything when scanning for resources.

TODO

  • /morph export-build

@theotherjimmy
Copy link
Contributor Author

/morph export-build

@mbed-bot
Copy link

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph export-build

Output

mbed Build Number: 135

All exports and builds passed!

@sg-
Copy link
Contributor

sg- commented Mar 11, 2017

/morph export-build

@mbed-bot
Copy link

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph export-build

Output

mbed Build Number: 136

All exports and builds passed!

@0xc0170
Copy link
Contributor

0xc0170 commented Mar 13, 2017

I restarted jenkins CI as I could not locate the test results, please @theotherjimmy review once it finishes

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.

LGTM

Small typo in the commit message- bulid (build?). I had to look at the prepare_toolchian definition to see what is being set to "". It was not clear to me from the commit.

@0xc0170
Copy link
Contributor

0xc0170 commented Mar 14, 2017

Restarted CI jenkins to report back the status

@adbridge
Copy link
Contributor

@theotherjimmy "We are not using the toolchains to bulid, and they ignore everything in
the build_dir when scanning, so let's not ignore everything" Could you please re-write this to a meaningful comment that everybody can understand.

@theotherjimmy
Copy link
Contributor Author

Ah, I missed the the tool chains have the build dir set to the root of the project bit

When constructing a toolchain for export, we currently set the
`build_dir` to the `export_dir`. When exporting offline, the
`export_dir` is always set to the root of the project. The toolchains
ignore their `build_dir` when scanning for sorces, so when the exporters
use the toolchains to scan for their resources, they get nothing.

In this patch we set the `build_dir` of the toolchain that the exports
use to nothing. A path of nothing should not match anything, and will
therefore not ignore everything when scanning for resources.
@theotherjimmy
Copy link
Contributor Author

Commit message changed. Copying to PR description.

@theotherjimmy
Copy link
Contributor Author

/morph export-build

@theotherjimmy
Copy link
Contributor Author

'cause rebase

@theotherjimmy
Copy link
Contributor Author

@adbridge I changed the commit message to be more useful (and updated the PR description to match it). Could you comment again?

@adbridge
Copy link
Contributor

@theotherjimmy Thanks for the updated description, much improved.

@theotherjimmy
Copy link
Contributor Author

@adbridge Your welcome. I'm changing it to needs: CI then.

@adbridge
Copy link
Contributor

@marhil01 @SeppoTakalo Any idea why pr_head is failing here? I couldn't see an obvious failure?

@mbed-bot
Copy link

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph export-build

Output

mbed Build Number: 138

All exports and builds passed!

@bridadan
Copy link
Contributor

Looks like there's a build failure with K64F for the mbed-client-testapp?

18:27:49 [K64F ARM] "/tmp/4Bnhfm", line 128 (column 3): Warning: L6312W: Empty Execution region description for region RW_IRAM1
18:27:49 [K64F ARM] Error: L6200E: Symbol __asm___12_Ethernet_cpp___Z7__REV16j multiply defined (by Ethernet.o and CAN.o).
18:27:49 [K64F ARM] Error: L6200E: Symbol __asm___12_Ethernet_cpp___Z7__REVSHi multiply defined (by Ethernet.o and CAN.o).
18:27:49 [K64F ARM] Error: L6200E: Symbol __asm___12_Ethernet_cpp___Z5__RRXj multiply defined (by Ethernet.o and CAN.o).
18:27:49 [K64F ARM] Not enough information to list the image map.
18:27:49 [K64F ARM] Finished: 1 information, 1 warning and 3 error messages.
18:27:49 [K64F ARM] [ERROR] "/tmp/4Bnhfm", line 128 (column 3): Warning: L6312W: Empty Execution region description for region RW_IRAM1
18:27:49 [K64F ARM] Error: L6200E: Symbol __asm___12_Ethernet_cpp___Z7__REV16j multiply defined (by Ethernet.o and CAN.o).
18:27:49 [K64F ARM] Error: L6200E: Symbol __asm___12_Ethernet_cpp___Z7__REVSHi multiply defined (by Ethernet.o and CAN.o).
18:27:49 [K64F ARM] Error: L6200E: Symbol __asm___12_Ethernet_cpp___Z5__RRXj multiply defined (by Ethernet.o and CAN.o).

@0xc0170
Copy link
Contributor

0xc0170 commented Mar 15, 2017

@bridadan where is the failure? All tests are now green?

@bridadan
Copy link
Contributor

@0xc0170 I had restarted the CI once more after posting that, glad the issue is resolved!

@0xc0170
Copy link
Contributor

0xc0170 commented Mar 16, 2017

@theotherjimmy This is a bugfix for a bug that is on master and even on 5.4 branch (I faced this issue locally and took me a while to figure out that this is not my local setup but upstream bug). The importance of this bug is higher than it seems. It clicked all once I started browsing and saw all the reports (were referenced only 2 days ago, but this patch was sent 6 days ago thus we could already know more about this bug 6 days ago?). This could be easily integrated for the last release but was not as the description was lacking details, and even after improved, I still don't find it enough. For instance, when was this bug introduced? I had to go to the history, this one : theotherjimmy@fbb6f71. So this is fixing already another fix that introduced this bug. How can I reproduce this bug ? what does this bugfix fixes? As in the commit message : Before this patch: description here. After this patch: description here.

Please take more time to describe the issue, how this patch fixes it and reference issues or any relevant information. I assume this bugfix could be already in the last release!

How come this was not discovered with our build test that the project even fails to export or exported project is empty (only root is scanned, and in my case it was just config header file in the workspace view) ? @theotherjimmy Did you check build tests? I checked the PR that introduced this change, we did not run build CI test ! Here's it : #3852 (no mention of running build CI). Would it fail?

@bridadan
Copy link
Contributor

To help prevent this from happening in the future, I have a test job that will replace the nightly. It will test the exporters in parallel to running tests on the hardware, so you shouldn't have to run the explicit exporter job any more.

@adbridge
Copy link
Contributor

@bridadan Do you mean that when we run /morph test-nightly going forward it will automatically test exporters as well? Or do you mean you have added a new, separate command ? If it's the latter +1 if it's the former +5 !

@mbed-bot
Copy link

Result: FAILURE

Your command has finished executing! Here's what you wrote!

/morph test-nightly going forward it will automatically test exporters as well? Or do you mean you have added a new, separate command ? If it's the latter +1 if it's the former +5 !

Output

mbed Build Number: 1700

Example Build failed!

@bridadan
Copy link
Contributor

@adbridge It's not active now, but going forward the plan is to have the nightly command run the exporters as well. There a still a few issues to iron out. But this really needs to get in first!

@sg-
Copy link
Contributor

sg- commented Mar 20, 2017

/morph test-nightly

@mbed-bot
Copy link

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph test-nightly

Output

mbed Build Number: 1706

All builds and test passed!

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.

6 participants