Contents of /trunk/extras/bluez/bluez-5.51-r1.smage2
Parent Directory | Revision Log
Revision 33275 -
(show annotations)
(download)
Wed Oct 23 07:36:17 2019 UTC (4 years, 11 months ago) by niro
File size: 4864 byte(s)
Wed Oct 23 07:36:17 2019 UTC (4 years, 11 months ago) by niro
File size: 4864 byte(s)
auto added: ver bump to 5.51-r1
1 | # $Id$ |
2 | |
3 | PNAME="bluez" |
4 | PVER="5.51" |
5 | PBUILD="r1" |
6 | |
7 | SPLIT_PACKAGES="bluez-libs bluez bluez-cups bluez-utils bluez-hid2hci bluez-plugins" |
8 | |
9 | PCAT="net-wlan" |
10 | |
11 | HOMEPAGE="http://www.bluez.org/" |
12 | |
13 | DBUS_DEPEND=">= sys-apps/dbus-1.10" |
14 | UDEV_DEPEND=">= sys-fs/udev-242" |
15 | GLIB_DEPEND=">= dev-libs/glib2-2.62" |
16 | |
17 | LIB_DEPEND=">= virtual/glibc" |
18 | BLUEZ_DEPEND="${GLIB_DEPEND} |
19 | ${DBUS_DEPEND} |
20 | >= dev-libs/libical-1" |
21 | UTILS_DEPEND="${GLIB_DEPEND} |
22 | ${DBUS_DEPEND} |
23 | ${UDEV_DEPEND} |
24 | >= sys-libs/readline-8.0" |
25 | HID_DEPEND="${UDEV_DEPEND}" |
26 | PLUGINS_DEPEND="${UDEV_DEPEND}" |
27 | CUPS_DEPEND="${GLIB_DEPEND} |
28 | ${DBUS_DEPEND} |
29 | >= net-print/cups-2.3" |
30 | |
31 | SDEPEND="${LIB_DEPEND} |
32 | ${BLUEZ_DEPEND} |
33 | ${CUPS_DEPEND} |
34 | ${UTILS_DEPEND} |
35 | ${HID_DEPEND} |
36 | ${PLUGINS_DEPEND} |
37 | >= dev-util/pkgconfig-0.25" |
38 | |
39 | SRCFILE="${PNAME}-${PVER}.tar.xz" |
40 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
41 | |
42 | sminclude mtools multilib mbuild udev systemd cleanutils |
43 | |
44 | SRC_URI=( |
45 | http://www.kernel.org/pub/linux/bluetooth/${SRCFILE} |
46 | mirror://${PNAME}/${SRCFILE} |
47 | mirror://${PNAME}/bluetooth.modprobe |
48 | ) |
49 | |
50 | UP2DATE="updatecmd http://www.kernel.org/pub/linux/bluetooth/ | grep ${PNAME}-[0-9] | highesttarball xz" |
51 | |
52 | split_info_bluez-libs() |
53 | { |
54 | DESCRIPTION="Libraries for the Bluetooth protocol stack." |
55 | DEPEND="${LIB_DEPEND}" |
56 | } |
57 | |
58 | split_info_bluez() |
59 | { |
60 | DESCRIPTION="Daemon and tools for the Bluetooth protocol stack." |
61 | DEPEND=">= net-wlan/bluez-libs-${PVER} |
62 | ${BLUEZ_DEPEND}" |
63 | } |
64 | |
65 | split_info_bluez-cups() |
66 | { |
67 | DESCRIPTION="CUPS backend for Bluetooth printers." |
68 | DEPEND=">= net-wlan/bluez-${PVER} |
69 | ${CUPS_DEPEND}" |
70 | } |
71 | |
72 | split_info_bluez-utils() |
73 | { |
74 | DESCRIPTION="Development and debugging utilities for the bluetooth protocol stack." |
75 | DEPEND=">= net-wlan/bluez-${PVER} |
76 | ${UTILS_DEPEND}" |
77 | } |
78 | |
79 | split_info_bluez-hid2hci() |
80 | { |
81 | DESCRIPTION="CUPS backend for Bluetooth printers." |
82 | DEPEND=">= net-wlan/bluez-${PVER} |
83 | ${HID_DEPEND}" |
84 | } |
85 | |
86 | split_info_bluez-plugins() |
87 | { |
88 | DESCRIPTION="bluez plugins (like support for the PS3 Sixaxis controller)." |
89 | DEPEND=">= net-wlan/bluez-${PVER} |
90 | ${PLUGINS_DEPEND}" |
91 | } |
92 | |
93 | src_compile() |
94 | { |
95 | mconfigure \ |
96 | --libexecdir=/usr/$(mlibdir) \ |
97 | --localstatedir=/var \ |
98 | --disable-debug \ |
99 | --disable-test \ |
100 | --enable-pie \ |
101 | --enable-threads \ |
102 | --enable-library \ |
103 | --enable-tools \ |
104 | --enable-monitor \ |
105 | --enable-client \ |
106 | --enable-cups \ |
107 | --enable-obex \ |
108 | --enable-systemd \ |
109 | --enable-sixaxis \ |
110 | || die |
111 | |
112 | mmake || die |
113 | } |
114 | |
115 | src_install_bluez-libs() |
116 | { |
117 | mmake DESTDIR=${BINDIR} install-libLTLIBRARIES || die |
118 | mmake DESTDIR=${BINDIR} install-pkgincludeHEADERS || die |
119 | mmake DESTDIR=${BINDIR} install-pkgconfigDATA || die |
120 | } |
121 | |
122 | src_install_bluez() |
123 | { |
124 | mmake DESTDIR=${BINDIR} install-pkglibexecPROGRAMS || die |
125 | mmake DESTDIR=${BINDIR} install-systemdsystemunitDATA || die |
126 | mmake DESTDIR=${BINDIR} install-systemduserunitDATA || die |
127 | mmake DESTDIR=${BINDIR} install-dbussessionbusDATA || die |
128 | mmake DESTDIR=${BINDIR} install-dbussystembusDATA || die |
129 | mmake DESTDIR=${BINDIR} install-dbusDATA || die |
130 | mmake DESTDIR=${BINDIR} install-man8 || die |
131 | |
132 | # config |
133 | minstalldir /etc/bluetooth || die |
134 | minstallfile src/main.conf /etc/bluetooth || die |
135 | minstallfile profiles/input/input.conf /etc/bluetooth || die |
136 | minstallfile profiles/network/network.conf /etc/bluetooth || die |
137 | #minstallfile profiles/proximity/proximity.conf /etc/bluetooth || die |
138 | |
139 | # modprobe config |
140 | minstalldir /etc/modprobe.d || die |
141 | minstallfile -s bluetooth.modprobe /etc/modprobe.d/bluetooth.conf || die |
142 | |
143 | # load modules at system start required by some functions |
144 | minstalldir /etc/modules-load.d || die |
145 | echo "crypto_user" > /etc/modules-load.d/bluez.conf || die |
146 | |
147 | # fix obex file transfer, required by some pkgs |
148 | mlink $(mget-systemd-unit-dir)/obex.service $(mget-systemd-unit-dir)/dbus-org.bluez.obex.service || die |
149 | |
150 | minstalldocs AUTHORS ChangeLog README || die |
151 | } |
152 | |
153 | src_install_bluez-cups() |
154 | { |
155 | mmake DESTDIR=${BINDIR} install-cupsPROGRAMS || die |
156 | } |
157 | |
158 | src_install_bluez-utils() |
159 | { |
160 | mmake DESTDIR=${BINDIR} install-binPROGRAMS || die |
161 | mmake DESTDIR=${BINDIR} install-man1 || die |
162 | # provided by hid2hci package |
163 | mdelete /usr/share/man/man1/hid2hci.1 || die |
164 | # provided by lib package |
165 | #mmake DESTDIR=${BINDIR} uninstall-libLTLIBRARIES || die |
166 | mdelete -r /usr/$(mlibdir) || die |
167 | } |
168 | |
169 | src_install_bluez-hid2hci() |
170 | { |
171 | mmake DESTDIR=${BINDIR} install-udevPROGRAMS || die |
172 | mmake DESTDIR=${BINDIR} install-rulesDATA || die |
173 | minstallman tools/hid2hci.1 || die |
174 | } |
175 | |
176 | src_install_bluez-plugins() |
177 | { |
178 | mmake DESTDIR=${BINDIR} install-pluginLTLIBRARIES || die |
179 | } |
180 | |
181 | postinstall_bluez() |
182 | { |
183 | # reload dbus |
184 | mreloadunit dbus.service |
185 | |
186 | # start bluetooth service |
187 | mstartunit bluetooth.service |
188 | } |
189 | |
190 | postinstall_bluez-hid2hci() |
191 | { |
192 | if [[ ${MAGE_BOOTSTRAP} != true ]] && [[ -z ${MROOT} ]] || [[ ${MROOT} = / ]] |
193 | then |
194 | # reload udev-rules |
195 | udevadm control --reload-rules |
196 | udevadm trigger --subsystem-match=usb |
197 | fi |
198 | } |
199 | |
200 | postremove_bluez() |
201 | { |
202 | # stop bluetooth service |
203 | mstopunit bluetooth.service |
204 | |
205 | # reload dbus |
206 | mreloadunit dbus.service |
207 | } |