]>
Commit | Line | Data |
---|---|---|
00900554 | 1 | # |
a1d9536a | 2 | # Conditional build: |
7b5e04bd JP |
3 | %bcond_without gtk # without GTK GUI |
4 | %bcond_without qt # without Qt GUI | |
00900554 | 5 | %bcond_with verchange # changes client version identification to 2.42 |
45cd44dc | 6 | |
c72d551a JP |
7 | %define qtver 5.2 |
8 | ||
0f16bf9a | 9 | Summary: A versatile and multi-platform BitTorrent client |
f2dfe381 | 10 | Summary(hu.UTF-8): Egy sokoldalú és multiplatformos BitTorrent kliens |
bb59eb4f | 11 | Summary(pl.UTF-8): Wszechstronny i wieloplatformowy klient BitTorrenta |
905dacdd | 12 | Name: transmission |
c72d551a | 13 | Version: 3.00 |
35de15cb | 14 | Release: 2 |
0f16bf9a PZ |
15 | License: MIT |
16 | Group: Applications/Communications | |
f9a02be3 | 17 | Source0: https://github.com/transmission/transmission-releases/raw/master/%{name}-%{version}.tar.xz |
c72d551a | 18 | # Source0-md5: a23a32672b83c89b9b61e90408f53d98 |
9232dd57 PG |
19 | Source1: %{name}.sysconfig |
20 | Source2: %{name}.init | |
147f3fba | 21 | Patch0: %{name}-ckb_po.patch |
07b38397 | 22 | Patch2: %{name}-version.patch |
ec12ede2 | 23 | URL: http://transmissionbt.com/ |
e9d3e015 | 24 | BuildRequires: autoconf |
39ef82b2 | 25 | BuildRequires: automake >= 1:1.9 |
071083d3 | 26 | BuildRequires: curl-devel >= 7.16.3 |
9bafbf8d | 27 | BuildRequires: gettext-tools |
7b5e04bd | 28 | %if %{with gtk} |
d4984600 | 29 | BuildRequires: glib2-devel >= 1:2.32.0 |
5ea5fb34 | 30 | BuildRequires: gtk+3-devel >= 3.4.0 |
7b5e04bd | 31 | %endif |
0f16bf9a | 32 | BuildRequires: intltool >= 0.35.5 |
c3bb290c | 33 | BuildRequires: libevent-devel >= 2.0.10 |
c72d551a | 34 | BuildRequires: libnatpmp-devel |
f237c99d | 35 | BuildRequires: libstdc++-devel |
e9d3e015 | 36 | BuildRequires: libtool |
4c544984 | 37 | BuildRequires: lsb-release |
c72d551a | 38 | BuildRequires: miniupnpc-devel >= 1.7 |
07b38397 | 39 | BuildRequires: openssl-devel >= 0.9.7 |
0f16bf9a | 40 | BuildRequires: pkgconfig |
4c544984 | 41 | BuildRequires: rpmbuild(macros) >= 1.357 |
c80b5c00 | 42 | BuildRequires: systemd-devel |
05606945 | 43 | BuildRequires: tar >= 1:1.22 |
d8e696e8 | 44 | BuildRequires: util-linux |
4c544984 | 45 | BuildRequires: which |
071083d3 | 46 | BuildRequires: xfsprogs-devel |
05606945 | 47 | BuildRequires: xz |
07b38397 | 48 | BuildRequires: zlib-devel >= 1.2.3 |
7b5e04bd JP |
49 | %if %{with qt} |
50 | BuildRequires: Qt5Core-devel >= %{qtver} | |
51 | BuildRequires: Qt5DBus-devel >= %{qtver} | |
52 | BuildRequires: Qt5Gui-devel >= %{qtver} | |
53 | BuildRequires: Qt5Network-devel >= %{qtver} | |
54 | BuildRequires: Qt5Widgets-devel >= %{qtver} | |
55 | BuildRequires: qt5-build >= %{qtver} | |
56 | BuildRequires: qt5-qmake >= %{qtver} | |
57 | %endif | |
b4dc7e64 | 58 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
0f16bf9a | 59 | |
c6dfa0bb | 60 | %define _appdir %{_datadir}/%{name}/web |
61 | ||
0f16bf9a PZ |
62 | %description |
63 | Transmission has been built from the ground up to be a lightweight, | |
64 | yet powerful BitTorrent client. Its simple, intuitive interface is | |
65 | designed to integrate tightly with whatever computing environment you | |
66 | choose to use. Transmission strikes a balance between providing useful | |
67 | functionality without feature bloat. | |
68 | ||
f2dfe381 | 69 | %description -l hu.UTF-8 |
d8e696e8 | 70 | Transmission egy könnyűsúlyú, de mégis egy erőteljes BitTorrent |
71 | kliens. Egyszerű, intuitív felülete szorosan illeszkedik bármilyen | |
f2dfe381 ZU |
72 | számítógépes környezetbe, amit csak választasz. A Transmission célja |
73 | megtalálni a használható funkcionalitást lehetőségek áradata nélkül. | |
74 | ||
bb59eb4f JB |
75 | %description -l pl.UTF-8 |
76 | Transmission został stworzony od podstaw, aby być lekkim lecz mającym | |
77 | duże możliwości klientem BitTorrenta. Jego prosty, intuicyjny | |
78 | interfejs jest zaprojektowany spójnie z dowolnym środowiskiem wybranym | |
79 | przez użytkownika. Transmission stawia na równowagę zapewnienia | |
80 | przydatnej funkcjonalności bez nadmiaru opcji. | |
81 | ||
35de15cb JP |
82 | %package cli |
83 | Summary: Command line implementation for BitTorrent client | |
84 | Summary(pl.UTF-8): Implementacja w wierszu poleceń dla klienta BitTorrenta | |
85 | Group: Applications/Networking | |
86 | Requires: %{name}-common = %{version}-%{release} | |
87 | Requires: curl-libs >= 7.16.3 | |
88 | Requires: libevent >= 2.0.10 | |
89 | Requires: miniupnpc >= 1.7 | |
90 | Requires: openssl >= 0.9.7 | |
91 | Requires: zlib >= 1.2.3 | |
92 | ||
93 | %description cli | |
94 | Transmission has been built from the ground up to be a lightweight, | |
95 | yet powerful BitTorrent client. Its simple, intuitive interface is | |
96 | designed to integrate tightly with whatever computing environment you | |
97 | choose to use. Transmission strikes a balance between providing useful | |
98 | functionality without feature bloat. | |
99 | ||
100 | Command line implementation for BitTorrent client. | |
101 | ||
102 | %description cli -l hu.UTF-8 | |
103 | Transmission egy könnyűsúlyú, de mégis egy erőteljes BitTorrent | |
104 | kliens. Egyszerű, intuitív felülete szorosan illeszkedik bármilyen | |
105 | számítógépes környezetbe, amit csak választasz. A Transmission célja | |
106 | megtalálni a használható funkcionalitást lehetőségek áradata nélkül. | |
107 | ||
108 | %description cli -l pl.UTF-8 | |
109 | Transmission został stworzony od podstaw, aby być lekkim lecz mającym | |
110 | duże możliwości klientem BitTorrenta. Jego prosty, intuicyjny | |
111 | interfejs jest zaprojektowany spójnie z dowolnym środowiskiem wybranym | |
112 | przez użytkownika. Transmission stawia na równowagę zapewnienia | |
113 | przydatnej funkcjonalności bez nadmiaru opcji. | |
114 | ||
115 | Implementacja w wierszu poleceń dla klienta BitTorrenta. | |
116 | ||
117 | %package common | |
118 | Summary: Common files for Transmission BitTorrent client | |
119 | Summary(pl.UTF-8): Pliki wspólne dla klienta BitTorrenta Transmission | |
120 | Group: Applications/Networking | |
121 | %{?noarchpackage} | |
122 | ||
123 | %description common | |
124 | Common files for Transmission BitTorrent client. | |
125 | ||
126 | %description common -l pl.UTF-8 | |
127 | Pliki wspólne dla klienta BitTorrenta Transmission. | |
128 | ||
129 | %package daemon | |
00900554 JB |
130 | Summary: Daemon package for BitTorrent client |
131 | Summary(pl.UTF-8): Pakiet demona dla klienta BitTorrenta | |
4c544984 | 132 | Group: Networking/Daemons |
35de15cb JP |
133 | Requires: %{name}-common = %{version}-%{release} |
134 | Requires: curl-libs >= 7.16.3 | |
135 | Requires: libevent >= 2.0.10 | |
136 | Requires: miniupnpc >= 1.7 | |
137 | Requires: openssl >= 0.9.7 | |
138 | Requires: zlib >= 1.2.3 | |
139 | Obsoletes: Transmission <= 1.05 | |
140 | Obsoletes: transmission < 3.00-2 | |
141 | Obsoletes: transmission-init < 3.00-2 | |
142 | ||
143 | %description daemon | |
144 | Transmission has been built from the ground up to be a lightweight, | |
145 | yet powerful BitTorrent client. Its simple, intuitive interface is | |
146 | designed to integrate tightly with whatever computing environment you | |
147 | choose to use. Transmission strikes a balance between providing useful | |
148 | functionality without feature bloat. | |
9232dd57 | 149 | |
00900554 JB |
150 | Daemon package for BitTorrent client. |
151 | ||
35de15cb JP |
152 | %description daemon -l hu.UTF-8 |
153 | Transmission egy könnyűsúlyú, de mégis egy erőteljes BitTorrent | |
154 | kliens. Egyszerű, intuitív felülete szorosan illeszkedik bármilyen | |
155 | számítógépes környezetbe, amit csak választasz. A Transmission célja | |
156 | megtalálni a használható funkcionalitást lehetőségek áradata nélkül. | |
157 | ||
158 | %description daemon -l pl.UTF-8 | |
159 | Transmission został stworzony od podstaw, aby być lekkim lecz mającym | |
160 | duże możliwości klientem BitTorrenta. Jego prosty, intuicyjny | |
161 | interfejs jest zaprojektowany spójnie z dowolnym środowiskiem wybranym | |
162 | przez użytkownika. Transmission stawia na równowagę zapewnienia | |
163 | przydatnej funkcjonalności bez nadmiaru opcji. | |
164 | ||
00900554 | 165 | Pakiet demona dla klienta BitTorrenta. |
9232dd57 | 166 | |
f237c99d KK |
167 | %package gui |
168 | Summary: A versatile and multi-platform BitTorrent client | |
169 | Summary(pl.UTF-8): Wszechstronny i wieloplatformowy klient BitTorrenta | |
4c544984 | 170 | Group: X11/Applications/Networking |
a29d91d7 | 171 | Requires(post,postun): gtk-update-icon-cache |
4c544984 | 172 | Requires(post,postun): hicolor-icon-theme |
35de15cb JP |
173 | Requires: %{name}-common = %{version}-%{release} |
174 | Requires: curl-libs >= 7.16.3 | |
d4984600 | 175 | Requires: glib2 >= 1:2.32.0 |
c72d551a JP |
176 | Requires: gtk+3 >= 3.4.0 |
177 | Requires: libcanberra-gtk3 | |
35de15cb JP |
178 | Requires: libevent >= 2.0.10 |
179 | Requires: miniupnpc >= 1.7 | |
180 | Requires: openssl >= 0.9.7 | |
181 | Requires: zlib >= 1.2.3 | |
f237c99d KK |
182 | |
183 | %description gui | |
184 | Transmission has been built from the ground up to be a lightweight, | |
185 | yet powerful BitTorrent client. Its simple, intuitive interface is | |
186 | designed to integrate tightly with whatever computing environment you | |
187 | choose to use. Transmission strikes a balance between providing useful | |
188 | functionality without feature bloat. | |
189 | ||
190 | %description gui -l hu.UTF-8 | |
191 | Transmission egy könnyűsúlyú de mégis egy erőteljes BitTorrent kliens. | |
192 | Egyszerű, intuitív felülete szorosan illeszkedik bármilyen | |
193 | számítógépes környezetbe, amit csak választasz. A Transmission célja | |
194 | megtalálni a használható funkcionalitást lehetőségek áradata nélkül. | |
195 | ||
196 | %description gui -l pl.UTF-8 | |
197 | Transmission został stworzony od podstaw, aby być lekkim lecz mającym | |
198 | duże możliwości klientem BitTorrenta. Jego prosty, intuicyjny | |
199 | interfejs jest zaprojektowany spójnie z dowolnym środowiskiem wybranym | |
200 | przez użytkownika. Transmission stawia na równowagę zapewnienia | |
201 | przydatnej funkcjonalności bez nadmiaru opcji. | |
202 | ||
820ff2df | 203 | %package gui-qt |
00900554 JB |
204 | Summary: A GUI to Transmission based on Qt 5 |
205 | Summary(pl.UTF-8): Graficzny interfejs do Transmission oparty na Qt 5 | |
4c544984 | 206 | Group: X11/Applications/Networking |
35de15cb | 207 | Requires: %{name}-common = %{version}-%{release} |
c72d551a JP |
208 | Requires: Qt5Core >= %{qtver} |
209 | Requires: Qt5DBus >= %{qtver} | |
210 | Requires: Qt5Gui >= %{qtver} | |
211 | Requires: Qt5Network >= %{qtver} | |
212 | Requires: Qt5Widgets >= %{qtver} | |
35de15cb | 213 | Requires: curl-libs >= 7.16.3 |
c72d551a | 214 | Requires: libcanberra-gtk3 |
35de15cb JP |
215 | Requires: libevent >= 2.0.10 |
216 | Requires: miniupnpc >= 1.7 | |
217 | Requires: openssl >= 0.9.7 | |
218 | Requires: zlib >= 1.2.3 | |
820ff2df ZU |
219 | |
220 | %description gui-qt | |
00900554 JB |
221 | A GUI to Transmission based on Qt 5. |
222 | ||
223 | %description gui-qt -l pl.UTF-8 | |
224 | Graficzny interfejs do Transmission oparty na Qt 5. | |
820ff2df | 225 | |
35de15cb JP |
226 | %package utils |
227 | Summary: Utilities for Transmission BitTorrent client | |
228 | Summary(pl.UTF-8): Narzędzia dla klienta BitTorrenta Transmission | |
229 | Group: Applications/Networking | |
230 | ||
231 | %description utils | |
232 | Utilities for Transmission BitTorrent client. | |
233 | ||
234 | %description utils -l pl.UTF-8 | |
235 | Narzędzia dla klienta BitTorrenta Transmission. | |
236 | ||
0f16bf9a | 237 | %prep |
8f94c0ac | 238 | %setup -q |
147f3fba | 239 | %patch0 -p1 |
45cd44dc | 240 | %if %{with verchange} |
07b38397 | 241 | %patch2 -p1 |
45cd44dc KK |
242 | ./update-version-h.sh |
243 | %endif | |
244 | ||
ec12ede2 | 245 | %{__rm} po/ckb.po |
5a14d6ed | 246 | %{__sed} -i 's/\(^CONFIG.*\)\( debug\)/\1/' qt/qtr.pro |
0f16bf9a PZ |
247 | |
248 | %build | |
39ef82b2 | 249 | %configure \ |
7b5e04bd | 250 | %{__with_without gtk} \ |
07b38397 | 251 | --disable-silent-rules \ |
c72d551a JP |
252 | --enable-cli \ |
253 | --enable-external-natpmp | |
0f16bf9a PZ |
254 | %{__make} |
255 | ||
7b5e04bd | 256 | %if %{with qt} |
820ff2df | 257 | cd qt |
b806da71 | 258 | qmake-qt5 |
820ff2df | 259 | %{__make} |
2b837bd5 | 260 | cd - |
7b5e04bd | 261 | %endif |
820ff2df | 262 | |
0f16bf9a PZ |
263 | %install |
264 | rm -rf $RPM_BUILD_ROOT | |
4c544984 | 265 | install -d $RPM_BUILD_ROOT/etc/{sysconfig,rc.d/init.d} \ |
266 | $RPM_BUILD_ROOT%{_sysconfdir}/%{name} \ | |
9232dd57 | 267 | $RPM_BUILD_ROOT/var/lib/%{name} |
0f16bf9a PZ |
268 | |
269 | %{__make} install \ | |
270 | DESTDIR=$RPM_BUILD_ROOT | |
271 | ||
9232dd57 | 272 | install %{SOURCE1} $RPM_BUILD_ROOT/etc/sysconfig/%{name} |
61330340 | 273 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name} |
9232dd57 | 274 | |
7b5e04bd | 275 | %if %{with qt} |
67a32c48 KK |
276 | install qt/transmission-qt $RPM_BUILD_ROOT%{_bindir} |
277 | install qt/transmission-qt.desktop $RPM_BUILD_ROOT%{_desktopdir} | |
278 | install gtk/transmission.png $RPM_BUILD_ROOT%{_pixmapsdir}/transmission-qt.png | |
7b5e04bd JP |
279 | %endif |
280 | %if %{with gtk} | |
c72d551a | 281 | %{__rm} -r $RPM_BUILD_ROOT%{_localedir}/jbo |
65730317 ZU |
282 | |
283 | %find_lang %{name} --all-name --with-gnome | |
7b5e04bd | 284 | %endif |
ec12ede2 | 285 | |
286 | # copy of GPLv2 not needed | |
39ef82b2 | 287 | %{__rm} $RPM_BUILD_ROOT%{_appdir}/LICENSE |
ec12ede2 | 288 | |
0f16bf9a PZ |
289 | %clean |
290 | rm -rf $RPM_BUILD_ROOT | |
291 | ||
35de15cb | 292 | %post daemon |
9232dd57 PG |
293 | /sbin/chkconfig --add transmission |
294 | %service transmission restart | |
295 | ||
35de15cb | 296 | %preun daemon |
9232dd57 PG |
297 | if [ "$1" = "0" ]; then |
298 | %service transmission stop | |
299 | /sbin/chkconfig --del transmission | |
300 | fi | |
301 | ||
f237c99d | 302 | %post gui |
0f16bf9a | 303 | %update_desktop_database_post |
e65cafbb | 304 | %update_icon_cache hicolor |
0f16bf9a | 305 | |
f237c99d | 306 | %postun gui |
0f16bf9a | 307 | %update_desktop_database_postun |
e65cafbb | 308 | %update_icon_cache hicolor |
0f16bf9a | 309 | |
35de15cb | 310 | %files cli |
0f16bf9a | 311 | %defattr(644,root,root,755) |
fccbf9d7 | 312 | %attr(755,root,root) %{_bindir}/transmission-cli |
fccbf9d7 | 313 | %{_mandir}/man1/transmission-cli.1* |
35de15cb JP |
314 | |
315 | %files common | |
316 | %defattr(644,root,root,755) | |
317 | %doc AUTHORS NEWS.md README.md | |
147f3fba | 318 | %dir %{_datadir}/%{name} |
c4a49d1e | 319 | %dir %{_appdir} |
c6dfa0bb | 320 | %{_appdir}/images |
321 | %{_appdir}/javascript | |
39ef82b2 | 322 | %{_appdir}/style |
c6dfa0bb | 323 | %{_appdir}/index.html |
f237c99d | 324 | |
35de15cb | 325 | %files daemon |
9232dd57 | 326 | %defattr(644,root,root,755) |
4c544984 | 327 | %attr(751,root,daemon) %dir %{_sysconfdir}/%{name} |
9232dd57 | 328 | %attr(640,root,daemon) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/%{name} |
61330340 | 329 | %attr(754,root,root) /etc/rc.d/init.d/%{name} |
35de15cb JP |
330 | %attr(755,root,root) %{_bindir}/transmission-daemon |
331 | %{_mandir}/man1/transmission-daemon.1* | |
9232dd57 PG |
332 | %attr(750,daemon,root) %dir /var/lib/%{name} |
333 | ||
7b5e04bd | 334 | %if %{with gtk} |
b911b3bd | 335 | %files gui -f %{name}.lang |
c1ca1d17 | 336 | %defattr(644,root,root,755) |
fccbf9d7 CM |
337 | %attr(755,root,root) %{_bindir}/transmission-gtk |
338 | %{_mandir}/man1/transmission-gtk.1* | |
339 | %{_desktopdir}/transmission-gtk.desktop | |
f237c99d | 340 | %{_pixmapsdir}/transmission.png |
f237c99d | 341 | %{_iconsdir}/hicolor/*/apps/transmission.svg |
c72d551a | 342 | %{_datadir}/appdata/transmission-gtk.appdata.xml |
7b5e04bd | 343 | %endif |
820ff2df | 344 | |
7b5e04bd | 345 | %if %{with qt} |
820ff2df ZU |
346 | %files gui-qt |
347 | %defattr(644,root,root,755) | |
67a32c48 KK |
348 | %attr(755,root,root) %{_bindir}/transmission-qt |
349 | %{_desktopdir}/transmission-qt.desktop | |
350 | %{_pixmapsdir}/transmission-qt.png | |
7b5e04bd | 351 | %endif |
35de15cb JP |
352 | |
353 | %files utils | |
354 | %defattr(644,root,root,755) | |
355 | %attr(755,root,root) %{_bindir}/transmission-create | |
356 | %attr(755,root,root) %{_bindir}/transmission-edit | |
357 | %attr(755,root,root) %{_bindir}/transmission-remote | |
358 | %attr(755,root,root) %{_bindir}/transmission-show | |
359 | %{_mandir}/man1/transmission-create.1* | |
360 | %{_mandir}/man1/transmission-edit.1* | |
361 | %{_mandir}/man1/transmission-remote.1* | |
362 | %{_mandir}/man1/transmission-show.1* |