Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Aug 2001 02:22:44 +0200 (CEST)
From:      "Thomas E. Zander" <riggs@f113.hadiko.de>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/29944: graphics/mplayer port
Message-ID:  <200108220022.f7M0Mio80278@f113.hadiko.de>

next in thread | raw e-mail | index | archive | help

>Number:         29944
>Category:       ports
>Synopsis:       graphics/mplayer port
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Aug 21 17:30:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Thomas E. Zander
>Release:        FreeBSD 4.4-RC i386
>Organization:
>Environment:
System: FreeBSD f113.hadiko.de 4.4-RC FreeBSD 4.4-RC #0: Fri Aug 17 00:34:57 CEST 2001 root@f113.hadiko.de:/usr/obj/usr/src/sys/MARVIN i386
>Description:

This is the port of mplayer, a project which has the effort
to become a very stable and useful movie player.

It is based on the windows codec compilation and
provides the ability to play many formats
in a very good quality without much CPU comsumption.

WWW: http://mplayer.sourceforge.net
>How-To-Repeat:
>Fix:

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	/usr/ports/graphics/mplayer
#	/usr/ports/graphics/mplayer/Makefile
#	/usr/ports/graphics/mplayer/distinfo
#	/usr/ports/graphics/mplayer/pkg-descr
#	/usr/ports/graphics/mplayer/pkg-comment
#	/usr/ports/graphics/mplayer/files
#	/usr/ports/graphics/mplayer/files/patch-ac
#	/usr/ports/graphics/mplayer/files/patch-ab
#	/usr/ports/graphics/mplayer/files/install-user
#	/usr/ports/graphics/mplayer/files/patch-ad
#	/usr/ports/graphics/mplayer/files/patch-ae
#	/usr/ports/graphics/mplayer/pkg-plist
#	/usr/ports/graphics/mplayer/pkg-message
#
echo c - /usr/ports/graphics/mplayer
mkdir -p /usr/ports/graphics/mplayer > /dev/null 2>&1
echo x - /usr/ports/graphics/mplayer/Makefile
sed 's/^X//' >/usr/ports/graphics/mplayer/Makefile << 'END-of-/usr/ports/graphics/mplayer/Makefile'
X# New ports collection makefile for:	mplayer
X# Date created:		10 August 2001
X# Whom:			Thomas E. Zander
X#			with lots of help from Vladimir Kushnir
X# $FreeBSD$
X#
X
XPORTNAME=	mplayer
XPORTVERSION=	0.18
XCATEGORIES=	graphics
XMASTER_SITES=	http://mp.dev.hu/MPlayer/releases/ \
X		http://www.stud.uni-karlsruhe.de/~uedc/mplayer/
XDISTNAME=	MPlayer-${PORTVERSION}pre
XEXTRACT_SUFX=	.tgz
X
XMAINTAINER=	riggs@rrr.de
X
XONLY_FOR_ARCHS=	i386
X
XWRKSRC=		${WRKDIR}/MPlayer-${PORTVERSION}pre5
XCONFIGURE_ENV=	PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
X		PTHREAD_LIBS="${PTHREAD_LIBS}"
XCFLAGS+=	-O3 -ffast-math -fomit-frame-pointer
X
XMAN1=		mplayer.1
XMANCOMPRESSED=	no
X
XGNU_CONFIGURE=	yes
XUSE_GMAKE=	yes
XUSE_XLIB=	yes
X
XLIB_DEPENDS=	png.4:${PORTSDIR}/graphics/png
XRUN_DEPENDS=	${PREFIX}/share/mplayer/fonts:${PORTSDIR}/graphics/mplayer-fonts
X
XCONFIGURE_ARGS+=--disable-esd \
X		--enable-mmx2 \
X		--enable-3dnow \
X		--enable-3dnowex
X
X.if defined(WITH_SDL)
XLIB_DEPENDS+=    SDL-1.1.3:${PORTSDIR}/devel/sdl12
X.else
XBUILD_DEPENDS+=  nasm:${PORTSDIR}/devel/nasm
X.endif
X
X.if defined(USE_AVIFILE_CODECS)
XBUILD_DEPENDS+=	${PREFIX}/lib/win32:${PORTSDIR}/graphics/win32-codecs
X.else
XBUILD_DEPENDS+=	${PREFIX}/lib/mplayer-codecs:${PORTSDIR}/graphics/mplayer-codecs
XCONFIGURE_ARGS+=--with-win32libdir=${LOCALBASE}/lib/mplayer-codecs
X.endif
X
Xpost-install:
X	@${MKDIR} ${PREFIX}/share/mplayer
X	@${CHMOD} 755 ${PREFIX}/share/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/codecs.conf ${PREFIX}/share/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/example.conf ${PREFIX}/share/mplayer
X.if !defined(NOPORTDOCS)
X	@${MKDIR} ${PREFIX}/share/doc/mplayer
X	@${CHMOD} 755 ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/DGA ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/FREEBSD ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/MPlayer-FAQ ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/OpenDivX ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/README ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/SDL ${PREFIX}/share/doc/mplayer
X	@${INSTALL_DATA} ${WRKSRC}/DOCS/VIDEOCARDS ${PREFIX}/share/doc/mplayer
X.endif
X	@${CAT} pkg-message
X
Xinstall-user:
X	@${PERL} ${FILESDIR}/install-user
X
X.include <bsd.port.mk>
END-of-/usr/ports/graphics/mplayer/Makefile
echo x - /usr/ports/graphics/mplayer/distinfo
sed 's/^X//' >/usr/ports/graphics/mplayer/distinfo << 'END-of-/usr/ports/graphics/mplayer/distinfo'
XMD5 (MPlayer-0.18pre.tgz) = cc86cd8cdc61d6aea243c6e539b5df2e
END-of-/usr/ports/graphics/mplayer/distinfo
echo x - /usr/ports/graphics/mplayer/pkg-descr
sed 's/^X//' >/usr/ports/graphics/mplayer/pkg-descr << 'END-of-/usr/ports/graphics/mplayer/pkg-descr'
XThis is the port of mplayer, a project which has the effort
Xto become a very stable and useful movie player.
X
XIt is based on the windows codec compilation and
Xprovides the ability to play many formats
Xin a very good quality without much CPU comsumption.
X
XWWW: http://mplayer.sourceforge.net
END-of-/usr/ports/graphics/mplayer/pkg-descr
echo x - /usr/ports/graphics/mplayer/pkg-comment
sed 's/^X//' >/usr/ports/graphics/mplayer/pkg-comment << 'END-of-/usr/ports/graphics/mplayer/pkg-comment'
XHigh performance media player using win32 codecs
END-of-/usr/ports/graphics/mplayer/pkg-comment
echo c - /usr/ports/graphics/mplayer/files
mkdir -p /usr/ports/graphics/mplayer/files > /dev/null 2>&1
echo x - /usr/ports/graphics/mplayer/files/patch-ac
sed 's/^X//' >/usr/ports/graphics/mplayer/files/patch-ac << 'END-of-/usr/ports/graphics/mplayer/files/patch-ac'
X*** ../MPlayer-0.18pre5.old/loader/config.h	Sat Feb 24 22:30:26 2001
X--- loader/config.h	Fri Aug 17 10:14:46 2001
X***************
X*** 56,62 ****
X  #define HAVE_LIMITS_H 1
X  
X  /* Define if you have the <malloc.h> header file.  */
X! #define HAVE_MALLOC_H 1
X  
X  /* Define if you have the <sys/ioctl.h> header file.  */
X  #define HAVE_SYS_IOCTL_H 1
X--- 56,62 ----
X  #define HAVE_LIMITS_H 1
X  
X  /* Define if you have the <malloc.h> header file.  */
X! /* #undef HAVE_MALLOC_H */
X  
X  /* Define if you have the <sys/ioctl.h> header file.  */
X  #define HAVE_SYS_IOCTL_H 1
END-of-/usr/ports/graphics/mplayer/files/patch-ac
echo x - /usr/ports/graphics/mplayer/files/patch-ab
sed 's/^X//' >/usr/ports/graphics/mplayer/files/patch-ab << 'END-of-/usr/ports/graphics/mplayer/files/patch-ab'
X*** /home/volodya/usr/ports/graphics/mplayer/work/MPlayer-0.18pre5/DOCS/FREEBSD	Thu Jun 21 03:06:40 2001
X--- DOCS/FREEBSD	Thu Aug 16 03:54:08 2001
X***************
X*** 6,11 ****
X--- 6,13 ----
X  
X  2. To run mplayer you will need to re-compile the kernel with 
X  "options USER_LDT" (unless you are running -CURRENT, where this is default).
X+ If you have a CPU with SSE also use "options CPU_ENABLE_SSE" to use it
X+ (FreeBSD-STABLE required, or use kernel patches).
X  
X  3. If mplayer complains about "CD-ROM Device '/dev/cdrom' not found!" make a 
X  symbolic link : ln -s /dev/<your_cdrom_device> /dev/cdrom 
END-of-/usr/ports/graphics/mplayer/files/patch-ab
echo x - /usr/ports/graphics/mplayer/files/install-user
sed 's/^X//' >/usr/ports/graphics/mplayer/files/install-user << 'END-of-/usr/ports/graphics/mplayer/files/install-user'
X#This perl script links the codec config file
X#and the fonts dir to the user's home dir.
X
Xif (-e "$ENV{HOME}/.mplayer/")
X{
X	print "Sorry, you should execute this target without having a .mplayer directory in your homedir.\n";
X	exit 1;
X}
X
X#Determining location of fonts:
X
X@pkg=`pkg_info -Lx mplayer-fonts`;
Xprint "$prefix[3]";
X$prefix=$pkg[3];
X$prefix=~ s/(.+mplayer).*/$1/;
Xchop $prefix;
X
Xprint "You may choose any of the available language sets:\n\n";
Xprint "European fonts (e.g. dutch, french, german...) : e\n";
Xprint "Cyrillic fonts : c\n";
Xprint "Russian fonts: r\n";
X
Xprint "Your decision? ";
Xchomp ($lang=<STDIN>);
Xprint "\n";
X
Xsystem "mkdir $ENV{HOME}/.mplayer";
Xif ($lang eq "c")
X{
X	system "ln -s $prefix/fonts/cyrillic/ $ENV{HOME}/.mplayer/font";
X}
Xelsif ($lang eq "r")
X{
X	system "ln -s $prefix/fonts/koi8r/ $ENV{HOME}/.mplayer/font";
X}
Xelse {system "ln -s $prefix/fonts/iso/ $ENV{HOME}/.mplayer/font"};
X
Xsystem "ln -s $prefix/codecs.conf $ENV{HOME}/.mplayer/codecs.conf";
END-of-/usr/ports/graphics/mplayer/files/install-user
echo x - /usr/ports/graphics/mplayer/files/patch-ad
sed 's/^X//' >/usr/ports/graphics/mplayer/files/patch-ad << 'END-of-/usr/ports/graphics/mplayer/files/patch-ad'
X*** configure.orig	Fri Jul  6 23:00:22 2001
X--- configure	Sat Aug 18 22:25:58 2001
X***************
X*** 181,187 ****
X  
X  system_name=`uname -s 2>&1`
X  if [ "$system_name" = "FreeBSD" ]; then
X! _archlibs="-rdynamic -pthread"
X  else
X  _archlibs="-ldl -lpthread"
X  fi
X--- 181,187 ----
X  
X  system_name=`uname -s 2>&1`
X  if [ "$system_name" = "FreeBSD" ]; then
X! _archlibs="-rdynamic ${PTHREAD_LIBS}"
X  else
X  _archlibs="-ldl -lpthread"
X  fi
X***************
X*** 587,593 ****
X  $_cc $_extraincdir $_extralibdir $TMPC -o $TMPO -lvgagl -lvga > /dev/null 2>&1 && _svga=yes
X  
X  if [ "$system_name" = "FreeBSD" ]; then
X! $_cc $TMPC -o $TMPO -pthread > /dev/null 2>&1 || \
X   { echo "Lib pthread not found."; rm -f $TMPC $TMPO $TMPS ; exit 1; }
X  else
X  $_cc $TMPC -o $TMPO -lpthread > /dev/null 2>&1 || \
X--- 587,593 ----
X  $_cc $_extraincdir $_extralibdir $TMPC -o $TMPO -lvgagl -lvga > /dev/null 2>&1 && _svga=yes
X  
X  if [ "$system_name" = "FreeBSD" ]; then
X! $_cc $TMPC -o $TMPO ${PTHREAD_LIBS} > /dev/null 2>&1 || \
X   { echo "Lib pthread not found."; rm -f $TMPC $TMPO $TMPS ; exit 1; }
X  else
X  $_cc $TMPC -o $TMPO -lpthread > /dev/null 2>&1 || \
X***************
X*** 669,675 ****
X  $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXxf86vm $_socklib > /dev/null 2>&1 && _vm=yes
X  
X  if [ "$system_name" = "FreeBSD" ]; then
X! $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL -pthread $_socklib > /dev/null 2>&1 && _gl=yes
X  else
X  $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL $_socklib > /dev/null 2>&1 && _gl=yes
X  fi
X--- 669,675 ----
X  $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXxf86vm $_socklib > /dev/null 2>&1 && _vm=yes
X  
X  if [ "$system_name" = "FreeBSD" ]; then
X! $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL ${PTHREAD_LIBS} $_socklib > /dev/null 2>&1 && _gl=yes
X  else
X  $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL $_socklib > /dev/null 2>&1 && _gl=yes
X  fi
X***************
X*** 679,685 ****
X  int main( void ) { return 0; }
X  EOF
X  if [ "$system_name" = "FreeBSD" ]; then
X! $_cc $_x11incdir $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL -pthread $_socklib > /dev/null 2>&1 || \
X   { _gl=no; echo "GL includes not found!";}
X  else
X  $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL $_socklib > /dev/null 2>&1 || \
X--- 679,685 ----
X  int main( void ) { return 0; }
X  EOF
X  if [ "$system_name" = "FreeBSD" ]; then
X! $_cc $_x11incdir $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL ${PTHREAD_LIBS} $_socklib > /dev/null 2>&1 || \
X   { _gl=no; echo "GL includes not found!";}
X  else
X  $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL $_socklib > /dev/null 2>&1 || \
X***************
X*** 1162,1168 ****
X     if [ "$system_name" = "FreeBSD" ]; then
X        # Under XFree86 4.x GL port is poorly designed
X        if [ -r /usr/X11R6/bin/XFree86 ]; then
X!          _gllib='-lGL -pthread'
X        else
X           _gllib='-lGL'
X        fi
X--- 1162,1168 ----
X     if [ "$system_name" = "FreeBSD" ]; then
X        # Under XFree86 4.x GL port is poorly designed
X        if [ -r /usr/X11R6/bin/XFree86 ]; then
X!          _gllib="-lGL ${PTHREAD_LIBS}"
X        else
X           _gllib='-lGL'
X        fi
X***************
X*** 1329,1335 ****
X  # Under FreeBSD (maybe other systems as well?) we have to add to CFLAGS
X  # for MT applications: 
X  if [ "$system_name" = "FreeBSD" ]; then
X! CFLAGS="$CFLAGS -D_THREAD_SAFE"
X  fi
X  
X  # echo 'CFLAGS=$(OPTFLAGS) -Wall -DMPG12PLAY' >> config.mak
X--- 1329,1335 ----
X  # Under FreeBSD (maybe other systems as well?) we have to add to CFLAGS
X  # for MT applications: 
X  if [ "$system_name" = "FreeBSD" ]; then
X! CFLAGS="$CFLAGS ${PTHREAD_CFLAGS}"
X  fi
X  
X  # echo 'CFLAGS=$(OPTFLAGS) -Wall -DMPG12PLAY' >> config.mak
END-of-/usr/ports/graphics/mplayer/files/patch-ad
echo x - /usr/ports/graphics/mplayer/files/patch-ae
sed 's/^X//' >/usr/ports/graphics/mplayer/files/patch-ae << 'END-of-/usr/ports/graphics/mplayer/files/patch-ae'
X--- Makefile	Sun Jul  8 02:21:20 2001
X+++ Makefile.freebsd	Wed Aug 15 19:23:54 2001
X@@ -85,14 +85,14 @@
X $(PRG_CFG):        version.h codec-cfg.c codec-cfg.h
X 	$(CC) $(CFLAGS) -g codec-cfg.c -o $(PRG_CFG) -DCODECS2HTML
X 
X-install: $(PRG) $(PRG_FIBMAP)
X-	install -D -m 755 -s $(PRG) $(BINDIR)/$(PRG)
X-	install -D -m 644 DOCS/mplayer.1 $(prefix)/man/man1/mplayer.1
X-	@echo "Following task requires root privs. If it fails don't panic"
X-	@echo "however it means you can't use fibmap_mplayer."
X-	@echo "Without this (or without running mplayer as root) you won't be"
X-	@echo "able to play DVDs."
X-	install -D -o root -g root -m 4755 -s $(PRG_FIBMAP) $(BINDIR)/$(PRG_FIBMAP)
X+install: $(PRG)
X+	install -C -m 755 -s $(PRG) $(BINDIR)/$(PRG)
X+	install -C -m 644 DOCS/mplayer.1 $(prefix)/man/man1/mplayer.1
X+#	@echo "Following task requires root privs. If it fails don't panic"
X+#	@echo "however it means you can't use fibmap_mplayer."
X+#	@echo "Without this (or without running mplayer as root) you won't be"
X+#	@echo "able to play DVDs."
X+#	install -D -o root -g root -m 4755 -s $(PRG_FIBMAP) $(BINDIR)/$(PRG_FIBMAP)
X 
X clean:
X 	rm -f *.o *~ $(OBJS)
END-of-/usr/ports/graphics/mplayer/files/patch-ae
echo x - /usr/ports/graphics/mplayer/pkg-plist
sed 's/^X//' >/usr/ports/graphics/mplayer/pkg-plist << 'END-of-/usr/ports/graphics/mplayer/pkg-plist'
Xbin/mplayer
Xshare/doc/mplayer/DGA
Xshare/doc/mplayer/FREEBSD
Xshare/doc/mplayer/MPlayer-FAQ
Xshare/doc/mplayer/OpenDivX
Xshare/doc/mplayer/README
Xshare/doc/mplayer/SDL
Xshare/doc/mplayer/VIDEOCARDS
Xshare/mplayer/codecs.conf
Xshare/mplayer/example.conf
X@dirrm share/doc/mplayer
X@dirrm share/mplayer
END-of-/usr/ports/graphics/mplayer/pkg-plist
echo x - /usr/ports/graphics/mplayer/pkg-message
sed 's/^X//' >/usr/ports/graphics/mplayer/pkg-message << 'END-of-/usr/ports/graphics/mplayer/pkg-message'
XThis port provides a simple and easy to use
Xpossibility for any user to make mplayer ready
Xto run with a working codecs.conf and the
Xright font by logging in with the username,
Xthen cd to the mplayer port directory and
Xenter:
X
Xmake install-user
X
XPlease take a look at docs in
X/usr/local/share/doc/mplayer
END-of-/usr/ports/graphics/mplayer/pkg-message
exit

>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200108220022.f7M0Mio80278>