]> git.pld-linux.org Git - packages/ffmpeg.git/blob - ffmpeg.spec
- cosmetics
[packages/ffmpeg.git] / ffmpeg.spec
1 # TODO:
2 # - separate ffserver and its config to separate server package.
3 #   Make whole init-stuff for it.
4 #
5 # Conditional build:
6 %bcond_without  imlib2          # we can safely play without it:-)
7 %bcond_without  autoreqdep      # don't care about package name deps generated by rpm
8 #
9 %define snap    20060129
10 %define _rel 8.2
11 Summary:        Realtime audio/video encoder and streaming server
12 Summary(pl):    Koder audio/wideo czasu rzeczywistego oraz serwer strumieni
13 Name:           ffmpeg
14 Version:        0.4.9
15 Release:        3.%{snap}.%{_rel}
16 # LGPL or GPL, chosen at configure time (GPL version is more featured)
17 License:        GPL
18 Group:          Daemons
19 #Source0:       http://dl.sourceforge.net/ffmpeg/%{name}-%{version}-pre1.tar.gz
20 #Source0:       ftp://ftp2.mplayerhq.hu/MPlayer/cvs/FFMpeg-%{snap}.tar.bz2
21 Source0:        %{name}-%{snap}.tar.bz2
22 # Source0-md5:  d8ea09431d6c0c91bfd35e0ca74a67e1
23 Patch0:         %{name}-libtool.patch
24 Patch1:         %{name}-libdir.patch
25 Patch2:         %{name}-gcc4.patch
26 URL:            http://ffmpeg.sourceforge.net/
27 BuildRequires:  SDL-devel
28 BuildRequires:  faac-devel
29 BuildRequires:  faad2-devel
30 BuildRequires:  freetype-devel
31 %ifarch ppc
32 # require version with altivec support fixed
33 BuildRequires:  gcc >= 5:3.3.2-3
34 %endif
35 %{?with_imlib2:BuildRequires:   imlib2-devel >= 1.1.0-2}
36 BuildRequires:  lame-libs-devel
37 BuildRequires:  libdts-devel
38 BuildRequires:  libgsm-devel
39 BuildRequires:  libtheora-devel
40 BuildRequires:  libtool >= 2:1.4d-3
41 BuildRequires:  libvorbis-devel
42 #BuildRequires: libx264-devel
43 BuildRequires:  lzo-devel
44 %ifarch %{ix86}
45 %ifnarch i386 i486
46 BuildRequires:  nasm
47 %endif
48 %endif
49 BuildRequires:  perl-tools-pod
50 BuildRequires:  tetex
51 BuildRequires:  texinfo
52 BuildRequires:  xvid-devel >= 1:1.1.0
53 BuildRequires:  zlib-devel
54 %{?with_autoreqdep:BuildConflicts:      libpostproc}
55 Requires:       %{name}-libs = %{version}-%{release}
56 Requires:       xvid >= 1:1.1.0
57 Obsoletes:      libpostproc
58 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
59
60 %define         _noautoreqdep   libGL.so.1 libGLU.so.1
61
62 %define         specflags       -fno-strict-aliasing
63
64 # -fomit-frame-pointer is always needed on x86 due to lack of registers (-fPIC takes one)
65 %define         specflags_ia32  -fomit-frame-pointer
66 # -mmmx is needed to enable <mmintrin.h> code.
67 %define         specflags_i586  -mmmx
68 %define         specflags_i686  -mmmx
69
70 %description
71 ffmpeg is a hyper fast realtime audio/video encoder and streaming
72 server. It can grab from a standard Video4Linux video source and
73 convert it into several file formats based on DCT/motion compensation
74 encoding. Sound is compressed in MPEG audio layer 2 or using an AC3
75 compatible stream.
76
77 %description -l pl
78 ffmpeg jest bardzo szybkim koderem audio/wideo w czasie rzeczywistym
79 oraz serwerem strumieni multimedialnych. ffmpeg potrafi zrzucaæ dane
80 ze standardowego urz±dzenia Video4Linux i przekonwertowaæ je w kilka
81 formatów plików bazuj±cych na kodowaniu DCT/kompensacji ruchu. D¼wiêk
82 jest kompresowany do strumienia MPEG audio layer 2 lub u¿ywaj±c
83 strumienia kompatybilnego z AC3.
84
85 %package libs
86 Summary:        ffmpeg libraries
87 Summary(pl):    Biblioteki ffmpeg
88 Group:          Libraries
89
90 %description libs
91 This package contains ffmpeg shared libraries.
92
93 %description libs -l pl
94 Ten pakiet zawiera biblioteki wspó³dzielone ffmpeg.
95
96 %package devel
97 Summary:        ffmpeg header files
98 Summary(pl):    Pliki nag³ówkowe ffmpeg
99 Group:          Development/Libraries
100 Requires:       %{name}-libs = %{version}-%{release}
101 Obsoletes:      libpostproc-devel
102 # for libavcodec:
103 Requires:       faac-devel
104 Requires:       lame-libs-devel
105 Requires:       libdts-devel
106 Requires:       libgsm-devel
107 Requires:       libtheora-devel
108 Requires:       libvorbis-devel
109 Requires:       xvid-devel >= 1:1.1.0
110 Requires:       zlib-devel
111
112 %description devel
113 ffmpeg header files.
114
115 %description devel -l pl
116 Pliki nag³ówkowe ffmpeg.
117
118 %package static
119 Summary:        ffmpeg static libraries
120 Summary(pl):    Statyczne biblioteki ffmpeg
121 Group:          Development/Libraries
122 Requires:       %{name}-devel = %{version}-%{release}
123
124 %description static
125 ffmpeg static libraries (libavcodec and libavformat).
126
127 %description static -l pl
128 Statyczne biblioteki ffmpeg (libavcodec i libavformat).
129
130 %package ffplay
131 Summary:        FFplay - SDL-based media player
132 Summary(pl):    FFplay - odtwarzacz mediów oparty na SDL
133 Group:          Applications/Multimedia
134 Requires:       %{name}-libs = %{version}-%{release}
135
136 %description ffplay
137 FFplay is a very simple and portable media player using the FFmpeg
138 libraries and the SDL library. It is mostly used as a test bench for
139 the various APIs of FFmpeg.
140
141 %description ffplay -l pl
142 FFplay to bardzo prosty i przeno¶ny odtwarzacz mediów u¿ywaj±cy
143 bibliotek FFmpeg oraz biblioteki SDL. Jest u¿ywany g³ównie do
144 testowania ró¿nych API FFmpeg.
145
146 %package vhook-imlib2
147 Summary:        imlib2 based hook
148 Summary(pl):    Modu³ przej¶ciowy oparty o imlib2
149 Group:          Libraries
150 Requires:       %{name}-libs = %{version}-%{release}
151
152 %description vhook-imlib2
153 This module implements a text overlay for a video image. Currently it
154 supports a fixed overlay or reading the text from a file. The string
155 is passed through strftime so that it is easy to imprint the date and
156 time onto the image.
157
158 %description vhook-imlib2 -l pl
159 Ten modu³ implementuje tekstow± nak³adkê dla obrazu. Aktualnie
160 obs³uguje sta³± nak³adkê lub wczytywanie tekstu z pliku. £añcuch jest
161 przepuszczany przez strftime, wiêc ³atwo umie¶ciæ datê i czas na
162 obrazie.
163
164 %prep
165 %setup -q -n %{name}
166 %patch0 -p1
167 %patch1 -p1
168 %patch2 -p1
169
170 %build
171 # notes:
172 # - it's not autoconf configure
173 # - --disable-debug, --disable-opts, tune=generic causes not to override our optflags
174 ./configure \
175         --prefix=%{_prefix} \
176         --libdir=%{_libdir} \
177         --mandir=%{_mandir} \
178         --disable-strip \
179         --enable-a52 \
180         --enable-a52bin \
181         --enable-dts \
182         --enable-faac \
183         --enable-faad \
184         --enable-faadbin \
185         --enable-gpl \
186         --enable-libgsm \
187         --enable-libogg \
188         --enable-mp3lame \
189         --enable-pp \
190         --enable-pthreads \
191         --enable-shared \
192         --enable-theora \
193         --enable-vorbis \
194         --enable-xvid \
195 %ifnarch %{ix86} %{x8664}
196         --disable-mmx \
197 %endif
198 %ifarch i386 i486
199         --disable-mmx \
200 %endif
201         --cc="%{__cc}" \
202         --extra-cflags="%{rpmcflags}" \
203         --extra-ldflags="%{rpmldflags}" \
204         --disable-debug \
205         --disable-opts \
206         --tune=generic
207
208 %{__make} \
209         BUILD_DOC=yes
210
211 %install
212 rm -rf $RPM_BUILD_ROOT
213 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_sbindir}}
214
215 %{__make} install \
216         DESTDIR=$RPM_BUILD_ROOT
217
218 install xvmc_render.h $RPM_BUILD_ROOT%{_includedir}/ffmpeg
219
220 mv -f $RPM_BUILD_ROOT{%{_bindir},%{_sbindir}}/ffserver
221 install doc/*.conf $RPM_BUILD_ROOT%{_sysconfdir}
222
223 %clean
224 rm -rf $RPM_BUILD_ROOT
225
226 %post   -p /sbin/ldconfig
227 %postun -p /sbin/ldconfig
228
229 %files
230 %defattr(644,root,root,755)
231 %doc Changelog README doc/*.html doc/TODO
232 %attr(755,root,root) %{_bindir}/ffmpeg
233 %attr(755,root,root) %{_sbindir}/ffserver
234 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/ffserver.conf
235 %{_mandir}/man1/ffmpeg.1*
236 %{_mandir}/man1/ffserver.1*
237
238 %files libs
239 %defattr(644,root,root,755)
240 %attr(755,root,root) %{_libdir}/libavcodec.so.*.*.*
241 %attr(755,root,root) %{_libdir}/libavformat.so.*.*.*
242 %attr(755,root,root) %{_libdir}/libavutil.so.*.*.*
243 %attr(755,root,root) %{_libdir}/libpostproc.so.*.*.*
244 %dir %{_libdir}/vhook
245 %attr(755,root,root) %{_libdir}/vhook/drawtext.so
246 %attr(755,root,root) %{_libdir}/vhook/fish.so
247 %attr(755,root,root) %{_libdir}/vhook/null.so
248 %attr(755,root,root) %{_libdir}/vhook/ppm.so
249 %attr(755,root,root) %{_libdir}/vhook/watermark.so
250
251 %files devel
252 %defattr(644,root,root,755)
253 %doc doc/optimization.txt
254 %attr(755,root,root) %{_libdir}/libavcodec.so
255 %attr(755,root,root) %{_libdir}/libavformat.so
256 %attr(755,root,root) %{_libdir}/libavutil.so
257 %attr(755,root,root) %{_libdir}/libpostproc.so
258 %{_libdir}/lib*.la
259 %{_includedir}/ffmpeg
260 %{_includedir}/postproc
261 %{_pkgconfigdir}/*.pc
262
263 %files static
264 %defattr(644,root,root,755)
265 %{_libdir}/lib*.a
266
267 %files ffplay
268 %defattr(644,root,root,755)
269 %attr(755,root,root) %{_bindir}/ffplay
270 %{_mandir}/man1/ffplay.1*
271
272 %if %{with imlib2}
273 %files vhook-imlib2
274 %defattr(644,root,root,755)
275 %attr(755,root,root) %{_libdir}/vhook/imlib2.so
276 %endif
This page took 0.04447 seconds and 3 git commands to generate.