]> git.lyx.org Git - lyx.git/blob - development/cmake/src/support/CMakeLists.txt
fix compilation on Mac, patch from Stefan.
[lyx.git] / development / cmake / src / support / CMakeLists.txt
1 # This file is part of LyX, the document processor.
2 # Licence details can be found in the file COPYING.
3 #
4 # Copyright (c) 2006, Peter Kümmel, <syntheticpp@gmx.net>
5 #
6
7 project(support)
8
9 file(GLOB support_sources ${TOP_SRC_DIR}/src/support/${LYX_CPP_FILES})
10 file(GLOB support_headers ${TOP_SRC_DIR}/src/support/${LYX_HPP_FILES})
11
12 file(GLOB support_minizip_sources ${TOP_SRC_DIR}/src/support/minizip/*.c)
13 file(GLOB support_minizip_cpp_sources ${TOP_SRC_DIR}/src/support/minizip/*.cpp)
14 file(GLOB support_minizip_headers ${TOP_SRC_DIR}/src/support/minizip/*.h)
15
16 list(REMOVE_ITEM support_sources        
17         ${TOP_SRC_DIR}/src/support/os_win32.cpp
18         ${TOP_SRC_DIR}/src/support/os_unix.cpp
19         ${TOP_SRC_DIR}/src/support/os_cygwin.cpp
20         ${TOP_SRC_DIR}/src/support/os_os2.C
21         ${TOP_SRC_DIR}/src/support/atexit.c
22         ${TOP_SRC_DIR}/src/support/strerror.c
23         ${TOP_SRC_DIR}/src/support/minizip/iowin32.h
24         ${TOP_SRC_DIR}/src/support/minizip/iowin32.c)
25
26 lyx_add_msvc_pch(support)
27         
28 include_directories(${TOP_SRC_DIR}/src/support
29         ${TOP_SRC_DIR}/src/support/minizip
30         ${QT_INCLUDES}
31         ${ICONV_INCLUDE_DIR})
32
33
34 if(NOT MERGE_FILES)
35         set(support_sources ${support_sources} ${support_minizip_sources} ${support_minizip_cpp_sources})
36         set(support_headers ${support_headers} ${support_minizip_headers})
37         add_library(support ${library_type} ${support_sources} ${support_headers})
38 else()
39         lyx_const_touched_files(_allinone  support_sources)
40         add_library(support ${library_type} ${_allinone_files}
41                 ${support_minizip_sources} ${support_minizip_cpp_sources})
42 endif()
43
44
45 target_link_libraries(support boost_signals)
46
47 if(WIN32)
48         target_link_libraries(support shlwapi)
49 endif()
50
51 project_source_group("${GROUP_CODE}" support_sources support_headers)
52