summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSuren A. Chilingaryan <csa@suren.me>2016-03-03 00:10:09 +0100
committerSuren A. Chilingaryan <csa@suren.me>2016-03-03 00:10:09 +0100
commit1e53d2d17e611586030e3ff3e9ab87e5bb753c9b (patch)
treeeadf19e2560dc9d73567962a299f2df53932357d
parentf7636162ba124c0d6b5accaa72c842033f3e2309 (diff)
downloadpcitool-1e53d2d17e611586030e3ff3e9ab87e5bb753c9b.tar.gz
pcitool-1e53d2d17e611586030e3ff3e9ab87e5bb753c9b.tar.bz2
pcitool-1e53d2d17e611586030e3ff3e9ab87e5bb753c9b.tar.xz
pcitool-1e53d2d17e611586030e3ff3e9ab87e5bb753c9b.zip
Fix CMakeLists.txt script for Python3
-rw-r--r--CMakeLists.txt4
-rw-r--r--xml/test/test_prop4.py1
2 files changed, 2 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5c2d45b..d3a8166 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -50,9 +50,9 @@ if (NOT DISABLE_PYTHON)
# execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "from sysconfig import get_path; print get_path('platlib')" OUTPUT_VARIABLE PYTHON_INSTALL_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
- execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "import site; print site.PREFIXES[-1]" OUTPUT_VARIABLE PYTHON_PREFIX OUTPUT_STRIP_TRAILING_WHITESPACE)
+ execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "import site; print (site.PREFIXES[-1])" OUTPUT_VARIABLE PYTHON_PREFIX OUTPUT_STRIP_TRAILING_WHITESPACE)
file (TO_CMAKE_PATH "${PYTHON_PREFIX}" PYTHON_PREFIX)
- execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "import site; print site.getsitepackages()[0]" OUTPUT_VARIABLE PYTHON_SITE_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
+ execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "import site; print (site.getsitepackages()[0])" OUTPUT_VARIABLE PYTHON_SITE_DIR OUTPUT_STRIP_TRAILING_WHITESPACE)
file (TO_CMAKE_PATH "${PYTHON_SITE_DIR}" PYTHON_SITE_DIR)
string (REGEX REPLACE "^${PYTHON_PREFIX}/" "${CMAKE_INSTALL_PREFIX}/" PYTHON_SITE_DIR "${PYTHON_SITE_DIR}")
diff --git a/xml/test/test_prop4.py b/xml/test/test_prop4.py
index a7e0269..30e9ece 100644
--- a/xml/test/test_prop4.py
+++ b/xml/test/test_prop4.py
@@ -10,7 +10,6 @@ def read_from_register(ctx, value):
read_from_register.counter += 1
for i in range (0, 5):
time.sleep(0.1)
- print(cur)
out = ctx.get_property('/test/prop3') / 2
ctx.unlock('test_prop4')