added support to anaconda and python 3.6+

scons-python3
Luca Quartesan 2022-01-06 17:46:58 +01:00
parent 3adf91b42a
commit 2695e3becc
1 changed files with 12 additions and 3 deletions

View File

@ -5,7 +5,9 @@ class PkgConfig(dict):
_paths = [
'/usr/lib/pkgconfig',
'/usr/lib/%s-linux-gnu/pkgconfig' % (os.uname()[4]),
'/usr/lib%i/pkgconfig' % (struct.calcsize('P')*8)
'/usr/lib%i/pkgconfig' % (struct.calcsize('P')*8),
'/root/miniconda3/lib/pkgconfig',
'/root/anaconda3/lib/pkgconfig'
]
def __init__(self, name):
@ -42,12 +44,15 @@ def find_boost_python(version):
libnames = [
'boost_python-mt-py%s' % version,
'boost_python-py%s' % version,
'boost_python%s' % version,
'boost_python' + ('3' if version.startswith('3') else '')
]
basepaths = [
'/usr/lib',
'/usr/lib/%s-linux-gnu' % (os.uname()[4]),
'/usr/lib%i' % (struct.calcsize('P')*8)
'/usr/lib%i' % (struct.calcsize('P')*8),
'/root/miniconda3/lib/',
'/root/anaconda3/lib/',
]
for basepath in basepaths:
@ -57,7 +62,11 @@ def find_boost_python(version):
return None
def detect_python():
pyver = ['2.6', '2.7', '3.0', '3.1', '3.2', '3.3', '3.4', '3.5', '3.6']
pyver = [
'2.6', '2.7',
'3.0', '3.1', '3.2', '3.3',
'3.4', '3.5', '3.6','3.7',
'3.8', '3.9', '3.10']
pyenv = {}
for version in pyver: