Add cmake target to generate API docs and write some basic API docs where needed.
[qtgstreamer:qtgstreamer.git] / CMakeLists.txt
1 project(QtGstreamer)
2 cmake_minimum_required(VERSION 2.6)
3 enable_testing()
4
5 set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules)
6 set(BUILDING_QTGSTREAMER TRUE)
7 set(QTGSTREAMER_VERSION 0.1)
8 set(QTGSTREAMER_SOVERSION 0)
9
10 find_package(Qt4 COMPONENTS QtCore QtTest REQUIRED)
11 find_package(QtGstreamer REQUIRED)
12 find_package(Automoc4 REQUIRED)
13 find_package(GStreamer REQUIRED)
14 find_package(GLIB2 REQUIRED)
15 find_package(GObject REQUIRED)
16 find_package(LibXml2 REQUIRED)
17 find_package(FLEX REQUIRED)
18 find_package(BISON REQUIRED)
19
20 include(${QT_USE_FILE})
21
22 if (CMAKE_COMPILER_IS_GNUCXX)
23     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wformat-security -Wundef -Wpointer-arith -Wcast-align -fno-common")
24 endif ()
25
26 add_subdirectory(codegen)
27 add_subdirectory(src)
28 add_subdirectory(tests)
29 add_subdirectory(examples)
30
31 # Add uninstall target. Taken from the KDE4 scripts
32 configure_file("${CMAKE_SOURCE_DIR}/cmake/modules/cmake_uninstall.cmake.in" "${CMAKE_BINARY_DIR}/cmake_uninstall.cmake" @ONLY)
33 add_custom_target(uninstall "${CMAKE_COMMAND}" -P "${CMAKE_BINARY_DIR}/cmake_uninstall.cmake")
34
35 # Add doc target
36 include(UseDoxygen)