Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 58563 - libmpeg2-0.4.0b fails to compile (uses O_BINARY)
Summary: libmpeg2-0.4.0b fails to compile (uses O_BINARY)
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High critical (vote)
Assignee: Chris White (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-07-27 09:58 UTC by Felix von Leitner
Modified: 2004-10-20 17:28 UTC (History)
2 users (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 Felix von Leitner 2004-07-27 09:58:50 UTC
emerging libmpeg2-0.4.0b fails:

make[1]: Entering directory `/var/tmp/portage/libmpeg2-0.4.0b/work/mpeg2dec-0.4.0/src'
gcc -DHAVE_CONFIG_H -I. -I. -I../include -I../include -I../include   -Wall -fomit-frame-pointer -fno-common -mcpu=pentiumpro -I/usr/X11R6/include -I/usr/include/SDL -D_REENTRANT -pipe -Os -c `test -f 'mpeg2dec.c' || echo './'`mpeg2dec.c
gcc -DHAVE_CONFIG_H -I. -I. -I../include -I../include -I../include   -Wall -fomit-frame-pointer -fno-common -mcpu=pentiumpro -I/usr/X11R6/include -I/usr/include/SDL -D_REENTRANT -pipe -Os -c `test -f 'dump_state.c' || echo './'`dump_state.c
`-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.
`-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.
mpeg2dec.c: In function `main':
mpeg2dec.c:766: warning: implicit declaration of function `setmode'
mpeg2dec.c:766: error: `O_BINARY' undeclared (first use in this function)
mpeg2dec.c:766: error: (Each undeclared identifier is reported only once
mpeg2dec.c:766: error: for each function it appears in.)


When I add #define O_BINARY 0 to unistd.h, it still fails at link time, because the linker can not resolve "setmode".

Reproducible: Always
Steps to Reproduce:
1. emerge media-libs/libmpeg2-0.4.0-b

That's it.  I'm using ~x86 with glibc 2.3.4.20040619 and gcc 3.4.1.
Actual Results:  
build fails.

Expected Results:  
compile through and install package.

Portage 2.0.50-r9 (default-x86-1.4, gcc-3.4.1, glibc-2.3.4.20040619-r0, 2.6.7)
=================================================================
System uname: 2.6.7 i686 AMD Athlon(tm) XP 2400+
Gentoo Base System version 1.5.1
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-pipe -Os"
CHOST="i686-pc-linux-gnu"
COMPILER="gcc3"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config /usr/kde/3/share/config /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-mcpu=athlon-xp -Os -pipe -fomit-frame-pointer"
DISTDIR="/cvs/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="http://160.45.44.196:81 http://gentoo.oregonstate.edu/
http://distro.ibiblio.org/pub/linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/cvs/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync3.de.gentoo.org/gentoo-portage"
USE="X aalib apm avi berkdb cdr crypt encode esd fbcon foomaticdb gdbm gif gnome
gphoto2 gpm gtk2 imlib ipv6 java jpeg kde ldap libg++ libwww mad mikmod motif
mpeg ncurses nls nptl oggvorbis opengl oss pam pdflib perl png python qt
quicktime readline sdl slang spell ssl tcpd truetype x86 xml2 xv zlib"
Comment 1 Chris White (RETIRED) gentoo-dev 2004-07-27 10:02:51 UTC
I'll check this out.
Comment 2 Chris White (RETIRED) gentoo-dev 2004-07-27 12:08:27 UTC
Can you post your linux-headers version please?
Comment 3 Travis Tilley (RETIRED) gentoo-dev 2004-07-27 12:12:25 UTC
it compiles fine here on amd64 with gcc 3.4.1, so it's not a general gcc 3.4 error if that helps any.
Comment 4 f5d8fd51ed1e804c9e8d0357e8614e0493b06e96 2004-08-07 02:21:20 UTC
works fine here using gcc-3.4.1 and glibc-2.3.4.20040619-r1.
for me it's linux26-headers-2.6.7-r4
Comment 5 Chris White (RETIRED) gentoo-dev 2004-10-20 17:28:24 UTC
I'd try and re-create this again.

One thing I will mention:

`-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.
`-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.

I'd try as it says and see if you get the error again.  Also, you might want
to upgrade to gcc 3.4.2 which has some bug fixes here and there.