View previous topic :: View next topic |
Author |
Message |
s_ridenour n00b
Joined: 02 Feb 2004 Posts: 4
|
Posted: Thu Aug 26, 2004 12:02 pm Post subject: Mplayer compile problems |
|
|
I can't seem to get Mplayer to compile.
I've got an older version installed, and since the sound starts to drift when playing certain .WMVs, I thought I'd upgrade, hoping the problem had been fixed.
But I get this error when trying to emerge Mplayer:
Quote: |
msmpeg4.c: In function `msmpeg4_pred_dc':
msmpeg4.c:735: error: can't find a register in class `BREG' while reloading `asm'
make[1]: *** [msmpeg4.o] Error 1
make[1]: Leaving directory `/var/tmp/portage/mplayer-1.0_pre4-r7/work/MPlayer-1.0pre4/libavcodec'
make: *** [libavcodec/libavcodec.a] Error 2
!!! ERROR: media-video/mplayer-1.0_pre4-r7 failed.
!!! Function src_compile, Line 312, Exitcode 2
!!! Failed to build MPlayer!
|
So I am stuck with a really old version of Mplayer for now, it seems. Oh, BTW, this was with GCC 3.3.3 20040412, and I had just done "emerge sync" before trying to emerge Mplayer.
Any ideas? |
|
Back to top |
|
|
Minox Apprentice
Joined: 12 Apr 2004 Posts: 188 Location: Germany / Munich
|
Posted: Thu Aug 26, 2004 1:36 pm Post subject: |
|
|
Greetings,
https://bugs.gentoo.org/show_bug.cgi?id=48699
Quote: | ------- Additional Comment #5 From Piotr Turek 2004-08-21 03:00 PST -------
In mplayer You can edit confgiure.sh or (this is better) makeconfig (in bz2 file) and add flag for gcc:-fno-pie.
After this mplayer compiled succesfuly (and work). It's propably error similiar to X.org + hardened gcc.
Piotr Turek
|
Kind regards, _________________ proud to be 100% M$ free |
|
Back to top |
|
|
bens n00b
Joined: 03 Mar 2004 Posts: 37 Location: MIT
|
Posted: Sun Sep 12, 2004 10:13 pm Post subject: A workaround |
|
|
I really wanted to (re)install mplayer, and I didn't want to have to reinstall gcc to stop being hardened, so I found a workaround for this bug (it should really be fixed). The solution is do the 'emerge' manually and make one minor modification to the ebuild. This example is for mplayer-1.0pre5-r3.
Step 1: Get the mplayer source
Code: | ebuild /usr/portage/media-video/mplayer/mplayer-1.0_pre5-r3.ebuild fetch |
Step 2: Unpack and configure the source
Code: | ebuild /usr/portage/media-video/mplayer/mplayer-1.0_pre5-r3.ebuild unpack |
Step 3: Edit the config file to ad "-fno-pie" to the code. This will allow everything, and in particular msmpeg4 in libavcodec, to compile happily.
Code: | nano -w /var/tmp/portage/mplayer-1.0_pre5-r3/work/MPlayer-1.0pre5/config.mak |
Change line 20 from
Code: | OPTFLAGS = -I../libvo -I../../libvo -I/usr/X11R6/include -O4 -march=pentium4 -mcpu=pentium4 -pipe -ffast-math -fomit-frame-pointer -D_REENTRANT -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(EXTRA_INC)
|
to
Code: | OPTFLAGS = -I../libvo -I../../libvo -I/usr/X11R6/include -O4 -march=pentium4 -mcpu=pentium4 -pipe -ffast-math -fomit-frame-pointer -D_REENTRANT -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(EXTRA_INC) -fno-pie |
i.e. add "-fno-pie" to the end of the line.
Step 4: Type Code: | cd /var/tmp/portage/mplayer-1.0_pre5-r3/work/MPlayer-1.0pre5 |
and there type
which will compile the code.
Step 5: Type
Code: | FEATURES="noauto" ebuild /usr/portage/media-video-mplayer/mplayer-1.0_pre5-r3.ebuild install |
FEATURES="noauto" prevents ebuild from automatically noticing that the timestamps of certain files do not match, indicating that it is starting in the middle of the mplayer build process and should restart. Without FEATURES="noauto" ebuild would build mplayer from scratch and overwrite our modification to config.mak.
Step 6: Type
Code: | FEATURES="noauto" ebuild /usr/portage/media-video-mplayer/mplayer-1.0_pre5-r3.ebuild qmerge |
You should now have a totally happy mplayer install.
But I'm no expert, so don't take my word for it.
-Ben |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|