self-build-x264-vl.spec 6.9 KB

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