Merge pull request #11581 from haslinghuis/bump_clang_version
[betaflight.git] / make / targets_list.mk
blob072a9f45a0aefb9f1e5a7cdc2b956a9fddab7a2e
1 ALT_TARGET_PATHS = $(filter-out %/target,$(basename $(wildcard $(ROOT)/src/main/target/*/*.mk)))
2 ALT_TARGET_NAMES = $(notdir $(ALT_TARGET_PATHS))
3 BASE_TARGET_NAMES = $(notdir $(patsubst %/,%,$(dir $(ALT_TARGET_PATHS))))
4 BASE_ALT_PAIRS = $(join $(BASE_TARGET_NAMES:=/),$(ALT_TARGET_NAMES))
6 ALT_TARGETS = $(sort $(notdir $(BASE_ALT_PAIRS)))
7 BASE_TARGETS = $(sort $(notdir $(patsubst %/,%,$(dir $(wildcard $(ROOT)/src/main/target/*/target.mk)))))
8 NOBUILD_TARGETS = $(sort $(filter-out target,$(basename $(notdir $(wildcard $(ROOT)/src/main/target/*/*.nomk)))))
9 VALID_TARGETS = $(sort $(filter-out $(NOBUILD_TARGETS),$(BASE_TARGETS) $(ALT_TARGETS)))
11 # For alt targets, returns their base target name.
12 # For base targets, returns the (same) target name.
13 # param $1 = target name
14 find_target_pair = $(filter %/$(1),$(BASE_ALT_PAIRS))
15 get_base_target = $(if $(call find_target_pair,$(1)),$(patsubst %/,%,$(dir $(call find_target_pair,$(1)))),$(1))
17 UNSUPPORTED_TARGETS := \
18 AFROMINI \
19 BEEBRAIN \
20 CJMCU \
21 MICROSCISKY \
22 AIR32 \
23 BEEBRAIN_V2D \
24 BEEBRAIN_V2F \
25 BEESTORM \
26 COLIBRI_RACE \
27 FF_ACROWHOOPSP \
28 FF_KOMBINI \
29 FF_PIKOBLX \
30 FF_RADIANCE \
31 KISSCC \
32 KISSFC \
33 LUXV2_RACE \
34 LUX_RACE \
35 MOTOLAB \
36 MULTIFLITEPICO \
37 OMNIBUS \
38 RACEBASE \
39 RMDO \
40 SINGULARITY \
41 SIRINFPV \
42 SPARKY \
43 TINYFISH \
44 X_RACERSPI
46 UNIFIED_TARGETS := STM32F405 \
47 STM32F411 \
48 STM32F7X2 \
49 STM32F745 \
50 STM32G47X \
51 STM32H743 \
52 STM32F411SX1280
54 # Legacy targets are targets that have been replaced by Unified Target configurations
55 LEGACY_TARGETS := MATEKF405 \
56 AIKONF4 \
57 ALIENFLIGHTF4 \
58 BEEROTORF4 \
59 CLRACINGF4 \
60 CRAZYBEEF4FR \
61 DYSF4PRO \
62 ELINF405 \
63 FF_RACEPIT \
64 FLYWOOF405 \
65 FLYWOOF411 \
66 FURYF4OSD \
67 HAKRCF411 \
68 KAKUTEF4V2 \
69 MAMBAF411 \
70 MATEKF411 \
71 MATEKF411RX \
72 MERAKRCF405 \
73 MLTEMPF4 \
74 MLTYPHF4 \
75 OMNIBUSF4 \
76 OMNIBUSF4FW \
77 OMNIBUSF4NANOV7 \
78 OMNIBUSF4SD \
79 OMNIBUSF4V6 \
80 SPEEDYBEEF4 \
81 SYNERGYF4 \
82 TMOTORF4 \
83 TRANSTECF411 \
84 VGOODRCF4 \
85 XILOF4 \
86 AIRBOTF7 \
87 AIRF7 \
88 ALIENFLIGHTNGF7 \
89 CLRACINGF7 \
90 ELINF722 \
91 EXF722DUAL \
92 FLYWOOF7DUAL \
93 FOXEERF722DUAL \
94 FPVM_BETAFLIGHTF7 \
95 JHEF7DUAL \
96 KAKUTEF7 \
97 KAKUTEF7MINI \
98 LUXMINIF7 \
99 MAMBAF722 \
100 MATEKF722 \
101 MATEKF722SE \
102 MERAKRCF722 \
103 NERO \
104 OMNIBUSF7NANOV7 \
105 OMNIBUSF7V2 \
106 RUSHCORE7 \
107 SPEEDYBEEF7 \
108 SPRACINGF7DUAL \
109 TMOTORF7 \
110 TRANSTECF7 \
111 AIRBOTF4 \
112 AIRBOTF4SD \
113 BLUEJAYF4 \
114 CRAZYBEEF4DX \
115 CRAZYBEEF4FS \
116 DALRCF405 \
117 FOXEERF405 \
118 HAKRCF405 \
119 KAKUTEF4 \
120 NOX \
121 OMNINXT4 \
122 REVO \
123 DALRCF722DUAL \
124 OMNINXT7 \
125 BETAFLIGHTF4 \
126 EXUAVF4PRO \
127 FRSKYF4 \
128 KIWIF4 \
129 KIWIF4V2 \
130 PLUMF4 \
131 SKYZONEF405 \
132 XRACERF4 \
133 AG3XF7 \
134 YUPIF7 \
135 PYRODRONEF4 \
136 AG3XF4 \
137 COLIBRI \
138 ELLE0 \
139 F4BY \
140 FF_FORTINIF4 \
141 FF_FORTINIF4_REV03 \
142 FF_PIKOF4 \
143 FF_PIKOF4OSD \
144 FURYF4 \
145 LUXF4OSD \
146 REVOLT \
147 REVOLTOSD \
148 REVONANO \
149 SOULF4 \
150 SPARKY2 \
151 SPRACINGF4EVO \
152 SPRACINGF4NEO \
153 STM32F411DISCOVERY \
154 UAVPNG030MINI \
155 WORMFC \
156 YUPIF4 \
157 ANYFCF7 \
158 ANYFCM7 \
159 HAKRCF722 \
160 KAKUTEF7V2 \
161 NUCLEOF722 \
162 OMNIBUSF7 \
163 ALIENWHOOPF4 \
164 FISHDRONEF4 \
165 PIRXF4 \
166 PODIUMF4 \
167 STACKX \
168 VRRACE \
169 KROOZX
171 # Temporarily excluded to get CI coverage for USE_SPI_TRANSACTION
172 # STM32F4DISCOVERY \
174 CI_TARGETS := $(filter-out $(LEGACY_TARGETS) $(UNSUPPORTED_TARGETS), $(VALID_TARGETS))
176 TARGETS_TOTAL := $(words $(CI_TARGETS))
177 TARGET_GROUPS := 3
178 TARGETS_PER_GROUP := $(shell expr $(TARGETS_TOTAL) / $(TARGET_GROUPS) )
180 ST := 1
181 ET := $(shell expr $(ST) + $(TARGETS_PER_GROUP))
182 GROUP_1_TARGETS := $(wordlist $(ST), $(ET), $(CI_TARGETS))
184 ST := $(shell expr $(ET) + 1)
185 ET := $(shell expr $(ST) + $(TARGETS_PER_GROUP))
186 GROUP_2_TARGETS := $(wordlist $(ST), $(ET), $(CI_TARGETS))
188 GROUP_OTHER_TARGETS := $(filter-out $(GROUP_1_TARGETS) $(GROUP_2_TARGETS), $(CI_TARGETS))