[Buildd-tools-devel] Bug#379478: [schroot]: FTBFS: error: no match for ‘operator!=’ in ‘pos != std::vector

Jens Seidel jensseidel at users.sf.net
Sun Jul 23 20:52:19 UTC 2006


Package: schroot
Version: 0.99.4-1
Severity: important
Tags: patch

Hi,

I get the following error if I try to compile schroot using g++ 4.0.4:

if i486-linux-gnu-g++ -DGETTEXT_PACKAGE=\"schroot\" -DLOCALEDIR=\"/usr/share/locale\" -D_GNU_SOURCE -I. -I../../../schroot -I.. -I../sbuild    -I../../..  -pedantic -Wall -Wcast-align -Wwrite-strings -Wswitch-default -Wcast-qual -Wunused-variable -Wredundant-decls -Wctor-dtor-privacy -Wnon-virtual-dtor -Wreorder -Wold-style-cast -Woverloaded-virtual -fstrict-aliasing -g -O2 -MT schroot-listmounts-main.o -MD -MP -MF ".deps/schroot-listmounts-main.Tpo" -c -o schroot-listmounts-main.o ../../../schroot/schroot-listmounts-main.cc; \
        then mv -f ".deps/schroot-listmounts-main.Tpo" ".deps/schroot-listmounts-main.Po"; else rm -f ".deps/schroot-listmounts-main.Tpo"; exit 1; fi
../../../schroot/schroot-listmounts-main.cc: In member function ‘virtual void schroot_listmounts::main::action_listmounts()’:
../../../schroot/schroot-listmounts-main.cc:124: error: no match for ‘operator!=’ in ‘pos != std::vector<_Tp, _Alloc>::rend() [with _Tp = std::basic_string<char, std::char_traits<char>, std::allocator<char> >, _Alloc = std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >]()’
make[4]: *** [schroot-listmounts-main.o] Fehler 1
make[4]: Leaving directory `/tmp/schroot-0.99.4/debian/build/schroot'
make[3]: *** [all-recursive] Fehler 1
make[3]: Leaving directory `/tmp/schroot-0.99.4/debian/build/schroot'
make[2]: *** [all-recursive] Fehler 1
make[2]: Leaving directory `/tmp/schroot-0.99.4/debian/build'
make[1]: *** [all] Fehler 2
make[1]: Leaving directory `/tmp/schroot-0.99.4/debian/build'
make: *** [build-stamp] Fehler 2

The following patch fixes it:
diff -ur schroot-0.99.4/schroot/schroot-listmounts-main.cc schroot-0.99.4.new/schroot/schroot-listmounts-main.cc

--- schroot-0.99.4/schroot/schroot-listmounts-main.cc   2006-07-20 16:00:38.000000000 +0200
+++ schroot-0.99.4.new/schroot/schroot-listmounts-main.cc       2006-07-23 18:14:33.000000000 +0200
@@ -117,7 +117,7 @@
 main::action_listmounts ()
 {
   // Check mounts.
-  sbuild::string_list mounts =
+  const sbuild::string_list mounts =
     list_mounts("/proc/mounts");
 
   for (sbuild::string_list::const_reverse_iterator pos = mounts.rbegin();

Jens




More information about the Buildd-tools-devel mailing list