Skip to content

Commit

Permalink
zephyr: move to strict headers builds for all targets
Browse files Browse the repository at this point in the history
Remove CONFIG_SOF_ZEPHYR_STRICT_HEADERS and make strict headers mode the
only supported way to build SOF with Zephyr. This means SOF Zephyr
builds do not use any headers from sof/xtos/include anymore.

This change simplifies the SOF build as full RTOS adaptation is
in sof/zephyr/include for Zephyr builds.

Link: thesofproject#9015
Signed-off-by: Kai Vehmanen <[email protected]>
  • Loading branch information
kv2019i committed Oct 30, 2024
1 parent b5d78bb commit c1afb28
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 21 deletions.
2 changes: 0 additions & 2 deletions smex/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ target_include_directories(smex PRIVATE
)

# TODO: smex should not need RTOS headers: FIX.
if (NOT CONFIG_SOF_ZEPHYR_STRICT_HEADERS)
target_include_directories(smex PRIVATE
"${SOF_ROOT_SOURCE_DIRECTORY}/xtos/include"
)
endif()
10 changes: 1 addition & 9 deletions zephyr/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -158,15 +158,7 @@ target_include_directories(SOF INTERFACE ${RIMAGE_TOP}/src/include)
target_include_directories(SOF INTERFACE ${SOF_SRC_PATH}/include)
target_include_directories(SOF INTERFACE ${SOF_SRC_PATH}/arch/${ARCH}/include)
target_include_directories(SOF INTERFACE ${sof_top_dir}/third_party/include)

# TODO: Zephyr should not need xtos headers: FIX.
if (CONFIG_SOF_ZEPHYR_STRICT_HEADERS)
target_include_directories(SOF INTERFACE ${sof_top_dir}/zephyr/include)
else()
# include Zephyr before xtos to flag up any errors in SOF
target_include_directories(SOF INTERFACE ${sof_top_dir}/zephyr/include)
target_include_directories(SOF INTERFACE ${sof_top_dir}/${PLATFORM_HEADERS}/include)
endif()
target_include_directories(SOF INTERFACE ${sof_top_dir}/zephyr/include)

# SOF module init
zephyr_library_named(modules_sof)
Expand Down
10 changes: 0 additions & 10 deletions zephyr/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,6 @@ config ZEPHYR_NATIVE_DRIVERS
dai-zephyr
will be used instead of legacy xtos version.

config SOF_ZEPHYR_STRICT_HEADERS
bool "Experimental: Force build with Zephyr RTOS headers only"
default n
help
This is a transitional option that allows developers to test builds
only using the Zephyr RTOS headers. This will eventually become the
default header configuration when native Zephyr is ready and this menu
choice will be removed.
If unsure, say n.

config DMA_DOMAIN
bool "Enable the usage of DMA domain."
default y if IMX8M
Expand Down

0 comments on commit c1afb28

Please sign in to comment.