ports/98914: [PATCH] multimedia/mplayer: Fix x264-encoder inclusion

Mark Daniel Reidel ports at mark.reidel.info
Tue Jun 13 21:00:31 UTC 2006


>Number:         98914
>Category:       ports
>Synopsis:       [PATCH] multimedia/mplayer: Fix x264-encoder inclusion
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jun 13 21:00:26 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Mark Daniel Reidel
>Release:        FreeBSD 6.1-RELEASE i386
>Organization:
>Environment:
System: FreeBSD raffi.reidel.info 6.1-RELEASE FreeBSD 6.1-RELEASE #1: Wed May 31 06:45:17 CEST 2006
>Description:
When compiling mplayer against x264, configure says it's unavailable
because it does not link the test-program with -pthread.

The attached patch removes the static -lx264 and replaces it
with the accurate `pkg-config --libs x264`, so the linker finds
all the symbols needed. After that, mencoder can finally encode
x264-movies.

Port maintainer (riggs at rrr.de) is cc'd.
>How-To-Repeat:
>Fix:

--- mplayer-0.99.7_14.patch begins here ---
diff -ruN --exclude=CVS /var/tmp/portbackup/multimedia/mplayer/files/patch-ad /usr/ports/multimedia/mplayer/files/patch-ad
--- /var/tmp/portbackup/multimedia/mplayer/files/patch-ad	Tue Jun 13 22:50:16 2006
+++ /usr/ports/multimedia/mplayer/files/patch-ad	Tue Jun 13 22:47:16 2006
@@ -152,7 +152,7 @@
    fi
    # internal faad: check if our dear gcc is able to compile it...
    cp "`pwd`/libfaad2/cfft.c" $TMPC
-@@ -5935,7 +5874,7 @@
+@@ -5935,12 +5878,12 @@
  cat > $TMPC << EOF
  #include <inttypes.h>
  #include <x264.h>
@@ -161,6 +161,12 @@
  #error We do not support old versions of x264. Get the latest from SVN.
  #endif
  int main(void) { x264_encoder_open((void*)0); return 0; }
+ EOF
+-_ld_x264="$_ld_x264 -lx264 $_ld_lm"
++_ld_x264="$_ld_x264 `pkg-config --libs x264` $_ld_lm"
+ if test "$_x264" != no && cc_check $_inc_x264 $_ld_x264 ; then
+   _x264=yes
+   _def_x264='#define HAVE_X264 1'
 @@ -6115,8 +6054,11 @@
   if test "$_tv" = yes ; then
      cat > $TMPC <<EOF
--- mplayer-0.99.7_14.patch ends here ---

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



More information about the freebsd-ports-bugs mailing list