Bug#455184: FTBFS with GCC 4.3: missing #includes

Martin Michlmayr tbm at cyrius.com
Sun Dec 9 07:11:20 UTC 2007


Package: libebml
Version: 0.7.7-3
Usertags: ftbfs-gcc-4.3

Your package fails to build with GCC 4.3.  Version 4.3 has not been
released yet but I'm building with a snapshot in order to find errors
and give people an advance warning.  In GCC 4.3, the C++ header
dependencies have been cleaned up.  The advantage of this is that
programs will compile faster.  The downside is that you actually
need to directly #include everything you use (but you really should
do this anyway, otherwise your program won't work with any compiler
other than GCC).  There's some more information about this at
http://www.cyrius.com/journal/2007/05/10#gcc-4.3-include

You can reproduce this problem with gcc-snapshot from unstable.  Note
that Red Hat, Novell and Ubuntu have done some work getting packages
to build with GCC 4.3 so there might be patches floating around
somewhere.  I suggest you talk to your upstream.

> Automatic build of libebml_0.7.7-3 on em64t by sbuild/amd64 0.53
...
> /usr/bin/make -C make/linux CUSTOMFLAGS="-O2"
> make[1]: Entering directory `/build/tbm/libebml-0.7.7/make/linux'
> g++ -c -Wall -Wno-unknown-pragmas -ansi -fno-gnu-keywords -Wshadow -O2   -I/build/tbm/libebml-0.7.7/make/linux/../.. -o /build/tbm/libebml-0.7.7/make/linux/../../src/Debug.o /build/tbm/libebml-0.7.7/make/linux/../../src/Debug.cpp
> g++ -c -Wall -Wno-unknown-pragmas -ansi -fno-gnu-keywords -Wshadow -O2   -I/build/tbm/libebml-0.7.7/make/linux/../.. -o /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.o /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp
> In file included from /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_algo.h:66,
>                  from /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/algorithm:67,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlEndian.h:41,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlTypes.h:42,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlBinary.h:42,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp:39:
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/algorithmfwd.h:259:41: error: macro "min" passed 3 arguments, but takes just 2

Not sure about that, I'd just ignore for now.

> In file included from /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_algo.h:66,
>                  from /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/algorithm:67,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlEndian.h:41,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlTypes.h:42,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlBinary.h:42,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp:39:
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/algorithmfwd.h:255: error: expected unqualified-id before 'const'
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/algorithmfwd.h:255: error: expected `)' before 'const'
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/algorithmfwd.h:255: error: expected `)' before 'const'
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/algorithmfwd.h:255: error: expected initializer before 'const'
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/algorithmfwd.h:259: error: template declaration of 'const _Tp& std::min'

I didn't check these.

> In file included from /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/algorithm:67,

>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlEndian.h:41,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlTypes.h:42,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlBinary.h:42,
>                  from /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp:39:
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_algo.h: In function 'void std::__merge_sort_loop(_RandomAccessIterator1, _RandomAccessIterator1, _RandomAccessIterator2, _Distance)':
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_algo.h:3042: error: expected unqualified-id before '(' token
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_algo.h: In function 'void std::__merge_sort_loop(_RandomAccessIterator1, _RandomAccessIterator1, _RandomAccessIterator2, _Distance, _Compare)':
> /usr/lib/gcc-snapshot/lib/gcc/x86_64-linux-gnu/4.3.0/../../../../include/c++/4.3.0/bits/stl_algo.h:3066: error: expected unqualified-id before '(' token
> In file included from /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp:39:
> /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlBinary.h: In member function 'void libebml::EbmlBinary::CopyBuffer(const binary*, uint32)':
> /build/tbm/libebml-0.7.7/make/linux/../../ebml/EbmlBinary.h:81: error: 'memcpy' was not declared in this scope
> /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp: In copy constructor 'libebml::EbmlBinary::EbmlBinary(const libebml::EbmlBinary&)':
> /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp:55: error: 'memcpy' was not declared in this scope
> /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp: In member function 'bool libebml::EbmlBinary::operator==(const libebml::EbmlBinary&) const':
> /build/tbm/libebml-0.7.7/make/linux/../../src/EbmlBinary.cpp:98: error: 'memcmp' was not declared in this scope

These are definitely bugs in your program.

-- 
Martin Michlmayr
http://www.cyrius.com/





More information about the pkg-multimedia-maintainers mailing list