Skip to content

Commit

Permalink
fix issue with persistent parameters for sitl mode (#89)
Browse files Browse the repository at this point in the history
  • Loading branch information
PonomarevDA authored Dec 2, 2024
1 parent deb4a14 commit f9d1487
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Src/platform/ubuntu/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Copyright (C) 2023-2024 Dmitry Ponomarev <[email protected]>
# Distributed under the terms of the GPL v3 license, available in the file LICENSE.

# Generate temp parameters for SITL
include(${CMAKE_DIR}/libparams_generate_default_params.cmake)

set(EXECUTABLE ${PROJECT_NAME}.out)
add_executable(${EXECUTABLE}
${APPLICATION_SOURCES}
Expand Down
13 changes: 13 additions & 0 deletions cmake/libparams_generate_default_params.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Copyright (C) 2023-2024 Dmitry Ponomarev <[email protected]>
# Distributed under the terms of the GPL v3 license, available in the file LICENSE.

execute_process(
COMMAND ${LIBPARAMS_PATH}/scripts/generate_default_params.py
--out-dir ${BUILD_SRC_DIR}
-f ${BUILD_SRC_DIR}/params.cpp
--out-file-name default_params
RESULT_VARIABLE ret
)
if(NOT ret EQUAL 0)
message( FATAL_ERROR "Default Params Generator has been failed. Abort.")
endif()

0 comments on commit f9d1487

Please sign in to comment.