Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 78030 - advancemame 0.97.0 fails to compile on ppc
Summary: advancemame 0.97.0 fails to compile on ppc
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Games (show other bugs)
Hardware: PPC Linux
: High normal
Assignee: Gentoo Games
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-01-14 16:42 UTC by Alessandro Ronchi
Modified: 2006-05-08 22:32 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alessandro Ronchi 2005-01-14 16:42:24 UTC
When I try to compile advancemame package, i get a big list of similar errors that blocks the compilation:


ure or union
src/cpu/v60/v60.c:747: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:748: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:749: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:750: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:751: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:752: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:753: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:754: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:755: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:756: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:757: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:758: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:759: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:760: error: request for member `reg' in something not a struct ure or union
src/cpu/v60/v60.c:761: error: request for member `tcb' in something not a struct ure or union
make: *** [obj/mame/linux/blend/cpu/v60/v60.o] Error 1
make: *** Waiting for unfinished jobs....



Reproducible: Always
Steps to Reproduce:
1. emerge advancemame
Comment 1 Mr. Bones. (RETIRED) gentoo-dev 2005-01-19 22:00:15 UTC
reopen with the output of emerge --info please.
Comment 2 Lars Weiler (RETIRED) gentoo-dev 2005-04-02 07:16:07 UTC
Still does not compile on ~ppc.  Take my pegasos' emerge --info:

Portage 2.0.51.19 (default-linux/ppc/2004.3, gcc-3.4.3, glibc-2.3.4.20050125-r1, 2.6.11-pegasos-r2-elrohir ppc)
=================================================================
System uname: 2.6.11-pegasos-r2-elrohir ppc 7447/7457, altivec supported
Gentoo Base System version 1.6.10
Python:              dev-lang/python-2.3.5 [2.3.5 (#1, Feb 21 2005, 20:01:03)]
distcc 2.18.3 powerpc-unknown-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.4 [enabled]
dev-lang/python:     2.3.5
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.6.3, 1.4_p6, 1.8.5-r3, 1.9.5, 1.7.9-r1, 1.5
sys-devel/binutils:  2.15.90.0.3-r4
sys-devel/libtool:   1.5.14
virtual/os-headers:  2.6.8.1-r4
ACCEPT_KEYWORDS="ppc ~ppc"
AUTOCLEAN="yes"
CFLAGS="-O3 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -pipe"
CHOST="powerpc-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3.4/env /usr/kde/3.4/share/config /usr/kde/3.4/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="-O3 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache cvs digest distlocks sandbox sfperms strict userpriv usersandbox"
GENTOO_MIRRORS="http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror"
LANG="C"
LC_ALL="C"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://localhost/gentoo-portage"
USE="X a52 aac aalib alsa altivec apache2 arts audiofile bash-completion berkdb bitmap-fonts bzlib ccache cdr cjk crypt cscope css cups curl dba dga dmx droproot dts dv dvd dvdr dvdread emboss encode erandom esd ethereal evo exif exim faac faad fam fame fbcon ffmpeg flac font-server foomaticdb fortran freetype ftp fusion gd gdbm gif gimp gimpprint gkrellm gnome gpm gstreamer gtk gtk2 gtkhtml ieee1394 imagemagick imap imlib inetd ipv6 irda jabber java javascript jpeg jpeg2k kde kdeenablefinal kdepim latex ldap libcaca libwww maildir mbox mikmod mng mozcalendar mozilla mp3 mpeg mpeg4 mplayer music mysql ncurses nethack network nls nntp nodrm nptl offensive oggvorbis opengl pam perl png posix ppc ppds procmail python qt quicktime readline rtc samba scanner sdl simplexml skey smime snmp speex spell ssl svg tcltk tcpd tetex theora threads tiff timidity transcode truetype truetype-fonts type1-fonts unicode usb userlocales vim vnc wmf xine xinerama xinetd xml xml2 xosd xprint xv xvid yv12 zlib linguas_de"
Unset:  ASFLAGS, CBUILD, CTARGET, LDFLAGS
Comment 3 SpanKY gentoo-dev 2005-04-02 23:49:34 UTC
a useful error:
obj/mame/linux/blend/cpu/v60/v60.o
src/cpu/v60/v60.c:88: warning: declaration does not declare anything
src/cpu/v60/v60.c:88: warning: no semicolon at end of struct or union
src/cpu/v60/v60.c:88: error: parse error before numeric constant
src/cpu/v60/v60.c:89: warning: data definition has no type or storage class
src/cpu/v60/v60.c:144:1: warning: "PPC" redefined
<built-in>:74:1: warning: this is the location of the previous definition
src/cpu/v60/v60.c: In function `v60ReadPSW':
src/cpu/v60/v60.c:228: error: request for member `reg' in something not a structure or union
src/cpu/v60/v60.c:228: error: request for member `reg' in something not a structure or union
src/cpu/v60/v60.c:228: error: request for member `reg' in something not a structure or union
Comment 4 SpanKY gentoo-dev 2005-04-02 23:58:47 UTC
seems 'PPC' gets defined somewhere along the line so when v60.c is compiled and it uses a variable named 'PPC', stuff blows up ...

quick fix:
+#undef PPC
 struct v60info {
     struct cpu_info info;
     UINT32 reg[68];
     UINT32 tcb;
     Flags flags;
     int irq_line;
     int nmi_line;
     int (*irq_cb)(int irqline);
     UINT32 PPC;
 } v60;
Comment 5 Mr. Bones. (RETIRED) gentoo-dev 2005-04-12 07:31:44 UTC
Can I assume 0.95.0 is the same?
Comment 6 SpanKY gentoo-dev 2005-04-12 16:58:18 UTC
yeah prob
Comment 7 Joe Jezak (RETIRED) gentoo-dev 2005-05-24 15:35:02 UTC
It's the same case with 0.95.
Comment 8 Mr. Bones. (RETIRED) gentoo-dev 2005-05-24 16:21:50 UTC
we're up to 0.96 now.
Comment 9 Henrique Rodrigues 2005-07-20 16:17:47 UTC
I'm trying to emerge advancemame-0.97.0. This bug does not seem to occur, but
another does:

obj/mame/linux/blend/advance/zlib/zutil.o
obj/mame/linux/blend/advance/zlib/uncompr.o
obj/mame/linux/blend/advance/zlib/compress.o
obj/mame/linux/blend/advance/libz.a
obj/mame/linux/blend/advmame
/usr/lib/gcc/powerpc-unknown-linux-gnu/3.4.4/../../../crt1.o(.text+0x20): In fun
ction `_start':
: relocation truncated to fit: R_PPC_REL24 __libc_start_main@@GLIBC_2.0
/usr/lib/gcc/powerpc-unknown-linux-gnu/3.4.4/../../../crti.o(.text+0x10): In fun
ction `call_gmon_start':
/var/tmp/portage/glibc-2.3.4.20041102-r1/work/build-default-powerpc-unknown-linu
x-gnu-nptl/csu/crti.S:16: relocation truncated to fit: R_PPC_LOCAL24PC _GLOBAL_O
FFSET_TABLE_+fffffffffffffffc
obj/mame/linux/blend/advance/linux/file.o(.text+0x38): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 memset@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0x44): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 getcwd@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0x7c): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 snprintf@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0x88): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 getenv@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0xac): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 snprintf@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0xc8): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 strlen@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0x110): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 strlen@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0x14c): In function `file_init':
: relocation truncated to fit: R_PPC_REL24 snprintf@@GLIBC_2.0
obj/mame/linux/blend/advance/linux/file.o(.text+0x158): In function `file_init':
: additional relocation overflows omitted from the output
Comment 10 Henrique Rodrigues 2005-07-20 16:18:39 UTC
Oops, forgot my emerge info:

Portage 2.0.51.22-r2 (default-linux/ppc/2005.0, gcc-3.4.4,
glibc-2.3.4.20041102-r1, 2.6.12-gentoo-r6 ppc)
=================================================================
System uname: 2.6.12-gentoo-r6 ppc 7447A, altivec supported
Gentoo Base System version 1.6.13
dev-lang/python:     2.3.5
sys-apps/sandbox:    1.2.10
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5
sys-devel/binutils:  2.15.90.0.3-r5
sys-devel/libtool:   1.5.18-r1
virtual/os-headers:  2.6.8.1-r4
ACCEPT_KEYWORDS="ppc"
AUTOCLEAN="yes"
CBUILD="powerpc-unknown-linux-gnu"
CFLAGS="-O2 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -pipe -fomit-frame-pointer"
CHOST="powerpc-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -mcpu=G4 -mtune=G4 -maltivec -mabi=altivec -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig candy distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
LC_ALL="en_IE.UTF-8"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="ppc X alsa altivec apm artworkextra bitmap-fonts browserplugin cdr cups dga
dhcp dvd eds encode esd foomaticdb gnome gpm gstreamer gtk gtk2 gtkhtml hal
jikes jpeg mad mikmod mozsvg mp3 mpeg mppe-mppc network nls nptl nptlonly
offensive ogg oggvorbis opengl pic png ppds samba sdl ssl theora truetype
unicode usb vorbis xml2 xvid userland_GNU kernel_linux elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LDFLAGS, LINGUAS, MAKEOPTS
Comment 11 SpanKY gentoo-dev 2005-07-20 18:38:13 UTC
comment #9 is unrelated ... your glibc is probably broken, try re-emerging it
Comment 12 Joe Jezak (RETIRED) gentoo-dev 2005-07-22 06:07:44 UTC
If it is glibc, I guess crt1.o isn't compiled with pic, the same thing happens
on both 2.3.4.20041102 and 2.3.5.
Comment 13 SpanKY gentoo-dev 2005-07-22 10:19:08 UTC
crt1.o shouldnt be PIC, that's the point of having a sep Scrt1.o
Comment 14 Joe Jezak (RETIRED) gentoo-dev 2005-08-04 08:10:52 UTC
So should it be forced to link against Scrt1.o instead?
Comment 15 SpanKY gentoo-dev 2005-08-04 19:32:30 UTC
you shouldnt have to worry about what the toolchain is doing wrt to crt1.o/Scrt1.o
Comment 16 Joe Jezak (RETIRED) gentoo-dev 2005-08-10 13:48:49 UTC
Marked -ppc until we get this fixed.
Comment 17 Mr. Bones. (RETIRED) gentoo-dev 2005-08-18 20:27:02 UTC
I'll go ahead and close this bug with LATER then.
Comment 18 Joe Jezak (RETIRED) gentoo-dev 2006-05-01 06:50:18 UTC
I got it to compile fine by passing LDFLAGS="-Wl,--relax" to configure. Since the advmame executable is > 32Mb (It's almost 41 for 104) we need to pass this to allow for the >24bit jumps that need to happen in a binary of that size.
Comment 19 Joe Jezak (RETIRED) gentoo-dev 2006-05-08 22:32:22 UTC
Fixed in CVS.