From e754d0931ca75403647cc16100edd98e7e5ceadb Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Tue, 5 Dec 2017 10:21:53 +0100 Subject: Remove CXXFLAGS_CXX11 from Clang plugin compilation CXXFLAGS_CXX11 is for the compiler used to compile LO proper. The plugin needs to be compiled in a way compatible with compiling Clang, and the compiler and any relevant flags can be controlled with COMPILER_PLUGINS_CXX. (And at least on macOS when compiling LO against a locally-built recent Clang trunk, CXXFLAGS_CXX11 will now contain -std=gnu++17, but COMPILER_PLUGINS_CXX can still point at Apple's Xcode clang++, which does not understand -std=gnu++17.) Also, if COMPILER_PLUGINS_CXX is not set, simply default it to g++ instead of trying to construct an acceptable CLANGCXX value from CXX (which would be Clang). (The problem with using Clang without CXXFLAGS_CXX11 is that Clang, unlike GCC, typically defaults to C++03, but building compilerplugins requires C++11 at least. That would cause e.g. the Gerrit/Jenkins linux_clang_dbgutil_64 builds to fail---but which also needs COMPILER_PLUGINS_CXX to be explicitly set to "g++ -std=c++11" as GCC on those machines is still 4.8.5 defaulting to C++03.) Change-Id: Id4ee4e54fa871cb6e621069cd050ae5b31922b34 Reviewed-on: https://gerrit.libreoffice.org/45856 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- distro-configs/Jenkins/linux_clang_dbgutil_64 | 1 + 1 file changed, 1 insertion(+) (limited to 'distro-configs/Jenkins') diff --git a/distro-configs/Jenkins/linux_clang_dbgutil_64 b/distro-configs/Jenkins/linux_clang_dbgutil_64 index 61c274af4caf..9865be076515 100644 --- a/distro-configs/Jenkins/linux_clang_dbgutil_64 +++ b/distro-configs/Jenkins/linux_clang_dbgutil_64 @@ -1,2 +1,3 @@ --enable-dbgutil --enable-compiler-plugins +COMPILER_PLUGINS_CXX=g++ -std=c++11 -- cgit