Skip to content

boards/common/remote: fix mis-migrated path for flash/reset#10472

Merged
jcarrano merged 1 commit intoRIOT-OS:masterfrom
cladmi:pr/board/remote/common/fix_jlink_flasher
Nov 27, 2018
Merged

boards/common/remote: fix mis-migrated path for flash/reset#10472
jcarrano merged 1 commit intoRIOT-OS:masterfrom
cladmi:pr/board/remote/common/fix_jlink_flasher

Conversation

@cladmi
Copy link
Contributor

@cladmi cladmi commented Nov 26, 2018

Contribution description

The path to flash/reset/debug was not migrated correctly when moving to
remote-common (even before common/remote).

Testing procedure

Trying reset, flash-only, debug should use the file in boards/common/remote/dist when using PROGRAMMER=jlink for boards depending on common/remote.

Here it fails as JlinkExe is not found which shows the right script is used.

PORT=/dev/null PROGRAMMER=jlink BOARD=remote-reva make --no-print-directory -C examples/hello-world/ reset
/home/harter/work/git/RIOT/boards/common/remote/dist/reset.sh /home/harter/work/git/RIOT/examples/hello-world/bin/remote-reva
/home/harter/work/git/RIOT/boards/common/remote/dist/reset.sh: 16: /home/harter/work/git/RIOT/boards/common/remote/dist/reset.sh: JLinkExe: not found
PORT=/dev/null PROGRAMMER=jlink BOARD=remote-reva make --no-print-directory -C examples/hello-world/ flash-only
/home/harter/work/git/RIOT/boards/common/remote/dist/flash.sh /home/harter/work/git/RIOT/examples/hello-world/bin/remote-reva /home/harter/work/git/RIOT/examples/hello-world/bin/remote-reva/hello-world.bin
/home/harter/work/git/RIOT/boards/common/remote/dist/flash.sh: 22: /home/harter/work/git/RIOT/boards/common/remote/dist/flash.sh: JLinkExe: not found
PORT=/dev/null PROGRAMMER=jlink BOARD=remote-reva make --no-print-directory -C examples/hello-world/ debug
/home/harter/work/git/RIOT/boards/common/remote/dist/debug.sh /home/harter/work/git/RIOT/examples/hello-world/bin/remote-reva /home/harter/work/git/RIOT/examples/hello-world/bin/remote-reva/hello-world.elf
/home/harter/work/git/RIOT/examples/hello-world/../../Makefile.include:539: recipe for target 'debug' failed

In master the script is not found as using the wrong path:

PORT=/dev/null PROGRAMMER=jlink BOARD=remote-reva make --no-print-directory -C examples/hello-world/ reset
Reset program /home/harter/work/git/RIOT/boards/remote-reva/dist/reset.sh is required but not found in PATH.  Aborting.
/home/harter/work/git/RIOT/examples/hello-world/../../Makefile.include:551: recipe for target 'reset' failed
make: *** [reset] Error 1

PORT=/dev/null PROGRAMMER=jlink BOARD=remote-reva make --no-print-directory -C examples/hello-world/ flash-only 
Flash program /home/harter/work/git/RIOT/boards/remote-reva/dist/flash.sh is required but not found in PATH.  Aborting.
/home/harter/work/git/RIOT/examples/hello-world/../../Makefile.include:520: recipe for target 'flash' failed
make: *** [flash] Error 1

PORT=/dev/null PROGRAMMER=jlink BOARD=remote-reva make --no-print-directory -C examples/hello-world/ debug
Debug program /home/harter/work/git/RIOT/boards/remote-reva/dist/debug.sh is required but not found in PATH.  Aborting.
/home/harter/work/git/RIOT/examples/hello-world/../../Makefile.include:539: recipe for target 'debug' failed

Issues/PRs references

Found while testing #10471

The path to flash/reset/debug was not migrated correctly when moving to
`remote-common` (even before `common/remote`).
@cladmi cladmi added Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Area: boards Area: Board ports labels Nov 26, 2018
@cladmi cladmi requested a review from jcarrano November 26, 2018 16:12
@jcarrano jcarrano 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 Nov 26, 2018
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 don't have jlink, but this is about the scripts being found or not, and that fixes it (I tried the commands posted).

@jcarrano jcarrano merged commit 0294a38 into RIOT-OS:master Nov 27, 2018
@cladmi
Copy link
Contributor Author

cladmi commented Nov 27, 2018

Thanks for reviewing.

As the change breaking it is likely to be this one 8d07c01#diff-9f122f733b5127db6637053c7f2bbd4f it means it was not working for 2 years.

@jcarrano
Copy link
Contributor

it was not working for 2 years.

This raises some questions:

  1. Is this board/family of boards being maintained?
  2. Is somebody using this boards at all?
  3. If (1) and (2) are a "yes", then is somebody using jlink at all?
  4. If (1) or (2) are "no", why is it kept?

@cladmi cladmi deleted the pr/board/remote/common/fix_jlink_flasher branch November 27, 2018 16:20
@aabadie aabadie added this to the Release 2019.01 milestone Dec 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: boards Area: Board ports 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