summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorNathaniel Graff <nathaniel.graff@sifive.com>2019-03-14 14:22:51 -0700
committerNathaniel Graff <nathaniel.graff@sifive.com>2019-03-14 16:24:59 -0700
commit28956117d173b478d6e47b570aa05ea38d605976 (patch)
treec9c5cc953b600b41193d7a4bbfecf1b634c3e1be /Makefile
parent6f9be963e3d31c4daed248b875e8169c15f7d64c (diff)
BSPs are any directory with settings.mk
Signed-off-by: Nathaniel Graff <nathaniel.graff@sifive.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 5 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index 1769d44..c513359 100644
--- a/Makefile
+++ b/Makefile
@@ -106,11 +106,12 @@ clean:
# format or fixed text of the output without consulting the
# Freedom Studio dev team.
#############################################################
-#
-# Metal boards are any folders that aren't the Legacy BSP or update-targets.sh
-EXCLUDE_TARGET_DIRS = drivers env include libwrap update-targets.sh
+
+# Finds all directories in bsp/ with settings.mk, extracts the name of those directories, and sorts them
+ALL_TARGETS = $(sort $(patsubst $(TARGET_ROOT)/bsp/%/,%,$(dir $(shell find $(TARGET_ROOT)/bsp -name settings.mk))))
+
list-targets:
- @echo bsp-list: $(sort $(filter-out $(EXCLUDE_TARGET_DIRS),$(notdir $(wildcard bsp/*))))
+ @echo bsp-list: $(ALL_TARGETS)
# Metal programs are any submodules in the software folder
list-programs: