[521] | 1 | %{!?python_sitearch:%global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} |
---|
[2725] | 2 | %global pyqt4_version 4.8 |
---|
[521] | 3 | |
---|
| 4 | %define ver 1.78 |
---|
| 5 | |
---|
[3001] | 6 | %define _qt4_version 4.7.2 |
---|
| 7 | %define _qt4_prefix %(pkg-config --variable prefix --silence-errors Qt 2>/dev/null || echo %{_libdir}/qt-%{_qt4_version}) |
---|
[1444] | 8 | %define _qt4_libdir %(pkg-config --variable libdir --silence-errors Qt 2>/dev/null || echo %{_qt4_prefix}/lib) |
---|
| 9 | %define _qt4_includedir %(pkg-config --variable headerdir --silence-errors Qt 2>/dev/null || echo %{_qt4_prefix}/include) |
---|
| 10 | %define _qt4_translationdir %(pkg-config --variable translationdir --silence-errors Qt 2>/dev/null || echo %{_datadir}/qt4/translations) |
---|
| 11 | |
---|
[3001] | 12 | %global qtdir %(pkg-config --variable prefix --silence-errors Qt 2>/dev/null || echo %{_libdir}/qt-%{qt4_version}) |
---|
[521] | 13 | %global qtinc %{qtdir}/include |
---|
| 14 | %global qtlib %{qtdir}/lib |
---|
| 15 | |
---|
| 16 | Summary: A Scintilla port to Qt |
---|
| 17 | Name: qscintilla |
---|
[2725] | 18 | Version: 2.4.6 |
---|
[3001] | 19 | Release: 2%{?_dist_release} |
---|
[2725] | 20 | |
---|
[521] | 21 | # matches up (pretty much) with qt4 |
---|
| 22 | License: GPLv3 or GPLv2 with exceptions |
---|
| 23 | Group: Development/Tools |
---|
| 24 | URL: http://www.riverbankcomputing.co.uk/qscintilla |
---|
[2725] | 25 | |
---|
[521] | 26 | Source: QScintilla-gpl-%{version}.tar.gz |
---|
| 27 | # TODO: upstream this |
---|
| 28 | Patch1: QScintilla-2-gpl-Qt4-incpath.patch |
---|
| 29 | |
---|
| 30 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
[3001] | 31 | BuildRequires: qt4-devel |
---|
[521] | 32 | BuildRequires: PyQt4-devel >= %{pyqt4_version} |
---|
[3001] | 33 | Requires: qt4 = %{_qt4_version} |
---|
[521] | 34 | |
---|
| 35 | %description |
---|
| 36 | QScintilla is a port of Scintilla to the Qt GUI toolkit. |
---|
| 37 | |
---|
| 38 | This version of QScintilla is based on Scintilla v%{ver}. |
---|
| 39 | |
---|
| 40 | %package designer |
---|
| 41 | Summary: QScintilla designer plugin |
---|
| 42 | Group: Development/Tools |
---|
| 43 | Requires: %{name} = %{version}-%{release} |
---|
| 44 | Requires: qt4-designer |
---|
| 45 | |
---|
| 46 | %description designer |
---|
| 47 | %{summary}. |
---|
| 48 | |
---|
| 49 | %package devel |
---|
| 50 | Summary: QScintilla Development Files |
---|
| 51 | Group: Development/Libraries |
---|
| 52 | Requires: %{name} = %{version} |
---|
[3001] | 53 | Requires: qt4-devel = %{_qt4_version} |
---|
[521] | 54 | |
---|
| 55 | %description devel |
---|
| 56 | This packages contains the libraries, include and other files |
---|
| 57 | you can use to develop applications with QScintilla. |
---|
| 58 | |
---|
| 59 | %package python |
---|
| 60 | Summary: QScintilla PyQt4 bindings |
---|
| 61 | Group: Development/Libraries |
---|
| 62 | Requires: %{name} = %{version}-%{release} |
---|
| 63 | Requires: PyQt4 >= %{pyqt4_version} |
---|
| 64 | |
---|
| 65 | %description python |
---|
| 66 | %{summary}. |
---|
| 67 | |
---|
| 68 | %package python-devel |
---|
| 69 | Summary: Development files for QScintilla PyQt4 bindings |
---|
| 70 | Group: Development/Libraries |
---|
| 71 | Requires: %{name}-python = %{version}-%{release} |
---|
| 72 | Requires: PyQt4-devel |
---|
| 73 | |
---|
| 74 | %description python-devel |
---|
| 75 | %{summary}. |
---|
| 76 | |
---|
| 77 | %prep |
---|
| 78 | %setup -q -n QScintilla-gpl-%{version} |
---|
| 79 | %patch1 -p1 -b .designer-incpath-qt4 |
---|
| 80 | |
---|
| 81 | # fix permissions on doc files |
---|
| 82 | find doc example-Qt4 -type f -exec chmod 0644 {} ';' |
---|
| 83 | find src include -type f -exec chmod 0644 {} ';' |
---|
| 84 | |
---|
| 85 | # fix line endings in license file(s) |
---|
| 86 | sed -i 's/\r//' LICENSE.GPL2 GPL_EXCEPTION_ADDENDUM.TXT |
---|
| 87 | |
---|
| 88 | %build |
---|
[1444] | 89 | export QTDIR=%{_qt4_prefix} |
---|
[521] | 90 | %ifarch x86_64 |
---|
| 91 | export QMAKESPEC=$QTDIR/mkspecs/linux-g++-64/ |
---|
| 92 | %else |
---|
| 93 | export QMAKESPEC=$QTDIR/mkspecs/linux-g++/ |
---|
| 94 | %endif |
---|
| 95 | |
---|
| 96 | pushd Qt4 |
---|
| 97 | $QTDIR/bin/qmake -o Makefile qscintilla.pro |
---|
| 98 | make %{?_smp_mflags} |
---|
| 99 | popd |
---|
| 100 | |
---|
| 101 | pushd designer-Qt4 |
---|
| 102 | $QTDIR/bin/qmake -o Makefile designer.pro |
---|
| 103 | make %{?_smp_mflags} |
---|
| 104 | popd |
---|
| 105 | |
---|
| 106 | pushd Python |
---|
| 107 | %{__python} configure.py \ |
---|
| 108 | -c -j 3 \ |
---|
| 109 | -n ../Qt4 \ |
---|
| 110 | -o ../Qt4 |
---|
| 111 | make %{?_smp_mflags} |
---|
| 112 | popd |
---|
| 113 | |
---|
| 114 | %install |
---|
| 115 | rm -rf $RPM_BUILD_ROOT |
---|
| 116 | |
---|
| 117 | make install INSTALL_ROOT=$RPM_BUILD_ROOT -C Qt4 |
---|
| 118 | make install INSTALL_ROOT=$RPM_BUILD_ROOT -C designer-Qt4 |
---|
| 119 | make install DESTDIR=$RPM_BUILD_ROOT -C Python |
---|
| 120 | |
---|
| 121 | |
---|
| 122 | %clean |
---|
| 123 | rm -rf $RPM_BUILD_ROOT |
---|
| 124 | |
---|
| 125 | %post -p /sbin/ldconfig |
---|
| 126 | |
---|
| 127 | %postun -p /sbin/ldconfig |
---|
| 128 | |
---|
| 129 | %files |
---|
| 130 | %defattr(-, root, root, 755) |
---|
[1444] | 131 | %doc NEWS README |
---|
| 132 | %doc LICENSE.GPL3 LICENSE.GPL2 GPL_EXCEPTION.TXT GPL_EXCEPTION_ADDENDUM.TXT |
---|
| 133 | %{_qt4_libdir}/libqscintilla2.so.* |
---|
| 134 | %{_qt4_prefix}/qsci/* |
---|
| 135 | %{_qt4_translationdir}/* |
---|
[521] | 136 | |
---|
| 137 | %files designer |
---|
| 138 | %defattr(-,root,root,-) |
---|
[1444] | 139 | %{_qt4_prefix}/plugins/designer/libqscintillaplugin.so |
---|
[521] | 140 | |
---|
| 141 | %files devel |
---|
[1444] | 142 | %defattr(-, root, root, -) |
---|
| 143 | %{_qt4_includedir}/* |
---|
| 144 | %{_qt4_libdir}/libqscintilla2.so |
---|
[521] | 145 | |
---|
| 146 | %files python |
---|
| 147 | %defattr(-,root,root,-) |
---|
| 148 | %{python_sitearch}/PyQt4/Qsci.so |
---|
| 149 | |
---|
| 150 | %files python-devel |
---|
| 151 | %defattr(-,root,root,-) |
---|
| 152 | %{_datadir}/sip/PyQt4/Qsci |
---|
| 153 | |
---|
| 154 | %changelog |
---|
[3001] | 155 | * Sun Mar 13 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.4.6-2 |
---|
| 156 | - rebuilt with qt-4.7.2 |
---|
| 157 | |
---|
[2725] | 158 | * Sun Feb 20 2011 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.4.6-1 |
---|
| 159 | - new upstream release |
---|
| 160 | - fix qt4_ver from 4.6.3 to 4.7.1 |
---|
| 161 | |
---|
[1670] | 162 | * Wed Aug 25 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.4.4-2 |
---|
| 163 | - rebuild with qt4-4.6.3 |
---|
| 164 | - fix qt4_ver from 4.6.1 to 4.6.3 |
---|
| 165 | - fix BuildRequires: qt4-devel = %{qt4_ver} (add version) |
---|
| 166 | |
---|
[1444] | 167 | * Sun Jul 25 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.4.4-1 |
---|
| 168 | - new upstream release |
---|
| 169 | - updated qt4 macros |
---|
| 170 | |
---|
[521] | 171 | * Sat Feb 06 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.4.2-1 |
---|
| 172 | - new upstream release |
---|
| 173 | |
---|
| 174 | * Fri Feb 05 2010 Shu KONNO <owa@bg.wakwak.com> 2.4-3 |
---|
| 175 | - rebuilt with qt4-4.6.1, python-2.6 |
---|
| 176 | - installed translation to %%{_datadir}/qt4/translations now |
---|
| 177 | |
---|
| 178 | * Thu Oct 22 2009 Shu KONNO <owa@bg.wakwak.com> 2.4-2 |
---|
| 179 | - updated macro pyqt4_version to 4.6 |
---|
| 180 | - fixed changelog year below (2008 -> 2009) |
---|
| 181 | |
---|
| 182 | * Sat Aug 29 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 2.4-1 |
---|
| 183 | - new upstream release |
---|
| 184 | - added designer, python and python-devel sub-packages |
---|
| 185 | |
---|
| 186 | * Sun Aug 17 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.7.1-1 |
---|
| 187 | - appiled new versioning policy |
---|
| 188 | |
---|
| 189 | * Fri Nov 30 2007 Shu KONNO <owa@bg.wakwak.com> 1.7.1-0vl2 |
---|
| 190 | - updated macro QMAKESPEC to linux-g++-64 (if x86_64) |
---|
| 191 | |
---|
| 192 | * Thu Sep 13 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.7.1-0vl1 |
---|
| 193 | - new upstream release (1.71) |
---|
| 194 | |
---|
| 195 | * Mon Jun 4 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.6-0vl1 |
---|
| 196 | - new upstream release (1.65) |
---|
| 197 | - changed Group to System Environment/Libraries |
---|
| 198 | |
---|
| 199 | * Sat Jan 15 2005 Satoshi MACHINO <machino@vinelinux.org> 1.4-0vl1 |
---|
| 200 | - initial built for VineLinux |
---|
| 201 | |
---|