[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

gcc-2.95/c++



Hi,

Did anybody manage to build rtems-snapshots/rtems-4.0.0 with gcc-2.95
prereleases?

Here, gcc-2.95 19990704 (prerelease) (From gcc-2.95 from cvs updated
last night) refuses to build librtems++ with both rtems-4.0.0 and
rtems-19990528.

> make[4]: Entering directory `/users/rtems/src/build/c/src/lib/librtems++'
> test -d o-erc32 || /bin/mkdir -p o-erc32
> /opt/rtems/bin/sparc-rtems-g++ -B/users/rtems/src/build/./erc32/lib/ -specs bsp_specs -qrtems  -mcpu=cypress
> -I/users/rtems/src/build/./erc32/lib/include/networking  -g -Wall -ansi -fasm  -c -o o-erc32/rtemsEvent.o
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc
> In file included from /users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:26,
>                  from ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:21:
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsTask.h:110: declaration of `const int rtemsTask::rtemsTask'
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsTask.h:95: conflicts with previous declaration `void rtemsTask::rtemsTask(int)'
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsTask.h:110: parse error before `&'
> In file included from ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:21:
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:55: declaration of `const int rtemsEvent::rtemsEvent'
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:52: conflicts with previous declaration `void
> rtemsEvent::rtemsEvent(int)'/users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:55: parse error before `&'
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:34: parse error before `&'
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:35: prototype for `rtemsEvent::rtemsEvent(...)' does not match any in class
> `rtemsEvent'
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:50: candidates are: rtemsEvent::rtemsEvent()
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:49:                 rtemsEvent::rtemsEvent(const rtemsEvent &)
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:28:                 rtemsEvent::rtemsEvent(const char *, unsigned int = 0)
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc: In method `rtemsEvent::rtemsEvent(...)':
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:36: `event' undeclared (first use this function)
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:36: (Each undeclared identifier is reported only once
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:36: for each function it appears in.)
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc: At top level:
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:50: parse error before `&'
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:51: `rtemsEvent::operator =(...)' must take exactly one argument
> ../../../../../rtems-rc-19990528-0/c/src/lib/librtems++/rtemsEvent.cc:51: prototype for `const class rtemsEvent & rtemsEvent::operator =(...)'
> does not match any in class `rtemsEvent'
> /users/rtems/src/build/erc32/lib/include/rtems++/rtemsEvent.h:84: candidate is: class rtemsEvent & rtemsEvent::operator =(const
> rtemsEvent &)
> make[4]: *** [o-erc32/rtemsEvent.o] Error 1
> make[4]: Leaving directory `/users/rtems/src/build/c/src/lib/librtems++'
> make[3]: *** [all] Error 1
> make[3]: Leaving directory `/users/rtems/src/build/c/src/lib'
> make[2]: *** [all] Error 1
> make[2]: Leaving directory `/users/rtems/src/build/c/src'
> make[1]: *** [all] Error 1
> make[1]: Leaving directory `/users/rtems/src/build/c'
> make: *** [all] Error 1
>

Interestingly enough this problem does not show when preprocessing
rtemsEvent.cc and then compiling the preprocessed file. Therefore I'd
guess that RTEMS is affected by a nasty bug in gcc-2.95/preprocessor
somewhere.

Until now I have only tried sparc-rtems/erc32 and i960-rtems/cvme961
(both are affected), but I guess that probably all targets are affected.

Ralf.