]> git.pld-linux.org Git - packages/bluez-utils.git/blob - bluez-utils.spec
5455c2bf45b69b02a1402ab41783b37ce0109374
[packages/bluez-utils.git] / bluez-utils.spec
1 # TODO:
2 # - check init script, add support for rfcomm bind on startup
3 # - security http://www.gentoo.org/security/en/glsa/glsa-200508-09.xml
4 Summary:        Bluetooth utilities
5 Summary(pl):    Narzêdzia Bluetooth
6 Name:           bluez-utils
7 Version:        2.21
8 Release:        1
9 Epoch:          0
10 License:        GPL v2
11 Group:          Applications/System
12 Source0:        http://bluez.sourceforge.net/download/%{name}-%{version}.tar.gz
13 # Source0-md5:  f61b3b87177d876c4fcfaba890b049b4
14 Source1:        %{name}.init
15 Source2:        %{name}.sysconfig
16 Patch0:         %{name}-etc_dir.patch
17 Patch1:         %{name}-dbuslate.patch
18 URL:            http://bluez.sourceforge.net/
19 BuildRequires:  autoconf
20 BuildRequires:  automake
21 BuildRequires:  bison
22 BuildRequires:  bluez-libs-devel >= 2.15
23 BuildRequires:  dbus-devel >= 0.33
24 BuildRequires:  libtool
25 BuildRequires:  libusb-devel
26 # alsa-lib-devel, openobex-devel - currently only checked for, not used
27 PreReq:         rc-scripts
28 Requires:       bluez-libs >= 2.15
29 Obsoletes:      bluez-pan
30 Obsoletes:      bluez-sdp
31 Conflicts:      bluez-bluefw
32 ExcludeArch:    s390 s390x
33 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35 # currently lib, not %{_lib} (see cups.spec)
36 %define         cupsdir         /usr/lib/cups/backend
37
38 %description
39 Bluetooth utilities:
40  - hcitool
41  - hciattach
42  - hciconfig
43  - hcid
44  - l2ping
45  - start scripts (PLD)
46  - PCMCIA configuration files
47
48 The BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., U.S.A.
49
50 %description -l pl
51 Narzêdzia Bluetooth:
52  - hcitool
53  - hciattach
54  - hciconfig
55  - hcid
56  - l2ping
57  - skrypty startowe (PLD)
58  - pliki konfiguracji PCMCIA
59
60 %package -n cups-backend-bluetooth
61 Summary:        Bluetooth backend for CUPS
62 Summary(pl):    Backend Bluetooth dla CUPS-a
63 Group:          Applications/Printing
64 Requires:       bluez-libs >= 2.11
65 Requires:       cups
66
67 %description -n cups-backend-bluetooth
68 Bluetooth backend for CUPS.
69
70 %description -n cups-backend-bluetooth -l pl
71 Backend Bluetooth dla CUPS-a.
72
73 %package init
74 Summary:        Init script for Bluetooth subsystem
75 Summary(pl):    Skrypt init dla podsystemu Bluetooth
76 Group:          Applications/System
77 Requires:       %{name} = %{epoch}:%{version}-%{release}
78 Requires(post,preun):   /sbin/chkconfig
79
80 %description init
81 Init script for Bluetooth subsystem.
82
83 %description init -l pl
84 Skrypt init dla podsystemu Bluetooth.
85
86 %prep
87 %setup -q
88 %patch0 -p1
89 %patch1 -p1
90
91 %build
92 %{__libtoolize}
93 %{__aclocal}
94 %{__autoconf}
95 %{__automake}
96 %configure \
97         --enable-bcm203x \
98         --enable-cups \
99         --enable-pcmcia \
100         --with-cups=/usr
101 %{__make} \
102         cupsdir=%{cupsdir}
103
104 %install
105 rm -rf $RPM_BUILD_ROOT
106 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig}
107
108 %{__make} install \
109         DESTDIR=$RPM_BUILD_ROOT \
110         cupsdir=%{cupsdir}
111
112 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/bluetooth
113 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/bluetooth
114
115 %clean
116 rm -rf $RPM_BUILD_ROOT
117
118 %post init
119 /sbin/chkconfig --add bluetooth
120 if [ -f /var/lock/subsys/bluetooth ]; then
121         /etc/rc.d/init.d/bluetooth restart >&2
122 else
123         echo "Run \"/etc/rc.d/init.d/bluetooth\" to start bluetooth." >&2
124 fi
125
126 %postun init
127 if [ "$1" = "0" ]; then
128         if [ -f /var/lock/subsys/bluetooth ]; then
129                 /etc/rc.d/init.d/bluetooth stop 1>&2
130         fi
131         /sbin/chkconfig --del bluetooth
132 fi
133
134 %files
135 %defattr(644,root,root,755)
136 %doc AUTHORS ChangeLog README
137 %attr(755,root,root) %{_bindir}/*
138 %attr(755,root,root) %{_sbindir}/*
139 %{_mandir}/man*/*
140 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/bluetooth
141 %dir %{_sysconfdir}/bluetooth
142 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/bluetooth/*
143 %attr(755,root,root) %{_sysconfdir}/hotplug/usb/bcm203x
144 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/hotplug/usb/bcm203x.usermap
145 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/pcmcia/bluetooth.conf
146 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/pcmcia/bluetooth
147
148 %files -n cups-backend-bluetooth
149 %defattr(644,root,root,755)
150 %attr(755,root,root) %{_prefix}/lib/cups/backend/bluetooth
151
152 %files init
153 %defattr(644,root,root,755)
154 %attr(754,root,root) /etc/rc.d/init.d/bluetooth
This page took 0.033897 seconds and 2 git commands to generate.