[MPlayer-users] Configuration/Makefile patches and one bug report/fix

D J Hawkey Jr hawkeyd at visi.com
Mon Nov 19 20:14:46 CET 2001


Hi, All.

First, let's get the preliminaries out of the way:

===8<===

[sheol] ~$ dmesg |less
Copyright (c) 1992-2000 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
        The Regents of the University of California. All rights reserved.
FreeBSD 4.2-RELEASE #32: Fri Aug 17 06:43:47 CDT 2001
    root at sheol.localdomain:/usr/src/sys/compile/SHEOL
Timecounter "i8254"  frequency 1193182 Hz
CPU: Pentium III/Pentium III Xeon/Celeron (764.35-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0x686  Stepping = 6
  Features=0x383f9ff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,SEP,MTRR,PGE, \
MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE>
real memory  = 133103616 (129984K bytes)
avail memory = 126005248 (123052K bytes)
Preloaded elf kernel "kernel" at 0xc038c000.
Pentium Pro MTRR support enabled
   ...

[shoel] ~$ mplayer
MPlayer CVS-011119-09:11(C) 2000-2001 Arpad Gereoffy (see DOCS!)
CPU vendor name: GenuineIntel  max cpuid level: 2
CPU: Intel Celeron 2/Pentium III Coppermine,Geyserville
CPUflags: Type: 6 MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 0 SSE2: 0
   ...

===>8===


Now then.

I built MPLayer-current (20011118) last night, and all went well.
mplayer works fine, except for one error on one MPEG stream.
libmpeg2/decode.c:mpeg2_decode_data() consistantly kicks out

    "@@@ libmpeg2 returned from sig11... (bad file?) @@@"

which might be true except that another media player handles it fine.
Problem is, the program hangs (or maybe never leaves that loop). So I
added this hack:

===8<===

--- MPlayer-20011118/libmpeg2/decode.c.DIST     Thu Nov  8 20:17:01 2001
+++ MPlayer-20011118/libmpeg2/decode.c  Sun Nov 18 16:59:00 2001
@@ -366,6 +366,7 @@
	     if (config.flags & MM_ACCEL_X86_MMX) emms ();
 #endif
       printf("@@@ libmpeg2 returned from sig11... (bad file?) @@@\n");
+      return 0; /* djhjr - 11/18/01 */
     }
   }
   //--------------------

===>8===

I tried "break;", and that resulted in a bright flash in the playback.
This "return 0;" doesn't, and the debug output shows no dropped frames.
I have no idea if this'll work for other platforms.


OK, so then I wanted DVD support and the GUI. I built and installed
libdvdread, but being the paranoid^H^H^H^H^H^H^H^Hcautious hacker/admin
that I am, set "./configure --prefix=..." to the directory I installed
MPlayer in, $(HOME)/projects/MPlayer. This was fine. So, on rebuilding
MPlayer, I set "./configure --with-extraincdir=... --with-extralibdir=..."
to the appropriate paths (the prefix path, too) within that destination,
but the extra paths wouldn't take. So after a bunch of messing around, I
settled on these hacks:

===8<===

--- MPlayer-20011118/configure.DIST	Fri Nov 16 12:40:27 2001
+++ MPlayer-20011118/configure	Mon Nov 19 08:35:36 2001
@@ -467,8 +467,8 @@
 # or only /usr/local/include.
 
 if freebsd ; then
-_extralibdir=-L/usr/local/lib
-_extraincdir=-I/usr/local/include
+_extralibdir="$_extralibdir -L/usr/local/lib"
+_extraincdir="$_extraincdir -I/usr/local/include"
 fi
 
 test -z "$_extralibdir" && _extralibdir=-L/usr/lib


--- MPlayer-20011118/Gui/mplayer/Makefile.DIST	Mon Oct  1 04:30:44 2001
+++ MPlayer-20011118/Gui/mplayer/Makefile	Mon Nov 19 09:02:30 2001
@@ -7,7 +7,7 @@
 
 LIB = mplayer
 
-INCDIR  = -I. -I../event -I../wm -I../skin $(GTKINC)
+INCDIR  = -I. -I../event -I../wm -I../skin $(GTKINC) $(EXTRA_INC)
 
 OPTIMIZE =  $(OPTFLAGS) -fomit-frame-pointer \
 	    -fexpensive-optimizations -fschedule-insns2 -Wall

===>8===

Pretty obvious, really. Seems the configure script set up /usr/local in
the _extra*dir directory variables, but doesn't account for command line
parameters. This should present no problems for the generic install.


As an aside, mplayer is way ahead of xine, at least as far as FreeBSD is
concerned. Sure, xine holds the promise of a killer app, with all sorts
of nice features mplayer doesn't [yet?], but it's still quite unstable
(again, on my FreeBSD boxen). mplayer runs the stuff I've thrown at it
beautifully; xine can barely stay awake through an MPEG. And mplayer
uses less CPU, to boot!

Kudos to the developers,
Dave

-- 
  ______________________                         ______________________
  \__________________   \    D. J. HAWKEY JR.   /   __________________/
     \________________/\     hawkeyd at visi.com    /\________________/
                      http://www.visi.com/~hawkeyd/




More information about the MPlayer-users mailing list