Revert "Objective-C compililation support with cmake and C++11"

This reverts commit c2e67a41ce.
This commit is contained in:
Benjamin Piwowarski 2014-04-22 09:36:17 +02:00
parent a4ea543f2f
commit d863088986
5 changed files with 4 additions and 13 deletions

View File

@ -204,8 +204,7 @@ else()
endif()
# Variable that hold the flags that should only be used with C++ files
set(LYX_CXX_SPECIFIC_FLAGS)
set(LYX_GCC11_MODE)
if(UNIX OR MINGW)
execute_process(COMMAND ${CMAKE_CXX_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION)
message(STATUS "Using GCC version ${GCC_VERSION}")
@ -220,7 +219,7 @@ if(UNIX OR MINGW)
if(NOT CXX11COMPILER_FOUND)
message(FATAL_ERROR "A C++11 compatible compiler is required.")
endif()
set(LYX_CXX_SPECIFIC_FLAGS "${LYX_CXX_SPECIFIC_FLAGS} ${CXX11_FLAG}")
set(LYX_GCC11_MODE "${CXX11_FLAG}")
endif()
else()
if(MSVC10)
@ -484,7 +483,7 @@ if(NOT MSVC)
if(NOT LYX_QUIET)
set(CMAKE_VERBOSE_MAKEFILE ON)
endif()
set(LYX_CXX_FLAGS "-Wall -Wunused-parameter")
set(LYX_CXX_FLAGS "-Wall -Wunused-parameter ${LYX_GCC11_MODE}")
if(LYX_STDLIB_DEBUG)
set(LYX_CXX_FLAGS "${LYX_CXX_FLAGS} -D_GLIBCXX_DEBUG -D_GLIBCXX_DEBUG_PEDANTIC")
endif()

View File

@ -4,6 +4,5 @@
# Copyright (c) 2006-2011 Peter Kümmel, <syntheticpp@gmx.net>
#
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${LYX_CXX_SPECIFIC_FLAGS}")
add_subdirectory(libs)

View File

@ -11,15 +11,11 @@ include_directories(${TOP_SRC_DIR}/src)
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
set_property(GLOBAL PROPERTY PREDEFINED_TARGETS_FOLDER "CMakeTargets")
# support is the only directory containing objective-c files...
add_subdirectory(support)
# ...so we can add all the c++ specific flags after
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${LYX_CXX_SPECIFIC_FLAGS}")
add_subdirectory(frontends)
add_subdirectory(graphics)
add_subdirectory(insets)
add_subdirectory(mathed)
add_subdirectory(support)
add_subdirectory(tex2lyx)
if (UNIX)
add_subdirectory(client)

View File

@ -22,7 +22,6 @@ file(GLOB support_mythes_headers ${TOP_SRC_DIR}/src/support/mythes/*.hxx)
file(GLOB support_linkback_sources ${TOP_SRC_DIR}/src/support/linkback/*.m*)
file(GLOB support_linkback_headers ${TOP_SRC_DIR}/src/support/linkback/*.h)
set_source_files_properties(${support_sources} ${support_mythes_sources} PROPERTIES COMPILE_FLAGS "${LYX_CXX_SPECIFIC_FLAGS}")
list(REMOVE_ITEM support_sources
${TOP_SRC_DIR}/src/support/os_win32.cpp
${TOP_SRC_DIR}/src/support/os_unix.cpp

View File

@ -6,8 +6,6 @@
project(supporttest)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${LYX_CXX_SPECIFIC_FLAGS}")
macro(sources _program)
set(_tmplist)
foreach(_tmp ${ARGN})