FFmpeg is a complete, cross-platform solution to record, convert
and stream audio and video. It includes libavcodec - the leading audio/video codec library.
This commit is contained in:
parent
249c2baf0f
commit
c49c03dd59
14 changed files with 648 additions and 0 deletions
3
multimedia/ffmpeg2/DESCR
Normal file
3
multimedia/ffmpeg2/DESCR
Normal file
|
@ -0,0 +1,3 @@
|
|||
FFmpeg is a complete, cross-platform solution to record, convert
|
||||
and stream audio and video. It includes libavcodec - the leading
|
||||
audio/video codec library.
|
57
multimedia/ffmpeg2/Makefile
Normal file
57
multimedia/ffmpeg2/Makefile
Normal file
|
@ -0,0 +1,57 @@
|
|||
# $NetBSD: Makefile,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
PKGNAME= ${DISTNAME:S/ffmpeg/ffmpeg2/}
|
||||
MAINTAINER= pkgsrc-users@NetBSD.org
|
||||
HOMEPAGE= http://ffmpeg.mplayerhq.hu/
|
||||
COMMENT= Decoding, encoding and streaming software
|
||||
|
||||
CONFIGURE_ARGS+= --enable-avfilter
|
||||
#CONFIGURE_ARGS+= --enable-avfilter-lavf
|
||||
CONFIGURE_ARGS+= --enable-postproc
|
||||
|
||||
INSTALLATION_DIRS= lib share/doc/ffmpeg2 share/examples/ffmpeg2
|
||||
|
||||
CONF_FILES+= ${PREFIX}/share/examples/ffmpeg2/ffserver.conf \
|
||||
${PKG_SYSCONFDIR}/ffserver.conf
|
||||
|
||||
.include "../../mk/bsd.prefs.mk"
|
||||
|
||||
.if !empty(USE_CROSS_COMPILE:M[yY][eE][sS])
|
||||
CONFIGURE_ARGS+= --enable-cross-compile
|
||||
CONFIGURE_ARGS+= --arch=${MACHINE_ARCH}
|
||||
CONFIGURE_ARGS+= --host-cc=${NATIVE_CC:Q}
|
||||
CONFIGURE_ARGS+= --host-ld=${NATIVE_CC:Q}
|
||||
CONFIGURE_ARGS+= --target-os=${LOWER_OPSYS}
|
||||
.endif
|
||||
|
||||
TEST_TARGET= check
|
||||
|
||||
post-install:
|
||||
${INSTALL_DATA} ${WRKSRC}/doc/*.txt \
|
||||
${DESTDIR}${PREFIX}/share/doc/ffmpeg2
|
||||
${INSTALL_DATA} ${WRKSRC}/doc/ffserver.conf \
|
||||
${DESTDIR}${PREFIX}/share/examples/ffmpeg2
|
||||
|
||||
.include "options.mk"
|
||||
|
||||
.include "../../mk/compiler.mk"
|
||||
|
||||
# disable asm on i386 for non-gcc and gcc < 4.2
|
||||
# no alignment options needed for gcc >= 4.6 on i386
|
||||
.if ${MACHINE_ARCH} == "i386"
|
||||
. if !empty(MACHINE_PLATFORM:MDarwin-*-i386) \
|
||||
|| !empty(MACHINE_PLATFORM:MSunOS-*-i386)
|
||||
CONFIGURE_ARGS+= --disable-asm
|
||||
. elif !empty(CC_VERSION:Mgcc-4.[2345]*)
|
||||
CFLAGS+=-mstackrealign -mpreferred-stack-boundary=4
|
||||
. elif !empty(CC_VERSION:Mgcc-[123]*) \
|
||||
|| !empty(CC_VERSION:Mgcc-4.[01]*) || empty(CC_VERSION:Mgcc*)
|
||||
CONFIGURE_ARGS+= --disable-asm
|
||||
. endif
|
||||
.endif
|
||||
|
||||
.if !empty(PKGSRC_COMPILER:Mclang)
|
||||
CFLAGS+= -no-integrated-as
|
||||
.endif
|
||||
|
||||
.include "../../multimedia/ffmpeg2/Makefile.common"
|
96
multimedia/ffmpeg2/Makefile.common
Normal file
96
multimedia/ffmpeg2/Makefile.common
Normal file
|
@ -0,0 +1,96 @@
|
|||
# $NetBSD: Makefile.common,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
# used by multimedia/ffmpeg2/Makefile
|
||||
# used by multimedia/ffplay2/Makefile
|
||||
|
||||
DISTNAME= ffmpeg-2.0
|
||||
CATEGORIES= multimedia
|
||||
MASTER_SITES= http://www.ffmpeg.org/releases/
|
||||
EXTRACT_SUFX= .tar.bz2
|
||||
|
||||
LICENSE= gnu-lgpl-v2.1 AND gnu-gpl-v2
|
||||
|
||||
PREV_PKGPATH= multimedia/ffmpeg-devel
|
||||
PATCHDIR= ${.CURDIR}/../../multimedia/ffmpeg2/patches
|
||||
|
||||
USE_LANGUAGES= c99
|
||||
USE_LIBTOOL= yes
|
||||
USE_TOOLS+= gmake texi2html pod2man
|
||||
HAS_CONFIGURE= yes
|
||||
CONFIGURE_ARGS+= --cc=${CC:Q}
|
||||
CONFIGURE_ARGS+= --disable-debug
|
||||
CONFIGURE_ARGS+= --disable-optimizations
|
||||
CONFIGURE_ARGS+= --disable-stripping
|
||||
CONFIGURE_ARGS+= --enable-shared
|
||||
CONFIGURE_ARGS+= --enable-pthreads
|
||||
CONFIGURE_ARGS+= --enable-gpl
|
||||
CONFIGURE_ARGS+= --mandir=${PREFIX}/${PKGMANDIR}
|
||||
CONFIGURE_ARGS+= --prefix=${PREFIX}
|
||||
|
||||
CONFIGURE_ARGS+= --progs-suffix=2
|
||||
CONFIGURE_ARGS+= --datadir=${PREFIX}/share/ffmpeg2
|
||||
CONFIGURE_ARGS+= --incdir=${PREFIX}/include/ffmpeg2
|
||||
CONFIGURE_ARGS+= --libdir=${PREFIX}/lib/ffmpeg2
|
||||
CONFIGURE_ARGS+= --shlibdir=${PREFIX}/lib/ffmpeg2
|
||||
|
||||
PLIST_VARS+= opencl
|
||||
|
||||
.if ${OPSYS} == "Darwin"
|
||||
CONFIGURE_ARGS+= --enable-opencl
|
||||
PLIST.opencl= yes
|
||||
.endif
|
||||
|
||||
.if ${OPSYS} == "SunOS"
|
||||
CONFIGURE_ARGS+= --disable-amd3dnow
|
||||
CONFIGURE_ARGS+= --disable-amd3dnowext
|
||||
CONFIGURE_ARGS+= --disable-mmx
|
||||
CONFIGURE_ARGS+= --disable-sse
|
||||
CONFIGURE_ARGS+= --disable-ssse3
|
||||
.else
|
||||
CONFIGURE_ARGS+= --enable-runtime-cpudetect
|
||||
.endif
|
||||
|
||||
# No posix_memalign() in NetBSD 4.0 and earlier
|
||||
.if !empty(MACHINE_PLATFORM:MNetBSD-[1-4].*-*)
|
||||
CONFIGURE_ARGS+= --enable-memalign-hack
|
||||
.endif
|
||||
|
||||
# Let's not put garbage into /tmp
|
||||
CONFIGURE_ENV+= TMPDIR=${WRKSRC}/tmp
|
||||
|
||||
.include "../../mk/compiler.mk"
|
||||
|
||||
.if ${OPSYS} == "SunOS" && empty(CC_VERSION:Mgcc*)
|
||||
SUBST_CLASSES+= sunwspro
|
||||
SUBST_MESSAGE.sunwspro= Fixing compiler options for SunStudio C compiler.
|
||||
SUBST_STAGE.sunwspro= post-configure
|
||||
SUBST_FILES.sunwspro= config.mak
|
||||
SUBST_SED.sunwspro= -e "s/-O /-KPIC -DPIC /"
|
||||
SUBST_SED.sunwspro+= -e "s/-O3/-xO2/g"
|
||||
SUBST_SED.sunwspro+= -e "s/-std=c99/-xc99=all/"
|
||||
SUBST_SED.sunwspro+= -e "s/-Wl,-rpath-link,/-L /g"
|
||||
.endif
|
||||
|
||||
BUILD_DEPENDS+= yasm>=0.7.2:../../devel/yasm
|
||||
|
||||
REPLACE_PERL+= doc/texi2pod.pl
|
||||
REPLACE_SH+= configure version.sh
|
||||
|
||||
SUBST_CLASSES+= conf
|
||||
SUBST_STAGE.conf= post-patch
|
||||
SUBST_FILES.conf= ffserver.c
|
||||
SUBST_SED.conf= -e 's,/etc/ffserver.conf,${PKG_SYSCONFDIR}/ffserver.conf,g'
|
||||
SUBST_MESSAGE.conf= Fixing configuration path.
|
||||
|
||||
PLIST_SRC+= ${PKGDIR}/PLIST
|
||||
|
||||
MAKE_ENV+= EXTRA_LIBS=${LIBGETOPT:Q}
|
||||
# LOCALBASE=${LOCALBASE:Q}
|
||||
|
||||
pre-configure:
|
||||
mkdir ${WRKSRC}/tmp
|
||||
|
||||
.include "../../mk/pthread.buildlink3.mk"
|
||||
.include "../../archivers/bzip2/buildlink3.mk"
|
||||
.include "../../devel/libgetopt/buildlink3.mk"
|
||||
.include "../../devel/zlib/buildlink3.mk"
|
||||
.include "../../mk/bsd.pkg.mk"
|
160
multimedia/ffmpeg2/PLIST
Normal file
160
multimedia/ffmpeg2/PLIST
Normal file
|
@ -0,0 +1,160 @@
|
|||
@comment $NetBSD: PLIST,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
bin/ffmpeg2
|
||||
bin/ffprobe2
|
||||
bin/ffserver2
|
||||
include/ffmpeg2/libavcodec/avcodec.h
|
||||
include/ffmpeg2/libavcodec/avfft.h
|
||||
include/ffmpeg2/libavcodec/dxva2.h
|
||||
include/ffmpeg2/libavcodec/old_codec_ids.h
|
||||
include/ffmpeg2/libavcodec/vaapi.h
|
||||
include/ffmpeg2/libavcodec/vda.h
|
||||
include/ffmpeg2/libavcodec/vdpau.h
|
||||
include/ffmpeg2/libavcodec/version.h
|
||||
include/ffmpeg2/libavcodec/xvmc.h
|
||||
include/ffmpeg2/libavdevice/avdevice.h
|
||||
include/ffmpeg2/libavdevice/version.h
|
||||
include/ffmpeg2/libavfilter/asrc_abuffer.h
|
||||
include/ffmpeg2/libavfilter/avcodec.h
|
||||
include/ffmpeg2/libavfilter/avfilter.h
|
||||
include/ffmpeg2/libavfilter/avfiltergraph.h
|
||||
include/ffmpeg2/libavfilter/buffersink.h
|
||||
include/ffmpeg2/libavfilter/buffersrc.h
|
||||
include/ffmpeg2/libavfilter/version.h
|
||||
include/ffmpeg2/libavformat/avformat.h
|
||||
include/ffmpeg2/libavformat/avio.h
|
||||
include/ffmpeg2/libavformat/version.h
|
||||
include/ffmpeg2/libavutil/adler32.h
|
||||
include/ffmpeg2/libavutil/aes.h
|
||||
include/ffmpeg2/libavutil/attributes.h
|
||||
include/ffmpeg2/libavutil/audio_fifo.h
|
||||
include/ffmpeg2/libavutil/audioconvert.h
|
||||
include/ffmpeg2/libavutil/avassert.h
|
||||
include/ffmpeg2/libavutil/avconfig.h
|
||||
include/ffmpeg2/libavutil/avstring.h
|
||||
include/ffmpeg2/libavutil/avutil.h
|
||||
include/ffmpeg2/libavutil/base64.h
|
||||
include/ffmpeg2/libavutil/blowfish.h
|
||||
include/ffmpeg2/libavutil/bprint.h
|
||||
include/ffmpeg2/libavutil/bswap.h
|
||||
include/ffmpeg2/libavutil/buffer.h
|
||||
include/ffmpeg2/libavutil/channel_layout.h
|
||||
include/ffmpeg2/libavutil/common.h
|
||||
include/ffmpeg2/libavutil/cpu.h
|
||||
include/ffmpeg2/libavutil/crc.h
|
||||
include/ffmpeg2/libavutil/dict.h
|
||||
include/ffmpeg2/libavutil/error.h
|
||||
include/ffmpeg2/libavutil/eval.h
|
||||
include/ffmpeg2/libavutil/fifo.h
|
||||
include/ffmpeg2/libavutil/file.h
|
||||
include/ffmpeg2/libavutil/frame.h
|
||||
include/ffmpeg2/libavutil/hmac.h
|
||||
include/ffmpeg2/libavutil/imgutils.h
|
||||
include/ffmpeg2/libavutil/intfloat.h
|
||||
include/ffmpeg2/libavutil/intfloat_readwrite.h
|
||||
include/ffmpeg2/libavutil/intreadwrite.h
|
||||
include/ffmpeg2/libavutil/lfg.h
|
||||
include/ffmpeg2/libavutil/log.h
|
||||
include/ffmpeg2/libavutil/lzo.h
|
||||
include/ffmpeg2/libavutil/mathematics.h
|
||||
include/ffmpeg2/libavutil/md5.h
|
||||
include/ffmpeg2/libavutil/mem.h
|
||||
include/ffmpeg2/libavutil/murmur3.h
|
||||
include/ffmpeg2/libavutil/old_pix_fmts.h
|
||||
${PLIST.opencl}include/ffmpeg2/libavutil/opencl.h
|
||||
include/ffmpeg2/libavutil/opt.h
|
||||
include/ffmpeg2/libavutil/parseutils.h
|
||||
include/ffmpeg2/libavutil/pixdesc.h
|
||||
include/ffmpeg2/libavutil/pixfmt.h
|
||||
include/ffmpeg2/libavutil/random_seed.h
|
||||
include/ffmpeg2/libavutil/rational.h
|
||||
include/ffmpeg2/libavutil/ripemd.h
|
||||
include/ffmpeg2/libavutil/samplefmt.h
|
||||
include/ffmpeg2/libavutil/sha.h
|
||||
include/ffmpeg2/libavutil/sha512.h
|
||||
include/ffmpeg2/libavutil/time.h
|
||||
include/ffmpeg2/libavutil/timecode.h
|
||||
include/ffmpeg2/libavutil/timestamp.h
|
||||
include/ffmpeg2/libavutil/version.h
|
||||
include/ffmpeg2/libavutil/xtea.h
|
||||
include/ffmpeg2/libpostproc/postprocess.h
|
||||
include/ffmpeg2/libpostproc/version.h
|
||||
include/ffmpeg2/libswresample/swresample.h
|
||||
include/ffmpeg2/libswresample/version.h
|
||||
include/ffmpeg2/libswscale/swscale.h
|
||||
include/ffmpeg2/libswscale/version.h
|
||||
lib/ffmpeg2/libavcodec.a
|
||||
lib/ffmpeg2/libavcodec.so
|
||||
lib/ffmpeg2/libavcodec.so.55
|
||||
lib/ffmpeg2/libavcodec.so.55.18.102
|
||||
lib/ffmpeg2/libavdevice.a
|
||||
lib/ffmpeg2/libavdevice.so
|
||||
lib/ffmpeg2/libavdevice.so.55
|
||||
lib/ffmpeg2/libavdevice.so.55.3.100
|
||||
lib/ffmpeg2/libavfilter.a
|
||||
lib/ffmpeg2/libavfilter.so
|
||||
lib/ffmpeg2/libavfilter.so.3
|
||||
lib/ffmpeg2/libavfilter.so.3.79.101
|
||||
lib/ffmpeg2/libavformat.a
|
||||
lib/ffmpeg2/libavformat.so
|
||||
lib/ffmpeg2/libavformat.so.55
|
||||
lib/ffmpeg2/libavformat.so.55.12.100
|
||||
lib/ffmpeg2/libavutil.a
|
||||
lib/ffmpeg2/libavutil.so
|
||||
lib/ffmpeg2/libavutil.so.52
|
||||
lib/ffmpeg2/libavutil.so.52.38.100
|
||||
lib/ffmpeg2/libpostproc.a
|
||||
lib/ffmpeg2/libpostproc.so
|
||||
lib/ffmpeg2/libpostproc.so.52
|
||||
lib/ffmpeg2/libpostproc.so.52.3.100
|
||||
lib/ffmpeg2/libswresample.a
|
||||
lib/ffmpeg2/libswresample.so
|
||||
lib/ffmpeg2/libswresample.so.0
|
||||
lib/ffmpeg2/libswresample.so.0.17.102
|
||||
lib/ffmpeg2/libswscale.a
|
||||
lib/ffmpeg2/libswscale.so
|
||||
lib/ffmpeg2/libswscale.so.2
|
||||
lib/ffmpeg2/libswscale.so.2.3.100
|
||||
lib/ffmpeg2/pkgconfig/libavcodec.pc
|
||||
lib/ffmpeg2/pkgconfig/libavdevice.pc
|
||||
lib/ffmpeg2/pkgconfig/libavfilter.pc
|
||||
lib/ffmpeg2/pkgconfig/libavformat.pc
|
||||
lib/ffmpeg2/pkgconfig/libavutil.pc
|
||||
lib/ffmpeg2/pkgconfig/libpostproc.pc
|
||||
lib/ffmpeg2/pkgconfig/libswresample.pc
|
||||
lib/ffmpeg2/pkgconfig/libswscale.pc
|
||||
share/doc/ffmpeg2/avutil.txt
|
||||
share/doc/ffmpeg2/build_system.txt
|
||||
share/doc/ffmpeg2/errno.txt
|
||||
share/doc/ffmpeg2/ffmpeg.txt
|
||||
share/doc/ffmpeg2/filter_design.txt
|
||||
share/doc/ffmpeg2/git-howto.txt
|
||||
share/doc/ffmpeg2/issue_tracker.txt
|
||||
share/doc/ffmpeg2/mips.txt
|
||||
share/doc/ffmpeg2/multithreading.txt
|
||||
share/doc/ffmpeg2/optimization.txt
|
||||
share/doc/ffmpeg2/rate_distortion.txt
|
||||
share/doc/ffmpeg2/snow.txt
|
||||
share/doc/ffmpeg2/soc.txt
|
||||
share/doc/ffmpeg2/swresample.txt
|
||||
share/doc/ffmpeg2/swscale.txt
|
||||
share/doc/ffmpeg2/tablegen.txt
|
||||
share/doc/ffmpeg2/viterbi.txt
|
||||
share/examples/ffmpeg2/ffserver.conf
|
||||
share/ffmpeg2/examples/Makefile
|
||||
share/ffmpeg2/examples/README
|
||||
share/ffmpeg2/examples/decoding_encoding.c
|
||||
share/ffmpeg2/examples/demuxing.c
|
||||
share/ffmpeg2/examples/filtering_audio.c
|
||||
share/ffmpeg2/examples/filtering_video.c
|
||||
share/ffmpeg2/examples/metadata.c
|
||||
share/ffmpeg2/examples/muxing.c
|
||||
share/ffmpeg2/examples/resampling_audio.c
|
||||
share/ffmpeg2/examples/scaling_video.c
|
||||
share/ffmpeg2/ffprobe.xsd
|
||||
share/ffmpeg2/libvpx-1080p.ffpreset
|
||||
share/ffmpeg2/libvpx-1080p50_60.ffpreset
|
||||
share/ffmpeg2/libvpx-360p.ffpreset
|
||||
share/ffmpeg2/libvpx-720p.ffpreset
|
||||
share/ffmpeg2/libvpx-720p50_60.ffpreset
|
||||
share/ffmpeg2/libx264-ipod320.ffpreset
|
||||
share/ffmpeg2/libx264-ipod640.ffpreset
|
42
multimedia/ffmpeg2/buildlink3.mk
Normal file
42
multimedia/ffmpeg2/buildlink3.mk
Normal file
|
@ -0,0 +1,42 @@
|
|||
# $NetBSD: buildlink3.mk,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
BUILDLINK_TREE+= ffmpeg2
|
||||
|
||||
.if !defined(FFMPEG2_BUILDLINK3_MK)
|
||||
FFMPEG2_BUILDLINK3_MK:=
|
||||
|
||||
BUILDLINK_API_DEPENDS.ffmpeg2+= ffmpeg2>=2.0
|
||||
BUILDLINK_ABI_DEPENDS.ffmpeg2+= ffmpeg2>=2.0
|
||||
BUILDLINK_PKGSRCDIR.ffmpeg2?= ../../multimedia/ffmpeg2
|
||||
|
||||
pkgbase := ffmpeg2
|
||||
. include "../../mk/pkg-build-options.mk"
|
||||
|
||||
.include "../../mk/bsd.fast.prefs.mk"
|
||||
|
||||
.if !empty(PKG_BUILD_OPTIONS.ffmpeg2:Mtheora)
|
||||
. include "../../multimedia/libtheora/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
.if !empty(PKG_BUILD_OPTIONS.ffmpeg2:Mxvid)
|
||||
. include "../../multimedia/xvidcore/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
.if !empty(PKG_BUILD_OPTIONS.ffmpeg2:Mx264)
|
||||
. include "../../multimedia/x264-devel/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
.if !empty(PKG_BUILD_OPTIONS.ffmpeg2:Mfaac)
|
||||
. include "../../audio/faac/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
.if !empty(PKG_BUILD_OPTIONS.ffmpeg2:Mlibvpx)
|
||||
. include "../../multimedia/libvpx/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
.include "../../archivers/bzip2/buildlink3.mk"
|
||||
.include "../../devel/libgetopt/buildlink3.mk"
|
||||
.include "../../devel/zlib/buildlink3.mk"
|
||||
.endif # FFMPEG2_BUILDLINK3_MK
|
||||
|
||||
BUILDLINK_TREE+= -ffmpeg2
|
9
multimedia/ffmpeg2/distinfo
Normal file
9
multimedia/ffmpeg2/distinfo
Normal file
|
@ -0,0 +1,9 @@
|
|||
$NetBSD: distinfo,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
SHA1 (ffmpeg-2.0.tar.bz2) = 7583c25cd41b6b4741819b977672627abb772f7e
|
||||
RMD160 (ffmpeg-2.0.tar.bz2) = 4ac72eff199b56d25b12844cde521a5116751e67
|
||||
Size (ffmpeg-2.0.tar.bz2) = 6188516 bytes
|
||||
SHA1 (patch-Makefile) = ff8a7a5fdfd4987ef2835bd7360a78efd4310253
|
||||
SHA1 (patch-configure) = 394d203c5b89dd872d55a68141106de5fa03d32b
|
||||
SHA1 (patch-libavutil_common.h) = ebbd0c169f228af37ae2dd54b27d5dba11a34c5e
|
||||
SHA1 (patch-libavutil_x86_cpu.c) = 14006874aee07e7e41803269040f0ae0157d931d
|
125
multimedia/ffmpeg2/options.mk
Normal file
125
multimedia/ffmpeg2/options.mk
Normal file
|
@ -0,0 +1,125 @@
|
|||
# $NetBSD: options.mk,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
# Global and legacy options
|
||||
|
||||
PKG_OPTIONS_VAR= PKG_OPTIONS.ffmpeg2
|
||||
PKG_SUPPORTED_OPTIONS= faac lame ass libvpx theora vorbis x264 xvid \
|
||||
opencore-amr
|
||||
PKG_SUGGESTED_OPTIONS= lame ass libvpx theora vorbis x264 xvid
|
||||
#PKG_OPTIONS_OPTIONAL_GROUPS= aac-decoder
|
||||
#PKG_OPTIONS_GROUP.aac-decoder= faac
|
||||
|
||||
# Add VDPAU if it is available
|
||||
.include "../../multimedia/libvdpau/available.mk"
|
||||
.if ${VDPAU_AVAILABLE} == "yes"
|
||||
PKG_SUPPORTED_OPTIONS+= vdpau
|
||||
PKG_SUGGESTED_OPTIONS+= vdpau
|
||||
.endif
|
||||
|
||||
# Add VAAPI if it is available
|
||||
.include "../../multimedia/libva/available.mk"
|
||||
.if ${VAAPI_AVAILABLE} == "yes"
|
||||
PKG_SUPPORTED_OPTIONS+= vaapi
|
||||
PKG_SUGGESTED_OPTIONS+= vaapi
|
||||
.endif
|
||||
|
||||
.include "../../mk/bsd.options.mk"
|
||||
|
||||
# ass option
|
||||
.if !empty(PKG_OPTIONS:Mass)
|
||||
USE_TOOLS+= pkg-config
|
||||
CONFIGURE_ARGS+= --enable-libass
|
||||
.include "../../multimedia/libass/buildlink3.mk"
|
||||
.else
|
||||
CONFIGURE_ARGS+= --disable-libass
|
||||
.endif
|
||||
|
||||
# faac option
|
||||
.if !empty(PKG_OPTIONS:Mfaac)
|
||||
RESTRICTED= This software may require the payment of patent royalties
|
||||
NO_BIN_ON_CDROM= ${RESTRICTED}
|
||||
NO_BIN_ON_FTP= ${RESTRICTED}
|
||||
CONFIGURE_ARGS+= --enable-libfaac
|
||||
CONFIGURE_ARGS+= --enable-nonfree
|
||||
.include "../../audio/faac/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
# opencore-amr option
|
||||
.if !empty(PKG_OPTIONS:Mopencore-amr)
|
||||
CONFIGURE_ARGS+= --enable-libopencore-amrnb
|
||||
CONFIGURE_ARGS+= --enable-libopencore-amrwb
|
||||
|
||||
# "The OpenCORE external libraries are under the Apache License
|
||||
# 2.0. That license is incompatible with the LGPL v2.1 and the GPL
|
||||
# v2, but not with version 3 of those licenses. So to combine the
|
||||
# OpenCORE libraries with FFmpeg, the license version needs to be
|
||||
# upgraded by passing --enable-version3 to configure."
|
||||
CONFIGURE_ARGS+= --enable-version3
|
||||
# TODO: LICENSE
|
||||
|
||||
.include "../../audio/opencore-amr/buildlink3.mk"
|
||||
.else
|
||||
CONFIGURE_ARGS+= --disable-libopencore-amrnb
|
||||
CONFIGURE_ARGS+= --disable-libopencore-amrwb
|
||||
.endif
|
||||
|
||||
# OGG Theora support
|
||||
.if !empty(PKG_OPTIONS:Mtheora)
|
||||
CONFIGURE_ARGS+= --enable-libtheora
|
||||
.include "../../multimedia/libtheora/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
# OGG Vorbis support
|
||||
.if !empty(PKG_OPTIONS:Mvorbis)
|
||||
CONFIGURE_ARGS+= --enable-libvorbis
|
||||
.include "../../audio/libvorbis/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
# LAME MP3 encoder
|
||||
.if !empty(PKG_OPTIONS:Mlame)
|
||||
# "lame-3.98" isn't compatible with "ffmpeg" which breaks audio encoding.
|
||||
BUILDLINK_ABI_DEPENDS.lame+= lame>=3.98.2nb1
|
||||
CONFIGURE_ARGS+= --enable-libmp3lame
|
||||
.include "../../audio/lame/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
# XviD support
|
||||
.if !empty(PKG_OPTIONS:Mxvid)
|
||||
CONFIGURE_ARGS+= --enable-libxvid
|
||||
.include "../../multimedia/xvidcore/buildlink3.mk"
|
||||
.endif
|
||||
|
||||
# x264 support
|
||||
.if !empty(PKG_OPTIONS:Mx264)
|
||||
# ABI change between 20090326 and 20100201
|
||||
BUILDLINK_API_DEPENDS.x264-devel+= x264-devel>=20111207
|
||||
#BUILDLINK_API_DEPENDS.x264-devel+= x264-devel<20110102
|
||||
CONFIGURE_ARGS+= --enable-libx264
|
||||
.include "../../multimedia/x264-devel/buildlink3.mk"
|
||||
.else
|
||||
CONFIGURE_ARGS+= --disable-libx264
|
||||
.endif
|
||||
|
||||
# VDPAU support
|
||||
.if !empty(PKG_OPTIONS:Mvdpau)
|
||||
CONFIGURE_ARGS+= --enable-vdpau
|
||||
.include "../../multimedia/libvdpau/buildlink3.mk"
|
||||
.else
|
||||
CONFIGURE_ARGS+= --disable-vdpau
|
||||
.endif
|
||||
|
||||
# VAAPI support
|
||||
.if !empty(PKG_OPTIONS:Mvaapi)
|
||||
CONFIGURE_ARGS+= --enable-vaapi
|
||||
.include "../../multimedia/libva/buildlink3.mk"
|
||||
.else
|
||||
CONFIGURE_ARGS+= --disable-vaapi
|
||||
.endif
|
||||
|
||||
# VPX support
|
||||
.if !empty(PKG_OPTIONS:Mlibvpx)
|
||||
CONFIGURE_ARGS+= --enable-libvpx
|
||||
.include "../../multimedia/libvpx/buildlink3.mk"
|
||||
.else
|
||||
CONFIGURE_ARGS+= --disable-libvpx
|
||||
.endif
|
15
multimedia/ffmpeg2/patches/patch-Makefile
Normal file
15
multimedia/ffmpeg2/patches/patch-Makefile
Normal file
|
@ -0,0 +1,15 @@
|
|||
$NetBSD: patch-Makefile,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
--- Makefile.orig 2012-09-28 01:37:35.000000000 +0000
|
||||
+++ Makefile
|
||||
@@ -139,8 +139,8 @@ install-progs: install-progs-yes $(PROGS
|
||||
|
||||
install-data: $(DATA_FILES) $(EXAMPLES_FILES)
|
||||
$(Q)mkdir -p "$(DATADIR)/examples"
|
||||
- $(INSTALL) -m 644 $(DATA_FILES) "$(DATADIR)"
|
||||
- $(INSTALL) -m 644 $(EXAMPLES_FILES) "$(DATADIR)/examples"
|
||||
+ $(INSTALL) -c -m 644 $(DATA_FILES) "$(DATADIR)"
|
||||
+ $(INSTALL) -c -m 644 $(EXAMPLES_FILES) "$(DATADIR)/examples"
|
||||
|
||||
uninstall: uninstall-libs uninstall-headers uninstall-progs uninstall-data
|
||||
|
58
multimedia/ffmpeg2/patches/patch-configure
Normal file
58
multimedia/ffmpeg2/patches/patch-configure
Normal file
|
@ -0,0 +1,58 @@
|
|||
$NetBSD: patch-configure,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
--- configure.orig 2013-07-10 00:43:00.000000000 +0000
|
||||
+++ configure
|
||||
@@ -3426,6 +3426,11 @@ case $target_os in
|
||||
;;
|
||||
netbsd)
|
||||
disable symver
|
||||
+ # NetBSD/macppc *really* needs PIC enabled. ffmpeg has repeatedly
|
||||
+ # broken time and time again because PIC support has been removed
|
||||
+ # from architectures that need it. So, if you touch this, please
|
||||
+ # be careful and make sure that your changes work.
|
||||
+ test "${subarch}" != "x86_32" && enable pic
|
||||
oss_indev_extralibs="-lossaudio"
|
||||
oss_outdev_extralibs="-lossaudio"
|
||||
enabled gcc || check_ldflags -Wl,-zmuldefs
|
||||
@@ -3782,10 +3787,13 @@ check_cc <<EOF && enable attribute_may_a
|
||||
union { int x; } __attribute__((may_alias)) x;
|
||||
EOF
|
||||
|
||||
-check_cc <<EOF || die "endian test failed"
|
||||
-unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
|
||||
+check_exec <<EOF || enable bigendian
|
||||
+int main()
|
||||
+{
|
||||
+ long one = 1;
|
||||
+ return !(*((char *)(&one)));
|
||||
+}
|
||||
EOF
|
||||
-od -t x1 $TMPO | grep -q '42 *49 *47 *45' && enable bigendian
|
||||
|
||||
if enabled alpha; then
|
||||
|
||||
@@ -4348,6 +4356,7 @@ enabled xmm_clobber_test &&
|
||||
-Wl,--wrap,sws_scale ||
|
||||
disable xmm_clobber_test
|
||||
|
||||
+if false; then
|
||||
echo "X{};" > $TMPV
|
||||
if test_ldflags -Wl,--version-script,$TMPV; then
|
||||
append SHFLAGS '-Wl,--version-script,\$(SUBDIR)lib\$(NAME).ver'
|
||||
@@ -4360,6 +4369,7 @@ __asm__(".symver ff_foo,av_foo@VERSION")
|
||||
void ff_foo(void) {}
|
||||
EOF
|
||||
fi
|
||||
+fi
|
||||
|
||||
if [ -z "$optflags" ]; then
|
||||
if enabled small; then
|
||||
@@ -4834,7 +4844,7 @@ Version: $version
|
||||
Requires: $(enabled shared || echo $requires)
|
||||
Requires.private: $(enabled shared && echo $requires)
|
||||
Conflicts:
|
||||
-Libs: -L\${libdir} -l${shortname} $(enabled shared || echo $libs)
|
||||
+Libs: -L\${libdir} -Wl,-R\${libdir} -l${shortname} $(enabled shared || echo $libs)
|
||||
Libs.private: $(enabled shared && echo $libs)
|
||||
Cflags: -I\${includedir}
|
||||
EOF
|
27
multimedia/ffmpeg2/patches/patch-libavutil_common.h
Normal file
27
multimedia/ffmpeg2/patches/patch-libavutil_common.h
Normal file
|
@ -0,0 +1,27 @@
|
|||
$NetBSD: patch-libavutil_common.h,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
--- libavutil/common.h.orig 2013-01-06 21:53:29.000000000 +0000
|
||||
+++ libavutil/common.h
|
||||
@@ -39,6 +39,22 @@
|
||||
#include "version.h"
|
||||
#include "libavutil/avconfig.h"
|
||||
|
||||
+#if defined(__cplusplus)
|
||||
+#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__linux__)
|
||||
+#undef _STDINT_H_
|
||||
+#undef _SYS_STDINT_H_
|
||||
+#undef _STDINT_H
|
||||
+#undef _GCC_WRAP_STDINT_H
|
||||
+#ifndef __STDC_CONSTANT_MACROS
|
||||
+#define __STDC_CONSTANT_MACROS
|
||||
+#endif
|
||||
+#include <stdint.h>
|
||||
+#endif /* FreeBSD | OpenBSD | linux */
|
||||
+#if defined(__DragonFly__) || defined(__NetBSD__)
|
||||
+#include <machine/int_const.h>
|
||||
+#endif /* DragonFly | NetBSD */
|
||||
+#endif /* __cplusplus */
|
||||
+
|
||||
#if AV_HAVE_BIGENDIAN
|
||||
# define AV_NE(be, le) (be)
|
||||
#else
|
20
multimedia/ffmpeg2/patches/patch-libavutil_x86_cpu.c
Normal file
20
multimedia/ffmpeg2/patches/patch-libavutil_x86_cpu.c
Normal file
|
@ -0,0 +1,20 @@
|
|||
$NetBSD: patch-libavutil_x86_cpu.c,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
--- libavutil/x86/cpu.c.orig 2013-01-06 21:53:29.000000000 +0000
|
||||
+++ libavutil/x86/cpu.c
|
||||
@@ -115,6 +115,7 @@ int ff_get_cpu_flags_x86(void)
|
||||
#if HAVE_SSE
|
||||
if (std_caps & (1 << 25))
|
||||
rval |= AV_CPU_FLAG_SSE;
|
||||
+#if !defined(__GNUC__) || (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 2))
|
||||
if (std_caps & (1 << 26))
|
||||
rval |= AV_CPU_FLAG_SSE2;
|
||||
if (ecx & 1)
|
||||
@@ -134,6 +135,7 @@ int ff_get_cpu_flags_x86(void)
|
||||
rval |= AV_CPU_FLAG_AVX;
|
||||
}
|
||||
#endif /* HAVE_AVX */
|
||||
+#endif /* gcc >= 4.2 */
|
||||
#endif /* HAVE_SSE */
|
||||
}
|
||||
|
3
multimedia/ffplay2/DESCR
Normal file
3
multimedia/ffplay2/DESCR
Normal file
|
@ -0,0 +1,3 @@
|
|||
FFplay is a very simple and portable media player using the FFmpeg
|
||||
libraries and the SDL library. It is mostly used as a testbed for
|
||||
the various FFmpeg APIs.
|
31
multimedia/ffplay2/Makefile
Normal file
31
multimedia/ffplay2/Makefile
Normal file
|
@ -0,0 +1,31 @@
|
|||
# $NetBSD: Makefile,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
|
||||
PKGNAME= ${DISTNAME:S/ffmpeg/ffplay2/}
|
||||
MAINTAINER= pkgsrc-users@NetBSD.org
|
||||
HOMEPAGE= http://ffmpeg.mplayerhq.hu/
|
||||
COMMENT= Simple SDL frontend for FFmpeg
|
||||
|
||||
DISTINFO_FILE= ${.CURDIR}/../ffmpeg2/distinfo
|
||||
|
||||
CONFIGURE_ARGS+= --disable-ffmpeg
|
||||
CONFIGURE_ARGS+= --disable-ffserver
|
||||
CONFIGURE_ARGS+= --disable-encoders
|
||||
CONFIGURE_ARGS+= --disable-decoders
|
||||
CONFIGURE_ARGS+= --disable-hwaccels
|
||||
CONFIGURE_ARGS+= --disable-muxers
|
||||
CONFIGURE_ARGS+= --disable-demuxers
|
||||
CONFIGURE_ARGS+= --disable-parsers
|
||||
CONFIGURE_ARGS+= --disable-bsfs
|
||||
CONFIGURE_ARGS+= --disable-protocols
|
||||
CONFIGURE_ARGS+= --disable-devices
|
||||
#CONFIGURE_ARGS+= --disable-filters
|
||||
CONFIGURE_ARGS+= --enable-ffplay
|
||||
|
||||
INSTALLATION_DIRS+= bin ${PKGMANDIR}/man1
|
||||
|
||||
do-install:
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/ffplay2 ${DESTDIR}${PREFIX}/bin
|
||||
|
||||
.include "../../devel/SDL/buildlink3.mk"
|
||||
.include "../../multimedia/ffmpeg2/buildlink3.mk"
|
||||
.include "../../multimedia/ffmpeg2/Makefile.common"
|
2
multimedia/ffplay2/PLIST
Normal file
2
multimedia/ffplay2/PLIST
Normal file
|
@ -0,0 +1,2 @@
|
|||
@comment $NetBSD: PLIST,v 1.1 2013/08/04 10:29:02 adam Exp $
|
||||
bin/ffplay2
|
Loading…
Reference in a new issue