PyQt4-vl.spec 8.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296
  1. %global python_ver %(%{__python} -c "import sys ; print sys.version[:3]")
  2. %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")
  3. %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")
  4. %global sip_ver %(sip -V 2>/dev/null | cut -d' ' -f1 | cut -d- -f1)
  5. # Qt4 version auto-detection -- inagaki
  6. %define qtver %(pkg-config --modversion --silence-errors Qt 2>/dev/null || echo 4.6.1)
  7. %define qt4qmake %{_libdir}/qt-%{qtver}/bin/qmake
  8. Summary: Python bindings for Qt4
  9. Name: PyQt4
  10. Version: 4.7.4
  11. Release: 1%{?_dist_release}
  12. # GPLv2 exceptions(see GPL_EXCEPTIONS*.txt)
  13. License: GPLv3 or GPLv2 with exceptions
  14. Group: Development/Languages
  15. URL: http://www.riverbankcomputing.com/software/pyqt/
  16. Source0: http://www.riverbankcomputing.com/static/Downloads/PyQt4/PyQt-x11-gpl-%{version}.tar.gz
  17. Patch1: PyQt-x11-gpl-4.4.4-64bit.patch
  18. # HACK! FIXME: ping upstream why this isn't working right. -- Rex
  19. Patch2: PyQt-x11-gpl-4.5.2-QT_SHARED.patch
  20. Patch4: PyQt-x11-gpl-4.5.1-pyuic_shebang.patch
  21. # Vine Patch
  22. Patch100: PyQt-x11-gpl-4.7.3-phononpath_vine.patch
  23. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  24. #BuildRequires: chrpath
  25. BuildRequires: dbus-devel dbus-python-devel
  26. BuildRequires: findutils
  27. BuildRequires: phonon-devel
  28. # beware of PyQt4/qscintilla bootstap issues
  29. #BuildRequires: qscintilla
  30. BuildRequires: qt4-devel >= 4.5.0
  31. BuildRequires: python-devel
  32. BuildRequires: sip-devel >= 4.9
  33. BuildRequires: libXext-devel
  34. Requires: sip >= %{sip_ver}
  35. Requires: dbus-python
  36. Requires: qt4 >= %{qtver}
  37. %description
  38. These are Python bindings for Qt4.
  39. %package devel
  40. Summary: Files needed to build other bindings based on Qt4
  41. Group: Development/Libraries
  42. Requires: %{name} = %{version}-%{release}
  43. Requires: qt4-devel >= %{qtver}
  44. Requires: sip-devel >= 4.9
  45. %description devel
  46. Files needed to build other bindings for C++ classes that inherit from any
  47. of the Qt4 classes (e.g. KDE or your own).
  48. %prep
  49. %setup -q -n PyQt-x11-gpl-%{version}
  50. %patch1 -p1 -b .64bit
  51. %patch2 -p1 -b .QT_SHARED
  52. %patch4 -p1
  53. %patch100 -p1 -b .phononpath_vine
  54. ## permissions
  55. # mark examples non-executable
  56. find examples/ -name "*.py" | xargs chmod a-x
  57. chmod a+rx pyuic/uic/pyuic.py
  58. %build
  59. unset QTDIR || : ; . /etc/profile.d/qt4.sh
  60. CFLAGS="${CFLAGS:-%optflags}" \
  61. CXXFLAGS="${CXXFLAGS:-%optflags} -I%{_includedir}/KDE" \
  62. %{__python} configure.py \
  63. --confirm-license \
  64. --qmake=%{qt4qmake} \
  65. --no-qsci-api \
  66. --verbose
  67. make %{?_smp_mflags}
  68. %install
  69. rm -rf $RPM_BUILD_ROOT
  70. make install DESTDIR=$RPM_BUILD_ROOT INSTALL_ROOT=$RPM_BUILD_ROOT
  71. # HACK: fix multilb conflict, http://bugzilla.redhat.com/509415
  72. rm -fv $RPM_BUILD_ROOT%{_bindir}/pyuic4
  73. mv $RPM_BUILD_ROOT%{python_sitearch}/PyQt4/uic/pyuic.py \
  74. $RPM_BUILD_ROOT%{_bindir}/pyuic4
  75. ln -s %{_bindir}/pyuic4 \
  76. $RPM_BUILD_ROOT%{python_sitearch}/PyQt4/uic/pyuic.py
  77. %clean
  78. rm -rf $RPM_BUILD_ROOT
  79. %files
  80. %defattr(-,root,root,-)
  81. %doc NEWS README
  82. %doc OPENSOURCE-NOTICE.TXT
  83. %doc LICENSE.GPL2 GPL_EXCEPTION*.TXT
  84. %doc LICENSE.GPL3
  85. %{python_sitearch}/PyQt4/
  86. %exclude %{python_sitearch}/PyQt4/uic/pyuic.py*
  87. # fixme? -> sitearch? -- Rex
  88. %{python_sitelib}/dbus/mainloop/qt.so
  89. %{_libdir}/qt-%{qtver}/plugins/designer/*
  90. %files devel
  91. %defattr(-,root,root,-)
  92. %doc doc/*
  93. %doc examples/
  94. %{_bindir}/pylupdate4
  95. %{_bindir}/pyrcc4
  96. %{_bindir}/pyuic4
  97. %{python_sitearch}/PyQt4/uic/pyuic.py*
  98. %{_datadir}/sip/PyQt4/
  99. #{_qt4_prefix}/qsci/api/python/PyQt4.api
  100. %changelog
  101. * Sun Jul 25 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.7.4-1
  102. - new upstream release
  103. - rebuilt with sip-4.10.5 and qt4-4.6.3
  104. * Sun May 09 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.7.3-1
  105. - new upstream release
  106. - updated Patch100
  107. * Fri Feb 05 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.7-2
  108. - updated Patch100 to build phonon module
  109. * Wed Feb 03 2010 Shu KONNO <owa@bg.wakwak.com> 4.7-1
  110. - new upstream release
  111. - rebuilt with python-2.6.4
  112. - dropt Patch100: PyQt-x11-gpl-4.5.4-vine_phonon.patch
  113. * Fri Oct 23 2009 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 4.6-2
  114. - now BuildRequires sip-devel >= 4.9 (was 4.8.2)
  115. * Thu Oct 22 2009 Shu KONNO <owa@bg.wakwak.com> 4.6-1
  116. - new upstream release
  117. - added BR: libXext-devel
  118. * Sat Aug 29 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 4.5.4-3
  119. - added Patch100 for building phonon modules
  120. * Tue Aug 18 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 4.5.4-2
  121. - Initial build for Vine
  122. * Tue Jul 28 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.4-1
  123. - PyQt4-4.5.4
  124. * Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.5.2-2
  125. - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
  126. * Thu Jul 16 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.2-1
  127. - PyQt4-4.5.2
  128. * Thu Jul 02 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.1-2
  129. - fix build with qt-4.5.2
  130. - PyQt4-devel multilib conflict (#509415)
  131. * Tue Jun 16 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5.1-1
  132. - PyQt-4.5.1
  133. * Fri Jun 05 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5-1
  134. - PyQt-4.5
  135. * Thu May 21 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5-0.2.20090520
  136. - fix generation of sip_ver
  137. * Thu May 21 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.5-0.1.20090520
  138. - PyQt-4.5-snapshot-20090520
  139. * Sun Apr 26 2009 Rex Dieter <rdieter@fedoraproject.org> - 4.4.4-6
  140. - rebuild for phonon bindings (#497680)
  141. * Wed Mar 05 2009 Rex Dieter <rdieter@fedorproject.org> - 4.4.4-5
  142. - move designer plugins to main/runtime (#487622)
  143. * Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.4.4-4
  144. - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
  145. * Fri Feb 13 2009 Than Ngo <than@redhat.com> - 4.4.4-3
  146. - rebuild against qt-4.5rc1
  147. * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 4.4.4-2
  148. - Rebuild for Python 2.6
  149. * Mon Nov 10 2008 Rex Dieter <rdieter@fedoraproject.org> 4.4.4-1
  150. - PyQt-4.4.4
  151. * Tue Aug 26 2008 Rex Dieter <rdieter@fedoraproject.org> 4.4.3-1
  152. - PyQt-4.4.3
  153. * Sat Jun 14 2008 Rex Dieter <rdieter@fedoraproject.org> 4.4.2-2
  154. - PyQt4 is built without QtWebKit support (#451490)
  155. * Wed May 21 2008 Rex Dieter <rdieter@fedoraproject.org> 4.4.2-1
  156. - PyQt-4.4.2
  157. * Wed May 14 2008 Rex Dieter <rdieter@fedoraproject.org> 4.4-1
  158. - PyQt-4.4
  159. - License: GPLv3 or GPLv2 with exceptions
  160. * Mon Feb 11 2008 Rex Dieter <rdieter@fedoraproject.org> 4.3.3-2
  161. - respin (gcc43)
  162. * Wed Dec 05 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.3.3-1
  163. - PyQt-4.3.3
  164. * Thu Nov 22 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.3.1-3
  165. - dbus support (#395741)
  166. * Mon Nov 12 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.3.1-1
  167. - PyQt-4.3.1
  168. * Thu Oct 04 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-8
  169. - drop ExcludeArch: ppc64 , qt4 bug is (hopefully) fixed.
  170. * Thu Oct 04 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-7
  171. - fix QtDesigner plugin install
  172. * Wed Oct 03 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-6
  173. - 64bit QtDesigner patch
  174. * Mon Aug 27 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-5
  175. - -devel: Requires: qt4-devel
  176. * Sun Aug 26 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-4
  177. - use %%python_sitearch
  178. - License: GPLv2
  179. * Thu Aug 02 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-3
  180. - fix python_sitelib typo (wrt chrpath call)
  181. - move %%_bindir stuff to -devel
  182. - mark %%doc examples non-executable
  183. - add shebang to %%_bindir/pyuic4
  184. * Tue Jul 17 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-2
  185. - remove rpath from QtDesigner.so
  186. - BR: qt4-devel > 4.3.0-8
  187. * Wed Apr 11 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.2-1
  188. - PyQt4-4.2
  189. * Wed Feb 28 2007 Rex Dieter <rdieter[AT]fedoraproject.org> 4.1.1-2
  190. - fix build against multilib'd qt4
  191. * Mon Dec 11 2006 Rex Dieter <rexdieter[AT]usres.sf.net> 4.1.1-1
  192. - PyQt4-4.1.1
  193. - BR: sip-devel >= 4.5.1
  194. * Mon Nov 06 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.1-1
  195. - PyQt4-4.1
  196. * Wed Oct 04 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0.1-4
  197. - don't own %%_datadir/sip (bug #206633)
  198. * Mon Aug 28 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0.1-3
  199. - BR: qt4-devel < 4.2
  200. * Sat Jul 29 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0.1-2
  201. - fix reference(s) to qmake(4)
  202. * Sun Jul 16 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0.1-1
  203. - PyQt-4.0.1
  204. * Mon Jun 12 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0-1
  205. - PyQt-4.0(final)
  206. - BR: sip-devel >= 4.4.4 (see bug #199430)
  207. * Fri May 12 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0-0.6.beta1
  208. - drop BR: qt4-MySQL qt4-ODBC qt4-PostgreSQL
  209. - drop usage of (undefined) %%sip_min
  210. * Fri Apr 28 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0-0.5.beta1
  211. - cleanup for Extras
  212. * Fri Apr 28 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0-0.4.beta1
  213. - 4.0beta1
  214. * Thu Apr 27 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0-0.3.20060421
  215. - respin for sip-4.4.3
  216. - use sip-abi, sip-abi-min
  217. * Mon Apr 24 2006 Rex Dieter <rexdieter[AT]users.sf.net> 4.0-0.2.20060421
  218. - 20060421 snapshot
  219. * Wed Apr 19 2006 Rex Dieter <rexdieter[AT]users.sf.net> 0.0-0.1.20060417
  220. - first try, using 20060417 snapshot