X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FCMakeLists.txt;h=4ee7872d509434c2ebba912fc3e9cd7a293186a3;hb=4db3e641ed6765e005343010cb90ee8af26f8f99;hp=7f57845bf1bad13319eb6ef105b278ded0964cf9;hpb=3a5c0f66a008f9e7baadd017ff0b37c4f6789b6a;p=lyx.git diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 7f57845bf1..4ee7872d50 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -4,11 +4,13 @@ # Copyright (c) 2006-2011 Peter Kümmel, # -set(_lyx "${PACKAGE_BASE}${PROGRAM_SUFFIX}") project(${_lyx}) include_directories(${TOP_SRC_DIR}/src) +set_property(GLOBAL PROPERTY USE_FOLDERS ON) +set_property(GLOBAL PROPERTY PREDEFINED_TARGETS_FOLDER "CMakeTargets") + add_subdirectory(frontends) add_subdirectory(graphics) add_subdirectory(insets) @@ -31,8 +33,6 @@ list(REMOVE_ITEM lyx_sources ${TOP_SRC_DIR}/src/lyxinsets.cpp ${TOP_SRC_DIR}/src/lyxmathed.cpp) -set_property(SOURCE "${TOP_SRC_DIR}/src/version.cpp" APPEND PROPERTY COMPILE_DEFINITIONS LYX_DATE="${LYX_DATE}") - list(REMOVE_ITEM lyx_headers ${TOP_SRC_DIR}/src/Variables.h ${TOP_SRC_DIR}/src/Section.h) @@ -90,16 +90,17 @@ if (LYX_VLD) endif() if(WIN32) - set(FILE_RC ${TOP_SRC_DIR}/development/cmake/lyx.rc) + set(FILE_RC ${TOP_CMAKE_PATH}/lyx.rc) message(STATUS "Using icon defined in resource file: ${FILE_RC}") endif() lyx_find_info_files(LyXInfoFiles ${TOP_SRC_DIR}/*) -lyx_find_info_files(LyXCMakeFiles ${TOP_SRC_DIR}/development/cmake/*.txt) -lyx_find_info_files(LyXCMakeFiles ${TOP_SRC_DIR}/development/cmake/*.cmake) -lyx_find_info_files(LyXCMakeFiles ${TOP_SRC_DIR}/development/cmake/*.h) -lyx_find_info_files(LyXCMakeFiles ${TOP_SRC_DIR}/development/cmake/*.msvc) -lyx_find_info_files(LyXCMakeFiles ${TOP_SRC_DIR}/development/cmake/modules/*) +lyx_find_info_files(LyXCMakeFiles ${TOP_CMAKE_PATH}/*.txt) +lyx_find_info_files(LyXCMakeFiles ${TOP_CMAKE_PATH}/*.cmake) +lyx_find_info_files(LyXCMakeFiles ${TOP_CMAKE_PATH}/*.h) +lyx_find_info_files(LyXCMakeFiles ${TOP_CMAKE_PATH}/*.msvc) +lyx_find_info_files(LyXCMakeFiles ${TOP_MODULE_PATH}/*) +lyx_find_info_files(LyXCMakeFiles ${TOP_SCRIPT_PATH}/*) lyx_find_info_files(LyXUiFiles ${TOP_SRC_DIR}/lib/ui/*) if (APPLE AND LYX_BUNDLE) @@ -118,6 +119,11 @@ add_executable(${_lyx} ${OSX_BUNDLE_FILES} ) +add_dependencies(${_lyx} lyx_version) + +set_target_properties(${_lyx} PROPERTIES FOLDER "applications/LyX") + +qt_use_modules(${_lyx} Core Gui) lyx_add_gcc_pch(${_lyx}) @@ -128,12 +134,10 @@ target_link_libraries(${_lyx} frontend_qt4 graphics support - ${LIBINTL_LIBRARIES} ${ICONV_LIBRARY} ${QT_QTMAIN_LIBRARY} ${vld_dll}) - if(HUNSPELL_FOUND) target_link_libraries(${_lyx} ${HUNSPELL_LIBRARY}) endif() @@ -180,3 +184,9 @@ if(LYX_BUNDLE) fixup_bundle(\"${installed_lyx}\" \"\" \"\") " COMPONENT RUNTIME) endif() +if(NOT APPLE) + # unresoved handling for multiple definitions + # APPLE can be enabled, if the hack in src/support/tests/dummy_functions.cp + # which requires multiple definitions is resolved. (Georg) + add_subdirectory(tests) +endif()