From 94d4c254383a820517b27dd8933451d82af95d00 Mon Sep 17 00:00:00 2001 From: Corentin Le Molgat Date: Fri, 19 Nov 2021 14:24:03 +0100 Subject: [PATCH] cmake: Fix python executable in python install script --- cmake/python-install.cmake.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/python-install.cmake.in b/cmake/python-install.cmake.in index 49bd2a5930..95d6bd1dd2 100644 --- a/cmake/python-install.cmake.in +++ b/cmake/python-install.cmake.in @@ -13,7 +13,7 @@ endif() # Check if we have system Python on Debian/Ubuntu, if so tell setuptools # to use the deb layout (dist-packages instead of site-packages). execute_process( - COMMAND @Python_EXECUTABLE@ -c "import sys; sys.stdout.write(sys.path[-1])" + COMMAND @Python3_EXECUTABLE@ -c "import sys; sys.stdout.write(sys.path[-1])" OUTPUT_VARIABLE Python_STDLIB_DIR ) if(Python_STDLIB_DIR MATCHES ".*/dist-packages$") @@ -24,7 +24,7 @@ endif() execute_process( WORKING_DIRECTORY @PROJECT_BINARY_DIR@/python - COMMAND @Python_EXECUTABLE@ setup.py install + COMMAND @Python3_EXECUTABLE@ setup.py install ${ROOT} --prefix=@CMAKE_INSTALL_PREFIX@ ${SETUPTOOLS_INSTALL_LAYOUT}