aboutsummaryrefslogtreecommitdiff
path: root/multimedia/libquicktime
diff options
context:
space:
mode:
authorWilliam Grzybowski <wg@FreeBSD.org>2013-10-19 16:43:32 +0000
committerWilliam Grzybowski <wg@FreeBSD.org>2013-10-19 16:43:32 +0000
commit3624ddf181da71b2f213d44844a13f92e7088879 (patch)
tree69155a2473ecd42904d8ae76e85c62fefb67950b /multimedia/libquicktime
parent553546281034fefe3b27f6114931d6bbce236d38 (diff)
downloadports-3624ddf181da71b2f213d44844a13f92e7088879.tar.gz
ports-3624ddf181da71b2f213d44844a13f92e7088879.zip
multimedia/ffmpeg: update to 2.0.1
- Update main ffmpeg port to 2.0.1 - Bump and update dependent ports when necessary (API change) Approved by: portmgr (bapt)
Notes
Notes: svn path=/head/; revision=330909
Diffstat (limited to 'multimedia/libquicktime')
-rw-r--r--multimedia/libquicktime/Makefile46
-rw-r--r--multimedia/libquicktime/files/patch-ffmpeg296
-rw-r--r--multimedia/libquicktime/pkg-plist2
3 files changed, 111 insertions, 33 deletions
diff --git a/multimedia/libquicktime/Makefile b/multimedia/libquicktime/Makefile
index c38d5f01313f..42e5b8ebd007 100644
--- a/multimedia/libquicktime/Makefile
+++ b/multimedia/libquicktime/Makefile
@@ -8,18 +8,17 @@ CATEGORIES= multimedia
MASTER_SITES= SF
MAINTAINER= ports@FreeBSD.org
-COMMENT= A library for reading and writing quicktime files
+COMMENT= library for reading and writing quicktime files
.if !defined(_BUILDING_LIBQUICKTIME_PLUGINS)
-LIB_DEPENDS= vorbis.4:${PORTSDIR}/audio/libvorbis
+LIB_DEPENDS= libvorbis.so:${PORTSDIR}/audio/libvorbis
.endif
LICENSE= LGPL21
LICENSE_FILE= ${WRKSRC}/COPYING
USE_LDCONFIG= yes
-USES= pathfix pkgconfig gettext
-USE_GMAKE= yes
+USES= gmake pathfix pkgconfig gettext
USE_AUTOTOOLS= autoconf
CPPFLAGS+= -I${LOCALBASE}/include ${PTHREAD_CFLAGS}
@@ -34,6 +33,7 @@ MAN1= lqtplay.1
OPTIONS_DEFINE= ALSA DV FAAC FAAD FFMPEG GTK2 JPEG OPENGL OPTIMIZED_CFLAGS PNG \
SCHROEDINGER X264 DOCS
OPTIONS_DEFAULT= FFMPEG JPEG OPENGL PNG SCHROEDINGER X264
+OPTIONS_SUB= yes
PORTDOCS= api_usage.html codecs.html qt4l_building.html \
qt4l_codecs.html qt4l_index.html \
@@ -56,14 +56,12 @@ CONFIGURE_ARGS+= --without-cpuflags
.if ${PORT_OPTIONS:MGTK2}
USE_GNOME+= gtk20
CONFIGURE_ARGS+= --with-gtk
-PLIST_SUB+= GTK=""
.else
CONFIGURE_ARGS+= --without-gtk
-PLIST_SUB+= GTK="@comment "
.endif
.if ${PORT_OPTIONS:MALSA}
-LIB_DEPENDS= asound.2:${PORTSDIR}/audio/alsa-lib
+LIB_DEPENDS= libasound.so:${PORTSDIR}/audio/alsa-lib
.else
CONFIGURE_ARGS+= --without-alsa
.endif
@@ -76,73 +74,57 @@ CONFIGURE_ARGS+= --without-opengl
.endif
.if ${PORT_OPTIONS:MDV}
-LIB_DEPENDS+= dv.4:${PORTSDIR}/multimedia/libdv
-PLIST_SUB+= DV=""
+LIB_DEPENDS+= libdv.so:${PORTSDIR}/multimedia/libdv
CONFIGURE_ARGS+= --with-libdv
.else
-PLIST_SUB+= DV="@comment "
CONFIGURE_ARGS+= --without-libdv
.endif
.if ${PORT_OPTIONS:MJPEG}
-LIB_DEPENDS+= jpeg.11:${PORTSDIR}/graphics/jpeg
-PLIST_SUB+= JPEG=""
+LIB_DEPENDS+= libjpeg.so:${PORTSDIR}/graphics/jpeg
CONFIGURE_ARGS+= --with-libjpeg
.else
-PLIST_SUB+= JPEG="@comment "
CONFIGURE_ARGS+= --without-libjpeg
.endif
.if ${PORT_OPTIONS:MPNG}
-LIB_DEPENDS+= png15:${PORTSDIR}/graphics/png
-PLIST_SUB+= PNG=""
+LIB_DEPENDS+= libpng15.so:${PORTSDIR}/graphics/png
CONFIGURE_ARGS+= --with-libpng
.else
-PLIST_SUB+= PNG="@comment "
CONFIGURE_ARGS+= --without-libpng
.endif
.if ${PORT_OPTIONS:MFFMPEG}
-LIB_DEPENDS+= avcodec.1:${PORTSDIR}/multimedia/ffmpeg
-PLIST_SUB+= FFMPEG=""
+LIB_DEPENDS+= libavcodec.so:${PORTSDIR}/multimedia/ffmpeg
CONFIGURE_ARGS+= --with-ffmpeg
.else
-PLIST_SUB+= FFMPEG="@comment "
CONFIGURE_ARGS+= --without-ffmpeg
.endif
.if ${PORT_OPTIONS:MFAAC}
-LIB_DEPENDS+= faac.0:${PORTSDIR}/audio/faac
-PLIST_SUB+= FAAC=""
+LIB_DEPENDS+= libfaac.so:${PORTSDIR}/audio/faac
CONFIGURE_ARGS+= --with-faac
.else
-PLIST_SUB+= FAAC="@comment "
CONFIGURE_ARGS+= --without-faac
.endif
.if ${PORT_OPTIONS:MFAAD}
-LIB_DEPENDS+= faad.2:${PORTSDIR}/audio/faad
-PLIST_SUB+= FAAD=""
+LIB_DEPENDS+= libfaad.so:${PORTSDIR}/audio/faad
CONFIGURE_ARGS+= --with-faad2
.else
-PLIST_SUB+= FAAD="@comment "
CONFIGURE_ARGS+= --without-faad2
.endif
.if ${PORT_OPTIONS:MX264}
-LIB_DEPENDS+= x264:${PORTSDIR}/multimedia/x264
-PLIST_SUB+= X264=""
+LIB_DEPENDS+= libx264.so:${PORTSDIR}/multimedia/x264
CONFIGURE_ARGS+= --with-x264
.else
-PLIST_SUB+= X264="@comment "
CONFIGURE_ARGS+= --without-x264
.endif
.if ${PORT_OPTIONS:MSCHROEDINGER}
-LIB_DEPENDS+= schroedinger-1.0.11:${PORTSDIR}/multimedia/schroedinger
-PLIST_SUB+= SCHROEDINGER=""
+LIB_DEPENDS+= libschroedinger-1.0.so:${PORTSDIR}/multimedia/schroedinger
.else
-PLIST_SUB+= SCHROEDINGER="@comment "
CONFIGURE_ARGS+= --without-schroedinger
.endif
@@ -155,7 +137,7 @@ post-patch:
@${REINPLACE_CMD} -e 's|stdint.h|inttypes.h|' \
${WRKSRC}/plugins/audiocodec/* \
${WRKSRC}/plugins/videocodec/*
- @${REINPLACE_CMD} -e '/objformat=/s|=.*|=elf|' ${WRKSRC}/configure
+ @${REINPLACE_CMD} -E -e 's|objformat=aout|objformat=elf|g' ${WRKSRC}/configure
@${REINPLACE_CMD} -e 's|-DG.*_DISABLE_DEPRECATED||g' \
${WRKSRC}/configure*
diff --git a/multimedia/libquicktime/files/patch-ffmpeg2 b/multimedia/libquicktime/files/patch-ffmpeg2
new file mode 100644
index 000000000000..c7d9cc6f8897
--- /dev/null
+++ b/multimedia/libquicktime/files/patch-ffmpeg2
@@ -0,0 +1,96 @@
+Extracted from upstream CVS.
+Index: plugins/ffmpeg/audio.c
+===================================================================
+--- plugins/ffmpeg/audio.c.orig
++++ plugins/ffmpeg/audio.c
+@@ -45,6 +45,11 @@
+ #define ENCODE_AUDIO 1
+ #endif
+
++#ifndef AVCODEC_MAX_AUDIO_FRAME_SIZE
++/* from libavcodec/avcodec.h dated Dec 23 2012 */
++#define AVCODEC_MAX_AUDIO_FRAME_SIZE 192000 // 1 second of 48khz 32bit audio
++#endif
++
+ /* The following code was ported from gmerlin_avdecoder (http://gmerlin.sourceforge.net) */
+
+ /* MPEG Audio header parsing code */
+Index: plugins/ffmpeg/params.c
+===================================================================
+--- plugins/ffmpeg/params.c.orig
++++ plugins/ffmpeg/params.c
+@@ -101,6 +101,17 @@ typedef struct
+ } \
+ }
+
++#define PARAM_DICT_INT(name, dict_name) \
++ { \
++ if(!strcasecmp(name, key)) \
++ { \
++ char buf[128]; \
++ snprintf(buf, sizeof(buf), "%d", *(int*)value); \
++ av_dict_set(options, dict_name, buf, 0); \
++ found = 1; \
++ } \
++ }
++
+ #define PARAM_DICT_FLAG(name, dict_name) \
+ { \
+ if(!strcasecmp(name, key)) \
+@@ -202,8 +213,15 @@ void lqt_ffmpeg_set_parameter(AVCodecCon
+ PARAM_INT("ff_max_b_frames",max_b_frames);
+ PARAM_FLOAT("ff_b_quant_factor",b_quant_factor);
+ PARAM_INT("ff_b_frame_strategy",b_frame_strategy);
++
++#if LIBAVCODEC_VERSION_MAJOR >= 55
++ PARAM_DICT_INT("ff_luma_elim_threshold","luma_elim_threshold");
++ PARAM_DICT_INT("ff_chroma_elim_threshold","chroma_elim_threshold");
++#else
+ PARAM_INT("ff_luma_elim_threshold",luma_elim_threshold);
+ PARAM_INT("ff_chroma_elim_threshold",chroma_elim_threshold);
++#endif
++
+ PARAM_INT("ff_strict_std_compliance",strict_std_compliance);
+ PARAM_QP2LAMBDA("ff_b_quant_offset",b_quant_offset);
+ PARAM_INT("ff_rc_min_rate",rc_min_rate);
+@@ -241,8 +259,15 @@ void lqt_ffmpeg_set_parameter(AVCodecCon
+ PARAM_QP2LAMBDA("ff_lmax", lmax);
+ PARAM_INT("ff_noise_reduction",noise_reduction);
+ PARAM_INT_SCALE("ff_rc_initial_buffer_occupancy",rc_initial_buffer_occupancy,1000);
++
++#if LIBAVCODEC_VERSION_MAJOR >= 55
++ PARAM_DICT_INT("ff_inter_threshold","inter_threshold");
++ PARAM_DICT_INT("ff_quantizer_noise_shaping","quantizer_noise_shaping");
++#else
+ PARAM_INT("ff_inter_threshold",inter_threshold);
+ PARAM_INT("ff_quantizer_noise_shaping",quantizer_noise_shaping);
++#endif
++
+ PARAM_INT("ff_thread_count",thread_count);
+ PARAM_INT("ff_me_threshold",me_threshold);
+ PARAM_INT("ff_mb_threshold",mb_threshold);
+@@ -272,8 +297,16 @@ void lqt_ffmpeg_set_parameter(AVCodecCon
+ PARAM_FLAG("ff_flag_bitexact",CODEC_FLAG_BITEXACT);
+ PARAM_FLAG("ff_flag_ac_pred",CODEC_FLAG_AC_PRED);
+ // PARAM_FLAG("ff_flag_h263p_umv",CODEC_FLAG_H263P_UMV); // Unused
++
++#if LIBAVCODEC_VERSION_MAJOR >= 55
++ PARAM_DICT_FLAG("ff_flag_cbp_rd","cbp_rd");
++ PARAM_DICT_FLAG("ff_flag_qp_rd","qp_rd");
++ PARAM_DICT_FLAG("ff_flag2_strict_gop","strict_gop");
++#else
+ PARAM_FLAG("ff_flag_cbp_rd",CODEC_FLAG_CBP_RD);
+ PARAM_FLAG("ff_flag_qp_rd",CODEC_FLAG_QP_RD);
++ PARAM_FLAG2("ff_flag2_strict_gop",CODEC_FLAG2_STRICT_GOP);
++#endif
+
+ #if LIBAVCODEC_VERSION_MAJOR >= 54
+ PARAM_DICT_FLAG("ff_flag_h263p_aiv", "aiv");
+@@ -288,7 +321,6 @@ void lqt_ffmpeg_set_parameter(AVCodecCon
+ PARAM_FLAG("ff_flag_loop_filter",CODEC_FLAG_LOOP_FILTER);
+ PARAM_FLAG("ff_flag_closed_gop",CODEC_FLAG_CLOSED_GOP);
+ PARAM_FLAG2("ff_flag2_fast",CODEC_FLAG2_FAST);
+- PARAM_FLAG2("ff_flag2_strict_gop",CODEC_FLAG2_STRICT_GOP);
+ PARAM_ENUM("ff_coder_type",coder_type,coder_type);
+
+ }
diff --git a/multimedia/libquicktime/pkg-plist b/multimedia/libquicktime/pkg-plist
index 5c85b437c411..95f6100d716a 100644
--- a/multimedia/libquicktime/pkg-plist
+++ b/multimedia/libquicktime/pkg-plist
@@ -1,4 +1,4 @@
-%%GTK%%bin/libquicktime_config
+%%GTK2%%bin/libquicktime_config
bin/lqt_transcode
bin/lqtplay
bin/lqtremux