public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/58012] New: Gcc bootstrap failed with cloog-isl: undefined reference to std::istream::ignore(long)
@ 2013-07-28 16:17 goughost at yahoo dot com.cn
  2013-07-29 13:00 ` [Bug tree-optimization/58012] " goughost at yahoo dot com.cn
  0 siblings, 1 reply; 2+ messages in thread
From: goughost at yahoo dot com.cn @ 2013-07-28 16:17 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58012

            Bug ID: 58012
           Summary: Gcc bootstrap failed with cloog-isl: undefined
                    reference to std::istream::ignore(long)
           Product: gcc
           Version: 4.8.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: goughost at yahoo dot com.cn

../gcc-4.8.1/libstdc++-v3/src/c++98/istream.cc:116: error: undefined reference
to 'std::istream::ignore(long)'
../gcc-4.8.1/libstdc++-v3/src/c++98/istream.cc:521: error: undefined reference
to 'std::basic_istream<wchar_t, std::char_traits<wchar_t> >::ignore(long)'

Build failed with system cloog/isl (version 0.18.0 and 0.11.1), when making cc1
in ./gcc/ in stage2. Without cloog/isl, build is ok.

It's configured this way:
../gcc-4.8.1/configure --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu
--prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin
--sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include
--libdir=/usr/lib --libexecdir=/usr/libexec --localstatedir=/var
--sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info
--enable-lto --disable-multilib --enable-shared --disable-static
--enable-__cxa_atexit --enable-threads=posix --enable-languages=c,c++,fortran
--enable-plugin --with-system-zlib

When making cc1, `-static-libstdc++' is passed to bootstrap compiler, and
`libstdc++.a' (a copy of `libstdc++convenience.a') is used.
On the other hand, `libstdc++convenience.a' is an incomplete library. At least
`std::istream::ignore(long)' (in compatibility.cc) is not included.
Without cloog/isl, linking succeeds, since no linked object refers to istream.

With cloog/isl, graphite*.c files includes isl headers. In <isl/int.h>, there
is a function: `std::ostream &operator<<(std::ostream &os, isl_int i)'. Remove
this function definition, recompile graphite*.c, and link: succeed.

I'm not sure whether this is a bug in Gcc or there's something wrong with my
compile environment.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug tree-optimization/58012] Gcc bootstrap failed with cloog-isl: undefined reference to std::istream::ignore(long)
  2013-07-28 16:17 [Bug tree-optimization/58012] New: Gcc bootstrap failed with cloog-isl: undefined reference to std::istream::ignore(long) goughost at yahoo dot com.cn
@ 2013-07-29 13:00 ` goughost at yahoo dot com.cn
  0 siblings, 0 replies; 2+ messages in thread
From: goughost at yahoo dot com.cn @ 2013-07-29 13:00 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58012

goughost <goughost at yahoo dot com.cn> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |WORKSFORME

--- Comment #1 from goughost <goughost at yahoo dot com.cn> ---
It's not the function definition, but `#include <iostream>' that caused the
error. Either isl should get patched to `#include <ostream>'; or gcc provide a
bigger libstdc++convenience.a that has the missing bits. The previous is
easier, as long as only std::ostream is used in that header.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-07-29 13:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-28 16:17 [Bug tree-optimization/58012] New: Gcc bootstrap failed with cloog-isl: undefined reference to std::istream::ignore(long) goughost at yahoo dot com.cn
2013-07-29 13:00 ` [Bug tree-optimization/58012] " goughost at yahoo dot com.cn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).