self-build-x264-vl.spec 7.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196
  1. %global snapshot_date 20111216
  2. %global snapshot_time 2245
  3. %global branch stable
  4. %global pkgname x264
  5. %global name self-build-%{pkgname}
  6. %global version 0.0.0
  7. %global release 18.%{snapshot_date}%{?_dist_release}
  8. #define sourceurl0 ftp://ftp.videolan.org/pub/videolan/x264/snapshots/%{pkgname}-snapshot-%{date}-%{time}.tar.bz2
  9. %define sourceurl0 http://www.videolan.org/pub/videolan/x264/snapshots/%{pkgname}-snapshot-%{snapshot_date}-%{snapshot_time}%{?branch:-%{branch}}.tar.bz2
  10. Summary: Package to automatically build %{pkgname} rpm package
  11. Summary(ja): %{pkgname} の rpm パッケージを自動作成するパッケージ
  12. Name: %{name}
  13. Version: %{version}
  14. Release: %{release}
  15. Source0: %{pkgname}-vl.spec
  16. Source1: %{pkgname}.desktop
  17. Source111: %{pkgname}-shared.patch
  18. Source112: %{pkgname}-nostrip.patch
  19. License: GPLv2+
  20. Group: Restricted Software
  21. Obsoletes: x264 < %{version}-%{release}
  22. Obsoletes: self-build-x264 < %{version}-%{release}
  23. Requires(post): self-build-setup >= 0.9.9
  24. # (build)requies of target package.
  25. Requires(post): yasm
  26. Requires(post): self-build-gpac
  27. BuildArch: noarch
  28. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  29. Packager: munepi
  30. %description
  31. x264 is a free library for encoding H264/AVC video streams, written from
  32. scratch.
  33. If you install this package, it automaticaly downloads source
  34. code ,compile it, and create rpm packages of %{pkgname}-%{version}.
  35. And the created rpm packages are automatically installed
  36. if installation is executed by apt-get command or synaptic
  37. package manager.
  38. [Note]
  39. This package requires many other packages to compile
  40. targetsoftware. So it consume more disk space than usual.
  41. Also installation takes logner time because of compilation.
  42. (This will take a few minutes to quarter or half of an hour,
  43. depends on building environment)
  44. [About self-build package]
  45. For some kind of software, distributing of binary package
  46. may viorate the patent or law. Therefore we chose self-build
  47. packge, create binary package on your machine, for such kind
  48. of softwares instead of distributing binary package.
  49. Please obey the national law when you use the created binary
  50. packages. And if you want to use the softwares using patented
  51. thechnology, it may be required to get a permission, make an
  52. agreement or purchas a license. Please consider it with your
  53. purpose or way of use and take appropriate action.
  54. %description -l ja
  55. x264 はスクラッチから書かれた H264/AVC ビデオストリームをエン
  56. コードするためのフリーなライブラリです.
  57. このパッケージをインストールすると、自動的にソースコードを
  58. ダウンロードしてコンパイルし、%{pkgname}-%{version} の rpm
  59. パッケージを作成します。
  60. また apt-get コマンドや synaptic パッケージマネージャから実行
  61. した場合は、作成された rpm パッケージのインストールも自動的に
  62. 行います。
  63. [注意]
  64. コンパイルに必要な多くの関連パッケージを要求するので通常より
  65. ディスクの領域を多く消費します。
  66. またインストール時にコンパイルを行うため、通常より時間がかか
  67. る場合があります。(環境にもよりますが数分から数十分程度)
  68. [self-build パッケージについて]
  69. ソフトウェアによってはバイナリパッケージの配布が特許や法律に
  70. 違反する可能性があるものがあります。その為、このような問題が
  71. 懸念されるソフトウェアについてはバイナリパッケージを直接配布
  72. せずに、ユーザの環境でバイナリを作成する self-build パッケー
  73. ジという方法を採っています。
  74. 作成されたバイナリパッケージの利用にあたっては、各ソフトウェ
  75. アのライセンス、および利用する国の各種法令に従ってください。
  76. また特許に関連するソフトウェアの場合、利用許諾や契約、ライ
  77. センスの購入などが必要となる場合がありますので、利用する目的
  78. や形態に応じて各自で判断し適切な対応を取ってください。
  79. %prep
  80. [ "%{version}-%{release}" != $(rpm -q --queryformat "%%{version}-%%{release}\n" --specfile %{SOURCE0} | tail -1) ] && exit 1
  81. %install
  82. %{__rm} -rf ${RPM_BUILD_ROOT}
  83. %{__install} -d ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  84. %{__install} -m 644 %{SOURCE0} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  85. %{__install} -m 644 %{SOURCE1} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  86. %{__install} -m 644 %{SOURCE111} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  87. %{__install} -m 644 %{SOURCE112} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  88. %clean
  89. %{__rm} -rf ${RPM_BUILD_ROOT}
  90. %posttrans
  91. /usr/lib/rpm/self-build-rpm.sh %{name} %{pkgname}-vl.spec "%{sourceurl0}" 19000
  92. /usr/lib/rpm/pre-allocate-rpm.sh %{pkgname}-%{version}-%{release} \
  93. %{pkgname}-devel-%{version}-%{release}
  94. %files
  95. %defattr(-,root,root)
  96. %{_datadir}/%{name}
  97. %changelog
  98. * Sat Dec 17 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-18.20111216
  99. - updated source snapshot 20111216 stable branch (ABI 0.119)
  100. * Sun Oct 16 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-17.20111013
  101. - updated source snapshot 20111013 stable branch (ABI 0.116)
  102. * Thu Sep 01 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-16.20110322
  103. - changed to depend on %%{version} for Obsoletes: x264
  104. - added BuildArch: noarch
  105. * Wed Mar 23 2011 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-15.20110322
  106. - updated source snapshot 20110322
  107. * Sat Jun 26 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-14.20100625
  108. - updated source snapshot 20100625
  109. * Sat Mar 20 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-13.20100216
  110. - renamed %%{Source0} to x264-vl.spec
  111. * Wed Feb 17 2010 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-12.20100216
  112. - updated source snapshot 20100216
  113. - applied to link x264 binary to the shared library from RPM Fusion development
  114. * Mon Sep 07 2009 Munehiro Yamamoto <munepi@vinelinux.org> 0.0.0-11.20090522
  115. - changed to download from http://www.videolan.org/pub/videolan/x264/snapshots in %%sourceurl0
  116. - check version between original spec and self-build spec in %%prep
  117. * Sat Jun 06 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-10.20090522
  118. - dropped BuildArch: noarch
  119. * Sat May 23 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-9.20090522
  120. - 20090522 snapshot
  121. - updated x264-vine.patch
  122. - added BuildArch: noarch
  123. - avoided to execute self-build-rpm.sh on RPM transaction
  124. - moved %%post actions to %%posttrans
  125. * Fri Mar 20 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-8.20090110
  126. - corrected release number in x264.spec
  127. * Wed Mar 18 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 0.0.0-7.20090110
  128. - enable asm on x86/x86_64 arch. (fix typo?)
  129. * Sun Mar 01 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-6.20090110
  130. - added PreReq: self-build-gpac
  131. * Sun Jan 25 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-5.20090110
  132. - dropped PreReq: nasm for x86
  133. - added PreReq: yasm for x86
  134. * Sun Jan 11 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-4.20090110
  135. - 20090110 snapshot
  136. * Sun Dec 14 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-3.20081001
  137. - fixed License: GPLv2+
  138. - added BuildRequires: gettext
  139. - source updated
  140. - fixed x264-rpm.patch (merged x264-rpm.patch from RPM Fusion)
  141. and added x264-vine.patch
  142. #- changed version from 0.0.0-1.20080225 to 0.0.0-20081111.1
  143. * Sun Nov 02 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-2.20080225vl1
  144. - spec in utf8
  145. * Sun May 18 2008 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 0.0.0-1.20080225
  146. - run pre-allocate-rpm.sh in %%post
  147. - set PreReq: self-build-setup >= 0.8
  148. - apply new versioning policy
  149. * Wed Feb 27 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 0.0.0-0.20080225vl1
  150. - initial build for Vine Linux 4.2
  151. ### end of file