aboutsummaryrefslogtreecommitdiffstats
path: root/host/python/CMakeLists.txt
diff options
context:
space:
mode:
authorTrung Tran <trung.tran@ettus.com>2018-07-13 12:52:47 +0000
committerMartin Braun <martin.braun@ettus.com>2018-07-13 11:45:41 -0700
commit04987da5150d4043d8a424dd897eeae0b7110ee5 (patch)
tree45ebab89d88e192974e9f77025fb78da637e2369 /host/python/CMakeLists.txt
parent1f0a8561f0ccda4dee47dd364d30bef4ac966721 (diff)
downloaduhd-04987da5150d4043d8a424dd897eeae0b7110ee5.tar.gz
uhd-04987da5150d4043d8a424dd897eeae0b7110ee5.tar.bz2
uhd-04987da5150d4043d8a424dd897eeae0b7110ee5.zip
cmake: add support to make python api installer on windows
Diffstat (limited to 'host/python/CMakeLists.txt')
-rw-r--r--host/python/CMakeLists.txt8
1 files changed, 2 insertions, 6 deletions
diff --git a/host/python/CMakeLists.txt b/host/python/CMakeLists.txt
index a650529fa..92c4daadc 100644
--- a/host/python/CMakeLists.txt
+++ b/host/python/CMakeLists.txt
@@ -56,11 +56,7 @@ ADD_CUSTOM_TARGET(pyuhd_library ALL DEPENDS ${TIMESTAMP_FILE} pyuhd)
IF(HAVE_PYTHON_VIRTUALENV)
INSTALL(CODE "execute_process(COMMAND ${PYTHON} ${SETUP_PY} -q install --force)")
ELSE()
- EXECUTE_PROCESS(COMMAND ${PYTHON_EXECUTABLE} -c
- "from distutils import sysconfig; print(sysconfig.get_python_lib(plat_specific=True, prefix=''))"
- OUTPUT_VARIABLE UHD_PYTHON_DIR OUTPUT_STRIP_TRAILING_WHITESPACE
- )
+ SET(UHD_PYTHON_DIR "lib/site-packages")
MESSAGE(STATUS "Utilizing the python install directory: ${CMAKE_INSTALL_PREFIX}/${UHD_PYTHON_DIR}")
- INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/uhd DESTINATION ${CMAKE_INSTALL_PREFIX}/${UHD_PYTHON_DIR})
+ INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/uhd DESTINATION ${UHD_PYTHON_DIR} COMPONENT pythonapi)
ENDIF()
-