Skip to content

Commit

Permalink
Use python_interpreter_config to silence CMP0087 warning
Browse files Browse the repository at this point in the history
Signed-off-by: Robert Haschke <rhaschke@techfak.uni-bielefeld.de>
  • Loading branch information
rhaschke committed Sep 10, 2022
1 parent cc7ad4e commit 30db879
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ament_cmake_python/cmake/ament_python_install_package.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -161,9 +161,10 @@ setup(
)

# generate/install entry-point console scripts
get_executable_path(python_interpreter_config Python3::Interpreter CONFIGURE)
foreach(_dest ${ARG_SCRIPTS_DESTINATION})
get_filename_component(ABS_SCRIPTS_DESTINATION "${_dest}" ABSOLUTE BASE_DIR "${CMAKE_INSTALL_PREFIX}")
install(CODE "execute_process(COMMAND ${python_interpreter} setup.py install_scripts --install-dir \"${ABS_SCRIPTS_DESTINATION}\"
install(CODE "execute_process(COMMAND \"${python_interpreter_config}\" setup.py install_scripts --install-dir \"${ABS_SCRIPTS_DESTINATION}\"
WORKING_DIRECTORY \"${build_dir}\")")
endforeach()

Expand All @@ -175,7 +176,6 @@ setup(
)

if(NOT ARG_SKIP_COMPILE)
get_executable_path(python_interpreter_config Python3::Interpreter CONFIGURE)
# compile Python files
install(CODE
"execute_process(
Expand Down

0 comments on commit 30db879

Please sign in to comment.