emerging liboi-0.3.7 fails with the following error message (parts of it removed to save space): powerpc-unknown-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../.. -Wall -Wa,-mregnames -D_BSD_SOURCE -D_GNU_SOURCE -I../.. -O2 -O2 -mtune=powerpc -pipe -mcpu=7450 -maltivec -mabi=altivec -mpowerpc-gfxopt -fsigned-char -mmultiple -MT libpowerpc_la-conv.lo -MD -MP -MF .deps/libpowerpc_la-conv.Tpo -c conv.c -fPIC -DPIC -o .libs/libpowerpc_la-conv.o conv.c:78: error: syntax error before '*' token conv.c: In function `clipconv_s8_f32_powerpc': conv.c:78: error: `dst' undeclared (first use in this function) conv.c:78: error: (Each undeclared identifier is reported only once conv.c:78: error: for each function it appears in.) conv.c:78: error: `src' undeclared (first use in this function) conv.c:78: error: `n' undeclared (first use in this function) conv.c:78: error: `src_stride' undeclared (first use in this function) conv.c:78: error: `dst_stride' undeclared (first use in this function) conv.c: At top level: conv.c:79: error: syntax error before '*' token ... ... make[3]: *** [libpowerpc_la-conv.lo] Error 1 make[3]: Leaving directory `/var/tmp/portage/liboil-0.3.7/work/liboil-0.3.7/liboil/powerpc' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/liboil-0.3.7/work/liboil-0.3.7/liboil' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/liboil-0.3.7/work/liboil-0.3.7' make: *** [all] Error 2 Here's the output of 'emerge --info': Portage 2.1_pre4-r1 (default-linux/ppc/2005.1/ppc/G4, gcc-3.4.5, glibc-2.3.6-r2, 2.6.14-gentoo-r5 ppc) ================================================================= System uname: 2.6.14-gentoo-r5 ppc 7447A, altivec supported Gentoo Base System version 1.12.0_pre15 dev-lang/python: 2.3.5, 2.4.2-r1 sys-apps/sandbox: 1.2.17 sys-devel/autoconf: 2.13, 2.59-r7 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1 sys-devel/binutils: 2.16.1-r1 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.11-r4 ACCEPT_KEYWORDS="ppc ~ppc" AUTOCLEAN="yes" CBUILD="powerpc-unknown-linux-gnu" CFLAGS="-O2 -mtune=powerpc -pipe -mcpu=7450 -maltivec -mabi=altivec -mpowerpc-gfxopt -fsigned-char -mmultiple" CHOST="powerpc-unknown-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.4/env /usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/texmf/web2c /etc/env.d" CXXFLAGS="-O2 -mtune=powerpc -pipe -mcpu=7450 -maltivec -mabi=altivec -mpowerpc-gfxopt -fsigned-char -mmultiple" DISTDIR="/usr/portage/distfiles" FEATURES="autoconfig distlocks sandbox sfperms strict" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" MAKEOPTS="-j2" PKGDIR="/usr/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="ppc X alsa arts berkdb bitmap-fonts cdr crypt cups dvd eds emboss fortran gif gphoto2 gpm gstreamer gtk2 ipv6 jpeg kde libwww motif mp3 mpeg ncurses netdcf nls ogg oggvorbis opengl pam pda pdflib perl png python qt readline scanner spell ssl tcpd truetype truetype-fonts type1-fonts unicode usb v4l vorbis xine xml2 xmms xv xvid zlib elibc_glibc kernel_linux userland_GNU" Unset: ASFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
try CFLAGS="-O2" if that works for you, I will alter the ebuild. liboil is not benefited from all the funky flags coz it is just assembly code, it detects your platform itself and runs the correct asembly code routines.
I already use '-O2' in my CFLAGS. My impression is rather that some expressions (or makros) are not correctly defined for my platform. Maybe this is a problem with some 'if' or 'ifdef' precompiler commands (potentially in a header file)?
what I meant is comment out your current CFLAGS and just have O2 in them.
I did that. The same error still appears (see below). I still think that part of a declaration does not get included because of a conflict with 'if' or 'ifdef' precompiler commands. powerpc-unknown-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I../.. -Wall -Wa,-mregnames -D_BSD_SOURCE -D_GNU_SOURCE -I../.. -O2 -O2 -MT libpowerpc_la-conv.lo -MD -MP -MF .deps/libpowerpc_la-conv.Tpo -c conv.c -fPIC -DPIC -o .libs/libpowerpc_la-conv.o conv.c:78: error: syntax error before '*' token conv.c: In function `clipconv_s8_f32_powerpc': conv.c:78: error: `dst' undeclared (first use in this function) conv.c:78: error: (Each undeclared identifier is reported only once conv.c:78: error: for each function it appears in.) conv.c:78: error: `src' undeclared (first use in this function) conv.c:78: error: `n' undeclared (first use in this function) conv.c:78: error: `src_stride' undeclared (first use in this function) conv.c:78: error: `dst_stride' undeclared (first use in this function) conv.c: At top level: conv.c:79: error: syntax error before '*' token conv.c: In function `clipconv_u8_f32_powerpc': conv.c:79: error: `dst' undeclared (first use in this function) conv.c:79: error: `src' undeclared (first use in this function) conv.c:79: error: `n' undeclared (first use in this function) conv.c:79: error: `src_stride' undeclared (first use in this function) conv.c:79: error: `dst_stride' undeclared (first use in this function) ... ... make[3]: *** [libpowerpc_la-conv.lo] Error 1 make[3]: Leaving directory `/var/tmp/portage/liboil-0.3.7/work/liboil-0.3.7/liboil/powerpc' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/liboil-0.3.7/work/liboil-0.3.7/liboil' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/var/tmp/portage/liboil-0.3.7/work/liboil-0.3.7' make: *** [all] Error 2 !!! ERROR: dev-libs/liboil-0.3.7 failed. Call stack: ebuild.sh, line 1894: Called dyn_compile ebuild.sh, line 941: Called src_compile !!! emake failed !!! If you need support, post the topmost build error, and the call stack if relevant.
I was having this problem also, it has been taken care off by the liboil people. When replacing conv.c by revision 1.3 that can be find in their CVS, http://cvs.freedesktop.org/liboil/liboil/liboil/powerpc/conv.c?rev=1.3&view=markup this emerge builds without any issue! An update to this package in the portage tree is the solution for this bug in PPC! Sheers!!! :)
*** Bug 122106 has been marked as a duplicate of this bug. ***
fixed in portage now thx