From 9ef91ecec68d38ff4e0428a213d2036b3d99f898 Mon Sep 17 00:00:00 2001 From: Neil Date: Sat, 31 Mar 2018 12:20:00 +1100 Subject: Make clang 6.0 build without warnings. Requires clang to be on the path now. --- win32/makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/win32/makefile b/win32/makefile index 86c7e6792..183c732b5 100644 --- a/win32/makefile +++ b/win32/makefile @@ -13,8 +13,11 @@ LEXCOMPONENT = $(DIR_BIN)/SciLexer.dll LIBSCI = $(DIR_BIN)/libscintilla.a ifdef CLANG -# Common location for 32-bit clang on Windows -CXX = "C:\Program Files (x86)\LLVM\bin\clang++" +CXX = clang++ +# Clang doesn't like omitting braces in array initialization but they just add noise, +# __uuidof is a Microsoft extension but makes COM code neater, +# public visibility avoids warnings like 'locally defined symbol __std_terminate imported' +CLANG_OPTS = -Wno-missing-braces -Wno-language-extension-token -Xclang -flto-visibility-public-std else # MinGW GCC LDMINGW = -Wl,--enable-runtime-pseudo-reloc-v2 -Wl,--add-stdcall-alias @@ -50,7 +53,7 @@ ifdef ENABLE_BIDIRECTIONAL BIDIFLAGS=-DENABLE_BIDIRECTIONAL endif -CXXBASEFLAGS=--std=$(CXXSTD) -Wall -pedantic $(INCLUDEDIRS) $(D2DFLAGS) $(BIDIFLAGS) -D_CRT_SECURE_NO_DEPRECATE=1 +CXXBASEFLAGS=--std=$(CXXSTD) -Wall -pedantic $(INCLUDEDIRS) $(D2DFLAGS) $(BIDIFLAGS) -D_CRT_SECURE_NO_DEPRECATE=1 $(CLANG_OPTS) ifdef NO_CXX11_REGEX REFLAGS=-DNO_CXX11_REGEX -- cgit v1.2.3