summaryrefslogtreecommitdiffstats
path: root/video
diff options
context:
space:
mode:
authorTreeve Jelbert2022-06-12 13:39:52 +0200
committerTreeve Jelbert2022-06-12 13:45:41 +0200
commit0b9c8000a15317e018d4ff044d1abc475f472be6 (patch)
tree6bc3a572d6605dfc2b730374e958fe932dcdd67e /video
parentd302440f4280964956228d63ba98bd6a23d8a83b (diff)
ffmpeg5 5.0.1
Diffstat (limited to 'video')
-rwxr-xr-xvideo/ffmpeg5/BUILD49
-rwxr-xr-xvideo/ffmpeg5/CONFIGURE24
-rwxr-xr-xvideo/ffmpeg5/CONFLICTS2
-rwxr-xr-xvideo/ffmpeg5/DEPENDS311
-rwxr-xr-xvideo/ffmpeg5/DETAILS22
-rw-r--r--video/ffmpeg5/HISTORY3
-rwxr-xr-xvideo/ffmpeg5/INSTALL5
-rw-r--r--video/ffmpeg5/PRE_BUILD13
-rwxr-xr-xvideo/ffmpeg5/PROVIDES1
-rwxr-xr-xvideo/ffmpeg5/TRIGGERS7
-rwxr-xr-xvideo/ffmpeg5/UP_TRIGGERS19
11 files changed, 456 insertions, 0 deletions
diff --git a/video/ffmpeg5/BUILD b/video/ffmpeg5/BUILD
new file mode 100755
index 0000000000..05f91fad05
--- /dev/null
+++ b/video/ffmpeg5/BUILD
@@ -0,0 +1,49 @@
+disable_pic &&
+
+if list_find "$FFMPEG_PROGRAMS" "none"; then
+ OPTS="--disable-programs $OPTS"
+elif list_find "$FFMPEG_PROGRAMS" "all"; then
+ :
+else
+ for program in $FFMPEG_PROGRAM_LIST; do
+ if ! list_find "$FFMPEG_PROGRAMS" "$program"; then
+ OPTS="--disable-$program $OPTS"
+ fi
+ done &&
+
+ persistent_remove FFMPEG_PROGRAM_LIST &&
+ persistent_save &&
+ persistent_load
+fi &&
+
+OPTS="$FFMPEG_OPTS $OPTS" &&
+
+if echo "$CFLAGS" | grep -q "\-Os"; then
+ OPTS="--enable-small $OPTS"
+fi &&
+
+if is_depends_enabled $SPELL opencore-amr; then
+ OPTS="--enable-version3 $OPTS"
+fi &&
+
+# fixing issue #381
+if is_depends_enabled $SPELL openjpeg; then
+ CFLAGS="$CFLAGS -I${INSTALL_ROOT}/usr/include/openjpeg-1.5"
+fi &&
+
+LDFLAGS=${LDFLAGS//-Wl,--as-needed/} &&
+
+OPTS="--disable-cuda --disable-cuvid $OPTS" &&
+
+check_tmp_noexec /tmp &&
+./configure --prefix=${INSTALL_ROOT}/usr \
+ --mandir=${INSTALL_ROOT}/usr/share/man \
+ --enable-shared \
+ --disable-static \
+ --enable-pthreads \
+ --enable-postproc \
+ --enable-gpl \
+ $OPTS &&
+check_tmp_noexec /tmp &&
+make V=1 &&
+make V=1 tools/qt-faststart
diff --git a/video/ffmpeg5/CONFIGURE b/video/ffmpeg5/CONFIGURE
new file mode 100755
index 0000000000..4a29277d9f
--- /dev/null
+++ b/video/ffmpeg5/CONFIGURE
@@ -0,0 +1,24 @@
+. $GRIMOIRE/config_query_multi.function &&
+default_configure &&
+
+config_query_option FFMPEG_OPTS "Enable software scaler support?" y \
+ "--enable-swscale" \
+ "--disable-swscale" &&
+
+config_query_option FFMPEG_OPTS "Enable debugging symbols?" y \
+ "--enable-debug" \
+ "--disable-debug" &&
+
+config_query_option FFMPEG_OPTS "Enable support for Blackmagick Decklink output?" n \
+ "--enable-decklink" \
+ "--disable-decklink" &&
+
+persistent_add FFMPEG_PROGRAM_LIST &&
+local FFMPEG_PROGRAM_LIST="ffmpeg ffprobe" &&
+config_query_multi FFMPEG_PROGRAMS "Which command line programs would you like to build?" \
+ $FFMPEG_PROGRAM_LIST \
+ all \
+ none &&
+
+config_query_list FFMPEG_HTTPS "how to support https"\
+ gnutls SSL none
diff --git a/video/ffmpeg5/CONFLICTS b/video/ffmpeg5/CONFLICTS
new file mode 100755
index 0000000000..939893fbe5
--- /dev/null
+++ b/video/ffmpeg5/CONFLICTS
@@ -0,0 +1,2 @@
+conflicts ffmpeg-svn
+conflicts ffmpeg
diff --git a/video/ffmpeg5/DEPENDS b/video/ffmpeg5/DEPENDS
new file mode 100755
index 0000000000..09c4a5595d
--- /dev/null
+++ b/video/ffmpeg5/DEPENDS
@@ -0,0 +1,311 @@
+#optional_depends libmpx \
+# "--enable-mfx" \
+# "--disable-mfx" \
+# "for hardware acceleration through libmfx" &&
+
+#optional_depends openh264 \
+# "--enable-openh264" \
+# "--disable-openh264" \
+# "for H.264 support through OpenH264" &&
+
+optional_depends dav1d \
+ "--enable-libdav1d" \
+ "--disable-libdav1d" \
+ "enable AV1-codec support" &&
+
+optional_depends chromaprint \
+ "--enable-chromaprint" \
+ "--disable-chromaprint" \
+ "enable audio-fingerprinting support" &&
+
+optional_depends codec2 \
+ "--enable-libcodec2" \
+ "--disable-libcodec2" \
+ "enable codec2 support" &&
+
+optional_depends ladspa \
+ "--enable-ladspa" \
+ "--disable-ladspa" \
+ "enable ladspa support" &&
+
+optional_depends libdrm \
+ "--enable-libdrm" \
+ "--disable-libdrm" \
+ "enable DRM code" &&
+
+optional_depends libdc1394 \
+ "--enable-libdc1394" \
+ "--disable-libdc1394" \
+ "enable IIDC-1394 grabbing support" &&
+
+optional_depends alsa-lib \
+ "--enable-alsa" \
+ "--disable-alsa" \
+ "for alsa sound support" &&
+
+optional_depends JACK-DRIVER "--enable-libjack" "" "for libjack sound support" &&
+
+optional_depends librsvg2 \
+ "--enable-librsvg" \
+ "--disable-librsvg" \
+ "for svg support" &&
+
+optional_depends libxcb \
+ "--enable-libxcb --enable-libxcb-shm --enable-libxcb-xfixes --enable-libxcb-shape" \
+ "--disable-libxcb" \
+ "for X11 grabbing using xcb" &&
+
+optional_depends LZMA \
+ "--enable-lzma" \
+ "--disable-lzma" \
+ "for lzma support" &&
+
+optional_depends zlib \
+ "--enable-zlib" \
+ "--disable-zlib" \
+ "for zlib support" &&
+
+optional_depends X86-ASSEMBLER \
+ "" \
+ "--disable-x86asm" \
+ "for some assembler optimizations" &&
+
+optional_depends celt \
+ "--enable-libcelt" \
+ "" \
+ "for celt codec support" &&
+
+optional_depends frei0r-plugins \
+ "--enable-frei0r" \
+ "" \
+ "to use frei0r for video filtering" &&
+
+if [[ $FFMPEG_RELEASE == stable ]]; then
+ case $FFMPEG_HTTPS in
+ gnutls) depends gnutls "--enable-gnutls" ;;
+ SSL) depends SSL "--enable-nonfree --enable-openssl" &&
+ message "Open/Libre SSL ${PROBLEM_COLOR}nonfree${DEFAULT_COLOR}" ;;
+ esac &&
+
+ optional_depends fontconfig \
+ "--enable-libfontconfig" \
+ "" \
+ "to enable fontconfig" &&
+
+ optional_depends libass \
+ "--enable-libass" \
+ "" \
+ "use libass for subtitle rendering" &&
+
+ optional_depends libmodplug \
+ "--enable-libmodplug" \
+ "" \
+ "to enable libmodplug support for playing mod files" &&
+
+ optional_depends twolame \
+ "--enable-libtwolame" \
+ "" \
+ "for MP2 encoding" &&
+
+ optional_depends libcdio \
+ "--enable-libcdio" \
+ "" \
+ "for audio CD grabbing" &&
+
+ if is_depends_enabled $SPELL libcdio; then
+ depends libcdio-paranoia
+ fi &&
+
+ optional_depends libiec61883 \
+ "--enable-libiec61883" \
+ "" \
+ "to enable iec61883" &&
+
+ optional_depends flite \
+ "--enable-libflite" \
+ "" \
+ "for voice synthesis support" &&
+
+ optional_depends libcaca \
+ "--enable-libcaca" \
+ "" \
+ "for textual display support" &&
+
+ optional_depends libbluray \
+ "--enable-libbluray" \
+ "" \
+ "for BluRay reading support" &&
+
+ optional_depends openal \
+ "--enable-openal" \
+ "" \
+ "for OpenAL 1.1 capture support" &&
+
+ optional_depends v4l-utils \
+ "--enable-libv4l2" \
+ "" \
+ "to enable v4l support" &&
+
+ optional_depends pulseaudio \
+ "--enable-libpulse" \
+ "" \
+ "for Pulseaudio input support" &&
+
+ optional_depends libwebp \
+ "--enable-libwebp" \
+ "" \
+ "for WebP encoding via libwebp" &&
+
+ optional_depends OPENGL \
+ "--enable-opengl" \
+ "" \
+ "for OpenGL rendering"
+else
+ optional_depends dirac \
+ "--enable-libdirac" \
+ "" \
+ "for dirac encoder support via libdirac"
+fi &&
+
+#optional_depends libvmaf \
+# "--enable-libvmaf" \
+# "--disable-libvmaf" \
+# "to enable vmaf filter support" &&
+
+optional_depends libxml2 \
+ "--enable-libxml2" \
+ "--disable-libxml2" \
+ "to enable XML parsing code" &&
+
+optional_depends libvdpau \
+ "--enable-vdpau" \
+ "--disable-vdpau" \
+ "to enable VDPAU code" &&
+
+optional_depends opencv \
+ "--enable-libopencv" \
+ "" \
+ "to video filtering via libopencv" &&
+
+optional_depends libva '--enable-vaapi' '--disable-vaapi' 'Video Acceleration API' &&
+
+optional_depends libvpx \
+ "--enable-libvpx" \
+ "" \
+ "for VP8 (and VP9 for stable branch) de/encoding support" &&
+
+optional_depends speex \
+ "--enable-libspeex" \
+ "" \
+ "for Speex codec support" &&
+
+optional_depends openjpeg \
+ "--enable-libopenjpeg" \
+ "--disable-libopenjpeg" \
+ "for JPEG 2000 support" &&
+
+optional_depends lame \
+ "--enable-libmp3lame" \
+ "" \
+ "for mp3 encoding" &&
+
+optional_depends libvorbis \
+ "--enable-libvorbis" \
+ "" \
+ "for ogg/vorbis support" &&
+
+optional_depends freetype2 \
+ "--enable-libfreetype" \
+ "" \
+ "for a text render plugin" &&
+
+optional_depends xvid \
+ "--enable-libxvid" \
+ "" \
+ "for xvid support" &&
+
+optional_depends sdl2 \
+ "" \
+ "--disable-sdl2" \
+ "for ffplay video player" &&
+
+optional_depends opencore-amr \
+ "--enable-libopencore-amrnb" \
+ "" \
+ "for AMR-NB de/encoding via libopencore-amrnb (${PROBLEM_COLOR}GPLv3${DEFAULT_COLOR}) support" &&
+
+optional_depends opencore-amr \
+ "--enable-libopencore-amrwb" \
+ "" \
+ "for AMR-WB decoding via libopencore-amrwb (${PROBLEM_COLOR}GPLv3${DEFAULT_COLOR}) support" &&
+
+optional_depends libtheora \
+ "--enable-libtheora" \
+ "" \
+ "for Theora encoding" &&
+
+optional_depends x264 \
+ "--enable-libx264" \
+ "" \
+ "for H.264 encoding" &&
+
+optional_depends x265 \
+ "--enable-libx265" \
+ "" \
+ "for H.265 encoding" &&
+
+optional_depends gsm \
+ "--enable-libgsm" \
+ "" \
+ "for GSM de/encoding" &&
+
+optional_depends rtmpdump \
+ "--enable-librtmp" \
+ "" \
+ "for RTMP[E] support" &&
+
+optional_depends libdc1394 \
+ "--enable-libdc1394" \
+ "" \
+ "for IIDC-1394 grabbing" &&
+
+optional_depends rubberband \
+ "--enable-librubberband" \
+ "" \
+ "for rubberband filter" &&
+
+optional_depends tesseract \
+ "--enable-libtesseract" \
+ "" \
+ "for OCR filter" &&
+
+#optional_depends zimg \
+# "--enable-libzimg" \
+# "" \
+# "for zscale filter" &&
+#
+
+#optional_depends libmysofa \
+# "--enable-libmysofa" \
+# "--disable-libmysofa" \
+# "for sofalizer filter" &&
+
+if is_depends_enabled $SPELL libdc1394; then
+ depends libraw1394
+fi &&
+
+optional_depends snappy \
+ "--enable-libsnappy" \
+ "" \
+ "for Snappy compression, needed for hap encoding" &&
+
+optional_depends libxvmc --{en,dis}able-hwaccel=xvmc 'XVmc HW accelleration' &&
+optional_depends vulkan-headers --{en,dis}able-vulkan 'Vulkan support'
+#if is_depends_enabled $SPELL vulkan-headers;then
+# optional_depends glslang --{en,dis}able-libglslang 'GLSL->SPIRV compilation'
+#fi
+
+#optional_depends kvazaar \
+# "--enable-libkvazaar" \
+# "" \
+# "for HEVC encoding" &&
diff --git a/video/ffmpeg5/DETAILS b/video/ffmpeg5/DETAILS
new file mode 100755
index 0000000000..a9d981bfbe
--- /dev/null
+++ b/video/ffmpeg5/DETAILS
@@ -0,0 +1,22 @@
+ SPELL=ffmpeg5
+ SPELLX=ffmpeg
+ VERSION=5.0.1
+ SOURCE=$SPELLX-$VERSION.tar.xz
+ SOURCE2=$SOURCE.asc
+SOURCE_DIRECTORY="$BUILD_DIRECTORY/$SPELLX-$VERSION"
+ SOURCE_URL[0]=http://ffmpeg.org/releases/$SOURCE
+ SOURCE2_URL[0]=${SOURCE_URL[0]}.asc
+ SOURCE_GPG=ffmpeg.gpg:$SOURCE2:UPSTREAM_KEY
+ SOURCE2_IGNORE=signature
+ DOC_DIRS=""
+ WEB_SITE=http://ffmpeg.org/
+ ENTERED=20030514
+ LICENSE[0]=GPL
+ KEYWORDS="video"
+ SHORT="complete video and audio broadcasting solution"
+cat << EOF
+FFMpeg is a complete and free Internet live audio and video
+broadcasting solution for Linux/Unix. It also includes a digital VCR.
+It can encode in real time in many formats including MPEG1 audio and
+video, MPEG4, h263, ac3, asf, avi, real, mjpeg, and flash.
+EOF
diff --git a/video/ffmpeg5/HISTORY b/video/ffmpeg5/HISTORY
new file mode 100644
index 0000000000..c92e57e493
--- /dev/null
+++ b/video/ffmpeg5/HISTORY
@@ -0,0 +1,3 @@
+2022-06-12 Treeve Jelbert <treeve@sourcemage.org>
+ * DETAILS: version 5.0.1
+ new spell, dereved from ffmpeg
diff --git a/video/ffmpeg5/INSTALL b/video/ffmpeg5/INSTALL
new file mode 100755
index 0000000000..be73a2f173
--- /dev/null
+++ b/video/ffmpeg5/INSTALL
@@ -0,0 +1,5 @@
+make_single &&
+make V=1 install &&
+make_normal &&
+
+install -vm 755 "tools/qt-faststart" "$INSTALL_ROOT/usr/bin/qt-faststart"
diff --git a/video/ffmpeg5/PRE_BUILD b/video/ffmpeg5/PRE_BUILD
new file mode 100644
index 0000000000..af479995b2
--- /dev/null
+++ b/video/ffmpeg5/PRE_BUILD
@@ -0,0 +1,13 @@
+default_pre_build &&
+cd $SOURCE_DIRECTORY &&
+
+if [[ $FFMPEG_RELEASE == legacy ]]; then
+ patch -p0 < "$SPELL_DIRECTORY/freetype.patch"
+
+#fix bad pkg-config files
+sed -i \
+-e '/^pkg.*{/,/^}/ s|\$libdir|\$\{prefix\}/lib|;s|\$incdir|\$\{prefix\}/include|'\
+ configure &&
+#s|\\\$|\$|;
+sedit '/#define LIBAVCODEC_VERSION_INT/i#if !defined INT64_C\n#if defined __WORDSIZE && __WORDSIZE == 64\n#define INT64_C(c) c ## L\n#else\n#define INT64_C(c) c ## LL\n#endif\n#endif' libavcodec/avcodec.h
+fi
diff --git a/video/ffmpeg5/PROVIDES b/video/ffmpeg5/PROVIDES
new file mode 100755
index 0000000000..f6a1ac46c8
--- /dev/null
+++ b/video/ffmpeg5/PROVIDES
@@ -0,0 +1 @@
+LIBAVCODEC
diff --git a/video/ffmpeg5/TRIGGERS b/video/ffmpeg5/TRIGGERS
new file mode 100755
index 0000000000..fe55b38c13
--- /dev/null
+++ b/video/ffmpeg5/TRIGGERS
@@ -0,0 +1,7 @@
+on_cast libass check_self
+on_cast snappy check_self
+on_cast tesseract check_self
+on_cast x264 check_self
+on_cast x265 check_self
+on_cast codec2 check_self
+on_cast dav1d check_self
diff --git a/video/ffmpeg5/UP_TRIGGERS b/video/ffmpeg5/UP_TRIGGERS
new file mode 100755
index 0000000000..8fc029e18b
--- /dev/null
+++ b/video/ffmpeg5/UP_TRIGGERS
@@ -0,0 +1,19 @@
+# up_trigger everything on major version updates
+local NEW_SPELL_BRANCH="" &&
+local OLD_SPELL_BRANCH="" &&
+
+if spell_ok $SPELL; then
+ NEW_SPELL_BRANCH="$(echo $VERSION | cut -d. -f1,2)" &&
+ OLD_SPELL_BRANCH="$(installed_version $SPELL | cut -d. -f1,2)" &&
+
+ if test "${NEW_SPELL_BRANCH}" != "${OLD_SPELL_BRANCH}"; then
+ message "This is a possibly incompatible update of ${SPELL}..."
+ message "Figuring out what spells need to be recast, this may take a while."
+ for each in $(show_up_depends $SPELL 1); do
+ if gaze install $each | xargs readelf -d 2> /dev/null |
+ grep -q "NEEDED.*lib\(\(swscale\)\|\(avcodec\)\|\(avdevice\)\|\(avfilter\)\|\(avutil\)\|\(postproc\)\|\(swresample\)\)"; then
+ up_trigger $each cast_self
+ fi
+ done
+ fi
+fi