summaryrefslogtreecommitdiffstats
path: root/PySide/QtOpenGL/CMakeLists.txt
blob: 44ba1c1adf9fcf90ae8233469b144c7c6f3f421d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
project(QtOpenGL)

if (${QT_VERSION_MAJOR} EQUAL 4 AND ${QT_VERSION_MINOR} LESS 6)
  set(QtOpenGL_46_SRC )
else()
  set(QtOpenGL_46_SRC
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglframebufferobjectformat_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglshaderprogram_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglshader_wrapper.cpp
  )
endif()

if (${QT_VERSION_MAJOR} EQUAL 4 AND ${QT_VERSION_MINOR} LESS 7)
  set(QtOpenGL_47_SRC )
else()
  set(QtOpenGL_47_SRC
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglbuffer_wrapper.cpp
  )
endif()


set(QtOpenGL_SRC
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qgl_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglcolormap_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglcontext_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglformat_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglframebufferobject_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglpixelbuffer_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qglwidget_wrapper.cpp
    ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL/qtopengl_module_wrapper.cpp
    ${QtOpenGL_46_SRC}
    ${QtOpenGL_47_SRC}
)

set(QtOpenGL_typesystem_path "${QtCore_SOURCE_DIR}${PATH_SEP}${QtGui_SOURCE_DIR}${PATH_SEP}${QtOpenGL_SOURCE_DIR}${PATH_SEP}${QtGui_BINARY_DIR}")
set(QtOpenGL_include_dirs   ${CMAKE_CURRENT_SOURCE_DIR}
                            ${QT_QTCORE_INCLUDE_DIR}
                            ${QT_QTGUI_INCLUDE_DIR}
                            ${QT_QTOPENGL_INCLUDE_DIR}
                            ${SHIBOKEN_PYTHON_INCLUDE_DIR}
                            ${SHIBOKEN_INCLUDE_DIR}
                            ${libpyside_SOURCE_DIR}
                            ${QtGui_BINARY_DIR}/PySide/QtGui/
                            ${QtCore_BINARY_DIR}/PySide/QtCore/
                            ${CMAKE_CURRENT_BINARY_DIR}/PySide/QtOpenGL)
set(QtOpenGL_libraries      pyside
                            ${SHIBOKEN_PYTHON_LIBRARIES}
                            ${QT_QTCORE_LIBRARY}
                            ${QT_QTGUI_LIBRARY}
                            ${QT_QTOPENGL_LIBRARY})
set(QtOpenGL_deps QtGui)
create_pyside_module(QtOpenGL
                    QtOpenGL_include_dirs
                    QtOpenGL_libraries
                    QtOpenGL_deps
                    QtOpenGL_typesystem_path
                    QtOpenGL_SRC
                    "")