[PATCH] D57757: [scudo][standalone] Do not error out on spurious C(XX) flags
Kostya Kortchinsky via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 5 08:19:30 PST 2019
cryptoad created this revision.
cryptoad added reviewers: eugenis, vitalybuka, Eugene.Zelenko.
Herald added subscribers: Sanitizers, delcypher, mgorny.
Herald added projects: LLVM, Sanitizers.
The standalone Scudo version is being built with `-Werror` which can be
tripped by extraneous command line arguments. We have little control over
those as they can be passed down to us by `CMAKE_C(XX)_FLAGS`, the reported
scenario involving `-stdlib=libc++` (see https://reviews.llvm.org/D57412#1384504).
To work around this, disable `-Wunused-command-line-argument`.
Repository:
rCRT Compiler Runtime
https://reviews.llvm.org/D57757
Files:
lib/scudo/standalone/CMakeLists.txt
Index: lib/scudo/standalone/CMakeLists.txt
===================================================================
--- lib/scudo/standalone/CMakeLists.txt
+++ lib/scudo/standalone/CMakeLists.txt
@@ -9,6 +9,10 @@
-Werror
-nostdinc++)
+# Do not error out on spurious flags. They can be passed via CMAKE_CXX_FLAGS
+# for example, so we have very little control on those.
+list(APPEND SCUDO_CFLAGS -Wno-unused-command-line-argument)
+
append_list_if(COMPILER_RT_HAS_FFREESTANDING_FLAG -ffreestanding SCUDO_CFLAGS)
append_list_if(COMPILER_RT_HAS_FVISIBILITY_HIDDEN_FLAG -fvisibility=hidden SCUDO_CFLAGS)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D57757.185315.patch
Type: text/x-patch
Size: 607 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190205/ac851131/attachment.bin>
More information about the llvm-commits
mailing list