self-build-mplayer-vl.spec 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426
  1. %define pkgname mplayer
  2. %define name self-build-%{pkgname}
  3. %define version 1.0
  4. %define extver rc3
  5. #% define release 4%{?extver:.%{extver}}%{?_dist_release}
  6. %define svndate 20100709
  7. %define release 40.%{svndate}%{?_dist_release}
  8. %define source0path MPlayer/releases/MPlayer-%{version}%{extver}.tar.bz2
  9. %define source1path MPlayer/skins/Blue-1.7.tar.bz2
  10. %define with_vaapi 1
  11. %define with_libvpx 1
  12. Summary: Package to automatically build %{pkgname} rpm package
  13. Summary(ja): %{pkgname} の rpm パッケージを自動作成するパッケージ
  14. Name: %{name}
  15. Version: %{version}
  16. Release: %{release}
  17. Source0: %{pkgname}-vl.spec
  18. Source1: %{pkgname}-snapshot-vine.sh
  19. #Source11: %{pkgname}-export-%{svndate}.tar.bz2
  20. #Source12: Blue-1.7.tar.bz2
  21. #Source102: %{pkgname}-config.patch
  22. Source102: %{pkgname}-config-20100709-vine.patch
  23. Source108: %{pkgname}-manlinks.patch
  24. Source114: %{pkgname}-nodvdcss.patch
  25. Source150: mplayer-20100709-fixed-vo_x11_create_vo_window.patch
  26. License: GPLv2+
  27. Group: Restricted Software
  28. Requires(post): self-build-setup >= 0.9.9
  29. Requires(post): subversion
  30. # (build)requies of target package.
  31. Requires(post): SDL-devel
  32. Requires(post): aalib-devel
  33. Requires(post): alsa-lib-devel
  34. Requires(post): cdparanoia-devel
  35. Requires(post): desktop-file-utils
  36. Requires(post): esound-devel
  37. Requires(post): enca-devel
  38. Requires(post): freetype2-devel
  39. Requires(post): fribidi-devel
  40. Requires(post): fontconfig-devel
  41. Requires(post): giflib-devel
  42. Requires(post): gtk2-devel
  43. Requires(post): mesa-libGL-devel
  44. Requires(post): libXinerama-devel
  45. Requires(post): libXScrnSaver-devel
  46. Requires(post): libXv-devel
  47. Requires(post): libXvMC-devel
  48. Requires(post): libXxf86dga-devel
  49. Requires(post): libXxf86vm-devel
  50. Requires(post): libpng-devel
  51. Requires(post): libjpeg-devel
  52. Requires(post): libdvdread
  53. Requires(post): libmpcdec-devel
  54. %{?with_vaapi:Requires(post):libva-devel}
  55. Requires(post): libvdpau-devel
  56. Requires(post): libvorbis-devel
  57. %{?with_libvpx:Requires(post): libvpx-devel >= 0.9.1}
  58. Requires(post): lzo-devel >= 2
  59. Requires(post): pulseaudio-lib-devel
  60. Requires(post): speex-devel >= 1.1
  61. Requires(post): twolame-devel
  62. Requires(post): xorg-x11-devel
  63. Requires(post): yasm
  64. Requires(post): zlib-devel
  65. Requires(post): self-build-mplayer-codecs
  66. Requires(post): self-build-libdvdcss
  67. Requires(post): self-build-libdvdnav
  68. Requires(post): self-build-faac
  69. Requires(post): self-build-faad2 >= 2.6
  70. Requires(post): self-build-lame
  71. Requires(post): self-build-libdca
  72. Requires(post): self-build-libmad
  73. Requires(post): self-build-x264 >= 0.0.0-9.20090522
  74. Requires(post): self-build-xvidcore >= 0.9.2
  75. Requires(post): self-build-libmpeg2
  76. Requires: TrueType-vlgothic
  77. Requires: mesa-libGL
  78. BuildArch: noarch
  79. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  80. Packager: munepi
  81. %description
  82. MPlayer can play most standard video formats out of the box and almost
  83. all others with the help of external codecs.
  84. MPlayer currently works best from the command line, but visual feedback
  85. for many functions is available from its onscreen status display (OSD),
  86. which is also used for displaying subtitles.
  87. MPlayer also has a GUI with skin support and several unofficial alternative
  88. graphical frontends are available.
  89. MEncoder is a command line video encoder for advanced users that can
  90. be built from the MPlayer source tree. Unofficial graphical frontends
  91. exist but arenot included.
  92. MPlayer supports most common formats, like DVDs, MPEG-1/2/4, etc, but
  93. support for some newer codecs are not yet inpmlemented.
  94. You should install mplayer-codecs package if you want to play videos
  95. using those new codecs.
  96. Additional function is automatically included if following
  97. packages are installed in advance.
  98. samba-libsmbclient-devel: SMB file system support
  99. [Note]
  100. This package requires many other packages to compile
  101. targetsoftware. So it consume more disk space than usual.
  102. Also installation takes logner time because of compilation.
  103. (This will take a few minutes to quarter or half of an hour,
  104. depends on building environment)
  105. [About self-build package]
  106. For some kind of software, distributing of binary package
  107. may viorate the patent or law. Therefore we chose self-build
  108. packge, create binary package on your machine, for such kind
  109. of softwares instead of distributing binary package.
  110. Please obey the national law when you use the created binary
  111. packages. And if you want to use the softwares using patented
  112. thechnology, it may be required to get a permission, make an
  113. agreement or purchas a license. Please consider it with your
  114. purpose or way of use and take appropriate action.
  115. %description -l ja
  116. MPlayer は一般的なフォーマットの動画ならそのままですぐ再生できます。
  117. またそれ以外のほとんど全てのフォーマットも外部 Codec を使用すること
  118. で生できます。
  119. 現在の MPlayer はコマンドラインから使うのが一番便利ですが、多くの操作
  120. は字幕と同様に、オンスクリーン・ディスプレイ (OSD) によりその結果が画
  121. 面上で確認できます。
  122. MPlayer には スキンを変更できる GUI も用意されていますし、また複数の
  123. 非公式なフロントエンドも利用できます。
  124. MEncoder は上級者向けのコマンドラインの動画用エンコーダーです。
  125. 非公式な GUI フロントエンドもありますが、このパッケージには含まれて
  126. いません。
  127. MPlayer は何もしなくても DVD や MPEG-1/2/4 のように一般的なフォーマット
  128. を再生できます。ただし一部の最新のフォーマットへの対応はまだ実装されて
  129. いないので、そのような動画を再生したい場合は mplayer-codecs パッケージ
  130. をインストールする必要があります。
  131. このパッケージより前に以下の関連パッケージをインストールして
  132. おくと、%{pkgname} が対応できる機能が自動的に追加されます。
  133. samba-libsmbclient-devel: SMB ファイルシステムのサポート
  134. [注意]
  135. コンパイルに必要な多くの関連パッケージを要求するので通常より
  136. ディスクの領域を多く消費します。
  137. またインストール時にコンパイルを行うため、通常より時間がかか
  138. る場合があります。(環境にもよりますが数分から数十分程度)
  139. [self-build パッケージについて]
  140. ソフトウェアによってはバイナリパッケージの配布が特許や法律に
  141. 違反する可能性があるものがあります。その為、このような問題が
  142. 懸念されるソフトウェアについてはバイナリパッケージを直接配布
  143. せずに、ユーザの環境でバイナリを作成する self-build パッケー
  144. ジという方法を採っています。
  145. 作成されたバイナリパッケージの利用にあたっては、各ソフトウェ
  146. アのライセンス、および利用する国の各種法令に従ってください。
  147. また特許に関連するソフトウェアの場合、利用許諾や契約、ライ
  148. センスの購入などが必要となる場合がありますので、利用する目的
  149. や形態に応じて各自で判断し適切な対応を取ってください。
  150. %prep
  151. [ "%{version}-%{release}" != $(rpm -q --queryformat "%%{version}-%%{release}\n" --specfile %{SOURCE0} | tail -1) ] && exit 1
  152. %install
  153. %{__rm} -rf ${RPM_BUILD_ROOT}
  154. %{__install} -d ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  155. %{__install} -m 644 %{SOURCE0} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  156. %{__install} -m 644 %{SOURCE1} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  157. #%{__install} -m 644 %{SOURCE11} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  158. #%{__install} -m 644 %{SOURCE12} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  159. %{__install} -m 644 %{SOURCE102} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  160. %{__install} -m 644 %{SOURCE108} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  161. %{__install} -m 644 %{SOURCE114} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  162. %{__install} -m 644 %{SOURCE150} ${RPM_BUILD_ROOT}/%{_datadir}/%{name}
  163. %clean
  164. %{__rm} -rf ${RPM_BUILD_ROOT}
  165. %posttrans
  166. ## svn checkout
  167. # set locale
  168. case $LANG in
  169. ja*)LOCALE=ja ;;
  170. *) LOCALE=C ;;
  171. esac
  172. GetSrc_C(){
  173. echo -n " "
  174. echo "Download source file with Subversion..."
  175. }
  176. GetSrc_ja(){
  177. echo -n " "
  178. echo "Subversion を用いてソースファイルをダウンロードしています..."
  179. }
  180. GetSrc_$LOCALE
  181. # svn checkout
  182. . /etc/self-build.conf
  183. (cd $TEMP_DIR
  184. su $BUILD_USER -c "/bin/bash %{_datadir}/%{name}/%{pkgname}-snapshot-vine.sh >/dev/null 2>&1 || exit 1"
  185. %__mv %{pkgname}-export-%{svndate}.tar.bz2 %{_datadir}/%{name}/ || exit 1
  186. )
  187. # /usr/lib/rpm/self-build-rpm.sh %{name} %{pkgname}-vl.spec \
  188. # http://www{,1,2,3,4,5,7,8}.mplayerhq.hu/%{source0path} \
  189. # http://www{,1,2,3,4,5,7,8}.mplayerhq.hu/%{source1path} \
  190. # 635000
  191. /usr/lib/rpm/self-build-rpm.sh %{name} %{pkgname}-vl.spec \
  192. http://www{,1,2,3,4,5,7,8}.mplayerhq.hu/%{source1path} \
  193. 635000
  194. %files
  195. %defattr(-,root,root)
  196. %{_datadir}/%{name}
  197. %changelog
  198. * Tue Feb 01 2011 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-40.20100709
  199. - added BuildRequires:
  200. - aalib-devel
  201. - enca-devel
  202. - lzo-devel
  203. - speex-devel
  204. * Sun Jul 25 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-39.20100709
  205. - updated fixed %{name}-config.patch
  206. - applied %{name}-config-20100709-vine.patch
  207. * Sat Jul 17 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-38.20100709
  208. - unpacked source archives
  209. * Sat Jul 10 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-37.20100709
  210. - updated source snapshot 20100709
  211. - renamed %%Source10 to mplayer-snapshot-vine.sh
  212. - added Requires(post): libva-devel, libvpx-devel >= 0.9.1
  213. - dropped vl4 support
  214. - updated %%description
  215. * Sat Jun 26 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-36.20100621
  216. - updated source snapshot 20100621
  217. - added Requires(post): libXinerama-devel
  218. - dropped vl4 support
  219. * Fri Apr 02 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-33.20100401
  220. - updated source snapshot 20100401
  221. * Thu Mar 18 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-31.20100317
  222. - updated source snapshot 20100317
  223. - renamed %%{Source0} to mplayer-vl.spec
  224. * Wed Feb 17 2010 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-30.20100216
  225. - updated source snapshot 20100216
  226. - dropped obsolete patches
  227. - added Requires(post): libvdpau-devel libXScrnSaver-devel
  228. * Sat Dec 26 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-28.20091031
  229. - update mplayer-config-20091215-vine.patch
  230. - update mplayer-20091215-x86_32-compile.patch
  231. * Sun Nov 01 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-27.20091031
  232. - source snapshot 20091031
  233. - updated mplayer-20091031-x86_32-compile.patch
  234. * Sun Oct 04 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-26.20091003
  235. - source snapshot 20091003
  236. * Sun Sep 13 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-25.20090905
  237. - added some if conditions for "vl6"
  238. * Sun Sep 06 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-24.20090905
  239. - source snapshot 20090905
  240. - added settings for vl6
  241. * Thu Aug 22 2009 Munehiro Yamamoto <munepi@vinelinux.org> 1.0-23.20090821
  242. - source snapshot 20090821
  243. - replaced BR: libungif-devel with BR: giflib-devel
  244. - mentioned VDPAU support in %%description
  245. * Thu Jul 23 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-22.20090722
  246. - source snapshot 20090722
  247. * Fri Jul 03 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-21.20090702
  248. - source snapshot 20090702
  249. - check version between original spec and self-build spec in %%prep
  250. * Fri Jun 12 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-20.20090611
  251. - source snapshot 20090611
  252. * Sun Jun 07 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-19.20090522
  253. - added Requires: TrueType-vlgothic
  254. * Sat May 23 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-18.20090522
  255. - source snapshot 20090522
  256. - build with x264 >= 0.0.0-9.20090522
  257. - updated mplayer-20090502-nodvdcss.patch
  258. - avoided to execute self-build-rpm.sh on RPM transaction
  259. - moved %%post actions to %%posttrans
  260. * Thu May 07 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-17.20090502
  261. - added PreReq: self-build-mplayer-codecs
  262. * Tue May 05 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-16.20090502
  263. - added BuildArch: noarch
  264. - source snapshot 20090502
  265. - updated mplayer-20090503-x86_32-compile.patch
  266. - updated mplayer-20090502-nodvdcss.patch
  267. * Thu Apr 09 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-15.20090327
  268. - included source archives:
  269. - mplayer-export-20090327.tar.bz2
  270. - Blue-1.7.tar.bz2
  271. - applied mplayer-config-vine.patch
  272. * Sat Mar 28 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-14.20090327
  273. - source snapshot 20090327
  274. - updated mplayer-20090327-x86_32-compile.patch
  275. - updated mplayer-20090325-nodvdcss.patch
  276. - dropped gmplayer-about-vine.patch
  277. * Sun Feb 08 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-10.20090206
  278. - source snapshot 20090206
  279. - dropped mplayer-man-zh_CN.patch
  280. - updated mplayer-20090206-nodvdcss.patch
  281. - changed to PreReq: self-build-faad2 from faad2-devel
  282. - added PreReq: self-build-libmad
  283. * Sun Feb 01 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-9.20090131
  284. - source snapshot 20090131
  285. - fixed %%files section
  286. * Thu Jan 29 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-8.20090122
  287. - fixed %%post: added rm -f "$pwd"/%{pkgname}-export-%{svndate}.tar.bz2
  288. * Sun Jan 25 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-7.20090122
  289. - source snapshot
  290. - update mplayer-nodvdcss.patch: mplayer-20090122-nodvdcss.patch
  291. - added PreReq:
  292. - faad2-devel
  293. - libmpcdec-devel
  294. - twolame-devel
  295. - yasm
  296. - self-build-libdvdcss
  297. - self-build-libdvdnav
  298. - self-build-faac
  299. - self-build-lame
  300. - self-build-libdca
  301. - self-build-x264 >= 0.0.0-4.20090110
  302. - self-build-xvidcore >= 0.9.2
  303. - move %%define source0Exists() from %%post section to header
  304. - fixed %%post section: clean up source archive
  305. * Sat Jan 10 2009 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-6.20090109
  306. - source snapshot
  307. - added --disable-faac-lavc --disable-mp3lame-lavc --disable-x264-lavc
  308. --disable-faad-internal in configure options
  309. - dropped gmplayer-add-flv-extension.patch
  310. * Sun Dec 14 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-5.20081001
  311. - source snapshot
  312. - fixed License
  313. - added some patches from RPM Fusion
  314. - updated gmplayer-about-vine.patch for 20081001 snapshot
  315. - added BuildRequires: libdvdread
  316. - added BuildRequires: self-build-libdvdcss self-build-libdvdnav
  317. - added --disable-dvdread-internal --enable-dvdread --enable-dvdnav
  318. in configure options
  319. #- applied mplayer-avoid-Warning_MVs_not_available.patch for VineSeed
  320. - added PreReq: subversion
  321. * Mon Nov 17 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-4.rc2
  322. - fixed License
  323. - added some devel packages to support OpenGL
  324. * Sun Nov 02 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-3.rc2
  325. - spec in utf8
  326. - fix sybolic link of subfont for vl5
  327. * Wed May 07 2008 Atsushi SHICHI <ats777@gmail.com> 1.0-2.rc2vl4
  328. - add "Source105: CVE-2008-1558.patch".
  329. * Fri May 02 2008 Atsushi SHICHI <ats777@gmail.com> 1.0-1.rc2vl4
  330. - build with new versioning policy.
  331. - add "Source200: gmplayer-about-vine.patch".
  332. - add "Source201: gmplayer-add-flv-extension.patch".
  333. - fix <BTS:VineLinux:603>.
  334. - add ">= 0.7-1vl4" to "PreReq: self-build-setup".
  335. - add mirror URLs to self-build-rpm.sh.
  336. * Sun Feb 17 2008 Munehiro Yamamoto <munepi@cg8.so-net.ne.jp> 1.0-0vl0.3rc2
  337. - add four official security patches (CVE-2008-0485, CVE-2008-0486,
  338. CVE-2008-0629, CVE-2008-0630)
  339. - add mplayer-1.0rc2-20080211-stream_cddb.patch
  340. * Tue Feb 12 2008 Kazutaka HARADA <Kazutaka HARADA> 1.0-0vl0.2rc2
  341. - change source download URL. <BTS:VineLinux:603>
  342. * Sun Jan 27 2008 Kazutaka HARADA <Kazutaka HARADA> 1.0-0vl0.1rc2
  343. - fix CONFDIR for make install in mplayer.spec. <BTS:wishes:33>
  344. * Fri Jan 18 2008 Kazutaka HARADA <Kazutaka HARADA> 1.0-0vl0.0rc2
  345. - initial build for Vine Linux.