Skip to content

makefiles/utils/test: remove explicit dependency on bash#21917

Merged
AnnsAnns merged 2 commits intoRIOT-OS:masterfrom
mguetschow:make-remove-bash-dep
Nov 26, 2025
Merged

makefiles/utils/test: remove explicit dependency on bash#21917
AnnsAnns merged 2 commits intoRIOT-OS:masterfrom
mguetschow:make-remove-bash-dep

Conversation

@mguetschow
Copy link
Contributor

Contribution description

Make tests succeed even on systems without bash as default shell installed.

Testing procedure

$ make -C tests/build_system/utils all test
$ BUILD_IN_DOCKER=1 make -C tests/build_system/utils all test
$ BUILD_IN_DOCKER=1 DOCKER_IMAGE=local/tinybuild-native64:latest make -C tests/build_system/utils all test

should all succeed on your favorite machine, and not print make[1]: python: No such file or directory anymore.

Issues/PRs references

Found while testing the Alpine tinybuild containers in RIOT-OS/riotdocker#259 (comment)

@github-actions github-actions bot added the Area: build system Area: Build system label Nov 26, 2025
@crasbe crasbe added Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Nov 26, 2025
# OSx 'date' does not support 'date +%s%N' so rely on python instead
# It could be OSx specific but we do not have 'OS' defined here to differentiate
date_nanoseconds = $(shell python -c 'import time; print(int(time.time() * 1000000000))')
date_nanoseconds = $(shell python3 -c 'import time; print(int(time.time() * 1000000000))')
Copy link
Member

Choose a reason for hiding this comment

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

Is python3 more universal? I'd always expect python to be there but not python3?`

Copy link
Contributor

Choose a reason for hiding this comment

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

Au contraire:

Ubuntu 22.04.5:

cbuec@W11nMate:~$ python
Command 'python' not found, did you mean:
  command 'python3' from deb python3
  command 'python' from deb python-is-python3

Ubuntu 24.04.1:

buechse@skyleaf:~$ python
Command 'python' not found, did you mean:
  command 'python3' from deb python3
  command 'python' from deb python-is-python3

Copy link
Member

Choose a reason for hiding this comment

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

Never took french in school so I can only respond with

"Oepsie doepsie, hoe meer je weet"

@AnnsAnns AnnsAnns enabled auto-merge November 26, 2025 14:21
@riot-ci
Copy link

riot-ci commented Nov 26, 2025

Murdock results

✔️ PASSED

2fd86cb makefiles/utils/test: rename python to more common python3

Success Failures Total Runtime
10931 0 10932 14m:23s

Artifacts

@AnnsAnns AnnsAnns added this pull request to the merge queue Nov 26, 2025
Merged via the queue into RIOT-OS:master with commit ccb5b8c Nov 26, 2025
31 checks passed
@mguetschow mguetschow deleted the make-remove-bash-dep branch November 27, 2025 09:04
@leandrolanzieri leandrolanzieri added this to the Release 2026.01 milestone Jan 13, 2026
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 Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants