Bug#1012894: apertium: ftbfs with GCC-12
Matthias Klose
doko at debian.org
Thu Jun 16 13:07:36 BST 2022
Package: src:apertium
Version: 3.8.1-2
Severity: normal
Tags: sid bookworm
User: debian-gcc at lists.debian.org
Usertags: ftbfs-gcc-12
[This bug is targeted to the upcoming bookworm release]
Please keep this issue open in the bug tracker for the package it
was filed for. If a fix in another package is required, please
file a bug for the other package (or clone), and add a block in this
package. Please keep the issue open until the package can be built in
a follow-up test rebuild.
The package fails to build in a test rebuild on at least amd64 with
gcc-12/g++-12, but succeeds to build with gcc-11/g++-11. The
severity of this report will be raised before the bookworm release.
The full build log can be found at:
http://qa-logs.debian.net/2022/06/09/gcc12/apertium_3.8.1-2_unstable_gcc12.log
The last lines of the build log are at the end of this report.
To build with GCC 11, either set CC=gcc-11 CXX=g++-11 explicitly,
or install the gcc, g++, gfortran, ... packages from experimental.
apt-get -t=experimental install g++
Common build failures are new warnings resulting in build failures with
-Werror turned on, or new/dropped symbols in Debian symbols files.
For other C/C++ related build failures see the porting guide at
http://gcc.gnu.org/gcc-11/porting_to.html
GCC 11 defaults to the GNU++17 standard. If your package installs
header files in /usr/include, please don't work around C++17 issues
by choosing a lower C++ standard for the package build, but fix these
issues to build with the C++17 standard.
[...]
117 | struct unary_function
| ^~~~~~~~~~~~~~
/bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c -o sentence_stream.lo sentence_stream.cc
libtool: compile: g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c sentence_stream.cc -fPIC -DPIC -o .libs/sentence_stream.o
/bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c -o stream.lo stream.cc
In file included from ../apertium/perceptron_tagger.h:6,
from perceptron_tagger.cc:1:
../apertium/perceptron_spec.h:478:27: warning: ‘template<class _Arg, class _Result> struct std::unary_function’ is deprecated [-Wdeprecated-declarations]
478 | struct In : public std::unary_function<const std::string&, bool> {
| ^~~~~~~~~~~~~~
In file included from /usr/include/c++/12/bits/stl_tree.h:65,
from /usr/include/c++/12/map:60,
from ../apertium/constant_manager.h:21,
from ../apertium/tagger_data.h:20,
from ../apertium/file_tagger.h:20,
from ../apertium/perceptron_tagger.h:4:
/usr/include/c++/12/bits/stl_function.h:117:12: note: declared here
117 | struct unary_function
| ^~~~~~~~~~~~~~
libtool: compile: g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c stream.cc -fPIC -DPIC -o .libs/stream.o
/bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c -o stream_tagger.lo stream_tagger.cc
libtool: compile: g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c stream_tagger.cc -fPIC -DPIC -o .libs/stream_tagger.o
/bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c -o shell_utils.lo shell_utils.cc
libtool: compile: g++ -DHAVE_CONFIG_H -I. -I.. -Wdate-time -D_FORTIFY_SOURCE=2 -I/usr/include/lttoolbox-3.6 -I/usr/include/libxml2 -Wall -Wextra -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -fstack-protector-strong -Wformat -Werror=format-security -std=c++20 -c shell_utils.cc -fPIC -DPIC -o .libs/shell_utils.o
stream.cc: In static member function ‘static void Apertium::Stream::outputLexicalUnit(const Apertium::LexicalUnit&, Apertium::Optional<Apertium::Analysis>, std::ostream&, Apertium::TaggerFlags&)’:
stream.cc:96:24: error: ‘rel_ops’ is not a namespace-name
96 | using namespace std::rel_ops;
| ^~~~~~~
make[3]: *** [Makefile:1497: stream.lo] Error 1
make[3]: *** Waiting for unfinished jobs....
In file included from /usr/include/c++/12/vector:64,
from /usr/include/c++/12/bits/random.h:34,
from /usr/include/c++/12/random:49,
from ../apertium/sentence_stream.h:5,
from sentence_stream.cc:1:
In member function ‘constexpr void std::vector<_Tp, _Alloc>::_M_erase_at_end(pointer) [with _Tp = Apertium::StreamedType; _Alloc = std::allocator<Apertium::StreamedType>]’,
inlined from ‘constexpr void std::vector<_Tp, _Alloc>::clear() [with _Tp = Apertium::StreamedType; _Alloc = std::allocator<Apertium::StreamedType>]’ at /usr/include/c++/12/bits/stl_vector.h:1601:24,
inlined from ‘Apertium::SentenceStream::TrainingCorpus::TrainingCorpus(Apertium::Stream&, Apertium::Stream&, bool, bool)’ at sentence_stream.cc:124:38:
/usr/include/c++/12/bits/stl_vector.h:1930:43: warning: ‘training_sentence’ may be used uninitialized [-Wmaybe-uninitialized]
1930 | if (size_type __n = this->_M_impl._M_finish - __pos)
| ~~~~~~~~~~~~~~^~~~~~~~~
sentence_stream.cc: In constructor ‘Apertium::SentenceStream::TrainingCorpus::TrainingCorpus(Apertium::Stream&, Apertium::Stream&, bool, bool)’:
sentence_stream.cc:91:21: note: ‘training_sentence’ was declared here
91 | TrainingSentence *training_sentence;
| ^~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12/bits/unique_ptr.h:41,
from /usr/include/c++/12/memory:76,
from /usr/include/unicode/localpointer.h:45,
from /usr/include/unicode/uenum.h:25,
from /usr/include/unicode/ucnv.h:52,
from /usr/include/unicode/ustdio.h:31,
from /usr/include/lttoolbox-3.6/lttoolbox/ustring.h:21,
from ../apertium/constant_manager.h:23:
In member function ‘std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(long unsigned int) [with _CharT = char; _Traits = std::char_traits<char>]’,
inlined from ‘virtual void Apertium::PerceptronTagger::train(Apertium::Stream&, Apertium::Stream&, int)’ at perceptron_tagger.cc:263:42:
/usr/include/c++/12/ostream:171:25: warning: ‘avail_skipped’ may be used uninitialized [-Wmaybe-uninitialized]
171 | { return _M_insert(__n); }
| ~~~~~~~~~^~~~~
perceptron_tagger.cc: In member function ‘virtual void Apertium::PerceptronTagger::train(Apertium::Stream&, Apertium::Stream&, int)’:
perceptron_tagger.cc:249:10: note: ‘avail_skipped’ was declared here
249 | size_t avail_skipped;
| ^~~~~~~~~~~~~
make[3]: Leaving directory '/<<PKGBUILDDIR>>/apertium'
make[2]: *** [Makefile:1001: all] Error 2
make[2]: Leaving directory '/<<PKGBUILDDIR>>/apertium'
make[1]: *** [Makefile:493: all-recursive] Error 1
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
dh_auto_build: error: make -j8 returned exit code 2
make: *** [debian/rules:13: binary] Error 25
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
More information about the debian-science-maintainers
mailing list