Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 170568 - games-emulation/snes9x-1.43-r1 fails to compile with gcc-4.1.2
Summary: games-emulation/snes9x-1.43-r1 fails to compile with gcc-4.1.2
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Games (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Games
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 117482
  Show dependency tree
 
Reported: 2007-03-12 13:48 UTC by Stefan Vunckx
Modified: 2007-07-28 22:22 UTC (History)
4 users (show)

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


Attachments
patch that fixes compilation errors (snes9x-1.43-externc.patch,611 bytes, patch)
2007-03-16 10:06 UTC, Stefan Vunckx
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Vunckx 2007-03-12 13:48:35 UTC
i686-pc-linux-gnu-g++  -fno-rtti -INONE -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/unzip -Ii386 -c -O2 -march=pentium-m -pipe -INONE  -INONE -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/unzip -Ii386 -DMITSHM -DVAR_CYCLES -DCPU_SHUTDOWN -DSPC700_SHUTDOWN -DZSNES_FX -DEXECUTE_SUPERFX_PER_LINE -DZSNES_C4 -DUSE_THREADS -DSPC700_C -DNETPLAY_SUPPORT -DUNZIP_SUPPORT   -DUSE_OPENGL  -DMMX -DSDD1_DECOMP -DJOYSTICK_SUPPORT -DNO_INLINE_SET_GET  -DDEBUGGER -DZLIB -DHAVE_LIBPNG -DHAVE_MKSTEMP -DHAVE_STRINGS_H -DHAVE_SYS_IOCTL_H -DHAVE_ENDIAN_H '-DACCEPT_SIZE_T=socklen_t' /var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/globals.cpp -o globals.o
i686-pc-linux-gnu-g++  -fno-rtti -INONE -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/unzip -Ii386 -c -O2 -march=pentium-m -pipe -INONE  -INONE -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x -I/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/unzip -Ii386 -DMITSHM -DVAR_CYCLES -DCPU_SHUTDOWN -DSPC700_SHUTDOWN -DZSNES_FX -DEXECUTE_SUPERFX_PER_LINE -DZSNES_C4 -DUSE_THREADS -DSPC700_C -DNETPLAY_SUPPORT -DUNZIP_SUPPORT   -DUSE_OPENGL  -DMMX -DSDD1_DECOMP -DJOYSTICK_SUPPORT -DNO_INLINE_SET_GET  -DDEBUGGER -DZLIB -DHAVE_LIBPNG -DHAVE_MKSTEMP -DHAVE_STRINGS_H -DHAVE_SYS_IOCTL_H -DHAVE_ENDIAN_H '-DACCEPT_SIZE_T=socklen_t' /var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/spc7110.cpp -o spc7110.o
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/dsp1.h:128: error: previous declaration of 'SDSP1 DSP1' with 'C++' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/globals.cpp:126: error: conflicts with new declaration with 'C' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/ppu.h:336: error: previous declaration of 'SnesModel M1SNES' with 'C++' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/globals.cpp:134: error: conflicts with new declaration with 'C' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/ppu.h:337: error: previous declaration of 'SnesModel M2SNES' with 'C++' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/globals.cpp:135: error: conflicts with new declaration with 'C' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/ppu.h:335: error: previous declaration of 'SnesModel* Model' with 'C++' linkage
/var/tmp/portage/games-emulation/snes9x-1.43-r1/work/snes9x-1.43-src/snes9x/globals.cpp:136: error: conflicts with new declaration with 'C' linkage
make: *** [globals.o] Error 1
make: *** Waiting for unfinished jobs....


Recently upgraded my gcc to 4.1.2, from 4.1.1, but Im not sure if initial compilation of this package happened with 4.1.1, but I am sure it happened with gcc4! Also recompiled my system recently with debug useflag set, but dont have enough knowledge to actually tell why it fails to compile.

Have tried disabling/enabling every use flag too, just to be complete, but without a differnce... Although it looks like compiler problem.

Reproducible: Always

Steps to Reproduce:
1. emerge snes9x
2.
3.




# emerge --info
Portage 2.1.2.2 (default-linux/x86/2006.0, gcc-4.1.2, glibc-2.5-r0, 2.6.19-suspend2-r3 i686)
=================================================================
System uname: 2.6.19-suspend2-r3 i686 Genuine Intel(R) CPU           T2250  @ 1.73GHz
Gentoo Base System release 1.12.9
Timestamp of tree: Mon, 12 Mar 2007 02:50:01 +0000
dev-java/java-config: 1.3.7, 2.0.31-r4
dev-lang/python:     2.4.4
dev-python/pycrypto: 2.0.1-r5
sys-apps/sandbox:    1.2.18.1
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.15
sys-devel/libtool:   1.5.23b
virtual/os-headers:  2.6.20-r1
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium-m -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/php/apache1-php5/ext-active/ /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c"
CXXFLAGS="-O2 -march=pentium-m -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks metadata-transfer nostrip sandbox sfperms strict"
GENTOO_MIRRORS="http://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/"
MAKEOPTS="-j3"
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/local/overlays/portage"
SYNC="rsync://192.168.1.1/gentoo-portage"
USE="X alsa apache2 apm berkdb bitmap-fonts cli cracklib crypt cups debug dri eds emboss encode esd foomaticdb fortran gdbm gif gpm gstreamer gtk2 iconv imlib ipv6 isdnlog jpeg kde libg++ libwww mad midi mikmod motif mp3 mpeg ncurses nls nptl nptlonly ogg opengl oss pam pcre perl png pppd python qt3 qt4 quicktime readline reflection sdl session spell spl ssl tcpd truetype truetype-fonts type1-fonts vorbis x86 xml xorg xv zlib" 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="evdev keyboard mouse joystick wacom" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS="radeon vesa vga"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Stefan Vunckx 2007-03-16 10:06:26 UTC
Created attachment 113454 [details, diff]
patch that fixes compilation errors

Ebuild installs succesfully with this patch; applied & tested myself. Hope this helps!
Comment 2 Sascha Hlusiak 2007-05-22 01:41:22 UTC
Patch worked for me. 
I suggest to include this patch as fast as possible in portage, because 1.43-r1 is marked stable, it's the only available version in the tree right now and upcoming version 1.51 has some regressions.
Comment 3 OxO pHz.60 2007-07-10 19:38:44 UTC
I have the same problem on x86_64...
Comment 4 Alessandro Guido 2007-07-12 12:23:08 UTC
(In reply to comment #1)
> Created an attachment (id=113454) [edit]
> patch that fixes compilation errors
> 
> Ebuild installs succesfully with this patch; applied & tested myself. Hope this
> helps!
> 

patch works for me(In reply to comment #1)


Comment 5 Tupone Alfredo gentoo-dev 2007-07-28 22:22:04 UTC
Fixed. Thanks for bug and patch