This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: trouble compiling the new Standard C++ Library V3


"Kuijk van, David" <David@lcn.nl> writes:

| Hi
| 
| I have trouble compiling the new Standard C++ Library V3.
| 
| I use Cygwin B20 under Windows NT Service Pack 4, with Mumit Khan's
| pre-built gcc-2.95 binary packages.
| 
| The first thing that goes wrong is executing the generated
| gen-num-limits.exe.

Thanks for your input.

| 
| The exe never returns because of a segmentation fault. This fault has
| something to do with the function "template<typename Operation> bool
| trapping(const Operation& op)" in gen-num-limits.cc, so I changed this
| function so it will always return "true", because that change did not look
| too harmful. 

Well, this problem is known: it's mainly due to an obscure "bug" in
Cygwin's exception handling machinery.  Had you played with trapping() 
further, you would have noticed that division by zero *sometimes*
traps, *sometimes* hangs!  But according to Phil Edwards too often it
hangs, causing trapping() not to return.  

| 
| After that change gen-num-limits.exe returns normally, and limitsMEMBERS.o
| is made.
| 
| But then I get the following errors:
| /bin/sh ../libtool --mode=compile c++ -DHAVE_CONFIG_H -I.
| -I../../libstdc++-2.90
| .6/src -I.. -nostdinc++ -I../../libstdc++-2.90.6
| -I../../libstdc++-2.90.6/stl -I
| ../../libstdc++-2.90.6/libio     -g -D_GNU_SOURCE -fno-implicit-templates
| -c ..
| /../libstdc++-2.90.6/src/complex.cc
| c++ -DHAVE_CONFIG_H -I. -I../../libstdc++-2.90.6/src -I.. -nostdinc++
| -I../../li
| bstdc++-2.90.6 -I../../libstdc++-2.90.6/stl -I../../libstdc++-2.90.6/libio
| -g -D
| _GNU_SOURCE -fno-implicit-templates -c ../../libstdc++-2.90.6/src/complex.cc
| -o
| complex.o
| In file included from ../../libstdc++-2.90.6/src/complex.cc:31:
| ../../libstdc++-2.90.6/bits/std_complex.h: In function `class complex<float>
| con
| j<float>(const complex<float> &)':
| ../../libstdc++-2.90.6/bits/std_complex.h:926: Internal compiler error.
| ../../libstdc++-2.90.6/bits/std_complex.h:926: Please submit a full bug
| report t
| o `egcs-bugs@egcs.cygnus.com'.
| ../../libstdc++-2.90.6/bits/std_complex.h:926: See
| <URL:http://egcs.cygnus.com/f
| aq.html#bugreport> for details.
| make[2]: *** [complex.lo] Error 1
| make[1]: *** [all-recursive] Error 1
| make: *** [all-recursive-am] Error 2
| 
| Please let me know if you need more info to solve these problems.

Mumit Khan and I reported this problem two weeks ago.  I eventually
figure out that the problem lies in gcc/expr.c:expand_assignment()
use of the result of gcc/expr.c:get_inner_reference().  I'm close to
provide a fix...

| 
| I would also appreciate hearing when this problem is solved, because I am
| very anxious to start using this STL-library.

We're working hard to fix these problems.  But you should note that
v-3 is still in development, not yet ready to be used by the large
public.  

gcc-2.95 comes with an integrated libstdc++, use it instead.

-- Gaby


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]