##// END OF EJS Templates
Modify typesystems to #ifdef PyString
Modify typesystems to #ifdef PyString

File last commit:

r208:1476f2d2cf46
r210:d5ac67324004
Show More
CMakeLists.txt
160 lines | 4.6 KiB | text/plain | TextLexer
Orochimarufan
Redo CMake build system, get Qt5 support...
r205 project(PythonQt_QtAll)
# Bindings
SET(HEADERS
PythonQt_QtAll.h
)
SET(SOURCES
PythonQt_QtAll.cpp
)
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 #-------------------------------------------------------------------
# Generated stuff
SET(GEN ../../generated_cpp${generated_cpp_suffix})
Orochimarufan
Redo CMake build system, get Qt5 support...
r205
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 foreach(MODULE core gui network opengl sql svg uitools webkit xml)
SET(MODULE_TROLL com_trolltech_qt_${MODULE})
SET(MODULE_BASE ${GEN}/${MODULE_TROLL}/${MODULE_TROLL})
FILE(GLOB HFILES ${MODULE_BASE}*.h)
FILE(GLOB CFILES ${MODULE_BASE}*.cpp)
LIST(APPEND HEADERS ${HFILES})
LIST(APPEND SOURCES ${CFILES})
endforeach()
## Core
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core0.h
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core1.h
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core2.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core0.cpp
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core1.cpp
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core2.cpp
# ${GEN}/com_trolltech_qt_core/com_trolltech_qt_core_init.cpp
#)
## Gui
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui0.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui1.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui2.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui3.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui4.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui5.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui6.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui7.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui8.h
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui9.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui0.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui1.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui2.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui3.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui4.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui5.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui6.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui7.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui8.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui9.cpp
# ${GEN}/com_trolltech_qt_gui/com_trolltech_qt_gui_init.cpp
#)
## Network
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_network/com_trolltech_qt_network0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_network/com_trolltech_qt_network0.cpp
# ${GEN}/com_trolltech_qt_network/com_trolltech_qt_network_init.cpp
#)
## OpenGL
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_opengl/com_trolltech_qt_opengl0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_opengl/com_trolltech_qt_opengl0.cpp
# ${GEN}/com_trolltech_qt_opengl/com_trolltech_qt_opengl_init.cpp
#)
## Sql
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_sql/com_trolltech_qt_sql0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_sql/com_trolltech_qt_sql0.cpp
# ${GEN}/com_trolltech_qt_sql/com_trolltech_qt_sql_init.cpp
#)
## Svg
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_svg/com_trolltech_qt_svg0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_svg/com_trolltech_qt_svg0.cpp
# ${GEN}/com_trolltech_qt_svg/com_trolltech_qt_svg_init.cpp
#)
## uitools
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_uitools/com_trolltech_qt_uitools0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_uitools/com_trolltech_qt_uitools0.cpp
# ${GEN}/com_trolltech_qt_uitools/com_trolltech_qt_uitools_init.cpp
#)
## WebKit
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_webkit/com_trolltech_qt_webkit0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_webkit/com_trolltech_qt_webkit0.cpp
# ${GEN}/com_trolltech_qt_webkit/com_trolltech_qt_webkit_init.cpp
#)
## Xml
#LIST(APPEND HEADERS
# ${GEN}/com_trolltech_qt_xml/com_trolltech_qt_xml0.h
#)
#LIST(APPEND SOURCES
# ${GEN}/com_trolltech_qt_xml/com_trolltech_qt_xml0.cpp
# ${GEN}/com_trolltech_qt_xml/com_trolltech_qt_xml_init.cpp
#)
Orochimarufan
Redo CMake build system, get Qt5 support...
r205
#-------------------------------------------------------------------
# Build
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 set(PythonQt_QtAll ${PythonQt_LibraryName}_QtAll${PythonQt_LibrarySuffix} CACHE INTERNAL "")
Orochimarufan
Redo CMake build system, get Qt5 support...
r205
include_directories(../../src)
add_definitions(-DPYTHONQT_QTALL_EXPORTS)
qt_wrap_cpp(GEN_MOC ${HEADERS})
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 SET(QT Core Gui Network OpenGL Sql Svg UiTools WebKit Xml)
Orochimarufan
Redo CMake build system, get Qt5 support...
r205 if(PythonQt_Qt5)
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 LIST(APPEND QT Widgets WebKitWidgets)
Orochimarufan
Redo CMake build system, get Qt5 support...
r205 endif()
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 add_library(${PythonQt_QtAll} SHARED ${SOURCES} ${GEN_MOC})
qt_use_modules(${PythonQt_QtAll} ${QT})
get_property(PythonQt_lib TARGET ${PythonQt} PROPERTY LOCATION)
target_link_libraries(${PythonQt_QtAll} ${PythonQt_lib} ${PYTHON_LIBRARIES})
Orochimarufan
Redo CMake build system, get Qt5 support...
r205
Orochimarufan
Now Works with Python 2 & 3, Qt 4 & 5....
r208 install(TARGETS ${PythonQt_QtAll}
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib)