mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2024-12-14 20:20:35 +00:00
cmake: Use standard way of getting python prefix
This commit is contained in:
parent
0038853c52
commit
f6311abc87
@ -116,12 +116,8 @@ endif()
|
|||||||
########################################################################
|
########################################################################
|
||||||
if(NOT DEFINED VOLK_PYTHON_DIR)
|
if(NOT DEFINED VOLK_PYTHON_DIR)
|
||||||
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "
|
execute_process(COMMAND ${PYTHON_EXECUTABLE} -c "
|
||||||
import os
|
from distutils import sysconfig
|
||||||
import sys
|
print(sysconfig.get_python_lib(plat_specific=True, prefix=''))
|
||||||
if os.name == 'posix':
|
|
||||||
print(os.path.join('lib', 'python' + sys.version[:3], 'dist-packages'))
|
|
||||||
if os.name == 'nt':
|
|
||||||
print(os.path.join('Lib', 'site-packages'))
|
|
||||||
" OUTPUT_VARIABLE VOLK_PYTHON_DIR OUTPUT_STRIP_TRAILING_WHITESPACE
|
" OUTPUT_VARIABLE VOLK_PYTHON_DIR OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
|
Loading…
Reference in New Issue
Block a user