From: Jakub Bogusz Date: Sun, 23 Dec 2012 20:56:52 +0000 (+0100) Subject: - new, just in case (fork of ffmpeg, less powerful at first sight) X-Git-Tag: auto/th/libav-11.4-0.1~18 X-Git-Url: http://git.pld-linux.org/gitweb.cgi?a=commitdiff_plain;h=97ebd1f276ec0b0fd5903d08827c2a889a48866f;p=packages%2Flibav.git - new, just in case (fork of ffmpeg, less powerful at first sight) --- 97ebd1f276ec0b0fd5903d08827c2a889a48866f diff --git a/avserver.conf b/avserver.conf new file mode 100644 index 0000000..16584d9 --- /dev/null +++ b/avserver.conf @@ -0,0 +1,349 @@ +# Port on which the server is listening. You must select a different +# port from your standard HTTP web server if it is running on the same +# computer. +Port 8090 + +# Address on which the server is bound. Only useful if you have +# several network interfaces. +BindAddress 0.0.0.0 + +# Number of simultaneous requests that can be handled. Since FFServer +# is very fast, it is more likely that you will want to leave this high +# and use MaxBandwidth, below. +MaxClients 1000 + +# This the maximum amount of kbit/sec that you are prepared to +# consume when streaming to clients. +MaxBandwidth 1000 + +# Access log file (uses standard Apache log file format) +# '-' is the standard output. +CustomLog /var/log/avserver/access.log + +# Suppress that if you want to launch avserver as a daemon. +#NoDaemon + + +################################################################## +# Definition of the live feeds. Each live feed contains one video +# and/or audio sequence coming from an ffmpeg encoder or another +# avserver. This sequence may be encoded simultaneously with several +# codecs at several resolutions. + + + +# You must use 'ffmpeg' to send a live feed to avserver. In this +# example, you can type: +# +# ffmpeg http://localhost:8090/feed1.ffm + +# avserver can also do time shifting. It means that it can stream any +# previously recorded live stream. The request should contain: +# "http://xxxx?date=[YYYY-MM-DDT][[HH:]MM:]SS[.m...]".You must specify +# a path where the feed is stored on disk. You also specify the +# maximum size of the feed, where zero means unlimited. Default: +# File=/tmp/feed_name.ffm FileMaxSize=5M +File /var/cache/avserver/feed1.ffm +FileMaxSize 200K + +# You could specify +# ReadOnlyFile /saved/specialvideo.ffm +# This marks the file as readonly and it will not be deleted or updated. + +# Specify launch in order to start ffmpeg automatically. +# First ffmpeg must be defined with an appropriate path if needed, +# after that options can follow, but avoid adding the http:// field +#Launch ffmpeg + +# Only allow connections from localhost to the feed. +ACL allow 127.0.0.1 + + + + +################################################################## +# Now you can define each stream which will be generated from the +# original audio and video stream. Each format has a filename (here +# 'test1.mpg'). FFServer will send this stream when answering a +# request containing this filename. + + + +# coming from live feed 'feed1' +Feed feed1.ffm + +# Format of the stream : you can choose among: +# mpeg : MPEG-1 multiplexed video and audio +# mpegvideo : only MPEG-1 video +# mp2 : MPEG-2 audio (use AudioCodec to select layer 2 and 3 codec) +# ogg : Ogg format (Vorbis audio codec) +# rm : RealNetworks-compatible stream. Multiplexed audio and video. +# ra : RealNetworks-compatible stream. Audio only. +# mpjpeg : Multipart JPEG (works with Netscape without any plugin) +# jpeg : Generate a single JPEG image. +# asf : ASF compatible streaming (Windows Media Player format). +# swf : Macromedia Flash compatible stream +# avi : AVI format (MPEG-4 video, MPEG audio sound) +# master : special ffmpeg stream used to duplicate a server +Format mpeg + +# Bitrate for the audio stream. Codecs usually support only a few +# different bitrates. +AudioBitRate 32 + +# Number of audio channels: 1 = mono, 2 = stereo +AudioChannels 1 + +# Sampling frequency for audio. When using low bitrates, you should +# lower this frequency to 22050 or 11025. The supported frequencies +# depend on the selected audio codec. +AudioSampleRate 44100 + +# Bitrate for the video stream +VideoBitRate 64 + +# Ratecontrol buffer size +VideoBufferSize 40 + +# Number of frames per second +VideoFrameRate 3 + +# Size of the video frame: WxH (default: 160x128) +# The following abbreviations are defined: sqcif, qcif, cif, 4cif +VideoSize 160x128 + +# Transmit only intra frames (useful for low bitrates, but kills frame rate). +#VideoIntraOnly + +# If non-intra only, an intra frame is transmitted every VideoGopSize +# frames. Video synchronization can only begin at an intra frame. +VideoGopSize 12 + +# More MPEG-4 parameters +# VideoHighQuality +# Video4MotionVector + +# Choose your codecs: +#AudioCodec mp2 +#VideoCodec mpeg1video + +# Suppress audio +#NoAudio + +# Suppress video +#NoVideo + +#VideoQMin 3 +#VideoQMax 31 + +# Set this to the number of seconds backwards in time to start. Note that +# most players will buffer 5-10 seconds of video, and also you need to allow +# for a keyframe to appear in the data stream. +#Preroll 15 + +# ACL: + +# You can allow ranges of addresses (or single addresses) +#ACL ALLOW + +# You can deny ranges of addresses (or single addresses) +#ACL DENY + +# You can repeat the ACL allow/deny as often as you like. It is on a per +# stream basis. The first match defines the action. If there are no matches, +# then the default is the inverse of the last ACL statement. +# +# Thus 'ACL allow localhost' only allows access from localhost. +# 'ACL deny 1.0.0.0 1.255.255.255' would deny the whole of network 1 and +# allow everybody else. + + + + +################################################################## +# Example streams + + +# Multipart JPEG + +# +#Feed feed1.ffm +#Format mpjpeg +#VideoFrameRate 2 +#VideoIntraOnly +#NoAudio +#Strict -1 +# + + +# Single JPEG + +# +#Feed feed1.ffm +#Format jpeg +#VideoFrameRate 2 +#VideoIntraOnly +##VideoSize 352x240 +#NoAudio +#Strict -1 +# + + +# Flash + +# +#Feed feed1.ffm +#Format swf +#VideoFrameRate 2 +#VideoIntraOnly +#NoAudio +# + + +# ASF compatible + + +Feed feed1.ffm +Format asf +VideoFrameRate 15 +VideoSize 352x240 +VideoBitRate 256 +VideoBufferSize 40 +VideoGopSize 30 +AudioBitRate 64 +StartSendOnKey + + + +# MP3 audio + +# +#Feed feed1.ffm +#Format mp2 +#AudioCodec mp3 +#AudioBitRate 64 +#AudioChannels 1 +#AudioSampleRate 44100 +#NoVideo +# + + +# Ogg Vorbis audio + +# +#Feed feed1.ffm +#Title "Stream title" +#AudioBitRate 64 +#AudioChannels 2 +#AudioSampleRate 44100 +#NoVideo +# + + +# Real with audio only at 32 kbits + +# +#Feed feed1.ffm +#Format rm +#AudioBitRate 32 +#NoVideo +#NoAudio +# + + +# Real with audio and video at 64 kbits + +# +#Feed feed1.ffm +#Format rm +#AudioBitRate 32 +#VideoBitRate 128 +#VideoFrameRate 25 +#VideoGopSize 25 +#NoAudio +# + + +################################################################## +# A stream coming from a file: you only need to set the input +# filename and optionally a new format. Supported conversions: +# AVI -> ASF + +# +#File "/usr/local/httpd/htdocs/tlive.rm" +#NoAudio +# + +# +#File "/usr/local/httpd/htdocs/test.asf" +#NoAudio +#Author "Me" +#Copyright "Super MegaCorp" +#Title "Test stream from disk" +#Comment "Test comment" +# + + +################################################################## +# RTSP examples +# +# You can access this stream with the RTSP URL: +# rtsp://localhost:5454/test1-rtsp.mpg +# +# A non-standard RTSP redirector is also created. Its URL is: +# http://localhost:8090/test1-rtsp.rtsp + +# +#Format rtp +#File "/usr/local/httpd/htdocs/test1.mpg" +# + + +################################################################## +# SDP/multicast examples +# +# If you want to send your stream in multicast, you must set the +# multicast address with MulticastAddress. The port and the TTL can +# also be set. +# +# An SDP file is automatically generated by avserver by adding the +# 'sdp' extension to the stream name (here +# http://localhost:8090/test1-sdp.sdp). You should usually give this +# file to your player to play the stream. +# +# The 'NoLoop' option can be used to avoid looping when the stream is +# terminated. + +# +#Format rtp +#File "/usr/local/httpd/htdocs/test1.mpg" +#MulticastAddress 224.124.0.1 +#MulticastPort 5000 +#MulticastTTL 16 +#NoLoop +# + + +################################################################## +# Special streams + +# Server status + + +Format status + +# Only allow local people to get the status +ACL allow localhost +ACL allow 192.168.0.0 192.168.255.255 + +#FaviconURL http://pond1.gladstonefamily.net:8080/favicon.ico + + + +# Redirect index.html to the appropriate site + + +URL http://ffmpeg.sourceforge.net/index.php + + + diff --git a/avserver.init b/avserver.init new file mode 100755 index 0000000..69e24b2 --- /dev/null +++ b/avserver.init @@ -0,0 +1,93 @@ +#!/bin/sh +# +# avserver FFserver video server +# +# chkconfig: 345 40 60 +# +# description: FFserver video server +# +# $Id$ + +# Source function library +. /etc/rc.d/init.d/functions + +# Get network config +. /etc/sysconfig/network + +# Get service config - may override defaults +[ -f /etc/sysconfig/avserver ] && . /etc/sysconfig/avserver + +# Check that networking is up. +if is_yes "${NETWORKING}"; then + if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then + msg_network_down avserver + exit 1 + fi +else + exit 0 +fi + +start() { + # Check if the service is already running? + if [ -f /var/lock/subsys/avserver ]; then + msg_already_running avserver + return + fi + + msg_starting avserver + daemon --user ffserver /usr/sbin/avserver + RETVAL=$? + [ $RETVAL -eq 0 ] && touch /var/lock/subsys/avserver +} + +stop() { + if [ ! -f /var/lock/subsys/avserver ]; then + msg_not_running avserver + return + fi + + # Stop daemons. + msg_stopping avserver + killproc avserver + rm -f /var/lock/subsys/avserver +} + +condrestart() { + if [ ! -f /var/lock/subsys/avserver ]; then + msg_not_running avserver + RETVAL=$1 + return + fi + + stop + start +} + +# See how we were called. +case "$1" in + start) + start + ;; + stop) + stop + ;; + restart) + stop + start + ;; + try-restart) + condrestart 0 + ;; + force-reload) + condrestart 7 + ;; + status) + status avserver + RETVAL=$? + ;; + *) + msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}" + exit 3 +esac + +exit $RETVAL diff --git a/avserver.sysconfig b/avserver.sysconfig new file mode 100644 index 0000000..79688f8 --- /dev/null +++ b/avserver.sysconfig @@ -0,0 +1 @@ +# Customized settings for avserver diff --git a/libav-cdio-paranoia.patch b/libav-cdio-paranoia.patch new file mode 100644 index 0000000..48ecede --- /dev/null +++ b/libav-cdio-paranoia.patch @@ -0,0 +1,24 @@ +--- ffmpeg-1.0.1/libavdevice/libcdio.c.orig 2012-12-03 22:17:35.000000000 +0100 ++++ ffmpeg-1.0.1/libavdevice/libcdio.c 2012-12-06 19:03:32.695282861 +0100 +@@ -23,8 +23,8 @@ + * libcdio CD grabbing + */ + +-#include +-#include ++#include ++#include + + #include "libavutil/log.h" + #include "libavutil/mem.h" +--- ffmpeg-1.0.1/configure.orig 2012-12-06 19:06:32.011945790 +0100 ++++ ffmpeg-1.0.1/configure 2012-12-06 19:29:13.155250760 +0100 +@@ -3771,7 +3771,7 @@ + enabled_any sndio_indev sndio_outdev && check_lib2 sndio.h sio_open -lsndio + + enabled libcdio && +- check_lib2 "cdio/cdda.h cdio/paranoia.h" cdio_cddap_open "-lcdio_paranoia -lcdio_cdda -lcdio" ++ check_lib2 "cdio/paranoia/cdda.h cdio/paranoia/paranoia.h" cdio_cddap_open "-lcdio_paranoia -lcdio_cdda -lcdio" + + enabled x11grab && + require X11 X11/Xlib.h XOpenDisplay -lX11 && diff --git a/libav-gsm.patch b/libav-gsm.patch new file mode 100644 index 0000000..6f4bca3 --- /dev/null +++ b/libav-gsm.patch @@ -0,0 +1,22 @@ +--- libav-0.8.4/configure.orig 2012-12-22 17:45:12.936567283 +0100 ++++ libav-0.8.4/configure 2012-12-22 17:52:41.616557932 +0100 +@@ -2942,7 +2942,7 @@ + "dirac_decoder_init dirac_encoder_init" + enabled libfaac && require2 libfaac "stdint.h faac.h" faacEncGetVersion -lfaac + enabled libfreetype && require_pkg_config freetype2 "ft2build.h freetype/freetype.h" FT_Init_FreeType +-enabled libgsm && require libgsm gsm/gsm.h gsm_create -lgsm ++enabled libgsm && require libgsm gsm.h gsm_create -lgsm + enabled libmp3lame && require "libmp3lame >= 3.98.3" lame/lame.h lame_set_VBR_quality -lmp3lame + enabled libnut && require libnut libnut.h nut_demuxer_init -lnut + enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb +--- ffmpeg-0.10/libavcodec/libgsm.c.orig 2012-01-26 23:15:59.000000000 +0100 ++++ ffmpeg-0.10/libavcodec/libgsm.c 2012-01-27 17:58:28.495275196 +0100 +@@ -27,7 +27,7 @@ + + // The idiosyncrasies of GSM-in-WAV are explained at http://kbs.cs.tu-berlin.de/~jutta/toast.html + +-#include ++#include + + #include "avcodec.h" + #include "gsm.h" diff --git a/libav-opencv24.patch b/libav-opencv24.patch new file mode 100644 index 0000000..eb1d133 --- /dev/null +++ b/libav-opencv24.patch @@ -0,0 +1,11 @@ +--- libav-0.8.4/configure.orig 2012-12-22 17:53:05.373224102 +0100 ++++ libav-0.8.4/configure 2012-12-22 17:58:36.386550536 +0100 +@@ -2947,7 +2947,7 @@ + enabled libnut && require libnut libnut.h nut_demuxer_init -lnut + enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb + enabled libopencore_amrwb && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb +-enabled libopencv && require_pkg_config opencv opencv/cv.h cvCreateImageHeader ++enabled libopencv && add_extralibs -lopencv_core -lopencv_features2d -lopencv_imgproc -lopencv_objdetect + enabled libopenjpeg && require libopenjpeg openjpeg.h opj_version -lopenjpeg + enabled libpulse && require_pkg_config libpulse-simple pulse/simple.h pa_simple_new + enabled librtmp && require_pkg_config librtmp librtmp/rtmp.h RTMP_Socket diff --git a/libav-openjpeg.patch b/libav-openjpeg.patch new file mode 100644 index 0000000..c774eb1 --- /dev/null +++ b/libav-openjpeg.patch @@ -0,0 +1,11 @@ +--- libav-0.8.4/configure.orig 2012-12-22 18:00:01.673215427 +0100 ++++ libav-0.8.4/configure 2012-12-22 18:04:38.113209665 +0100 +@@ -2948,7 +2948,7 @@ + enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb + enabled libopencore_amrwb && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb + enabled libopencv && add_extralibs -lopencv_core -lopencv_features2d -lopencv_imgproc -lopencv_objdetect +-enabled libopenjpeg && require libopenjpeg openjpeg.h opj_version -lopenjpeg ++enabled libopenjpeg && require_pkg_config libopenjpeg openjpeg.h opj_version + enabled libpulse && require_pkg_config libpulse-simple pulse/simple.h pa_simple_new + enabled librtmp && require_pkg_config librtmp librtmp/rtmp.h RTMP_Socket + enabled libschroedinger && require_pkg_config schroedinger-1.0 schroedinger/schro.h schro_init diff --git a/libav.spec b/libav.spec new file mode 100644 index 0000000..361a178 --- /dev/null +++ b/libav.spec @@ -0,0 +1,499 @@ +# NOTE: don't send it to Th unless you resolve libraries (incl. sonames) conflict with ffmpeg +# libav is a fork of ffmpeg; as of Dec 2012 they are not 100% compatible +# (e.g. libav didn't drop some deprecated APIs); ffmpeg 1.0.x seems more powerful than libav 0.8.x. +# +# How to deal with ffmpeg/opencv checken-egg problem: +# 1. make-request -r --without opencv ffmpeg.spec +# 2. make-request -r opencv.spec +# 3. bump release of ffmpeg.spec +# 4. make-request -r ffmpeg.spec +# +# Conditional build: +%bcond_with nonfree # non free options of package (currently: faac) +%bcond_without frei0r # frei0r video filtering +%bcond_without opencv # OpenCV video filtering +%bcond_without pulseaudio # PulseAudio input support +%bcond_without x264 # x264 encoder +%bcond_without va # VAAPI (Video Acceleration API) +%bcond_without vpx # VP8, a high-quality video codec +%bcond_without doc # don't build docs + +Summary: libav - Open Source audio and video processing tools +Summary(pl.UTF-8): libav - narzędzia do przetwarzania dźwięku i obrazu o otwartych źródłach +Name: libav +Version: 0.8.4 +Release: 0.1 +# LGPL or GPL, chosen at configure time (GPL version is more featured) +# (postprocessing, some filters, x264, xavs, xvid, x11grab) +# using v3 allows Apache-licensed libs (opencore-amr, libvo-*enc) +License: GPL v3+ with LGPL v3+ parts +Group: Libraries +Source0: http://libav.org/releases/%{name}-%{version}.tar.xz +# Source0-md5: 4634b35dec327f9aba61b3b894df03f7 +Source1: avserver.init +Source2: avserver.sysconfig +Source3: avserver.conf +Patch0: %{name}-gsm.patch +Patch1: %{name}-opencv24.patch +Patch2: %{name}-openjpeg.patch +Patch3: %{name}-cdio-paranoia.patch +URL: http://libav.org/ +BuildRequires: SDL-devel >= 1.2.1 +BuildRequires: alsa-lib-devel +BuildRequires: bzip2-devel +%{?with_nonfree:BuildRequires: faac-devel} +BuildRequires: freetype-devel +%{?with_frei0r:BuildRequires: frei0r-devel} +%ifarch ppc +# require version with altivec support fixed +BuildRequires: gcc >= 5:3.3.2-3 +%endif +BuildRequires: gnutls-devel +BuildRequires: jack-audio-connection-kit-devel +BuildRequires: lame-libs-devel >= 3.98.3 +BuildRequires: libcdio-paranoia-devel >= 0.90-2 +BuildRequires: libdc1394-devel >= 2 +BuildRequires: libgsm-devel +BuildRequires: libnut-devel +BuildRequires: libraw1394-devel >= 2 +BuildRequires: librtmp-devel +BuildRequires: libtheora-devel >= 1.0-0.beta3 +BuildRequires: libtool >= 2:1.4d-3 +%{?with_va:BuildRequires: libva-devel >= 1.0.3} +BuildRequires: libvdpau-devel >= 0.2 +BuildRequires: libvorbis-devel +%{?with_vpx:BuildRequires: libvpx-devel >= 0.9.1} +# X264_BUILD >= 118 +%{?with_x264:BuildRequires: libx264-devel >= 0.1.3-1.20111212_2245} +%ifarch %{ix86} +%ifnarch i386 i486 +BuildRequires: nasm +%endif +%endif +BuildRequires: opencore-amr-devel +%{?with_opencv:BuildRequires: opencv-devel} +BuildRequires: openjpeg-devel >= 1.5 +BuildRequires: perl-Encode +BuildRequires: perl-tools-pod +BuildRequires: pkgconfig +%{?with_pulseaudio:BuildRequires: pulseaudio-devel} +BuildRequires: rpmbuild(macros) >= 1.470 +BuildRequires: schroedinger-devel +BuildRequires: speex-devel >= 1:1.2-rc1 +BuildRequires: tar >= 1:1.22 +%{?with_doc:BuildRequires: tetex} +%{?with_doc:BuildRequires: texi2html} +%{?with_doc:BuildRequires: texinfo} +BuildRequires: vo-aacenc-devel +BuildRequires: vo-amrwbenc-devel +BuildRequires: xavs-devel +BuildRequires: xorg-lib-libXext-devel +BuildRequires: xorg-lib-libXfixes-devel +BuildRequires: xvid-devel >= 1:1.1.0 +BuildRequires: xz +BuildRequires: yasm +BuildRequires: zlib-devel +Requires: xvid >= 1:1.1.0 +Obsoletes: libpostproc +BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) + +%define _noautoreqdep libGL.so.1 libGLU.so.1 + +%define specflags -fno-strict-aliasing + +# -fomit-frame-pointer is always needed on x86 due to lack of registers (-fPIC takes one) +%define specflags_ia32 -fomit-frame-pointer +# -mmmx is needed to enable code. +%define specflags_i586 -mmmx +%define specflags_i686 -mmmx +%define specflags_ppc -fPIC + +%description +Libav provides cross-platform tools and libraries to convert, +manipulate and stream a wide range of multimedia formats and +protocols. + +%description -l pl.UTF-8 +Projekt libav udostępnia wieloplatformowe narzędzia i biblioteki do +konwersji, modyfikowania oraz nadawania strumieni przy użyciu +szerokiego zakresu formatów i protokołów multimedialnych. + +%package devel +Summary: libav header files +Summary(pl.UTF-8): Pliki nagłówkowe bibliotek libav +Group: Development/Libraries +Requires: %{name} = %{version}-%{release} +# Libs.private from *.pc (unreasonably they are all the same) +Requires: SDL-devel >= 1.2.1 +Requires: alsa-lib-devel +Requires: bzip2-devel +%{?with_nonfree:Requires: faac-devel} +Requires: freetype-devel +Requires: jack-audio-connection-kit-devel +Requires: lame-libs-devel >= 3.98.3 +Requires: libcdio-paranoia-devel >= 0.90-2 +Requires: libdc1394-devel >= 2 +Requires: libgsm-devel +Requires: libnut-devel +Requires: libraw1394-devel >= 2 +Requires: librtmp-devel +Requires: libtheora-devel >= 1.0-0.beta3 +%{?with_va:Requires: libva-devel >= 1.0.3} +Requires: libvorbis-devel +%{?with_vpx:Requires: libvpx-devel >= 0.9.1} +%{?with_x264:Requires: libx264-devel >= 0.1.3-1.20110625_2245} +Requires: opencore-amr-devel +%{?with_opencv:Requires: opencv-devel} +Requires: openjpeg-devel >= 1.5 +Requires: schroedinger-devel +Requires: speex-devel >= 1:1.2-rc1 +Requires: vo-aacenc-devel +Requires: vo-amrwbenc-devel +Requires: xavs-devel +Requires: xorg-lib-libXext-devel +Requires: xorg-lib-libXfixes-devel +Requires: xvid-devel >= 1:1.1.0 +Requires: zlib-devel +Obsoletes: libpostproc-devel + +%description devel +libav header files. + +%description devel -l pl.UTF-8 +Pliki nagłówkowe bibliotek libav. + +%package static +Summary: libav static libraries +Summary(pl.UTF-8): Statyczne biblioteki libav +Group: Development/Libraries +Requires: %{name}-devel = %{version}-%{release} + +%description static +libav static libraries. + +%description static -l pl.UTF-8 +Statyczne biblioteki libav. + +%package tools +Summary: libav video and audio conversion tools +Summary(pl.UTF-8): Narzędzia libav do konwersji obrazu i dźwięku +Group: Applications/Multimedia +Requires: %{name} = %{version}-%{release} + +%description tools +libav command line tools to convert one video file format to another. + +%description tools -l pl.UTF-8 +Narzędzia linii poleceń libav do konwersji filmów z jednego formatu do +innego. + +%package avplay +Summary: avplay - SDL-based media player +Summary(pl.UTF-8): avplay - odtwarzacz mediów oparty na SDL +Group: Applications/Multimedia +Requires: %{name} = %{version}-%{release} + +%description avplay +avplay is a very simple and portable media player using the libav +libraries and the SDL library. It is mostly used as a test bench for +the various APIs of libav. + +%description avplay -l pl.UTF-8 +avplay to bardzo prosty i przenośny odtwarzacz mediów używający +bibliotek libav oraz biblioteki SDL. Jest używany głównie do +testowania różnych API libav. + +%package avserver +Summary: avserver video server +Summary(pl.UTF-8): avserver - serwer strumieni obrazu +Group: Daemons +Requires(post,preun): /sbin/chkconfig +Requires: %{name} = %{version}-%{release} +Requires: rc-scripts >= 0.4.0.10 + +%description avserver +avserver is a streaming server for both audio and video. It supports +several live feeds, streaming from files and time shifting on live +feeds (you can seek to positions in the past on each live feed, +provided you specify a big enough feed storage in avserver.conf). + +%description avserver -l pl.UTF-8 +avserver to serwer strumieni dla dźwięku i obrazu. Obsługuje kilka +źródeł na żywo, przekazywanie strumieni z plików i przesuwanie w +czasie dla źródeł na żywo (można przeskakiwać na położenia w +przeszłości dla każdego źródła na żywo, pod warunkiem odpowiednio +dużej przestrzeni na dane skonfigurowanej w avserver.conf). + +%prep +%setup -q +%patch0 -p1 +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 + +# package the grep result for mplayer, the result formatted as ./mplayer/configure +cat < libav-avconfig +#! /bin/sh +_libavdecoders_all="`sed -n 's/^[^#]*DEC.*(.*, *\(.*\)).*/\1_decoder/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`" +_libavencoders_all="`sed -n 's/^[^#]*ENC.*(.*, *\(.*\)).*/\1_encoder/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`" +_libavparsers_all="`sed -n 's/^[^#]*PARSER.*(.*, *\(.*\)).*/\1_parser/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`" +_libavbsfs_all="`sed -n 's/^[^#]*BSF.*(.*, *\(.*\)).*/\1_bsf/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`" +_libavdemuxers_all="`sed -n 's/^[^#]*DEMUX.*(.*, *\(.*\)).*/\1_demuxer/p' libavformat/allformats.c | tr '[a-z]' '[A-Z]'`" +_libavmuxers_all="`sed -n 's/^[^#]*_MUX.*(.*, *\(.*\)).*/\1_muxer/p' libavformat/allformats.c | tr '[a-z]' '[A-Z]'`" +_libavprotocols_all="`sed -n 's/^[^#]*PROTOCOL.*(.*, *\(.*\)).*/\1_protocol/p' libavformat/allformats.c | tr '[a-z]' '[A-Z]'`" +EOF +cat <<'EOF' >> libav-avconfig + +case "$1" in +--decoders) + echo $_libavdecoders_all + ;; +--encoders) + echo $_libavencoders_all + ;; +--parsers) + echo $_libavparsers_all + ;; +--bsfs) + echo $_libavbsfs_all + ;; +--demuxers) + echo $_libavdemuxers_all + ;; +--muxers) + echo $_libavmuxers_all + ;; +--protocols) + echo $_libavprotocols_all + ;; +*) + cat <