X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ftests%2FCMakeLists.txt;h=c498b289f267dd47cc56af4780f807cb54e173c8;hb=a9409b47851e57afb2a9c1b1262e60c6963d9dc4;hp=3393b1849e764687ff37e8d1cc3c2887916d857c;hpb=c8e325afec1a8e352ae3760acf502986fc659f07;p=lyx.git diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt index 3393b1849e..c498b289f2 100644 --- a/src/tests/CMakeLists.txt +++ b/src/tests/CMakeLists.txt @@ -4,33 +4,36 @@ # Copyright (c) 2013 Kornel Benko kornel@lyx.org # -set(check_Layout_SOURCES) +set(check_layout_SOURCES) foreach(_f insets/InsetLayout.cpp Color.cpp Counters.cpp Floating.cpp FloatList.cpp FontInfo.cpp Layout.cpp LayoutFile.cpp Lexer.cpp - ModuleList.cpp Spacing.cpp TextClass.cpp tests/check_Layout.cpp + ModuleList.cpp Spacing.cpp TextClass.cpp tests/check_layout.cpp support/tests/boost.cpp support/tests/dummy_functions.cpp) - list(APPEND check_Layout_SOURCES "${TOP_SRC_DIR}/src/${_f}") + list(APPEND check_layout_SOURCES "${TOP_SRC_DIR}/src/${_f}") endforeach() add_definitions(-DNO_LAYOUT_CSS) -add_executable(check_Layout ${check_Layout_SOURCES}) +add_executable(check_layout ${check_layout_SOURCES}) if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--allow-multiple-definition") -elseif(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") +elseif(MSVC) set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /FORCE:MULTIPLE") else() - message(STATUS "Allow multiple definitions for cxx-compiler ${CMAKE_CXX_COMPILER_ID} not handled") -endif() + message(STATUS "Allow multiple definitions for cxx-compiler ${CMAKE_CXX_COMPILER_ID} not handled") + endif() -target_link_libraries(check_Layout support ${QT_QTMAIN_LIBRARY}) -add_dependencies(lyx_run_tests check_Layout) +target_link_libraries(check_layout support ${intl_link} + ${Lyx_Boost_Libraries} ${QT_QTGUI_LIBRARY} ${QT_QTCORE_LIBRARY} + ${ZLIB_LIBRARY} ${ICONV_LIBRARY}) +add_dependencies(lyx_run_tests check_layout) +set_target_properties(check_layout PROPERTIES FOLDER "tests/src") file(GLOB layout_files RELATIVE "${TOP_SRC_DIR}/lib/layouts" "${TOP_SRC_DIR}/lib/layouts/*.layout") list(SORT layout_files) foreach(bns ${layout_files}) string(REPLACE ".layout" "" bn ${bns}) - add_test(NAME "check_Layout/${bns}" - COMMAND check_Layout "${TOP_SRC_DIR}/lib/layouts/${bn}") + add_test(NAME "check_layout/${bns}" + COMMAND check_layout "${TOP_SRC_DIR}/lib/layouts/${bn}") endforeach()