Skip to content

makefiles/riotgen: fix colors and behavior for undefined generate-* targets #21448

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
Apr 29, 2025

Conversation

crasbe
Copy link
Contributor

@crasbe crasbe commented Apr 28, 2025

Contribution description

Recently I noticed that when you call make generate-Makefile.ci from the base directory, it would try to call riotgen Makefile.ci, which obviously fails. Likewise with any other generate-* target. Also, the colors for the warnings did not work for the warning when riotgen is not installed:

image

With this PR, the unrecognized target will be called out by the Welcome Message and the colors work for the warning. Also I made the warning a bit nicer.

image

Testing procedure

Run make generate-bogus and make generate-Makefile.ci in the base directory and observe that the correct warning is displayed.

Uninstall riotgen and see that the warning is colored.

Install riotgen again and see that make generate-test will still call riotgen and ask you for the application name.

@crasbe crasbe added Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) 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 Apr 28, 2025
@github-actions github-actions bot added Area: build system Area: Build system Area: tools Area: Supplementary tools labels Apr 28, 2025
When executing `make generate-Makefile.ci` in the base directory,
the make system would try to call `riotgen` with `Makefile.ci`,
which does not work. Likewise with any other target like
`make generate-bogus`. The pattern rule for the prerequisites was
not evaluated by make, therefore the check did not work as
intended.
@riot-ci
Copy link

riot-ci commented Apr 28, 2025

Murdock results

✔️ PASSED

f163888 makefiles/riotgen: fix colors and behav. for undef. targets

Success Failures Total Runtime
1 0 1 01m:31s

Artifacts

@crasbe crasbe added the Impact: minor The PR is small in size and might only require a quick look of a knowledgeable reviewer label Apr 28, 2025
Copy link
Contributor

@mguetschow mguetschow left a comment

Choose a reason for hiding this comment

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

Confirmed locally to work as described, thanks!

@mguetschow mguetschow enabled auto-merge April 29, 2025 07:55
@mguetschow mguetschow added this pull request to the merge queue Apr 29, 2025
@mguetschow mguetschow removed this pull request from the merge queue due to a manual request Apr 29, 2025
@mguetschow
Copy link
Contributor

Postponing this one in favor of #21450 and #21447 for today's release.

@crasbe crasbe added the CI: skip compile test If set, CI server will run only non-compile jobs, but no compile jobs or their dependent jobs label Apr 29, 2025
@crasbe crasbe enabled auto-merge April 29, 2025 10:17
@crasbe crasbe added this pull request to the merge queue Apr 29, 2025
@crasbe crasbe removed this pull request from the merge queue due to a manual request Apr 29, 2025
@crasbe crasbe 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 Apr 29, 2025
@crasbe crasbe enabled auto-merge April 29, 2025 11:46
@crasbe crasbe added this pull request to the merge queue Apr 29, 2025
Merged via the queue into RIOT-OS:master with commit 9df0a39 Apr 29, 2025
30 checks passed
@crasbe crasbe deleted the pr/gen_makeci branch May 8, 2025 12:14
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: tools Area: Supplementary tools CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR CI: skip compile test If set, CI server will run only non-compile jobs, but no compile jobs or their dependent jobs Impact: minor The PR is small in size and might only require a quick look of a knowledgeable reviewer Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) 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.

3 participants