1 | %define gpac_postinstall gpac_postinstall_sh=$(mktemp) && \ |
---|
2 | rpm -q --scripts self-build-gpac | \ |
---|
3 | /bin/sed -e 's|posttrans[[:blank:]].*|\#!/bin/bash|' > ${gpac_postinstall_sh} && \ |
---|
4 | /bin/bash ${gpac_postinstall_sh} && /bin/rm -f ${gpac_postinstall_sh} |
---|
5 | |
---|
6 | %define pkgname ffmpeg |
---|
7 | %define name self-build-%{pkgname} |
---|
8 | %define version 0.5.3 |
---|
9 | #% define svndate 20090202 |
---|
10 | %define release 2%{?svndate:.%svndate}%{?_dist_release} |
---|
11 | |
---|
12 | %define sourceurl0 http://ffmpeg.org/releases/%{pkgname}-%{version}.tar.bz2 |
---|
13 | |
---|
14 | Summary: Package to automatically build %{pkgname} rpm package |
---|
15 | Summary(ja): %{pkgname} の rpm パッケージを自動作成するパッケージ |
---|
16 | Name: %{name} |
---|
17 | Version: %{version} |
---|
18 | Release: %{release} |
---|
19 | Source0: %{pkgname}-vl5.spec |
---|
20 | #Source1: %{pkgname}-%{version}.tar.bz2 |
---|
21 | #Source1: %{pkgname}-%{version}.r%{svnrev}.tar.bz2 |
---|
22 | #Source2: %{pkgname}-snapshot.sh |
---|
23 | Source90: ffmpeg.1.gz |
---|
24 | Source91: ffplay.1.gz |
---|
25 | Source92: ffserver.1.gz |
---|
26 | Source100: %{pkgname}-textrel.patch |
---|
27 | Source110: ffmpeg-0.5-disable-texi2html.patch |
---|
28 | |
---|
29 | License: GPLv2+ |
---|
30 | Group: Restricted Software |
---|
31 | |
---|
32 | Requires(post): self-build-setup >= 0.8 |
---|
33 | #Requires(post): subversion |
---|
34 | |
---|
35 | # (build)requies of target package. |
---|
36 | Requires(post): bzip2-devel |
---|
37 | Requires(post): zlib-devel |
---|
38 | Requires(post): SDL-devel |
---|
39 | Requires(post): imlib2-devel |
---|
40 | #Requires(post): texi2html |
---|
41 | Requires(post): speex-devel |
---|
42 | Requires(post): libogg-devel |
---|
43 | Requires(post): libvorbis-devel |
---|
44 | #Requires(post): openjpeg-devel |
---|
45 | Requires(post): libtheora-devel |
---|
46 | Requires(post): gsm-devel |
---|
47 | Requires(post): libdc1394-devel |
---|
48 | Requires(post): libraw1394-devel |
---|
49 | %ifarch %{ix86} x86_64 |
---|
50 | Requires(post): yasm |
---|
51 | %endif |
---|
52 | Requires(post): self-build-xvidcore |
---|
53 | Requires(post): self-build-faac |
---|
54 | Requires(post): self-build-lame |
---|
55 | Requires(post): self-build-x264 |
---|
56 | Requires(post): self-build-libdca |
---|
57 | Requires(post): self-build-a52dec |
---|
58 | Requires(post): self-build-faad2 |
---|
59 | %{?_with_amr:Requires(post): amrnb-devel amrwb-devel} |
---|
60 | |
---|
61 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
62 | |
---|
63 | Packager: munepi |
---|
64 | |
---|
65 | %description |
---|
66 | FFMpeg is a complete and free Internet live audio and video |
---|
67 | broadcasting solution for Linux/Unix. It also includes a |
---|
68 | digital VCR. It can encode in real time in many formats |
---|
69 | including MPEG1 audio and video, MPEG4, h263, ac3, asf, avi, |
---|
70 | real, mjpeg, and flash. |
---|
71 | |
---|
72 | If you install this package, it automaticaly downloads source |
---|
73 | code ,compile it, and create rpm packages of %{pkgname}-%{version}. |
---|
74 | And the created rpm packages are automatically installed |
---|
75 | if installation is executed by apt-get command or synaptic |
---|
76 | package manager. |
---|
77 | |
---|
78 | [Note] |
---|
79 | This package requires many other packages to compile |
---|
80 | target software. So it consume more disk space than usual. |
---|
81 | Also installation takes longer time because of compilation. |
---|
82 | (This will take a few minutes to quarter or half of an hour, |
---|
83 | depends on building environment) |
---|
84 | |
---|
85 | [About self-build package] |
---|
86 | For some kind of software, distributing of binary package |
---|
87 | may viorate the patent or law. Therefore we chose self-build |
---|
88 | packge, create binary package on your machine, for such kind |
---|
89 | of softwares instead of distributing binary package. |
---|
90 | |
---|
91 | Please obey the national law when you use the created binary |
---|
92 | packages. And if you want to use the softwares using patented |
---|
93 | thechnology, it may be required to get a permission, make an |
---|
94 | agreement or purchas a license. Please consider it with your |
---|
95 | purpose or way of use and take appropriate action. |
---|
96 | |
---|
97 | %description -l ja |
---|
98 | FFMpeg は Linux/Unix に対する完全にフリーなインターネットライ |
---|
99 | ブオーティオ・ビデオブロードキャスティングソリューションです. |
---|
100 | またデジタル VCR を含んでいます.MPEG1 オーディオ・ビデオ, |
---|
101 | MPEG4, h263, ac3, asf, avi, real, mjpeg, flash を含む |
---|
102 | 多様なフォーマットをリアルタイムにエンコードすることができます. |
---|
103 | |
---|
104 | このパッケージをインストールすると、自動的にソースコードを |
---|
105 | ダウンロードしてコンパイルし、%{pkgname}-%{version} |
---|
106 | の rpm パッケージを作成します。 |
---|
107 | また apt-get コマンドや synaptic パッケージマネージャから実行 |
---|
108 | した場合は、作成された rpm パッケージのインストールも自動的に |
---|
109 | 行います。 |
---|
110 | |
---|
111 | [注意] |
---|
112 | コンパイルに必要な多くの関連パッケージを要求するので通常より |
---|
113 | ディスクの領域を多く消費します。 |
---|
114 | またインストール時にコンパイルを行うため、通常より時間がかか |
---|
115 | る場合があります。(環境にもよりますが数分から数十分程度) |
---|
116 | |
---|
117 | [self-build パッケージについて] |
---|
118 | ソフトウェアによってはバイナリパッケージの配布が特許や法律に |
---|
119 | 違反する可能性があるものがあります。その為、このような問題が |
---|
120 | 懸念されるソフトウェアについてはバイナリパッケージを直接配布 |
---|
121 | せずに、ユーザの環境でバイナリを作成する self-build パッケー |
---|
122 | ジという方法を採っています。 |
---|
123 | |
---|
124 | 作成されたバイナリパッケージの利用にあたっては、各ソフトウェ |
---|
125 | アのライセンス、および利用する国の各種法令に従ってください。 |
---|
126 | また特許に関連するソフトウェアの場合、利用許諾や契約、ライ |
---|
127 | センスの購入などが必要となる場合がありますので、利用する目的 |
---|
128 | や形態に応じて各自で判断し適切な対応を取ってください。 |
---|
129 | |
---|
130 | %prep |
---|
131 | [ "%{version}-%{release}" != $(rpm -q --queryformat "%%{version}-%%{release}\n" --specfile %{SOURCE0} | tail -1) ] && exit 1 |
---|
132 | |
---|
133 | %install |
---|
134 | %{__rm} -rf ${RPM_BUILD_ROOT} |
---|
135 | %{__install} -d ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
136 | %{__install} -m 644 %{SOURCE0} ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
137 | #%{__install} -p -m 644 %{SOURCE1} ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
138 | #%{__install} -m 644 %{SOURCE2} ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
139 | %{__install} -m 644 %{SOURCE90} %{SOURCE91} %{SOURCE92} \ |
---|
140 | ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
141 | %{__install} -m 644 %{SOURCE100} ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
142 | %{__install} -m 644 %{SOURCE110} ${RPM_BUILD_ROOT}/%{_datadir}/%{name} |
---|
143 | |
---|
144 | %clean |
---|
145 | %{__rm} -rf ${RPM_BUILD_ROOT} |
---|
146 | |
---|
147 | %posttrans |
---|
148 | /usr/lib/rpm/self-build-rpm.sh %{name} %{pkgname}-vl5.spec "%{sourceurl0}" 640000 |
---|
149 | /usr/lib/rpm/pre-allocate-rpm.sh %{pkgname}-%{version}-%{release} \ |
---|
150 | %{pkgname}-libs-%{version}-%{release} \ |
---|
151 | %{pkgname}-devel-%{version}-%{release} |
---|
152 | |
---|
153 | ## Rebuild gpac with ffmpeg-devel |
---|
154 | # set locale |
---|
155 | case $LANG in |
---|
156 | ja*)LOCALE=ja ;; |
---|
157 | *) LOCALE=C ;; |
---|
158 | esac |
---|
159 | |
---|
160 | Rebuild_gpac_C(){ |
---|
161 | echo -n " " |
---|
162 | echo "Rebuild gpac with ffmpeg-devel" |
---|
163 | } |
---|
164 | |
---|
165 | Rebuild_gpac_ja(){ |
---|
166 | echo -n " " |
---|
167 | echo "ffmpeg-devel で gpac をリビルドします。" |
---|
168 | } |
---|
169 | |
---|
170 | Rebuild_gpac_$LOCALE |
---|
171 | %{gpac_postinstall} |
---|
172 | |
---|
173 | |
---|
174 | %files |
---|
175 | %defattr(-,root,root) |
---|
176 | %{_datadir}/%{name} |
---|
177 | |
---|
178 | %changelog |
---|
179 | * Sat Oct 30 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.5.3-2 |
---|
180 | - collected Source0: tag |
---|
181 | |
---|
182 | * Sat Oct 30 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.5.3-1 |
---|
183 | - new upstream release |
---|
184 | |
---|
185 | * Sat Jul 17 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.5.2-2 |
---|
186 | - unpacked source archives |
---|
187 | |
---|
188 | * Thu Jun 03 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.5.2-1 |
---|
189 | - new upstream release |
---|
190 | |
---|
191 | * Sun Apr 18 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.5.1-1 |
---|
192 | - new upstream release |
---|
193 | |
---|
194 | * Sat Jun 06 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.5-6 |
---|
195 | - dropped BuildArch: noarch |
---|
196 | - added ffmpeg.1, ffplay.1, ffserver.1 |
---|
197 | |
---|
198 | * Tue May 26 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.5-5 |
---|
199 | - avoided to execute self-build-rpm.sh on RPM transaction |
---|
200 | - moved %%post actions to %%posttrans |
---|
201 | |
---|
202 | * Wed May 13 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.5-4 |
---|
203 | - added BuildArch: noarch |
---|
204 | - added ffmpeg-0.5-disable-texi2html.patch |
---|
205 | - dropped PreReq: texi2html |
---|
206 | |
---|
207 | * Thu Mar 12 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.5-3 |
---|
208 | - added %%{gpac_postinstall} in %%post |
---|
209 | |
---|
210 | * Wed Mar 11 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.5-2 |
---|
211 | - corrected release number |
---|
212 | |
---|
213 | * Wed Mar 11 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.5-1 |
---|
214 | - new upstream release |
---|
215 | - added PreReq: |
---|
216 | - speex-devel |
---|
217 | - bzip2-devel |
---|
218 | |
---|
219 | * Tue Feb 24 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-20090202.7 |
---|
220 | - change release to sync with ffmpeg |
---|
221 | |
---|
222 | * Sun Feb 08 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-20090202.6 |
---|
223 | - changed to PreReq: self-build-faad2 >= 2.0 from faad2-devel |
---|
224 | |
---|
225 | * Wed Feb 04 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-20090202.5 |
---|
226 | - 20090202 snapshot |
---|
227 | |
---|
228 | * Sun Jan 11 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-20090110.4 |
---|
229 | - 20090110 snapshot |
---|
230 | - dropped some patches |
---|
231 | |
---|
232 | * Sun Dec 14 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-15488.1 |
---|
233 | - source updated (r15488) |
---|
234 | - fixed License: GPLv2+ |
---|
235 | - added BuildRequires: gsm-devel libdc1394-devel libraw1394-devel |
---|
236 | - added BuildRequires: yasm (only %%ix86) |
---|
237 | - applied ffmpeg-cpu.patch (merged from RPM Fusion) |
---|
238 | |
---|
239 | * Sun Nov 02 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-11662.3vl4 |
---|
240 | - spec in utf8 |
---|
241 | |
---|
242 | * Tue May 20 2008 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.4.9-11662.2vl4 |
---|
243 | - run pre-allocate-rpm.sh in %%post |
---|
244 | - set PreReq: self-build-setup >= 0.8 |
---|
245 | - change release number |
---|
246 | |
---|
247 | * Wed Apr 16 2008 Atsushi SHICHI <ats777@gmail.com> 0.4.9-11662.1vl4 |
---|
248 | - add "Source1: %{pkgname}-%{version}.r%{svnrev}.tar.gz", |
---|
249 | include Source1 in the binary package. |
---|
250 | - drop "Source100: ffmpeg-vine.patch". |
---|
251 | - drop "PreReq: subversion". |
---|
252 | |
---|
253 | * Mon Apr 7 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-0.20080128.1vl4 |
---|
254 | - build with new versioning policy |
---|
255 | - change to use svn export from svn checkout on post install |
---|
256 | - fix ffmpeg-vine.patch for libswscale/swscale.c.rej |
---|
257 | |
---|
258 | * Thu Mar 13 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-0.20080128vl2 |
---|
259 | - For all pre-required package that is provied by self-build, |
---|
260 | changed to its self-build package |
---|
261 | |
---|
262 | * Sun Mar 9 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.4.9-0.20080128vl1 |
---|
263 | - initial build for Vine Linux 4.2 |
---|
264 | - snapshot 2008/01/28 + some Rev.11662 2008/01/29 |
---|
265 | |
---|
266 | ### end of file |
---|