1 # This file is part of LyX, the document processor.
2 # Licence details can be found in the file COPYING.
4 # Copyright (c) 2006, Peter Kümmel, <syntheticpp@gmx.net>
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})
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)
16 file(GLOB support_linkback_sources ${TOP_SRC_DIR}/src/support/linkback/*.m*)
17 file(GLOB support_linkback_headers ${TOP_SRC_DIR}/src/support/linkback/*.h)
19 list(REMOVE_ITEM support_sources
20 ${TOP_SRC_DIR}/src/support/os_win32.cpp
21 ${TOP_SRC_DIR}/src/support/os_unix.cpp
22 ${TOP_SRC_DIR}/src/support/os_cygwin.cpp
23 ${TOP_SRC_DIR}/src/support/os_os2.C
24 ${TOP_SRC_DIR}/src/support/atexit.c
25 ${TOP_SRC_DIR}/src/support/strerror.c
26 ${TOP_SRC_DIR}/src/support/minizip/iowin32.h
27 ${TOP_SRC_DIR}/src/support/minizip/iowin32.c
28 ${TOP_SRC_DIR}/src/support/gettext.cpp)
31 message(STATUS "Mac LinkBack support")
33 set(support_linkback_sources "")
34 set(support_linkback_headers "")
37 # needed to compile tex2lyx in merged mode
38 set(dont_merge ${TOP_SRC_DIR}/src/support/gettext.cpp)
40 lyx_add_msvc_pch(support)
42 lyx_automoc(${support_sources})
44 include_directories(${TOP_SRC_DIR}/src/support
45 ${CMAKE_BINARY_DIR}/src/support
46 ${TOP_SRC_DIR}/src/support/minizip
53 set(support_sources ${support_sources} ${support_minizip_sources} ${support_minizip_cpp_sources} ${support_linkback_sources})
54 set(support_headers ${support_headers} ${support_minizip_headers} ${support_linkback_headers})
55 add_library(support ${library_type} ${support_sources} ${support_headers} ${dont_merge})
57 lyx_const_touched_files(_allinone support_sources)
58 set(depends_moc ${support_headers})
59 set_source_files_properties(_allinone_const.C
60 PROPERTIES OBJECT_DEPENDS "${depends_moc}")
61 set_source_files_properties(_allinone_touched.C
62 PROPERTIES OBJECT_DEPENDS "${depends_moc}")
63 add_library(support ${library_type} ${_allinone_files}
64 ${support_minizip_sources} ${support_minizip_cpp_sources} ${support_linkback_sources} ${support_headers} ${dont_merge})
67 target_link_libraries(support boost_signals ${QT_QTCORE_LIBRARY} ${ZLIB_LIBRARY})
70 target_link_libraries(support "objc" "-framework Appkit" "-framework CoreFoundation")
72 target_link_libraries(support shlwapi)
75 project_source_group("${GROUP_CODE}" support_sources support_headers)