Skip to content

Commit

Permalink
cmake: add new ${RIMAGE_TOP} constant
Browse files Browse the repository at this point in the history
In preparation for changing it, see
thesofproject#8178

No functional change yet.

Signed-off-by: Marc Herbert <[email protected]>
  • Loading branch information
marc-hb authored and kv2019i committed Oct 5, 2023
1 parent 51159d8 commit 2e7296f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
6 changes: 4 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@ project(SOF C ASM)
set(SOF_ROOT_SOURCE_DIRECTORY "${PROJECT_SOURCE_DIR}")
set(SOF_ROOT_BINARY_DIRECTORY "${PROJECT_BINARY_DIR}")

set(RIMAGE_TOP "${PROJECT_SOURCE_DIR}/rimage")

# check git hooks
include(scripts/cmake/git-hooks.cmake)

Expand Down Expand Up @@ -159,8 +161,8 @@ install(
${PROJECT_SOURCE_DIR}/src/include/ipc
${PROJECT_SOURCE_DIR}/src/include/kernel
${PROJECT_SOURCE_DIR}/src/include/user
${PROJECT_SOURCE_DIR}/rimage/src/include/sof/kernel
${PROJECT_SOURCE_DIR}/rimage/src/include/sof/user
${RIMAGE_TOP}/src/include/sof/kernel
${RIMAGE_TOP}/src/include/sof/user
DESTINATION include/sof
PATTERN "*.h"
)
Expand Down
6 changes: 3 additions & 3 deletions src/arch/xtensa/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ add_custom_target(

ExternalProject_Add(rimage_ep
DEPENDS check_version_h
SOURCE_DIR "${PROJECT_SOURCE_DIR}/rimage"
SOURCE_DIR "${RIMAGE_TOP}"
PREFIX "${PROJECT_BINARY_DIR}/rimage_ep"
BINARY_DIR "${PROJECT_BINARY_DIR}/rimage_ep/build"
EXCLUDE_FROM_ALL TRUE
Expand Down Expand Up @@ -386,7 +386,7 @@ if(MEU_PATH OR DEFINED MEU_NO_SIGN) # Don't sign with rimage
run_rimage
COMMAND ${PROJECT_BINARY_DIR}/rimage_ep/build/rimage
-o sof-${fw_name}.ri
-c "${PROJECT_SOURCE_DIR}/rimage/config/${fw_name}.toml"
-c "${RIMAGE_TOP}/config/${fw_name}.toml"
-s ${MEU_OFFSET}
-k ${RIMAGE_PRIVATE_KEY}
-i ${RIMAGE_IMR_TYPE}
Expand Down Expand Up @@ -427,7 +427,7 @@ else() # sign with rimage
run_rimage
COMMAND ${PROJECT_BINARY_DIR}/rimage_ep/build/rimage
-o sof-${fw_name}.ri
-c "${PROJECT_SOURCE_DIR}/rimage/config/${fw_name}.toml"
-c "${RIMAGE_TOP}/config/${fw_name}.toml"
-k ${RIMAGE_PRIVATE_KEY}
-i ${RIMAGE_IMR_TYPE}
-f ${SOF_MAJOR}.${SOF_MINOR}.${SOF_MICRO}
Expand Down
2 changes: 1 addition & 1 deletion src/ipc/ipc4/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ add_local_sources(sof
ams_helpers.c
)

target_include_directories(sof_options INTERFACE ${PROJECT_SOURCE_DIR}/rimage/src/include)
target_include_directories(sof_options INTERFACE ${RIMAGE_TOP}/src/include)

0 comments on commit 2e7296f

Please sign in to comment.