Skip to content

Commit 57fd233

Browse files
committed
fix demo config paths handling
Signed-off-by: Gwenn Le Bihan <[email protected]>
1 parent 4f4cc73 commit 57fd233

File tree

2 files changed

+21
-18
lines changed

2 files changed

+21
-18
lines changed

CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,9 @@ endif(BUILD_PYTHON_INTERFACE)
146146
macro(create_demo source)
147147

148148
set(demo_name ${PROJECT_NAME}_${source})
149-
set(DEMO_ROOT "${PROJECT_SOURCE_DIR}/demos")
149+
string(REPLACE "demo_" "" device "${source}")
150+
set(DEMO_ROOT "${CMAKE_INSTALL_PREFIX}/demos")
151+
file(COPY "${PROJECT_SOURCE_DIR}/demos/config_${device}.yaml" DESTINATION "${DEMO_ROOT}")
150152
add_executable(${demo_name} demos/${source}.cpp)
151153
target_link_libraries(${demo_name} ${PROJECT_NAME})
152154
target_compile_definitions(

flake.lock

Lines changed: 18 additions & 17 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)