summaryrefslogtreecommitdiffstats
path: root/generator/CMakeLists.txt
blob: f3cbe08495cd6780ca3f0b07c1c61fd1266a2f47 (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
project(generators)

set(shiboken_SRC
cppgenerator.cpp
headergenerator.cpp
overloaddata.cpp
shiboken.cpp
shibokengenerator.cpp
shibokennormalize.cpp
)

include_directories(${CMAKE_CURRENT_SOURCE_DIR}
                    ${CMAKE_CURRENT_BINARY_DIR}
                    ${APIEXTRACTOR_INCLUDE_DIR}
                    ${GENERATORRUNNER_INCLUDE_DIR}
                    ${QT_INCLUDE_DIR}
                    ${QT_QTCORE_INCLUDE_DIR})

add_library(shiboken_generator SHARED ${shiboken_SRC})
set_property(TARGET shiboken_generator PROPERTY PREFIX "")

target_link_libraries(shiboken_generator
                      ${APIEXTRACTOR_LIBRARY}
                      ${GENERATORRUNNER_LIBRARY}
                      ${QT_QTCORE_LIBRARY})

configure_file(shibokenconfig.h.in "${CMAKE_CURRENT_BINARY_DIR}/shibokenconfig.h" @ONLY)

add_executable(shiboken main.cpp)
set_target_properties(shiboken PROPERTIES OUTPUT_NAME shiboken${shiboken_SUFFIX})
target_link_libraries(shiboken ${QT_QTCORE_LIBRARY})

add_dependencies(shiboken shiboken_generator)

install(TARGETS shiboken_generator DESTINATION "${GENERATORRUNNER_PLUGIN_DIR}")
install(TARGETS shiboken DESTINATION bin)