Subject: pkg/24018: add Matroska support to graphics/mplayer-share
To: None <gnats-bugs@gnats.netbsd.org>
From: Rhialto <rhialto@azenomei.knuffel.net>
List: netbsd-bugs
Date: 01/08/2004 00:11:12
>Number:         24018
>Category:       pkg
>Synopsis:       add Matroska support to graphics/mplayer-share
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Wed Jan 07 23:12:01 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator:     Rhialto
>Release:        NetBSD 1.6
>Organization:
	
>Environment:
System: NetBSD azenomei.falu.nl 1.6 NetBSD 1.6 (AZENOMEI) #4: Fri Oct 3 00:48:25 CEST 2003 root@azenomei.falu.nl:/usr/src/sys/arch/alpha/compile/AZENOMEI alpha
Architecture: alpha
Machine: alpha
>Description:
	This depends on my earlier submissions of libmatroska (pkg/24017)
	and libebml (pkg/24016).
	It adds support for the Matroska container format to MPlayer.
	This has been tested by viewing a .mtk file on i386.
>How-To-Repeat:
>Fix:
	Replaces patch-aa since configure needs a small extra patch.
	Includes some more buildlink2 files in Makefile.depends.

Index: Makefile.depends
===================================================================
RCS file: /cvsroot/pkgsrc/graphics/mplayer-share/Makefile.depends,v
retrieving revision 1.24
diff -u -r1.24 Makefile.depends
--- Makefile.depends	2003/12/12 22:09:02	1.24
+++ Makefile.depends	2004/01/07 23:04:08
@@ -32,10 +32,12 @@
 .include "../../audio/libmad/buildlink2.mk"
 .include "../../audio/libvorbis/buildlink2.mk"
 .include "../../converters/libiconv/buildlink2.mk"
+.include "../../devel/libebml/buildlink2.mk"
 .include "../../graphics/jpeg/buildlink2.mk"
 .include "../../graphics/libungif/buildlink2.mk"
 .include "../../graphics/png/buildlink2.mk"
 .include "../../graphics/xvidcore/buildlink2.mk"
+.include "../../graphics/libmatroska/buildlink2.mk"
 .include "../../misc/libdvdread/buildlink2.mk"
 
 .if defined(USE_OSS)


A new patches/patch-aa:

$NetBSD: patch-aa,v 1.8 2003/12/12 22:09:02 wiz Exp $

--- configure.orig	Mon Dec  8 22:33:31 2003
+++ configure	Wed Jan  7 23:24:01 2004
@@ -367,8 +367,8 @@
     _inc_extra=-I`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -I,g'`
     ;;
   --with-extralibdir=*)
-    _ld_extra=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'`
-#    _ld_extra="${_ld_extra} -Wl,-R"`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -Wl\,-R,g'`" -L"`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'`
+#    _ld_extra=-L`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'`
+    _ld_extra="${_ld_extra} -Wl,-R"`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -Wl\,-R,g'`" -L"`echo $ac_option | cut -d '=' -f 2 | sed 's,:, -L,g'`
     ;;
   --enable-runtime-cpudetection)
     _runtime_cpudetection=yes
@@ -431,7 +431,7 @@
       case "`( uname -m ) 2>&1`" in
       i[3-9]86*|x86|x86pc|k5|k6|k6_2|k6_3|k6-2|k6-3|pentium*|athlon*|i586_i686|i586-i686) host_arch=i386 ;;
       ia64) host_arch=ia64 ;;
-      x86_64) host_arch=x86_64 ;;
+      x86_64|amd64) host_arch=x86_64 ;;
       ppc) host_arch=ppc ;;
       alpha) host_arch=alpha ;;
       sparc*) host_arch=sparc ;;
@@ -499,7 +499,7 @@
  for _cc in "$_cc" gcc gcc-3.3 gcc-3.2 gcc-3.1 gcc3 gcc-3.0 cc ; do
   echocheck "$_cc version"
   cc_name=`( $_cc -v ) 2>&1 | tail -1 | cut -d ' ' -f 1`
-  cc_version=`( $_cc -dumpversion ) 2>&1`
+  cc_version=`( $_cc -dumpversion | sed -e 's/-nb[0-9]//' ) 2>&1`
   if test "$?" -gt 0; then
     cc_version="not found"
   fi
@@ -819,7 +819,7 @@
     _optimizing=''
     ;;
 
-  x86_64)
+  x86_64|amd64)
     _def_arch='#define ARCH_X86_64 1'
     _target_arch='TARGET_ARCH_X86_64 = yes'
     iproc='x86_64'
@@ -4491,11 +4491,11 @@
 
 int main(void) { return 0; }
 EOF
-  cc_check -lmatroska -lebml -lstdc++ && _matroska=yes
+  cc_check -lmatroska -lebml -lstdc++ -lm && _matroska=yes
   if test "$_matroska" = no ; then
     _saved_inc_extra=$_inc_extra
     _inc_extra="$_inc_extra -I/usr/local/include"
-    cc_check -lmatroska -lebml -lstdc++ && _matroska=yes
+    cc_check -lmatroska -lebml -lstdc++ -lm && _matroska=yes
     if test "$_matroska" = no ; then
       _inc_extra=$_saved_inc_extra
     fi


-Olaf.
-- 
___ Olaf 'Rhialto' Seibert
\X/ rhialto/at/xs4all.nl        -- Cetero censeo "authored" delendum esse.
>Release-Note:
>Audit-Trail:
>Unformatted: