Skip to content

Commit 40515d4

Browse files
committed
build: audio: put modules in alphabetical order
Put the Cmake and Kconfig modules in alphabetical order to help convenience scripting insert new modules. Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
1 parent da9ce1e commit 40515d4

2 files changed

Lines changed: 53 additions & 73 deletions

File tree

src/audio/CMakeLists.txt

Lines changed: 27 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,18 @@ if(NOT CONFIG_COMP_MODULE_SHARED_LIBRARY_BUILD)
1717
add_subdirectory(pcm_converter)
1818
add_subdirectory(pipeline)
1919

20+
if(CONFIG_COMP_BASEFW_IPC4 AND NOT CONFIG_LIBRARY)
21+
add_local_sources(sof base_fw.c)
22+
endif()
23+
add_local_sources_ifdef(CONFIG_IPC4_BASE_FW_INTEL sof base_fw_intel.c)
24+
2025
# directories and files included conditionally (alphabetical order)
2126
if(CONFIG_COMP_ARIA)
2227
add_subdirectory(aria)
2328
endif()
2429
if(CONFIG_COMP_ASRC)
2530
add_subdirectory(asrc)
2631
endif()
27-
if(CONFIG_COMP_BASEFW_IPC4 AND NOT CONFIG_LIBRARY)
28-
add_local_sources(sof base_fw.c)
29-
endif()
30-
add_local_sources_ifdef(CONFIG_IPC4_BASE_FW_INTEL sof base_fw_intel.c)
31-
if(CONFIG_COMP_CHAIN_DMA)
32-
add_local_sources(sof chain_dma.c)
33-
endif()
3432
if(CONFIG_COMP_COPIER)
3533
add_subdirectory(copier)
3634
endif()
@@ -52,19 +50,14 @@ if(NOT CONFIG_COMP_MODULE_SHARED_LIBRARY_BUILD)
5250
if(CONFIG_COMP_IIR)
5351
add_subdirectory(eq_iir)
5452
endif()
55-
if(CONFIG_COMP_KPB AND NOT CONFIG_LIBRARY_STATIC)
56-
add_local_sources(sof
57-
kpb.c
58-
)
59-
endif()
6053
if(CONFIG_COMP_MFCC)
6154
add_subdirectory(mfcc)
6255
endif()
6356
if(CONFIG_COMP_MIXER)
64-
add_subdirectory(mixer)
57+
add_subdirectory(mixer)
6558
endif()
6659
if(CONFIG_COMP_MIXIN_MIXOUT)
67-
add_subdirectory(mixin_mixout)
60+
add_subdirectory(mixin_mixout)
6861
endif()
6962
if(CONFIG_COMP_MODULE_ADAPTER)
7063
add_subdirectory(module_adapter)
@@ -90,39 +83,49 @@ if(NOT CONFIG_COMP_MODULE_SHARED_LIBRARY_BUILD)
9083
if(CONFIG_COMP_TDFB)
9184
add_subdirectory(tdfb)
9285
endif()
93-
if(CONFIG_COMP_TONE)
94-
add_local_sources(sof
95-
tone.c
96-
)
86+
if(CONFIG_COMP_TEMPLATE_COMP)
87+
add_subdirectory(template_comp)
88+
endif()
89+
if(CONFIG_COMP_TENSORFLOW)
90+
add_subdirectory(tensorflow)
9791
endif()
9892
if(CONFIG_COMP_UP_DOWN_MIXER)
9993
add_subdirectory(up_down_mixer)
10094
endif()
10195
if(CONFIG_COMP_VOLUME)
10296
add_subdirectory(volume)
10397
endif()
104-
if(CONFIG_COMP_TENSORFLOW)
105-
add_subdirectory(tensorflow)
106-
endif()
10798
if(CONFIG_DTS_CODEC)
10899
add_subdirectory(codec)
109100
endif()
101+
# end of directories and files included conditionally (alphabetical order)
102+
110103
add_subdirectory(google)
111104
add_subdirectory(nxp)
112105

106+
if(CONFIG_COMP_CHAIN_DMA)
107+
add_local_sources(sof chain_dma.c)
108+
endif()
109+
if(CONFIG_COMP_KPB AND NOT CONFIG_LIBRARY_STATIC)
110+
add_local_sources(sof
111+
kpb.c
112+
)
113+
endif()
113114
if(CONFIG_INTEL_ADSP_MIC_PRIVACY)
114115
add_subdirectory(mic_privacy_manager)
115116
endif()
117+
if(CONFIG_COMP_TONE)
118+
add_local_sources(sof
119+
tone.c
120+
)
121+
endif()
116122
if(CONFIG_ZEPHYR_NATIVE_DRIVERS)
117123
list(APPEND base_files host-zephyr.c)
118124
sof_list_append_ifdef(CONFIG_COMP_DAI base_files dai-zephyr.c)
119125
else()
120126
list(APPEND base_files host-legacy.c)
121127
sof_list_append_ifdef(CONFIG_COMP_DAI base_files dai-legacy.c)
122128
endif()
123-
if(CONFIG_COMP_TEMPLATE_COMP)
124-
add_subdirectory(template_comp)
125-
endif()
126129
endif()
127130

128131
### Common files (also used in shared library build)

src/audio/Kconfig

Lines changed: 26 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@
22

33
menu "Audio components"
44

5-
rsource "volume/Kconfig"
6-
rsource "aria/Kconfig"
7-
85
config COMP_BASEFW_IPC4
96
bool "BASEFW component"
107
default y
@@ -20,8 +17,6 @@ config IPC4_BASE_FW_INTEL
2017
This implements a set of additional IPC4 properties that
2118
extend the base spec.
2219

23-
rsource "copier/Kconfig"
24-
2520
config HOST_DMA_RELOAD_DELAY_ENABLE
2621
bool "Delay reloading DMA for host interfaces"
2722
default y
@@ -77,8 +72,6 @@ config MODULE_MAX_CONNECTIONS
7772
Specifies the maximum number of sink and source connections a module
7873
may have to other modules.
7974

80-
rsource "up_down_mixer/Kconfig"
81-
8275
config COMP_BLOB
8376
bool "Large IPC data as compound message blobs"
8477
default y
@@ -94,31 +87,19 @@ config MODULE_MAX_BLOB_SIZE
9487
Specify the maximum size of IPC4 module blob data that can be
9588
appended to each message.
9689

97-
rsource "src/Kconfig"
98-
9990
config COMP_STUBS
10091
bool "Build all selected third-party (3P) components with stubs"
10192
help
10293
Select to force all 3P blocks to link against stubs rather than their libraries. This
10394
should only be used in testing environments like fuzzers or CI.
10495

105-
rsource "eq_fir/Kconfig"
106-
107-
rsource "eq_iir/Kconfig"
108-
10996
config COMP_TONE
11097
bool "Tone component"
11198
select CORDIC_FIXED
11299
help
113100
Select for Tone component.
114101
Warning: This component is deprecated and will be removed from SOF v2.8.
115102

116-
rsource "mixer/Kconfig"
117-
118-
rsource "mixin_mixout/Kconfig"
119-
120-
rsource "mux/Kconfig"
121-
122103
config COMP_KPB
123104
bool "KPB component"
124105
default y
@@ -135,28 +116,6 @@ config KPB_FORCE_COPY_TYPE_NORMAL
135116

136117
endif # COMP_KPB
137118

138-
rsource "google/Kconfig"
139-
140-
rsource "nxp/Kconfig"
141-
142-
rsource "selector/Kconfig"
143-
144-
rsource "crossover/Kconfig"
145-
146-
rsource "drc/Kconfig"
147-
148-
rsource "multiband_drc/Kconfig"
149-
150-
rsource "dcblock/Kconfig"
151-
152-
rsource "smart_amp/Kconfig"
153-
154-
rsource "asrc/Kconfig"
155-
156-
rsource "tdfb/Kconfig"
157-
158-
rsource "tensorflow/Kconfig"
159-
160119
config COMP_MODULE_ADAPTER
161120
bool "Module adapter"
162121
default y
@@ -168,17 +127,35 @@ config COMP_MODULE_ADAPTER
168127
"src\include\sof\audio\module_adapter\interfaces.h". It is possible to link several
169128
different codecs and use them in parallel.
170129

171-
rsource "module_adapter/Kconfig"
172-
130+
# --- Kconfig Sources (alphabetical order) ---
131+
rsource "aria/Kconfig"
132+
rsource "asrc/Kconfig"
133+
rsource "codec/Kconfig"
134+
rsource "copier/Kconfig"
135+
rsource "crossover/Kconfig"
136+
rsource "dcblock/Kconfig"
137+
rsource "drc/Kconfig"
138+
rsource "eq_fir/Kconfig"
139+
rsource "eq_iir/Kconfig"
140+
rsource "google/Kconfig"
173141
rsource "igo_nr/Kconfig"
174-
175-
rsource "rtnr/Kconfig"
176-
177142
rsource "mfcc/Kconfig"
178-
179-
rsource "codec/Kconfig"
180-
143+
rsource "mixer/Kconfig"
144+
rsource "mixin_mixout/Kconfig"
145+
rsource "module_adapter/Kconfig"
146+
rsource "multiband_drc/Kconfig"
147+
rsource "mux/Kconfig"
148+
rsource "nxp/Kconfig"
149+
rsource "rtnr/Kconfig"
150+
rsource "selector/Kconfig"
151+
rsource "smart_amp/Kconfig"
152+
rsource "src/Kconfig"
153+
rsource "tdfb/Kconfig"
181154
rsource "template_comp/Kconfig"
155+
rsource "tensorflow/Kconfig"
156+
rsource "up_down_mixer/Kconfig"
157+
rsource "volume/Kconfig"
158+
# --- End Kconfig Sources (alphabetical order) ---
182159

183160
endmenu # "Audio components"
184161

0 commit comments

Comments
 (0)