extract python prefix to allow overriding
authorStefan Biereigel <stefan@biereigel.de>
Tue, 14 May 2019 13:28:03 +0000 (15:28 +0200)
committerStefan Biereigel <stefan@biereigel.de>
Tue, 14 May 2019 13:28:03 +0000 (15:28 +0200)
Makefile

index 7cb7ec016c7fffc8b2e7074d79934b2c5d7d5e41..c01573976712ada4cbd117bd14b4ee15d2728497 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -25,7 +25,8 @@ PYTHON_VERSION_TESTCODE := "import sys;t='{v[0]}.{v[1]}'.format(v=list(sys.versi
 PYTHON_EXECUTABLE := $(shell if python3 -c ""; then echo "python3"; else echo "python"; fi)
 PYTHON_VERSION := $(shell $(PYTHON_EXECUTABLE) -c ""$(PYTHON_VERSION_TESTCODE)"")
 PYTHON_MAJOR_VERSION := $(shell echo $(PYTHON_VERSION) | cut -f1 -d.)
-PYTHON_DESTDIR := `$(PYTHON_EXECUTABLE)-config --prefix`/lib/python$(PYTHON_VERSION)/dist-packages
+PYTHON_PREFIX := `$(PYTHON_EXECUTABLE)-config --prefix`
+PYTHON_DESTDIR := $(PYTHON_PREFIX)/lib/python$(PYTHON_VERSION)/site-packages
 
 # other configuration flags
 ENABLE_GCOV := 0