Skip to content

Conversation

@cladmi
Copy link
Contributor

@cladmi cladmi commented Jul 6, 2018

Contribution description

This makes most of the boards get the file used for flashing from command line arguments instead of environment variables. This prevents using arbitrary "HEXFILE" or "BINFILE".

This is a split of #8838 that already have been tested.

I split it to allow only fixing newly added boards before adding the FLASHFILE variable.

Issues/PRs references

Split of #8838

@cladmi cladmi added 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 CI: run tests If set, CI server will run tests on hardware for the labeled PR labels Jul 6, 2018
@cladmi
Copy link
Contributor Author

cladmi commented Jul 11, 2018

Updated the reference in the PR that was wrong.

Copy link
Member

@smlng smlng left a comment

Choose a reason for hiding this comment

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

I'm a bit confused when to use (and why) HEXFILE or BINFILE it looks a bit random to me, can you explain, eg. for the different flash script eg. cc2538 vs. calliope.

OS=`uname`
DID_MOUNT=false

BINFILE=$1
Copy link
Member

Choose a reason for hiding this comment

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

for the calliope you specified HEXFILE=$1

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 based myself on what file is actually used by the board:

make --no-print-directory -C examples/hello-world/ info-debug-variable-HEXFILE  BOARD=calliope-mini
.../examples/hello-world/bin/calliope-mini/hello-world.hex
make --no-print-directory -C examples/hello-world/ info-debug-variable-HEXFILE  BOARD=mbed_lpc1768
.../examples/hello-world/bin/mbed_lpc1768/hello-world.bin

The mbed board uses BINFILE as file to generate called HEXFILE currently

HEXFILE = $(BINFILE)

Copy link
Member

Choose a reason for hiding this comment

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

ah so you want to match the variable name in the script with the actual file ending, right? So BINFILE where it is <appname>.bin and HEXFILE for <appname>.hex. Makes sense, was just confusing to use different variable names inside all those flash scripts.

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 tried to be coherent with the filename/extension yes.

@cladmi
Copy link
Contributor Author

cladmi commented Oct 11, 2018

I can definitely split this PR if it helps you review (and maybe merge :)) separately.
If it is the case, please tell me how you want the split.

@cladmi cladmi force-pushed the pr/make/flashfile_from_cli branch from edbfa8f to fa912fd Compare October 11, 2018 15:47
@cladmi
Copy link
Contributor Author

cladmi commented Oct 11, 2018

Rebased to remove merge conflict with jlink.sh.

@smlng
Copy link
Member

smlng commented Oct 11, 2018

No need to split this further, just needed some clarification

@cladmi cladmi added this to the Release 2019.01 milestone Oct 21, 2018
@kYc0o
Copy link
Contributor

kYc0o commented Oct 30, 2018

Is this ready then?

@cladmi cladmi added CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR and removed CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Oct 30, 2018
@cladmi
Copy link
Contributor Author

cladmi commented Oct 30, 2018

I think it is ready but it is still only a subset of all the boards.

I could still split to allow testing only few boards at a time and get the fix merged.

@cladmi cladmi force-pushed the pr/make/flashfile_from_cli branch from fa912fd to 7bab27b Compare November 26, 2018 15:15
@cladmi cladmi added the State: waiting for other PR State: The PR requires another PR to be merged first label Nov 27, 2018
@cladmi
Copy link
Contributor Author

cladmi commented Nov 27, 2018

This PR is getting split with references in the original PR: #8838

Get HEXFILE and ELFFILE from command line instead of environment variable.
Get FLASH_FILE and ELFFILE from command line instead of environment variable.
@cladmi cladmi force-pushed the pr/make/flashfile_from_cli branch from 7bab27b to dbca7e1 Compare November 27, 2018 17:07
@aabadie
Copy link
Contributor

aabadie commented Dec 3, 2018

@cladmi, please rebase this PR.

@cladmi
Copy link
Contributor Author

cladmi commented Dec 3, 2018

I am splitting openocd out of this one to have a proper testing procedure. (writing in process)

@cladmi
Copy link
Contributor Author

cladmi commented Dec 3, 2018

Split in #10539

@cladmi
Copy link
Contributor Author

cladmi commented Dec 3, 2018

All the split boards were either merged or split outside now, so I close this one.

@cladmi cladmi closed this Dec 3, 2018
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 CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR CI: run tests If set, CI server will run tests on hardware for the labeled PR State: waiting for other PR State: The PR requires another PR to be merged first

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants