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