1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-15 01:23:49 +01:00

Merge pull request #21213 from mguetschow/list-examples

makefiles: fix output of info-applications
This commit is contained in:
mguetschow 2025-02-14 14:33:10 +00:00 committed by GitHub
commit fe72a9e01b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
11 changed files with 41 additions and 34 deletions

View File

@ -28,4 +28,4 @@ portable-atomic = { version = "1", features = [ "critical-section" ] }
# Rust, that may change; it is best practice for any RIOT application that has
# its own top-level Rust crate to include rust_riotmodules from inside
# RIOTBASE.
rust_riotmodules = { path = "../../sys/rust_riotmodules/" }
rust_riotmodules = { path = "../../../../sys/rust_riotmodules/" }

View File

@ -30,7 +30,7 @@ riot-coap-handler-demos = { git = "https://gitlab.com/etonomy/riot-module-exampl
# Rust, that may change; it is best practice for any RIOT application that has
# its own top-level Rust crate to include rust_riotmodules from inside
# RIOTBASE.
rust_riotmodules = { path = "../../sys/rust_riotmodules/" }
rust_riotmodules = { path = "../../../../sys/rust_riotmodules/" }
static_cell = "2.1.0"
[patch.crates-io]

View File

@ -21,4 +21,4 @@ riot-wrappers = { version = "0.9.0", features = [ "set_panic_handler" ] }
# Rust, that may change; it is best practice for any RIOT application that has
# its own top-level Rust crate to include rust_riotmodules from inside
# RIOTBASE.
rust_riotmodules = { path = "../../sys/rust_riotmodules/" }
rust_riotmodules = { path = "../../../../sys/rust_riotmodules/" }

View File

@ -5,7 +5,7 @@ APPLICATION = skald_eddystone
BOARD ?= nrf52dk
# This has to be the absolute path to the RIOT base directory:
RIOTBASE ?= $(CURDIR)/../../../..
RIOTBASE ?= $(CURDIR)/../../../../..
# include Skald
USEMODULE += skald_eddystone

View File

@ -5,7 +5,7 @@ APPLICATION = skald_ibeacon
BOARD ?= nrf52dk
# This has to be the absolute path to the RIOT base directory:
RIOTBASE ?= $(CURDIR)/../../../..
RIOTBASE ?= $(CURDIR)/../../../../..
# include Skald
USEMODULE += skald_ibeacon

View File

@ -5,7 +5,7 @@ APPLICATION = nimble_gatt
BOARD ?= nrf52dk
# This has to be the absolute path to the RIOT base directory:
RIOTBASE ?= $(CURDIR)/../../../..
RIOTBASE ?= $(CURDIR)/../../../../..
# Include NimBLE
USEPKG += nimble

View File

@ -5,7 +5,7 @@ APPLICATION = nimble_heart_rate_sensor
BOARD ?= nrf52dk
# This has to be the absolute path to the RIOT base directory:
RIOTBASE ?= $(CURDIR)/../../../..
RIOTBASE ?= $(CURDIR)/../../../../..
# Some RIOT modules needed for this example
USEMODULE += event_timeout_ztimer

View File

@ -5,7 +5,7 @@ APPLICATION = nimble_scanner
BOARD ?= nrf52dk
# This has to be the absolute path to the RIOT base directory:
RIOTBASE ?= $(CURDIR)/../../../..
RIOTBASE ?= $(CURDIR)/../../../../..
# We use the xtimer and the shell in this example
USEMODULE += shell

View File

@ -5,7 +5,7 @@ APPLICATION = gnrc_lorawan
DEVELHELP ?= 1
BOARD ?= b-l072z-lrwan1
RIOTBASE ?= ../../
RIOTBASE ?= $(CURDIR)/../../../..
# Include board's default network devices and auto-initialization of GNRC
# interfaces

View File

@ -0,0 +1,21 @@
examples/advanced_examples/bindist/
examples/advanced_examples/pio_blink/
examples/essentials/subfolders/
examples/language_bindings/community_supported/wasm/
tests/build_system/blob/
tests/build_system/cpp_exclude/external_modules/
tests/build_system/cpp_ext/external_modules/
tests/build_system/external_board_dirs/esp-ci-boards/
tests/build_system/external_board_dirs/netdev-ci-boards/
tests/build_system/external_board_native/external_boards/
tests/build_system/external_module_dirs/external_modules/
tests/build_system/external_pkg_dirs/external_pkgs/
tests/build_system/kconfig/external_modules/
tests/build_system/kconfig/external_pkgs/
tests/periph/qdec/boards_modded/
tests/pkg/openwsn_sock_udp/external_modules/
tests/pkg/tflite-micro/external_modules/
tests/pkg/utensor/external_modules/
tests/pkg/wolfcrypt-ed25519-verify/
tests/sys/suit_manifest/native_flashpage/
tests/unittests/

View File

@ -3,32 +3,18 @@
# fallback so empty RIOTBASE won't lead to "/examples/"
RIOTBASE ?= .
# 1. use wildcard to find Makefiles
# 2. use patsubst to drop trailing "/"
# 3. use patsubst to drop possible leading "./"
# 4. sort
APPS_BASE_DIRS = bootloaders examples fuzzing tests
# Prepare the list of application directories
APPLICATION_DIRS := \
fuzzing \
bootloaders \
examples \
tests \
tests/bench \
tests/build_system \
tests/core \
tests/cpu \
tests/drivers \
tests/net \
tests/periph \
tests/pkg \
tests/sys \
#
APPLICATION_DIRS := $(addprefix $(RIOTBASE)/,$(APPLICATION_DIRS))
APPLICATION_DIRS_RELATIVE := $(dir $(wildcard $(addsuffix /*/Makefile,$(APPLICATION_DIRS))))
APPLICATION_DIRS_ABSOLUTE := $(abspath $(APPLICATION_DIRS_RELATIVE))
APPLICATION_DIRS := $(sort $(patsubst ./%,%,$(patsubst %/,%,$(APPLICATION_DIRS_RELATIVE))))
# 1. recursively find Makefiles
# 2. take parent folders
# 3. exclude build artifacts (below bin/)
# 4. exclude false positives from app_dirs.blacklist
# 5. sort
APPLICATION_DIRS := $(shell find $(APPS_BASE_DIRS) -name Makefile -type f | \
xargs dirname | \
grep -vF "/bin/" | \
grep -vFf $(RIOTBASE)/makefiles/app_dirs.blacklist | \
sort | uniq)
info-applications:
@for dir in $(APPLICATION_DIRS); do echo $$dir; done