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

make: export DEVELHELP #20889

Merged
merged 1 commit into from
Oct 11, 2024
Merged

make: export DEVELHELP #20889

merged 1 commit into from
Oct 11, 2024

Conversation

Enoch247
Copy link
Contributor

@Enoch247 Enoch247 commented Oct 3, 2024

Contribution description

This patch exports the make macro DEVELHELP. Without this patch, use of the macro in the following files does not work when the macro is set in a makefile (such as in Makefile.local or an application's makefile as demonstrated in dist/Makefile). Inside these files DEVELHELP is not defined under these conditions.

  • pkg/littlefs/Makefile
  • pkg/littlefs2/Makefile
  • sys/stdio_null/Makefile

Note that use of the macro does work in these files when the macro is set from the command line, without the patch. For example:

$make DEVELHELP=1 all

Testing procedure

  1. run: make -C examples/hello-world/ USEMODULE+=stdio_null
  2. observe the warning Makefile:2: STDIO disabled via stdio_null, but DEVELHELP enabled is seen with this patch, and is not seen without the patch. The warning is being emmited from the file sys/stdio_null/Makefile

Issues/PRs references

  • none known

This patch exports the make macro `DEVELHELP`. Without this patch, use
of the macro in the following files does not work when the macro is set
in a makefile (such as in Makefile.local or an application's makefile as
demonstrated in dist/Makefile). Inside these files `DEVELHELP` is not
defined under these conditions.

 - pkg/littlefs/Makefile
 - pkg/littlefs2/Makefile
 - sys/stdio_null/Makefile

Note that use of the macro does work in these files when the macro is
set from the command line, without the patch. For example:

``` sh
$make DEVELHELP=1 all
```
@github-actions github-actions bot added the Area: build system Area: Build system label Oct 3, 2024
@Enoch247
Copy link
Contributor Author

Enoch247 commented Oct 3, 2024

Please note that I have a change in-mind that can remove the use of DEVELHELP from the littlefs1/2 pkgs. I still think this PR should be merged because it seems likely that the macro will be used in Makefiles in the future.

@maribu
Copy link
Member

maribu commented Oct 9, 2024

This PR:

USEMODULE=stdio_null BOARD=samr21-xpro make -C examples/hello-world
make: Entering directory '/home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/examples/hello-world'
Building application "hello-world" for "samr21-xpro" with CPU "samd21".

"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/pkg/cmsis/ 
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/boards/common/init
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/boards/samr21-xpro
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/core
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/core/lib
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/samd21
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/cortexm_common
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/cortexm_common/periph
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/sam0_common
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/sam0_common/periph
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/samd21/periph
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/samd21/vectors
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/drivers
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/drivers/periph_common
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/auto_init
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/div
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/libc
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/malloc_thread_safe
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/newlib_syscalls_default
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/pm_layered
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/preprocessor
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/stdio
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/stdio_null
Makefile:2: STDIO disabled via stdio_null, but DEVELHELP enabled
   text	  data	   bss	   dec	   hex	filename
  10552	   104	  2592	 13248	  33c0	/home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/examples/hello-world/bin/samr21-xpro/hello-world.elf
make: Leaving directory '/home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/examples/hello-world'

master:

USEMODULE=stdio_null BOARD=samr21-xpro make -C examples/hello-world
make: Entering directory '/home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/examples/hello-world'
Building application "hello-world" for "samr21-xpro" with CPU "samd21".

"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/pkg/cmsis/ 
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/boards/common/init
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/boards/samr21-xpro
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/core
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/core/lib
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/samd21
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/cortexm_common
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/cortexm_common/periph
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/sam0_common
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/sam0_common/periph
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/samd21/periph
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/cpu/samd21/vectors
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/drivers
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/drivers/periph_common
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/auto_init
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/div
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/libc
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/malloc_thread_safe
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/newlib_syscalls_default
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/pm_layered
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/preprocessor
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/stdio
"make" -C /home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/sys/stdio_null
   text	  data	   bss	   dec	   hex	filename
  10552	   104	  2592	 13248	  33c0	/home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/examples/hello-world/bin/samr21-xpro/hello-world.elf
make: Leaving directory '/home/marian.buschsieweke@ml-pa.loc/Repos/software/RIOT/master/examples/hello-world'

So indeed, the warning from stdio_null is only shown with this PR.

@maribu maribu enabled auto-merge October 9, 2024 19:03
@mguetschow mguetschow added the CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR label Oct 11, 2024
@riot-ci
Copy link

riot-ci commented Oct 11, 2024

Murdock results

✔️ PASSED

dda83bc make: export DEVELHELP

Success Failures Total Runtime
10197 0 10197 17m:40s

Artifacts

@maribu maribu added this pull request to the merge queue Oct 11, 2024
Merged via the queue into RIOT-OS:master with commit 4c92d78 Oct 11, 2024
27 checks passed
@Enoch247 Enoch247 deleted the fix_DEVELHELP branch October 21, 2024 14:33
@benpicco benpicco added this to the Release 2024.10 milestone Nov 27, 2024
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
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants