blob: 4a38a7e6d9ad9e1ba91669fb9885133b1963c56a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
diff --git a/cmake/python-site.py b/cmake/python-site.py
index 1e7fc8ce..95ef827f 100644
--- a/cmake/python-site.py
+++ b/cmake/python-site.py
@@ -1,4 +1,7 @@
-from distutils.sysconfig import get_python_lib, get_config_vars
+try:
+ from setuptools.sysconfig import get_python_lib, get_config_vars
+except ImportError:
+ from distutils.sysconfig import get_python_lib, get_config_vars
import sys
if sys.argv[1] == "prefix":
print(get_python_lib(True, False, sys.argv[2] if len(sys.argv) > 2 else None))
|