pygame-vl.spec 8.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242
  1. %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
  2. Name: pygame
  3. Version: 1.9.1
  4. Release: 1%{?_dist_release}
  5. Summary: Python modules for writing games
  6. Summary(ja): ゲームを書くための Python モジュール
  7. Group: Development/Languages
  8. License: LGPLv2+
  9. URL: http://www.pygame.org
  10. Source0: http://pygame.org/ftp/%{name}-%{version}release.tar.gz
  11. Patch0: %{name}-1.9.1-config.patch
  12. # porttime is part of libportmidi.so, there's no libporttime in Fedora
  13. Patch1: pygame-1.9.1-porttime.patch
  14. Patch2: pygame-1.9.1-no-test-install.patch
  15. # patch backported from upstream repository, V4L has been remove in linux-2.6.38
  16. # http://svn.seul.org/viewcvs/viewvc.cgi?view=rev&root=PyGame&revision=3077
  17. Patch3: pygame-remove-v4l.patch
  18. Patch4: MMX.diff
  19. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  20. BuildRequires: python-devel numpy
  21. BuildRequires: SDL_image-devel SDL_mixer-devel SDL_ttf-devel
  22. BuildRequires: SDL-devel
  23. BuildRequires: libpng-devel libjpeg-turbo-devel libX11-devel smpeg-devel
  24. #BuildRequires: portmidi-devel
  25. Requires: numpy
  26. %description
  27. Pygame is a set of Python modules designed for writing games. It is
  28. written on top of the excellent SDL library. This allows you to create
  29. fully featured games and multimedia programs in the python language.
  30. Pygame is highly portable and runs on nearly every platform and
  31. operating system.
  32. %package devel
  33. Summary: Files needed for developing programs which use pygame
  34. Summary(ja): pygame を使用するプログラム開発に必要なファイル
  35. Group: Development/Libraries
  36. Requires: %{name} = %{version}-%{release}
  37. Requires: SDL_ttf-devel SDL_mixer-devel
  38. Requires: python-devel
  39. %description devel
  40. This package contains headers required to build applications that use
  41. pygame.
  42. %prep
  43. %setup -qn %{name}-%{version}release
  44. %patch0 -p1
  45. %patch1 -p1
  46. %patch2 -p1
  47. %patch3 -p1
  48. %patch4 -p1
  49. # rpmlint fixes
  50. find examples/ -type f -print0 | xargs -0 chmod -x
  51. find docs/ -type f -print0 | xargs -0 chmod -x
  52. find src/ -type f -name '*.h' -print0 | xargs -0 chmod -x
  53. chmod -x README.txt WHATSNEW
  54. iconv -f iso8859-1 -t utf-8 WHATSNEW > WHATSNEW.conv && mv -f WHATSNEW.conv WHATSNEW
  55. iconv -f iso8859-1 -t utf-8 README.txt > README.txt.conv && mv -f README.txt.conv README.txt
  56. # These files must be provided by pygame-nonfree(-devel) packages on a
  57. # repository that does not have restrictions on providing non-free software
  58. rm -f src/ffmovie.[ch]
  59. %build
  60. CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
  61. %install
  62. rm -rf $RPM_BUILD_ROOT
  63. %{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
  64. # Fix permissions
  65. chmod 755 $RPM_BUILD_ROOT%{python_sitearch}/%{name}/*.so
  66. %check
  67. # base_test fails in mock, unable to find soundcard
  68. PYTHONPATH="$RPM_BUILD_ROOT%{python_sitearch}" %{__python} test/base_test.py || :
  69. PYTHONPATH="$RPM_BUILD_ROOT%{python_sitearch}" %{__python} test/image_test.py
  70. PYTHONPATH="$RPM_BUILD_ROOT%{python_sitearch}" %{__python} test/rect_test.py
  71. %clean
  72. rm -rf $RPM_BUILD_ROOT
  73. %files
  74. %defattr(-,root,root,-)
  75. %doc docs/ README.txt WHATSNEW
  76. #%dir %{python_sitearch}/%{name}
  77. %{python_sitearch}/%{name}*
  78. %files devel
  79. %defattr(-,root,root,-)
  80. %doc examples/
  81. %dir %{_includedir}/python*/%{name}
  82. %{_includedir}/python*/%{name}/*.h
  83. %changelog
  84. * Fri Jul 13 2012 Toshiharu Kudoh <toshi.kd2@gmail.com> - 1.9.1-1
  85. - initial build for VineSeed
  86. * Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-8
  87. - Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
  88. * Tue Dec 06 2011 Adam Jackson <ajax@redhat.com> - 1.9.1-7
  89. - Rebuild for new libpng
  90. * Thu Jun 23 2011 Jan Kaluza <jkaluza@redhat.com> - 1.9.1-6
  91. - Removed V4L support because V4L has been deprecated from the Linux
  92. kernel as of 2.6.38
  93. * Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-5
  94. - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
  95. * Mon Aug 16 2010 Jan Kaluza <jkaluza@redhat.com> - 1.9.1-4
  96. - fix #607753 - Do not install tests
  97. * Thu Aug 12 2010 Jan Kaluza <jkaluza@redhat.com> - 1.9.1-3
  98. - fix #585526 - add MIDI support
  99. * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1.9.1-2
  100. - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
  101. * Thu Oct 08 2009 Jon Ciesla <limb@jcomserv.net> - 1.9.1-1
  102. - New upstream release, BZ 526365.
  103. - Updated config_unix patch for 1.9.1.
  104. * Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.1-7
  105. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  106. * Fri Apr 17 2009 Jon Ciesla <limb@jcomserv.net> - 1.8.1-6
  107. - Dropped f2py deps, unneeded now that numpy is fixed: BZ 496277.
  108. * Fri Apr 17 2009 Jon Ciesla <limb@jcomserv.net> - 1.8.1-5
  109. - Add dep for numpy-f2py to fix broken games, BZ 496218.
  110. * Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8.1-4
  111. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  112. * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 1.8.1-3
  113. - Rebuild for Python 2.6
  114. * Wed Sep 17 2008 Robin Norwood <robin.norwood@gmail.com> 1.8.1-2
  115. - Bump release to trump F9 version.
  116. * Tue Aug 26 2008 Robin Norwood <robin.norwood@gmail.com> 1.8.1-1
  117. - Update to new upstream version.
  118. - rpmlint fixes
  119. * Mon Aug 25 2008 Robin Norwood <robin.norwood@gmail.com> 1.8.0-3
  120. - Rebase config patch for 1.8.0
  121. - Need to specify BR: SDL-devel
  122. * Mon Aug 25 2008 Robin Norwood <robin.norwood@gmail.com> 1.8.0-2
  123. - Change from requiring python-numeric to numpy
  124. - rhbz#457074
  125. * Thu May 22 2008 Christopher Stone <chris.stone@gmail.com> 1.8.0-1
  126. - Upstream sync
  127. - Remove Obsolets/Provides (been around since FC-4)
  128. - Remove no longer needed 64bit patch
  129. - Remove %%{version} macro from Patch0 definition
  130. - Add png, jpeg, and X11 libraries to BuildRequires
  131. - Simplify %%files section
  132. - Fix up some rpmlint warnings
  133. * Thu Feb 21 2008 Christopher Stone <chris.stone@gmail.com> 1.7.1-16
  134. - Add egginfo file to %%files
  135. - Update %%license
  136. - Fix permissions on .so files
  137. * Wed Feb 20 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1.7.1-15
  138. - Autorebuild for GCC 4.3
  139. * Tue May 15 2007 Christopher Stone <chris.stone@gmail.com> 1.7.1-14
  140. - Add one more bit to 64-bit patch
  141. * Sat May 12 2007 Christopher Stone <chris.stone@gmail.com> 1.7.1-13
  142. - Apply 64-bit patch for python 2.5 (bz #239899)
  143. - Some minor spec file cleanups
  144. * Mon Apr 23 2007 Christopher Stone <chris.stone@gmail.com> 1.7.1-12
  145. - Revert back to version 1.7.1-9
  146. * Mon Dec 11 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-11
  147. - Remove all Obsolete/Provides
  148. - Remove Requires on all devel packages
  149. * Sun Dec 10 2006 Christopher Stone <chris.stone@gmail.som> 1.7.1-10
  150. - Remove macosx examples
  151. - Move header files into main package
  152. - Move examples into examples subpackage
  153. - python(abi) = 0:2.5
  154. * Wed Sep 06 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-9
  155. - No longer %%ghost pyo files. Bug #205396
  156. * Sat Sep 02 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-8
  157. - FC6 Rebuild
  158. * Wed Jun 28 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-7.fc6.1
  159. - Rebuild bump
  160. * Wed May 03 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-7
  161. - Fix Obsolete/Provides of python-pygame-doc
  162. * Wed Apr 26 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-6
  163. - Bump release for new build on devel
  164. * Wed Apr 26 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-5
  165. - Add Obsolete/Provides tags for python-pygame-docs
  166. - Add Obsolete/Provides tags for python-pygame-devel to devel package
  167. - Hopefully this fixes Bugzilla bug #189991
  168. * Fri Apr 21 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-4
  169. - Add Requires to -devel package
  170. - Remove ffmovie.h from -devel package since it requires smpeg-devel
  171. * Fri Apr 21 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-3
  172. - Obsolete linva python-pygame package
  173. - Added Provides for python-pygame
  174. - Fix equal sign in devel requires
  175. * Thu Apr 20 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-2
  176. - Added a patch to clean up some warnings on 64 bit compiles
  177. * Tue Apr 18 2006 Christopher Stone <chris.stone@gmail.com> 1.7.1-1
  178. - Initial RPM release