diff mbox

[FFmpeg-devel] configure: Use -Wno-gnu-variable-sized-type-not-at-end with clang

Message ID CAB0OVGpuVJw1gf9ZNRi8RXVoFMZ-jewgBYxZOsXtaqjZgZ_=YQ@mail.gmail.com
State Superseded
Headers show

Commit Message

Carl Eugen Hoyos March 27, 2019, 2:18 p.m. UTC
Hi!

Attached patch fixes many warnings when compiling vaapi with clang.
Also tested with clang-3.4.

Please comment, Carl Eugen

Comments

Carl Eugen Hoyos March 27, 2019, 11:53 p.m. UTC | #1
2019-03-27 15:18 GMT+01:00, Carl Eugen Hoyos <ceffmpeg@gmail.com>:

> Attached patch fixes many warnings when compiling vaapi with clang.
> Also tested with clang-3.4.

Will push if there are no comments.

Carl Eugen
diff mbox

Patch

From 0df0773aaf6fa3b920ad078c534f4e1b4e203413 Mon Sep 17 00:00:00 2001
From: Carl Eugen Hoyos <ceffmpeg@gmail.com>
Date: Wed, 27 Mar 2019 15:15:54 +0100
Subject: [PATCH] configure: Use -Wno-gnu-variable-sized-type-not-at-end with
 clang.

Fixes many warnings like the following:
libavcodec/vaapi_encode.h:253:34: warning: field 'misc' with variable sized type 'VAEncMiscParameterBuffer'
      (aka 'struct _VAEncMiscParameterBuffer') not at the end of a struct or class is a GNU extension
      [-Wgnu-variable-sized-type-not-at-end]
        VAEncMiscParameterBuffer misc;
                                 ^
---
 configure |    1 +
 1 file changed, 1 insertion(+)

diff --git a/configure b/configure
index 331393f..867bb21 100755
--- a/configure
+++ b/configure
@@ -6760,6 +6760,7 @@  elif enabled clang; then
     check_cflags -Werror=implicit-function-declaration
     check_cflags -Werror=missing-prototypes
     check_cflags -Werror=return-type
+    check_cflags -Wno-gnu-variable-sized-type-not-at-end
 elif enabled cparser; then
     add_cflags -Wno-missing-variable-declarations
     add_cflags -Wno-empty-statement
-- 
1.7.10.4