Skip to content

Commit

Permalink
Fix Python 3.12 support
Browse files Browse the repository at this point in the history
sysconfig is available since Python 3.2

Tested on nixpkgs and works as expected
  • Loading branch information
SuperSandro2000 committed Mar 2, 2024
1 parent 81c9d30 commit 69f6e62
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cpp/cmake_modules/FindPython3Alt.cmake
Expand Up @@ -67,7 +67,7 @@ get_target_property(NUMPY_INCLUDE_DIRS Python3::NumPy INTERFACE_INCLUDE_DIRECTOR
# detect it ourselves.
# (https://gitlab.kitware.com/cmake/cmake/issues/20408)
execute_process(COMMAND "${PYTHON_EXECUTABLE}" "-c"
"from distutils import sysconfig; print(sysconfig.get_config_var('EXT_SUFFIX'))"
"import sysconfig; print(sysconfig.get_config_var('EXT_SUFFIX'))"
RESULT_VARIABLE _PYTHON_RESULT
OUTPUT_VARIABLE _PYTHON_STDOUT
ERROR_VARIABLE _PYTHON_STDERR)
Expand Down

0 comments on commit 69f6e62

Please sign in to comment.