[vlc-devel] [PATCH] configure: Prevent clang from accepting unknown compile flags

Rémi Denis-Courmont remi at remlab.net
Wed Sep 6 11:27:52 CEST 2017


Le 6 septembre 2017 12:13:27 GMT+03:00, "Hugo Beauzée-Luyssen" <hugo at beauzee.fr> a écrit :
>---
> configure.ac | 4 ++++
> 1 file changed, 4 insertions(+)
>
>diff --git a/configure.ac b/configure.ac
>index 9c07e2afc0..2b1885e242 100644
>--- a/configure.ac
>+++ b/configure.ac
>@@ -929,6 +929,10 @@ dnl
> dnl  Compiler warnings
> dnl
> 
>+dnl Prevent clang from accepting unknown flags with a mere warning
>+AX_APPEND_COMPILE_FLAGS([-Werror=unknown-warning-option], [CFLAGS])
>+AX_APPEND_COMPILE_FLAGS([-Werror=unknown-warning-option], [CXXFLAGS])
>+
>AX_APPEND_COMPILE_FLAGS([-Wall -Wextra -Wsign-compare -Wundef
>-Wpointer-arith -Wvolatile-register-var -Wformat -Wformat-security],
>[CFLAGS])
>AX_APPEND_COMPILE_FLAGS([-Wall -Wextra -Wsign-compare -Wundef
>-Wpointer-arith -Wvolatile-register-var -Wformat -Wformat-security],
>[CXXFLAGS])
> 
>-- 
>2.11.0
>
>_______________________________________________
>vlc-devel mailing list
>To unsubscribe or modify your subscription options:
>https://mailman.videolan.org/listinfo/vlc-devel

No objection. This won't work if C*FLAGS contains an unsupported flag from the beginning though.
-- 
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.


More information about the vlc-devel mailing list