[FFmpeg-devel] [PATCH v3] lavd/decklink_common: Fix error caused by -Werror=missing-prototypes
Michael Niedermayer
michael at niedermayer.cc
Mon Jun 27 14:36:28 CEST 2016
On Mon, Jun 27, 2016 at 07:59:00AM -0400, Richard Kern wrote:
>
> > On Jun 27, 2016, at 4:58 AM, Michael Niedermayer <michael at niedermayer.cc> wrote:
> >
> > On Sun, Jun 26, 2016 at 08:24:49PM -0400, Rick Kern wrote:
> >> decklink_common.cpp includes a .cpp file from the DeckLink API which fails
> >> to build because there are non-static functions in the included .cpp file.
> >> This disables the missing-prototypes error so the file can be included.
> >>
> >> Signed-off-by: Rick Kern <kernrj at gmail.com>
> >> ---
> >> libavdevice/Makefile | 2 ++
> >> 1 file changed, 2 insertions(+)
> >>
> >> diff --git a/libavdevice/Makefile b/libavdevice/Makefile
> >> index 585827b..e281825 100644
> >> --- a/libavdevice/Makefile
> >> +++ b/libavdevice/Makefile
> >> @@ -19,6 +19,8 @@ OBJS-$(CONFIG_BKTR_INDEV) += bktr.o
> >> OBJS-$(CONFIG_CACA_OUTDEV) += caca.o
> >> OBJS-$(CONFIG_DECKLINK_OUTDEV) += decklink_enc.o decklink_enc_c.o decklink_common.o
> >> OBJS-$(CONFIG_DECKLINK_INDEV) += decklink_dec.o decklink_dec_c.o decklink_common.o
> >
> >> +$(SUBDIR)decklink_common.o: CXXFLAGS += -Wno-error=missing-prototypes
> >
> > Is this portable ?
> > is there some posix document or similar that says that this
> > is supported by all compilers ?
>
> configure adds the -Werror=missing-prototypes only if it’s supported by the compiler. Instead, I could add -Wno-error=… to CFLAGS only if it’s supported.
if you wish to support these files as non system headers and noone
is against it then thats an option
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Never trust a computer, one day, it may think you are the virus. -- Compn
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20160627/87cda3bf/attachment.sig>
More information about the ffmpeg-devel
mailing list