aboutsummaryrefslogtreecommitdiffstats
path: root/host/python/CMakeLists.txt
diff options
context:
space:
mode:
authorTrung Tran <trung.tran@ettus.com>2018-07-26 01:23:31 +0000
committerBrent Stapleton <bstapleton@g.hmc.edu>2018-08-01 17:35:40 -0700
commit98057752006b5c567ed331c5b14e3b8a281b83b9 (patch)
tree9493f0a061b05f4e18704c1dd260ed6d09e84714 /host/python/CMakeLists.txt
parentf038a0284867faa65eedfd0d39ce0ecb8b8647f5 (diff)
downloaduhd-98057752006b5c567ed331c5b14e3b8a281b83b9.tar.gz
uhd-98057752006b5c567ed331c5b14e3b8a281b83b9.tar.bz2
uhd-98057752006b5c567ed331c5b14e3b8a281b83b9.zip
uhd: python: CMakeLists.txt change dll to pyd
To support python api installer
Diffstat (limited to 'host/python/CMakeLists.txt')
-rw-r--r--host/python/CMakeLists.txt8
1 files changed, 7 insertions, 1 deletions
diff --git a/host/python/CMakeLists.txt b/host/python/CMakeLists.txt
index 124e16649..c3099348a 100644
--- a/host/python/CMakeLists.txt
+++ b/host/python/CMakeLists.txt
@@ -27,9 +27,15 @@ TARGET_INCLUDE_DIRECTORIES(pyuhd PUBLIC
${PYTHON_NUMPY_INCLUDE_DIR}
${CMAKE_SOURCE_DIR}/lib
)
+
TARGET_LINK_LIBRARIES(pyuhd ${BOOST_PYTHON_LIBRARY} ${Boost_LIBRARIES} ${PYTHON_LIBRARY} uhd)
# Copy pyuhd library to the staging directory
-SET(PYUHD_LIBRARY_NAME ${CMAKE_SHARED_LIBRARY_PREFIX}pyuhd${CMAKE_SHARED_LIBRARY_SUFFIX})
+IF(WIN32)
+ SET(PYUHD_LIBRARY_NAME libpyuhd.pyd)
+ELSE()
+ SET(PYUHD_LIBRARY_NAME libpyuhd${CMAKE_SHARED_LIBRARY_SUFFIX})
+ENDIF(WIN32)
+
ADD_CUSTOM_COMMAND(TARGET pyuhd
POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy $<TARGET_FILE:pyuhd> ${CMAKE_CURRENT_BINARY_DIR}/uhd/${PYUHD_LIBRARY_NAME})