Skip to content
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

makefiles/buildtests.inc.mk: fix 'clean-intermediates' not cleaning #10235

Merged
merged 1 commit into from
Oct 24, 2018

Conversation

cladmi
Copy link
Contributor

@cladmi cladmi commented Oct 24, 2018

Contribution description

clean-intermediates should be done per board. Without this it only
tries to clean the default board.

This is a split of #9831 as the original problem mentioned there was different than I thought and unrelated to this fix only.

Testing procedure

Run buildtest in any example without bin at the beginning. Check the bin directory after, only the not intermediates files should be kept:
(it should not be run with variables set from the command line either it triggers another bug!)

rm -rf examples/hello-world/bin && \
  BOARDS="iotlab-m3 samr21-xpro" make --no-print-directory -C examples/hello-world/ buildtest && \
  ls examples/hello-world/bin/*

With this PR, we only have the iotlab-m3 and samr21-xpro outputs

Building for iotlab-m3 ... success.
Building for samr21-xpro ... success.
examples/hello-world/bin/iotlab-m3:
hello-world.elf  hello-world.hex  hello-world.map

examples/hello-world/bin/samr21-xpro:
hello-world.bin  hello-world.elf  hello-world.map

With master we have

Building for iotlab-m3 ... success.
Building for samr21-xpro ... success.
examples/hello-world/bin/iotlab-m3:
application_hello-world    auto_init.a  boards_common_iotlab    core.a            cortexm_common_periph    cpu.a      hello-world.elf  isrpipe                  newlib_syscalls_default.a  periph_common    pm_layered.a  stdio_uart.a    stm32_common_periph    sys.a
application_hello-world.a  board        boards_common_iotlab.a  cortexm_common    cortexm_common_periph.a  drivers    hello-world.hex  isrpipe.a                periph                     periph_common.a  riotbuild     stm32_common    stm32_common_periph.a  tsrb
auto_init                  board.a      core                    cortexm_common.a  cpu                      drivers.a  hello-world.map  newlib_syscalls_default  periph.a                   pm_layered       stdio_uart    stm32_common.a  sys                    tsrb.a

examples/hello-world/bin/native:

examples/hello-world/bin/samr21-xpro:
application_hello-world    auto_init.a  core            cortexm_common.a         cpu      drivers.a        hello-world.map  newlib_syscalls_default    periph.a         pm_layered    sam0_common         sam0_common_periph.a  sys    tsrb.a
application_hello-world.a  board        core.a          cortexm_common_periph    cpu.a    hello-world.bin  isrpipe          newlib_syscalls_default.a  periph_common    pm_layered.a  sam0_common.a       stdio_uart            sys.a
auto_init                  board.a      cortexm_common  cortexm_common_periph.a  drivers  hello-world.elf  isrpipe.a        periph                     periph_common.a  riotbuild     sam0_common_periph  stdio_uart.a          tsrb

Issues/PRs references

Split out of #9831 and found while working on #9742

`clean-intermediates` should be done per board. Without this it only
tries to clean the default board.
@cladmi cladmi added Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) Area: tests Area: tests and testing framework Area: build system Area: Build system CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Oct 24, 2018
@cladmi cladmi added this to the Release 2018.10 milestone Oct 24, 2018
@cladmi
Copy link
Contributor Author

cladmi commented Oct 24, 2018

Sorry to ask you to review again here, I extracted the most urgent part out of #9831

Copy link
Contributor

@jcarrano jcarrano left a comment

Choose a reason for hiding this comment

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

I could reproduce the issue and the fix fixes it.

@jia200x
Copy link
Member

jia200x commented Oct 24, 2018

Great, thank you!

@jia200x jia200x merged commit 90d15d1 into RIOT-OS:master Oct 24, 2018
@cladmi cladmi deleted the pr/make/buildtest/correctly_clean branch October 24, 2018 12:03
@cladmi
Copy link
Contributor Author

cladmi commented Oct 24, 2018

Thank you for reviewingy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: build system Area: Build system Area: tests Area: tests and testing framework CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants