Opened 8 years ago

Last modified 8 years ago

#2354 new defect

Fails to build with GCC 6: with GCC 6: no match for 'operator<<'

Reported by: Bas Couwenberg Owned by: potts@…
Priority: highest Milestone: OSSIM 2.0
Component: Algorithms/Functionality Version: OSSIM Roadmap
Severity: blocker Keywords:
Cc:

Description

As reported by Martin Michlmayr in Debian Bug #811851:

This package fails to build with GCC 6. GCC 6 has not been released yet, but it's expected that GCC 6 will become the default compiler for stretch.

Note that only the first error is reported; there might be more. You can find a snapshot of GCC 6 in experimental. To build with GCC 6, you can set CC=gcc-6 CXX=g++-6 explicitly.

You may be able to find out more about this issue at https://gcc.gnu.org/gcc-6/changes.html

sbuild (Debian sbuild) 0.67.0 (26 Dec 2015) on dl580gen9-02.hlinux
...
cd /<<BUILDDIR>>/ossim-1.8.20.3+ds/debian/build/src/ossim && /usr/bin/c++   -DOSSIMMAKINGDLL -Dossim_EXPORTS -I/<<BUILDDIR>>/ossim-1.8.20.3+ds/ossim/include -I/<<BUILDDIR>>/ossim-1.8.20.3+ds/debian/build/include -I/usr/include/geos -I/usr/include/geotiff -I/usr/include/x86_64-linux-gnu -I/usr/include/freetype2  -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2  -O3 -DNDEBUG -fPIC    -o CMakeFiles/ossim.dir/font/ossimFont.cpp.o -c /<<BUILDDIR>>/ossim-1.8.20.3+ds/ossim/src/ossim/font/ossimFont.cpp
/<<BUILDDIR>>/ossim-1.8.20.3+ds/ossim/src/ossim/elevation/ossimElevManager.cpp: In member function 'virtual std::ostream& ossimElevManager::print(std::ostream&) const':
/<<BUILDDIR>>/ossim-1.8.20.3+ds/ossim/src/ossim/elevation/ossimElevManager.cpp:650:52: error: no match for 'operator<<' (operand types are 'std::basic_ostream<char>' and 'std::ostream {aka std::basic_ostream<char>}')
          out<<"m_dbRoundRobin["<<i<<"]["<<j<<"] = "<<m_dbRoundRobin[i][j]->print(out)<<endl;
          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Attachments (1)

fix-ossim-trac-2354.diff (2.1 KB ) - added by rashadkm 8 years ago.

Download all attachments as: .zip

Change History (9)

comment:1 by rashadkm, 8 years ago

Milestone: OMAR Dec 2012
Version: ossim/OMAR 1.8.14-3

Bas,

is there a chroot in debian where I can get the same environment with gcc 6 ?

comment:2 by Bas Couwenberg, 8 years ago

You can setup an Debian unstable VM and add the experimental repository.

Or you can create an experimental cowbuilder chroot which creates an unstable chroot with the experimental repository in addition to sid.

comment:3 by rashadkm, 8 years ago

Component: OtherAlgorithms/Functionality
Milestone: OMAR Dec 2012OSSIM 2.0
Owner: changed from kmelero to potts@…
Version: ossim/OMAR 1.8.14-3OSSIM Roadmap

attached patch fixed the compilation for me. I had tested ossim-info after build and it worked fine.

comment:4 by Bas Couwenberg, 8 years ago

Thanks for the patch, I've added it to the Debian package to resolve the bugreport.

My apologies for taking this long, this issue had fallen off my radar. Today the Debian bugreport severity was raised to Release Critical bringing it back on the radar.

comment:5 by rashadkm, 8 years ago

Hello Bas,

No problem. the trac notification does not work for me too. there is a better fix in ossim dev branch

If had tested this and it works. If you need i can update the patch if not too late for inclusion

comment:6 by Bas Couwenberg, 8 years ago

If there is a better patch that can be backported to 1.8.20, I'm happy to replace the fix-ossim-trac-2354.diff patch in the ossim Debian package.

Which commit(s) are you referring to?

Last edited 8 years ago by Bas Couwenberg (previous) (diff)

by rashadkm, 8 years ago

Attachment: fix-ossim-trac-2354.diff added

comment:8 by Bas Couwenberg, 8 years ago

Thanks for the updated patch, I've updated the ossim Debian package to accordingly, see:

https://anonscm.debian.org/cgit/pkg-grass/ossim.git/commit/?id=5415e7729e332e4c9e436b0daf93a9f157967629

Note: See TracTickets for help on using tickets.