GNOME Bugzilla – Bug 752604
gst-plugins-ugly compile error use Dockerfile: variable 'vsize' set but not used [-Werror=unused-but-set-variable]
Last modified: 2015-07-21 10:40:57 UTC
Dockerfile as following: FROM ubuntu:14.04.2 MAINTAINER Zhang Ping, dqzhangp@163.com # install required packages RUN apt-get update RUN apt-get install -y git autoconf automake libtool pkg-config autopoint gettext liborc-0.4-dev make libglib2.0-dev flex bison RUN git clone git://anongit.freedesktop.org/gstreamer/gstreamer && \ cd gstreamer && \ git checkout 1.5.2 && \ ./autogen.sh --prefix=/usr --disable-gtk-doc-pdf --disable-gtk-doc --disable-gst-debug && \ make && \ make install RUN apt-get install -y libpango1.0-dev RUN git clone git://anongit.freedesktop.org/gstreamer/gst-plugins-base && \ cd gst-plugins-base && \ git checkout 1.5.2 && \ ./autogen.sh --prefix=/usr --disable-gtk-doc-pdf --disable-gtk-doc --disable-gst-debug && \ make && \ make install RUN git clone git://anongit.freedesktop.org/gstreamer/gst-plugins-good && \ cd gst-plugins-good && \ git checkout 1.5.2 && \ ./autogen.sh --prefix=/usr --disable-gtk-doc-pdf --disable-gtk-doc --disable-gst-debug && \ make && \ make install RUN apt-get install -y libmpeg2-4-dev libmad-ocaml-dev libmp3lame-dev liba52-0.7.4-dev libx264-dev RUN git clone git://anongit.freedesktop.org/gstreamer/gst-plugins-ugly && \ cd gst-plugins-ugly && \ git checkout 1.5.2 && \ ./autogen.sh --prefix=/usr --disable-gtk-doc-pdf --disable-gtk-doc && \ make && \ make install docker build output: make[3]: Entering directory `/gst-plugins-ugly/gst/asfdemux' CC libgstasf_la-gstasfdemux.lo gstasfdemux.c: In function 'gst_asf_demux_parse_stream_object': gstasfdemux.c:2798:59: error: variable 'silence_data' set but not used [-Werror=unused-but-set-variable] guint span, packet_size, chunk_size, data_size, silence_data; ^ gstasfdemux.c:2863:15: error: variable 'vsize' set but not used [-Werror=unused-but-set-variable] guint16 vsize; ^ gstasfdemux.c:2730:16: error: variable 'time_offset' set but not used [-Werror=unused-but-set-variable] GstClockTime time_offset; ^ gstasfdemux.c: In function 'gst_asf_demux_process_file': gstasfdemux.c:3418:11: error: variable 'packets_count' set but not used [-Werror=unused-but-set-variable] guint64 packets_count, play_time, preroll; ^ gstasfdemux.c: In function 'gst_asf_demux_process_ext_stream_props': gstasfdemux.c:3828:9: error: variable 'obj_size' set but not used [-Werror=unused-but-set-variable] guint obj_size; ^ gstasfdemux.c:3827:11: error: variable 'data_start' set but not used [-Werror=unused-but-set-variable] guint8 *data_start; ^ cc1: all warnings being treated as errors make[3]: *** [libgstasf_la-gstasfdemux.lo] Error 1 make[3]: Leaving directory `/gst-plugins-ugly/gst/asfdemux' make[2]: *** [asfdemux] Error 2 make[2]: Leaving directory `/gst-plugins-ugly/gst' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/gst-plugins-ugly' make: *** [all] Error 2 2015/07/19 18:40:53 The command [/bin/sh -c git clone git://anongit.freedesktop.org/gstreamer/gst-plugins-ugly && cd gst-plugins-ugly && git checkout 1.5.2 && ./autogen.sh --prefix=/usr --disable-gtk-doc-pdf --disable-gtk-doc && make && make install] returned a non-zero code: 2
Created attachment 307701 [details] [review] fix compile errors Can you check if this patch solves the compile error. The variables are being set and used only in logging statements. Hence the error.
> Dockerfile as following: > > FROM ubuntu:14.04.2 > > MAINTAINER Zhang Ping, dqzhangp@163.com > # install required packages > RUN apt-get update > RUN apt-get install -y git autoconf automake libtool pkg-config autopoint > gettext liborc-0.4-dev make libglib2.0-dev flex bison > RUN git clone git://anongit.freedesktop.org/gstreamer/gstreamer && \ > cd gstreamer && \ > git checkout 1.5.2 && \ > ./autogen.sh --prefix=/usr --disable-gtk-doc-pdf --disable-gtk-doc > --disable-gst-debug && \ > make && \ > make install Thanks for the bug report, but if --disable-gst-debug is used, you should also use --disable-fatal-warnings.
Note that this is only needed when building from git, not release tarballs. If someone wants to make a patch that detects GST_DISABLE_GST_DEBUG was used in core and disables fatal_warnings in the modules then, that would be acceptable.