From 29666f1d91b8922e27be6f446b5505a18ea76c0d Mon Sep 17 00:00:00 2001 From: Maarten Bent Date: Sat, 1 Dec 2018 13:44:32 +0100 Subject: [PATCH] CMake: Fix wxscintilla with precompiled headers and clang The problem also occurs on Linux. --- build/cmake/lib/stc/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/cmake/lib/stc/CMakeLists.txt b/build/cmake/lib/stc/CMakeLists.txt index 27af21bb79..8def395466 100644 --- a/build/cmake/lib/stc/CMakeLists.txt +++ b/build/cmake/lib/stc/CMakeLists.txt @@ -167,10 +167,10 @@ target_compile_definitions(wxscintilla PUBLIC if(wxBUILD_PRECOMP) # The auto-generated header causes undefined members and identifiers in the - # standard c++ headers when using clang on macOS or Windows. + # standard c++ headers when using clang. # Do not disable precompiled headers entirely but use the main Scintilla # header as prefix header so there is at least a small speedup. - if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" AND (APPLE OR WIN32)) + if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") set(wxSCINTILLA_PREC_HEADER "${wxSOURCE_DIR}/src/stc/scintilla/include/Scintilla.h") endif() wx_target_enable_precomp(wxscintilla ${wxSCINTILLA_PREC_HEADER})