maint: removed unsupported distros from release build list
[barry.git] / rpm / barry.spec
blob52cce055397c2c14cf320b2b5355dd6a93da77d5
1 %dump
3 # always build with GUI
4 %define with_gui 1
6 # Fedora 9 doesn't support opensync 0.22
7 %if 0%{?fc9}
8 %define with_opensync 0
9 %else
10 %define with_opensync 1
11 %endif
13 %if 0%{?fc12} || 0%{?fc13}
14 %define use_69_rules 1
15 %else
16 %define use_69_rules 0
17 %endif
20 Summary: BlackBerry(tm) Desktop for Linux
21 Name: barry
22 Version: 0.17.1
23 Release: 0
24 Group: Applications/Productivity
25 License: GPLv2+
26 Source: %{name}-%{version}.tar.bz2
27 URL: http://www.netdirect.ca/software/packages/barry
28 Vendor: Net Direct Inc.
29 BuildRoot: %{_tmppath}/%{name}-%{release}-%{version}-root
31 %if 0%{?suse_version}
32 BuildRequires: libusb, gcc-c++, pkgconfig, boost-devel, fuse-devel, zlib-devel
33 %else
34 BuildRequires: libusb-devel, gcc-c++, pkgconfig, boost-devel, fuse-devel, zlib-devel
35 %endif
37 %if %{with_gui}
38 BuildRequires: desktop-file-utils
39 %endif
41 %define barryroot %{_builddir}/%{name}-%{version}
43 %description
44 Barry is a desktop toolset for managing your BlackBerry(tm) device. (BlackBerry
45 is a registered trademark of Research in Motion Limited.)
48 %package -n libbarry0
49 Summary: BlackBerry(tm) Desktop for Linux - libbarry libraries
50 Group: Development/Libraries
51 Requires: libusb boost
53 %description -n libbarry0
54 Barry is a desktop toolset for managing your BlackBerry(tm) device. (BlackBerry
55 is a registered trademark of Research in Motion Limited.)
57 This package contains the library files, license agreement, README file,
58 and most other assorted documentation common to all sub-packages. You most
59 likely want to also install barry-util and barry-gui.
62 %package -n libbarry-devel
63 Summary: BlackBerry(tm) Desktop for Linux - libbarry libraries
64 Group: Development/Libraries
65 %if 0%{?suse_version}
66 Requires: libbarry0 libusb boost-devel
67 %else
68 Requires: libbarry0 libusb-devel boost-devel
69 %endif
71 %description -n libbarry-devel
72 Barry is a desktop toolset for managing your BlackBerry(tm) device. (BlackBerry
73 is a registered trademark of Research in Motion Limited.)
75 This package contains the development library files for Barry, libbarry.
78 %package util
79 Summary: BlackBerry(tm) Desktop for Linux - bcharge, btool, breset, bio and others
80 Group: Applications/Productivity
81 Requires: libbarry0 fuse
82 Conflicts: barry-bcharge
84 %description util
85 Barry is a desktop toolset for managing your BlackBerry(tm) device. (BlackBerry
86 is a registered trademark of Research in Motion Limited.)
88 This package contains the commandline tools bcharge, btool, breset, bio and
89 others which will enable you to charge your device with a proper 500mA
90 and be able to access the data on the device in many ways.
93 %if %{with_gui}
94 %package gui
95 Summary: BlackBerry(tm) Desktop for Linux - bcharge, btool, breset and others
96 Group: Applications/Productivity
97 %if 0%{?suse_version}
98 Requires: libbarry0 gtkmm2 libglademm libtar
99 BuildRequires: gtkmm2-devel libglademm-devel libtar-devel
100 %else
101 Requires: libbarry0 gtkmm24 libglademm24 libtar
102 BuildRequires: gtkmm24-devel libglademm24-devel libtar-devel
103 %endif
105 %description gui
106 Barry is a desktop toolset for managing your BlackBerry(tm) device. (BlackBerry
107 is a registered trademark of Research in Motion Limited.)
109 This package contains the GUI applications built on top of libbarry.
110 %endif
113 %if %{with_opensync}
114 %package opensync
115 Summary: BlackBerry(tm) Desktop for Linux - opensync plugin
116 Group: Applications/Productivity
117 Requires: libbarry0, libopensync >= 0.22
118 BuildRequires: libopensync-devel
120 %description opensync
121 Barry is a desktop toolset for managing your BlackBerry(tm) device. (BlackBerry
122 is a registered trademark of Research in Motion Limited.)
124 This package contains the opensync plugin.
125 %endif
127 %prep
128 %setup -q
130 %build
131 # main tree
132 %{configure} --enable-boost --enable-nls --with-zlib
133 %{__make} %{?_smp_mflags}
135 # gui tree
136 %if %{with_gui}
137 cd gui/
138 %{configure} PKG_CONFIG_PATH="..:$PKG_CONFIG_PATH" CXXFLAGS="-I../.." LDFLAGS="-L../../src" --enable-nls
139 %{__make} %{?_smp_mflags}
140 cd ../
141 %endif
143 # opensync tree
144 %if %{with_opensync}
145 cd opensync-plugin/
146 %{configure} PKG_CONFIG_PATH="..:$PKG_CONFIG_PATH" CXXFLAGS="-I../.." LDFLAGS="-L../../src" --enable-nls
147 %{__make} %{?_smp_mflags}
148 cd ../
149 %endif
151 %install
152 # main tree
153 %{__make} DESTDIR=%{buildroot} install
154 # delete some test-only programs
155 %{__rm} -f %{buildroot}%{_bindir}/bdptest
156 %{__rm} -f %{buildroot}%{_bindir}/bjvmdebug
157 # proceed as usual...
158 %{__mkdir_p} %{buildroot}%{_sysconfdir}/udev/rules.d
159 %{__cp} udev/10-blackberry.rules %{buildroot}%{_sysconfdir}/udev/rules.d/
160 %if %{use_69_rules}
161 %{__cp} udev/69-blackberry.rules %{buildroot}%{_sysconfdir}/udev/rules.d/
162 %else
163 %{__cp} udev/99-blackberry-perms.rules %{buildroot}%{_sysconfdir}/udev/rules.d/
164 %endif
165 %{__mkdir_p} %{buildroot}%{_sysconfdir}/modprobe.d
166 %{__cp} modprobe/blacklist-berry_charge.conf %{buildroot}%{_sysconfdir}/modprobe.d/
167 %{__mkdir_p} %{buildroot}%{_sysconfdir}/ppp/peers
168 %{__cp} ppp/barry-rogers %{buildroot}%{_sysconfdir}/ppp/peers/
169 %{__cp} ppp/barry-minimal %{buildroot}%{_sysconfdir}/ppp/peers/
170 %{__cp} ppp/barry-verizon %{buildroot}%{_sysconfdir}/ppp/peers/
171 %{__cp} ppp/barry-sprint %{buildroot}%{_sysconfdir}/ppp/peers/
172 %{__cp} ppp/barry-telus %{buildroot}%{_sysconfdir}/ppp/peers/
173 %{__cp} ppp/barry-o2ireland %{buildroot}%{_sysconfdir}/ppp/peers/
174 %{__cp} ppp/barry-tmobileus %{buildroot}%{_sysconfdir}/ppp/peers/
175 %{__cp} ppp/barry-att_cingular %{buildroot}%{_sysconfdir}/ppp/peers/
176 %{__cp} ppp/barry-chinamobile %{buildroot}%{_sysconfdir}/ppp/peers/
177 %{__cp} ppp/barry-kpn %{buildroot}%{_sysconfdir}/ppp/peers/
178 %{__cp} ppp/barry-orange-spain %{buildroot}%{_sysconfdir}/ppp/peers/
179 %{__cp} ppp/barry-optus-au %{buildroot}%{_sysconfdir}/ppp/peers/
180 %{__cp} ppp/barry-vodafone-au %{buildroot}%{_sysconfdir}/ppp/peers/
181 %{__mkdir_p} %{buildroot}%{_sysconfdir}/chatscripts
182 %{__cp} ppp/barry-rogers.chat %{buildroot}%{_sysconfdir}/chatscripts/
183 %{__cp} ppp/barry-minimal.chat %{buildroot}%{_sysconfdir}/chatscripts/
184 %{__cp} ppp/barry-verizon.chat %{buildroot}%{_sysconfdir}/chatscripts/
185 %{__cp} ppp/barry-sprint.chat %{buildroot}%{_sysconfdir}/chatscripts/
186 %{__cp} ppp/barry-telus.chat %{buildroot}%{_sysconfdir}/chatscripts/
187 %{__cp} ppp/barry-o2ireland.chat %{buildroot}%{_sysconfdir}/chatscripts/
188 %{__cp} ppp/barry-tmobileus.chat %{buildroot}%{_sysconfdir}/chatscripts/
189 %{__cp} ppp/barry-att_cingular.chat %{buildroot}%{_sysconfdir}/chatscripts/
190 %{__cp} ppp/barry-chinamobile.chat %{buildroot}%{_sysconfdir}/chatscripts/
191 %{__cp} ppp/barry-kpn.chat %{buildroot}%{_sysconfdir}/chatscripts/
192 %{__cp} ppp/barry-orange-spain.chat %{buildroot}%{_sysconfdir}/chatscripts/
193 %{__cp} ppp/barry-optus-au.chat %{buildroot}%{_sysconfdir}/chatscripts/
194 %{__cp} ppp/barry-vodafone-au.chat %{buildroot}%{_sysconfdir}/chatscripts/
195 # Install hal fdi config
196 %{__mkdir_p} %{buildroot}%{_datadir}/hal/fdi/information/10freedesktop
197 %{__mkdir_p} %{buildroot}%{_datadir}/hal/fdi/policy/10osvendor
198 %{__cp} hal/fdi/information/10freedesktop/10-blackberry.fdi %{buildroot}%{_datadir}/hal/fdi/information/10freedesktop
199 %{__cp} hal/fdi/policy/10osvendor/19-blackberry-acl.fdi %{buildroot}%{_datadir}/hal/fdi/policy/10osvendor
200 # Install hal support script
201 %{__mkdir_p} %{buildroot}%{_bindir}
202 %{__cp} hal/hal-blackberry %{buildroot}%{_bindir}
203 # Install bash completion scripts
204 %{__mkdir_p} %{buildroot}%{_sysconfdir}/bash_completion.d
205 %{__cp} bash/bjavaloader %{buildroot}%{_sysconfdir}/bash_completion.d
206 %{__cp} bash/btool %{buildroot}%{_sysconfdir}/bash_completion.d
208 # gui tree
209 %if %{with_gui}
210 cd gui/
211 %{__make} DESTDIR=%{buildroot} install
212 # Install barry logo icon
213 cd ../
214 %{__mkdir_p} %{buildroot}%{_datadir}/pixmaps
215 %{__cp} logo/barry_logo_icon.png %{buildroot}%{_datadir}/pixmaps
216 desktop-file-install --vendor netdirect \
217 --dir %{buildroot}%{_datadir}/applications \
218 menu/barrybackup.desktop
219 %endif
221 # opensync tree
222 %if %{with_opensync}
223 cd opensync-plugin/
224 %{__make} DESTDIR=%{buildroot} install
225 cd ../
226 %endif
228 %files -n libbarry0
229 %defattr(-,root,root)
230 %attr(-,root,root) %{_libdir}/*.so*
231 %doc AUTHORS ChangeLog COPYING NEWS README
233 %files -n libbarry-devel
234 %defattr(-,root,root)
235 %attr(0644,root,root) %{_includedir}/barry/*
236 %attr(0644,root,root) %{_libdir}/*.a
237 %attr(0755,root,root) %{_libdir}/*.la
238 %attr(0644,root,root) %{_libdir}/pkgconfig/*.pc
239 %doc COPYING TODO doc/* examples/*.cc
241 %files util
242 %defattr(-,root,root)
243 %attr(0755,root,root) %{_sbindir}/bcharge
244 %attr(0755,root,root) %{_sbindir}/breset
245 %attr(0755,root,root) %{_sbindir}/pppob
246 %attr(0755,root,root) %{_bindir}/btool
247 %attr(0755,root,root) %{_bindir}/bio
248 %attr(0755,root,root) %{_bindir}/btardump
249 %attr(0755,root,root) %{_bindir}/bfuse
250 %attr(0755,root,root) %{_bindir}/bjavaloader
251 %attr(0755,root,root) %{_bindir}/balxparse
252 %attr(0755,root,root) %{_bindir}/bjdwp
253 %attr(0755,root,root) %{_bindir}/brawchannel
254 %attr(0755,root,root) %{_bindir}/bs11nread
255 %attr(0755,root,root) %{_bindir}/bidentify
256 %attr(0755,root,root) %{_bindir}/brecsum
257 %attr(0755,root,root) %{_bindir}/upldif
258 %attr(0755,root,root) %{_bindir}/bktrans
259 %attr(0755,root,root) %{_bindir}/btranslate
260 %attr(0755,root,root) %{_bindir}/brimtrans
261 %attr(0755,root,root) %{_bindir}/hal-blackberry
262 %attr(0644,root,root) %{_mandir}/man1/btool*
263 %attr(0644,root,root) %{_mandir}/man1/bio*
264 %attr(0644,root,root) %{_mandir}/man1/btardump*
265 %attr(0644,root,root) %{_mandir}/man1/bfuse*
266 %attr(0644,root,root) %{_mandir}/man1/bjavaloader*
267 %attr(0644,root,root) %{_mandir}/man1/balxparse*
268 %attr(0644,root,root) %{_mandir}/man1/bjdwp*
269 %attr(0644,root,root) %{_mandir}/man1/brawchannel*
270 %attr(0644,root,root) %{_mandir}/man1/bs11nread*
271 %attr(0644,root,root) %{_mandir}/man1/bidentify*
272 %attr(0644,root,root) %{_mandir}/man1/bcharge*
273 %attr(0644,root,root) %{_mandir}/man1/pppob*
274 %attr(0644,root,root) %{_mandir}/man1/brecsum*
275 %attr(0644,root,root) %{_mandir}/man1/breset*
276 %attr(0644,root,root) %{_mandir}/man1/upldif*
277 %attr(0644,root,root) %{_datadir}/locale/*
278 %attr(0644,root,root) %{_datadir}/hal/fdi/information/10freedesktop/10-blackberry.fdi
279 %attr(0644,root,root) %{_datadir}/hal/fdi/policy/10osvendor/19-blackberry-acl.fdi
280 %attr(0644,root,root) %config %{_sysconfdir}/udev/rules.d/*
281 %attr(0644,root,root) %config %{_sysconfdir}/modprobe.d/blacklist-berry_charge.conf
282 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-rogers
283 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-minimal
284 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-verizon
285 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-sprint
286 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-telus
287 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-o2ireland
288 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-tmobileus
289 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-att_cingular
290 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-chinamobile
291 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-kpn
292 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-orange-spain
293 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-optus-au
294 %attr(0644,root,root) %config %{_sysconfdir}/ppp/peers/barry-vodafone-au
295 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-rogers.chat
296 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-minimal.chat
297 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-verizon.chat
298 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-sprint.chat
299 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-telus.chat
300 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-o2ireland.chat
301 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-tmobileus.chat
302 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-att_cingular.chat
303 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-chinamobile.chat
304 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-kpn.chat
305 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-orange-spain.chat
306 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-optus-au.chat
307 %attr(0640,root,root) %config %{_sysconfdir}/chatscripts/barry-vodafone-au.chat
308 %attr(0640,root,root) %config %{_sysconfdir}/bash_completion.d/bjavaloader
309 %attr(0640,root,root) %config %{_sysconfdir}/bash_completion.d/btool
310 %doc COPYING
311 %doc zsh
312 %doc ppp/README
314 %if %{with_gui}
315 %files gui
316 %defattr(-,root,root)
317 %attr(0755,root,root) %{_bindir}/barrybackup
318 %attr(0644,root,root) %{_datadir}/barry/glade/*.glade
319 %attr(0644,root,root) %{_datadir}/pixmaps/barry_logo_icon.png
320 %attr(0644,root,root) %{_datadir}/applications/*barrybackup.desktop
321 %attr(0644,root,root) %{_mandir}/man1/barrybackup*
322 %doc COPYING
323 %endif
325 %if %{with_opensync}
326 %files opensync
327 %defattr(-,root,root)
328 %attr(0755,root,root) %{_libdir}/opensync/plugins/*
329 %attr(0644,root,root) %{_datadir}/opensync/defaults/*
330 %doc COPYING
331 %endif
333 %clean
334 [ "%{buildroot}" != "/" ] && %{__rm} -rf %{buildroot}
335 [ "%{barryroot}" != "/" ] && %{__rm} -rf %{barryroot}
337 %post -n libbarry0
338 /sbin/ldconfig
340 %postun -n libbarry0
341 /sbin/ldconfig
343 %changelog
344 * Mon Feb 28 2011 Chris Frey <cdfrey@foursquare.net> 0.17.1-0
345 - version bump
347 * Fri May 28 2010 Chris Frey <cdfrey@foursquare.net> 0.17.0-0
348 - version bump
349 - added NLS support
350 - cleaned up conditionals
351 - added Fedora 13 support
352 - added new ppp chat scripts for Orange Spain, Optus and Vodafone AU
353 - added copy of barry-sprint as barry-telus
354 - added brawchannel, btardump, bio, and balxparse
356 * Sat Sep 29 2009 Chris Frey <cdfrey@foursquare.net> 0.16-0
357 - version bump
358 - added new ppp chat script for KPN Nederland
359 - using new udev rules set
360 - added bjdwp and manpage, and removed some test-only programs
361 - added bash and zsh completion scripts
362 - added .desktop file and icon for barrybackup
364 * Fri Apr 10 2009 Chris Frey <cdfrey@foursquare.net> 0.15-0
365 - version bump
366 - added HAL FDI scripts
367 - added bjavaloader and bfuse
368 - updated for udev directory reorganization in Barry source tree
369 - added zlib-devel to BuildRequires list
370 - added brimtrans
372 * Wed Sep 24 2008 Chris Frey <cdfrey@foursquare.net> 0.14-0
373 - version bump
374 - added new ppp chat script for T-Mobile US
375 - renamed libbarry to libbarry0
377 * Thu May 29 2008 Chris Frey <cdfrey@foursquare.net> 0.13-1
378 - version bump
379 - added brecsum
380 - added ppp options and chat scripts
381 - added manpages for pppob, brecsum, breset, upldif, barrybackup
382 - spec file now assumes gui and opensync, with conditional checks depending on host
384 * Fri Dec 07 2007 Chris Frey <cdfrey@foursquare.net> 0.12-1
385 - version bump
387 * Fri Nov 30 2007 Chris Frey <cdfrey@foursquare.net> 0.11-1
388 - version bump
390 * Fri Nov 30 2007 Chris Frey <cdfrey@foursquare.net> 0.10-1
391 - version bump
392 - removed ktrans and translate from rpm package
393 - added bidentify
395 * Thu Aug 09 2007 Chris Frey <cdfrey@foursquare.net> 0.9-1
396 - version bump
398 * Fri Aug 03 2007 Chris Frey <cdfrey@foursquare.net> 0.8-1
399 - version bump
400 - changed tarball to bz2
402 * Tue May 01 2007 Chris Frey <cdfrey@foursquare.net> 0.7-2
403 - added pppob to utils
405 * Thu Mar 08 2007 Chris Frey <cdfrey@foursquare.net> 0.7-1
406 - removed barry base package that only contained docs, and put docs in libbarry*
407 - changed barrybackup reference to barry-gui
408 - removed the patch step, as version 0.7 shouldn't need it
409 - added license file to each package
411 * Sun Mar 04 2007 Troy Engel <tengel@users.sourceforge.net> 0.6-1
412 - initial build
413 - adding udev and console perms patch for raw 0.6