]> git.sesse.net Git - vlc/blob - extras/buildsystem/cmake/CMakeLists/root_CMakeLists.txt
Fix SO versions
[vlc] / extras / buildsystem / cmake / CMakeLists / root_CMakeLists.txt
1 PROJECT(vlc)
2
3 ENABLE_TESTING()
4
5 # Set the module path
6 set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
7
8 # Our own include
9 include( vlc_module_funcs )
10
11 # Our config
12 include( config )
13
14 # Global definitions
15 add_definitions(-DHAVE_CONFIG_H)
16 add_definitions(-D__LIBVLC__)
17 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99")
18 set(CMAKE_INCLUDE_CURRENT_DIR ON)
19
20 # Needed for glibc:
21 add_definitions(-D_GNU_SOURCE)
22
23 # Our main include directories
24 include_directories(${CMAKE_SOURCE_DIR}/include ${CMAKE_BINARY_DIR}/include)
25
26 # our sources:
27 add_subdirectory(src)
28 add_subdirectory(modules)
29 add_subdirectory(po)
30
31 # Enable CPack: Automatic package creation
32
33 set(README "${CMAKE_CURRENT_SOURCE_DIR}/README")
34 set(LICENCE "${CMAKE_CURRENT_SOURCE_DIR}/COPYING")
35
36 if(APPLE)
37 set(README "${CMAKE_CURRENT_SOURCE_DIR}/extras/package/macosx/README.MacOSX.rtf")
38 set(LICENCE "") # FIXME: Mac OS X's Package Maker doesn't allow non .*
39 endif(APPLE)
40
41 set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "VLC Media Player")
42 set(CPACK_PACKAGE_VENDOR "VideoLAN Team")
43 set(CPACK_PACKAGE_DESCRIPTION_FILE ${README})
44 set(CPACK_RESOURCE_FILE_LICENSE ${LICENCE})
45 set(CPACK_PACKAGE_VERSION_MAJOR "${VLC_VERSION_MAJOR}")
46 set(CPACK_PACKAGE_VERSION_MINOR "${VLC_VERSION_MINOR}")
47 set(CPACK_PACKAGE_VERSION_PATCH "${VLC_VERSION_PATCH}${VLC_VERSION_EXTRA}")
48
49 include(CPack)