From: John Mulligan Date: Thu, 16 Jun 2022 19:41:04 +0000 (-0400) Subject: cephadm: use build.py in cmake configuration X-Git-Tag: v18.0.0~7^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=b2bd88f7cabc5828330b93aaeee82bfe9b191dcb;p=ceph-ci.git cephadm: use build.py in cmake configuration This change replaces the call to build.sh with a call to build.py. It also makes the build.py script a dependency to the cmake custom to ensure we rebuild the cephadm binary if build.py changes. Since, if one changes the build script used to make the binary we should rebuild the output as the new script may indeed change the intended output. Signed-off-by: John Mulligan --- diff --git a/src/cephadm/CMakeLists.txt b/src/cephadm/CMakeLists.txt index 464372debaa..fdb7c9881fa 100644 --- a/src/cephadm/CMakeLists.txt +++ b/src/cephadm/CMakeLists.txt @@ -7,9 +7,11 @@ set(bin_target_file ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/cephadm) add_custom_command( OUTPUT "${bin_target_file}" - DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/cephadm.py + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/cephadm.py + ${CMAKE_CURRENT_SOURCE_DIR}/build.py WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} - COMMAND bash build.sh ${bin_target_file} + COMMAND ${Python3_EXECUTABLE} build.py ${bin_target_file} ) add_custom_target(cephadm ALL