Bug 672799 - gcc-4.6 fails to compile mame's ldplayer
Summary: gcc-4.6 fails to compile mame's ldplayer
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: gcc
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Jakub Jelinek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-01-26 12:56 UTC by Julian Sikorski
Modified: 2011-01-27 09:36 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-01-27 09:36:48 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
requested ldplayer.ii file (687.02 KB, text/plain)
2011-01-26 22:20 UTC, Julian Sikorski
no flags Details

Description Julian Sikorski 2011-01-26 12:56:32 UTC
Description of problem:
I am not sure if this is really a compiler issue, but the upstream maintainer said he did not see anything obviously wrong with the line in question.
Anyway, I tried to build RPM Fusion's mame package and it failed with errors like
src/ldplayer/ldplayer.c:578:2: error: expected primary-expression before ',' token
build log is here:
http://buildsys.rpmfusion.org/logs/fedora-development-rpmfusion_nonfree/8973-mame-0.141u1-1.fc15/x86_64/build.log
For convenience, the source can be seen here:
http://mamedev.org/source/src/ldplayer/ldplayer.c.html

Version-Release number of selected component (if applicable):
4.6.0-0.3.fc15

How reproducible:
always

Steps to Reproduce:
1. get mame srpm from rpmfusion's nonfree cvs
2. go to devel branch
3. make mockbuild
  
Actual results:
build fails

Expected results:
build succeeds

Comment 1 Jakub Jelinek 2011-01-26 13:12:28 UTC
Please provide preprocessed source,
i.e. rerun the
gcc -DCRLF=2 -DINLINE="static inline" -DLSB_FIRST -DPTR64 -DNDEBUG  -DDISTRO=generic "-DSDLMAME_ARCH=" -DSYNC_IMPLEMENTATION=tc -DSDLMAME_UNIX -DUSE_OPENGL=1 -DUSE_DISPATCH_GL=1 -DSDLMAME_X11 -DNATIVE_DRC=drcbe_x64  -pipe -g2 -fno-omit-frame-pointer -O2 -fno-strict-aliasing  -Wall -Wcast-align -Wundef -Wformat-security -Wwrite-strings -Wno-sign-compare -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -DINI_PATH="\"/etc/mame;\"" -m64 `sdl-config --cflags  | sed -e 's:/SDL::' -e 's:\(-I[^ ]*\)::g'` `pkg-config --cflags-only-other gtk+-2.0` `pkg-config --cflags-only-other gconf-2.0` -Isrc/ldplayer -Iobj/sdl/ldplayer/ldplayer/layout -Isrc/emu -Iobj/sdl/ldplayer/emu -Iobj/sdl/ldplayer/emu/layout -Isrc/lib/util -Isrc/osd -Isrc/osd/sdl  -Isrc/debug -include src/osd/sdl/sdlprefix.h `sdl-config --cflags  | sed -e 's:/SDL::' -e 's:\(-D[^ ]*\)::g'` `pkg-config --cflags fontconfig` `pkg-config --cflags-only-I gtk+-2.0` `pkg-config --cflags-only-I gconf-2.0` -I/usr/X11/include -I/usr/X11R6/include -I/usr/openwin/include -Isrc/ldplayer -Iobj/sdl/ldplayer/ldplayer/layout -Isrc/emu -Iobj/sdl/ldplayer/emu -Iobj/sdl/ldplayer/emu/layout -Isrc/lib/util -Isrc/osd -Isrc/osd/sdl   -x c++ -std=gnu++98 -c src/ldplayer/ldplayer.c
command with additional -save-temps option and attach ldplayer.ii it creates.

Comment 2 Julian Sikorski 2011-01-26 22:20:31 UTC
Created attachment 475489 [details]
requested ldplayer.ii file

Comment 3 Jakub Jelinek 2011-01-27 09:36:48 UTC
You are not including <stddef.h> thus offsetof is not defined.


Note You need to log in before you can comment on or make changes to this bug.