Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] can't rebuild libstdc++
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC
View previous topic :: View next topic  
Author Message
veonline
n00b
n00b


Joined: 21 Mar 2005
Posts: 58

PostPosted: Mon May 14, 2007 1:38 pm    Post subject: [SOLVED] can't rebuild libstdc++ Reply with quote

im stumping into this problem since a while: libstdc++v3-3.3.6 doesn't compile.
here are the last linse of emerge output:
Code:

/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/build/gcc/xgcc -B/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/build/gcc/ -B/usr/powerpc64-unknown-linux-gnu/bin/ -B/usr/powerpc64-unknown-linux-gnu/lib/ -isystem /usr/powerpc64-unknown-linux-gnu/include -O2 -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include  -I. -I. -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/. -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/config -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/../include  -g0 -finhibit-size-directive -fno-inline-functions -fno-exceptions -fno-zero-initialized-in-bss  \
           -c /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c -DCRT_END \
          -o crtend.o
make[1]: *** [crtbegin.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: *** [crtbeginS.o] Error 1
In file included from /usr/include/stdio.h:833,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/tsystem.h:72,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c:62:
/usr/include/bits/stdio.h: In function `vprintf':
/usr/include/bits/stdio.h:36: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h: In function `getchar':
/usr/include/bits/stdio.h:43: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h:59: confused by earlier errors, bailing out
In file included from /usr/include/stdio.h:833,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/tsystem.h:72,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c:62:
/usr/include/bits/stdio.h: In function `vprintf':
/usr/include/bits/stdio.h:36: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h: In function `getchar':
/usr/include/bits/stdio.h:43: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h:59: confused by earlier errors, bailing out
make[1]: *** [crtbeginT.o] Error 1
make[1]: *** [crtend.o] Error 1
make[1]: Leaving directory `/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/build/gcc'
make: *** [all-gcc] Error 2

!!! ERROR: sys-libs/libstdc++-v3-3.3.6 failed.
Call stack:
  ebuild.sh, line 1614:   Called dyn_compile
  ebuild.sh, line 971:   Called qa_call 'src_compile'
  environment, line 4263:   Called src_compile
  libstdc++-v3-3.3.6.ebuild, line 233:   Called die


this is my emerge --info:
Code:

Portage 2.1.2.2 (default-linux/ppc/ppc64/2007.0/64bit-userland/desktop/970/pmac, gcc-4.1.1, glibc-2.5-r2, 2.6.21-rc3-git6 ppc64)
=================================================================
System uname: 2.6.21-rc3-git6 ppc64 PPC970MP, altivec supported
Gentoo Base System release 1.12.9
Timestamp of tree: Sat, 12 May 2007 10:00:10 +0000
dev-java/java-config: 1.3.7, 2.0.31-r5
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.61
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.16
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r2
ACCEPT_KEYWORDS="ppc64"
AUTOCLEAN="yes"
CBUILD="powerpc64-unknown-linux-gnu"
CFLAGS="-mcpu=G5 -O2 -pipe -maltivec -mabi=altivec -fno-strict-aliasing"
CHOST="powerpc64-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-mcpu=G5 -O2 -pipe -maltivec -mabi=altivec -fno-strict-aliasing"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks metadata-transfer parallel-fetch sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
LANG="it_IT@euro"
LC_ALL="it_IT@euro"
LDFLAGS="-Wl,-O1"
LINGUAS="it"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --filter=H_**/files/digest-*"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local/layman/openoffice-geki /usr/portage/local/layman/enlightenment /usr/portage/local/layman/nouveau"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac alsa altivec amr amuled apache2 artworkextra asf audiofile avahi bash-completion berkdb bitmap-fonts bzip2 cairo cdr cli cpudetection cracklib crypt cups daap dbus dga dio divx dri dv dvd dvdr dvdread eds emboss encode epiphany esd evolution fam fame fbcon fbdev ffmpeg firefox flac font-server fortran gcc64 gdbm gif glibc-omitfp glitz gmedia gnome gphoto2 gpm gstreamer gtk gtk2 gtkhtml hal hpn iconv ieee1394 imagemagick imlib isdnlog java javascript jpeg keyring libg++ libnotify mad midi mikmod modplug moznocompose moznoirc moznomail moznoroaming mozsha1 mozsvg mp3 mpeg mplayer msn mudflap musicbrainz mysql ncurses nls nptl nptlonly nsplugin ogg pam panel-plugin pcre pdf perl php png posix ppc64 pppd python qt3support quicktime readline realmedia reflection remote samba sdk sdl serpentine session skins spell spl srt ssl stats subtitles svg tagwriting tcpd tga theora threads threadsonly tiff truetype truetype-fonts type1-fonts unicode usb userlocales vorbis wma wmf wmp xanim xcomposite xml xorg xosd xpm xrandr xscreensaver xulrunner xv xvid xvmc yahoo zlib" ALSA_CARDS="powermac" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" ELIBC="glibc" INPUT_DEVICES="keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="it" USERLAND="GNU" VIDEO_CARDS="nv fbdev nouveau"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS


it seems to be know bug here http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23158.
i've tried to change the BOOT_CFLAGS=" -O2 -pipe" and STAGE1_CFLAGS="-O0 -g" as suggested into the ebuild, but no way...

don't know exaclty but libstdc++v3 should be quite important, doesn't it?
_________________
abbasso uindovs!!!


Last edited by veonline on Wed May 23, 2007 7:49 am; edited 1 time in total
Back to top
View user's profile Send private message
veonline
n00b
n00b


Joined: 21 Mar 2005
Posts: 58

PostPosted: Tue May 15, 2007 4:16 pm    Post subject: Reply with quote

...bump...
_________________
abbasso uindovs!!!
Back to top
View user's profile Send private message
JoseJX
Retired Dev
Retired Dev


Joined: 28 Apr 2002
Posts: 2774

PostPosted: Tue May 15, 2007 9:39 pm    Post subject: Reply with quote

On a reasonably new system, you shouldn't need it. libstdc++ is really for binaries that still use gcc-v3. If you're using gcc-4 and you don't have any binaries built against libstdc++-v3 (gcc 3), then you don't need it. Ether way, I'll try building it on my machine and see if I can reproduce the problem.
_________________
Gentoo PPC FAQ: http://www.gentoo.org/doc/en/gentoo-ppc-faq.xml
Back to top
View user's profile Send private message
printcap
n00b
n00b


Joined: 12 Feb 2005
Posts: 4
Location: Switzerland

PostPosted: Wed May 16, 2007 8:02 pm    Post subject: Reply with quote

I am struggling with the same problem on ppc64-64ul. In my case the JDKs from IBM have a dependency to libstdc++-v3.

Code:
/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/build/gcc/xgcc -B/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/build/gcc/ -B/usr/powerpc64-unknown-linux-gnu/bin/ -B/usr/powerpc64-unknown-linux-gnu/lib/ -isystem /usr/powerpc64-unknown-linux-gnu/include -O2 -DIN_GCC    -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include  -I. -I. -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/. -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/config -I/var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/../include  -g0 -finhibit-size-directive -fno-inline-functions -fno-exceptions -fno-zero-initialized-in-bss  \
           -c /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c -DCRT_END -DCRTSTUFFS_O \
          -o crtendS.o
In file included from /usr/include/stdio.h:833,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/tsystem.h:72,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c:62:
/usr/include/bits/stdio.h: In function `vprintf':
/usr/include/bits/stdio.h:36: error: syntax error before "__restrict__"
In file included from /usr/include/stdio.h:833,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/tsystem.h:72,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c:62:
/usr/include/bits/stdio.h: In function `vprintf':
/usr/include/bits/stdio.h:36: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h: In function `getchar':
/usr/include/bits/stdio.h:43: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h:59: confused by earlier errors, bailing out
/usr/include/bits/stdio.h: In function `getchar':
/usr/include/bits/stdio.h:43: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h:59: confused by earlier errors, bailing out
In file included from /usr/include/stdio.h:833,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/tsystem.h:72,
                 from /var/tmp/portage/sys-libs/libstdc++-v3-3.3.6/work/gcc-3.3.6/gcc/crtstuff.c:62:
/usr/include/bits/stdio.h: In function `vprintf':
/usr/include/bits/stdio.h:36: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h: In function `getchar':
/usr/include/bits/stdio.h:43: error: syntax error before "__restrict__"
/usr/include/bits/stdio.h:59: confused by earlier errors, bailing out


The preprocessed code at the specific location looks as follows:
Code:

vprintf (__const char *__restrict __fmt, __gnuc_va_list __arg)
{
  return vfprintf (__restrict, __fmt, __arg);
}


whereas in /usr/include/bits/stdio.h the declaration is:
Code:

__STDIO_INLINE int
vprintf (__const char *__restrict __fmt, _G_va_list __arg)
{
  return vfprintf (stdout, __fmt, __arg);
}


This is certainly a bit odd. In respect to the bug report at http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23158 changing STAGE1_CFLAGS="-O0" and instead of using the target 'all-target-libstdc++-v3' changing it to 'bootstrap' seems to work for me. That is I changed the ebuild as follows:
Code:

emake bootstrap \
        LIBPATH="${LIBPATH}" \
        BOOT_CFLAGS="${CFLAGS}" STAGE1_CFLAGS="-O0" || die


The IBM JVM seems to work with the newly built library.
Back to top
View user's profile Send private message
veonline
n00b
n00b


Joined: 21 Mar 2005
Posts: 58

PostPosted: Wed May 23, 2007 7:49 am    Post subject: Reply with quote

thank you printcap, it worked out!
_________________
abbasso uindovs!!!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum