diff options
author | Vasilii Chernov <vchernov@inr.ru> | 2016-02-03 16:48:45 +0100 |
---|---|---|
committer | Vasilii Chernov <vchernov@inr.ru> | 2016-02-03 16:48:45 +0100 |
commit | 99c165c078222c789d5fc90a79c756c8fffdafea (patch) | |
tree | 191428962f77d83577b82a8a1b213fa4bae5f17f /pcilib/CMakeLists.txt | |
parent | 817906fdd1c4509cb4b79160bb0d9ff72db7a604 (diff) | |
download | pcitool-99c165c078222c789d5fc90a79c756c8fffdafea.tar.gz pcitool-99c165c078222c789d5fc90a79c756c8fffdafea.tar.bz2 pcitool-99c165c078222c789d5fc90a79c756c8fffdafea.tar.xz pcitool-99c165c078222c789d5fc90a79c756c8fffdafea.zip |
Add python wrap for pcilib
Diffstat (limited to 'pcilib/CMakeLists.txt')
-rw-r--r-- | pcilib/CMakeLists.txt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/pcilib/CMakeLists.txt b/pcilib/CMakeLists.txt index cdc9c3f..ea275a3 100644 --- a/pcilib/CMakeLists.txt +++ b/pcilib/CMakeLists.txt @@ -13,6 +13,19 @@ add_library(pcilib SHARED pci.c datacpy.c memcpy.c pagecpy.c cpu.c timing.c expo target_link_libraries(pcilib dma protocols views ${CMAKE_THREAD_LIBS_INIT} ${UFODECODE_LIBRARIES} ${CMAKE_DL_LIBS} ${EXTRA_SYSTEM_LIBS} ${LIBXML2_LIBRARIES} ${PYTHON_LIBRARIES}) add_dependencies(pcilib dma protocols views) +#Creating python wrapping +FIND_PACKAGE(SWIG REQUIRED) +INCLUDE(${SWIG_USE_FILE}) + +INCLUDE_DIRECTORIES(${CMAKE_CURRENT_SOURCE_DIR}) + +SET(CMAKE_SWIG_FLAGS "") + +SET_SOURCE_FILES_PROPERTIES(pcipywrap.i PROPERTIES SWIG_FLAGS "-includeall") +SWIG_ADD_MODULE(pcipywrap python pcipywrap.i pcipywrap.c pci.c datacpy.c memcpy.c pagecpy.c cpu.c timing.c export.c value.c bar.c fifo.c model.c bank.c register.c view.c unit.c property.c xml.c py.c kmem.c irq.c locking.c lock.c dma.c event.c plugin.c tools.c error.c debug.c env.c) +SWIG_LINK_LIBRARIES(pcipywrap ${PYTHON_LIBRARIES} dma protocols views ${CMAKE_THREAD_LIBS_INIT} ${UFODECODE_LIBRARIES} ${CMAKE_DL_LIBS} ${EXTRA_SYSTEM_LIBS} ${LIBXML2_LIBRARIES}) +#wrapping end + install(TARGETS pcilib LIBRARY DESTINATION lib${LIB_SUFFIX} ) |