diff options
Diffstat (limited to 'meta/recipes-connectivity/connman/connman.inc')
-rw-r--r-- | meta/recipes-connectivity/connman/connman.inc | 110 |
1 files changed, 60 insertions, 50 deletions
diff --git a/meta/recipes-connectivity/connman/connman.inc b/meta/recipes-connectivity/connman/connman.inc index 776bbfbff2..7487ca0d0c 100644 --- a/meta/recipes-connectivity/connman/connman.inc +++ b/meta/recipes-connectivity/connman/connman.inc | |||
@@ -9,12 +9,14 @@ configuration methods, like DHCP and domain name resolving, are \ | |||
9 | implemented using plug-ins." | 9 | implemented using plug-ins." |
10 | HOMEPAGE = "http://connman.net/" | 10 | HOMEPAGE = "http://connman.net/" |
11 | BUGTRACKER = "https://01.org/jira/browse/CM" | 11 | BUGTRACKER = "https://01.org/jira/browse/CM" |
12 | LICENSE = "GPLv2" | 12 | LICENSE = "GPL-2.0-only" |
13 | LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ | 13 | LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ |
14 | file://src/main.c;beginline=1;endline=20;md5=486a279a6ab0c8d152bcda3a5b5edc36" | 14 | file://src/main.c;beginline=1;endline=20;md5=486a279a6ab0c8d152bcda3a5b5edc36" |
15 | 15 | ||
16 | inherit autotools pkgconfig systemd update-rc.d update-alternatives | 16 | inherit autotools pkgconfig systemd update-rc.d update-alternatives |
17 | 17 | ||
18 | CVE_PRODUCT = "connman connection_manager" | ||
19 | |||
18 | DEPENDS = "dbus glib-2.0 ppp" | 20 | DEPENDS = "dbus glib-2.0 ppp" |
19 | 21 | ||
20 | EXTRA_OECONF += "\ | 22 | EXTRA_OECONF += "\ |
@@ -25,21 +27,29 @@ EXTRA_OECONF += "\ | |||
25 | --enable-ethernet \ | 27 | --enable-ethernet \ |
26 | --enable-tools \ | 28 | --enable-tools \ |
27 | --disable-polkit \ | 29 | --disable-polkit \ |
30 | --runstatedir=/run \ | ||
28 | " | 31 | " |
32 | # For smooth operation it would be best to start only one wireless daemon at a time. | ||
33 | # If wpa-supplicant is running, connman will use it preferentially. | ||
34 | # Select either wpa-supplicant or iwd | ||
35 | WIRELESS_DAEMON ??= "wpa-supplicant" | ||
29 | 36 | ||
30 | PACKAGECONFIG ??= "wispr iptables client\ | 37 | PACKAGECONFIG ??= "wispr iptables client\ |
31 | ${@bb.utils.filter('DISTRO_FEATURES', '3g systemd wifi', d)} \ | 38 | ${@bb.utils.filter('DISTRO_FEATURES', '3g systemd', d)} \ |
32 | ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \ | 39 | ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \ |
40 | ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'wifi ${WIRELESS_DAEMON}', '', d)} \ | ||
33 | " | 41 | " |
34 | 42 | ||
35 | # If you want ConnMan to support VPN, add following statement into | 43 | # If you want ConnMan to support VPN, add following statement into |
36 | # local.conf or distro config | 44 | # local.conf or distro config |
37 | # PACKAGECONFIG_append_pn-connman = " openvpn vpnc l2tp pptp" | 45 | # PACKAGECONFIG:append:pn-connman = " openvpn vpnc l2tp pptp" |
38 | 46 | ||
39 | PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_unitdir}/system/ --with-tmpfilesdir=${sysconfdir}/tmpfiles.d/,--with-systemdunitdir='' --with-tmpfilesdir=''" | 47 | PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_system_unitdir}/ --with-tmpfilesdir=${sysconfdir}/tmpfiles.d/,--with-systemdunitdir='' --with-tmpfilesdir=''" |
40 | PACKAGECONFIG[wifi] = "--enable-wifi, --disable-wifi, wpa-supplicant, wpa-supplicant" | 48 | PACKAGECONFIG[wifi] = "--enable-wifi, --disable-wifi" |
41 | PACKAGECONFIG[bluez] = "--enable-bluetooth, --disable-bluetooth, bluez5, bluez5" | 49 | PACKAGECONFIG[bluez] = "--enable-bluetooth, --disable-bluetooth, bluez5, bluez5" |
42 | PACKAGECONFIG[3g] = "--enable-ofono, --disable-ofono, ofono, ofono" | 50 | PACKAGECONFIG[3g] = "--enable-ofono, --disable-ofono, ofono, ofono" |
51 | PACKAGECONFIG[wpa-supplicant] = ",,wpa-supplicant,wpa-supplicant" | ||
52 | PACKAGECONFIG[iwd] = "--enable-iwd,--disable-iwd,,iwd" | ||
43 | PACKAGECONFIG[tist] = "--enable-tist,--disable-tist," | 53 | PACKAGECONFIG[tist] = "--enable-tist,--disable-tist," |
44 | PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" | 54 | PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" |
45 | PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" | 55 | PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" |
@@ -64,16 +74,16 @@ python __anonymous () { | |||
64 | d.setVar('SYSTEMD_PACKAGES', systemd_packages) | 74 | d.setVar('SYSTEMD_PACKAGES', systemd_packages) |
65 | } | 75 | } |
66 | 76 | ||
67 | SYSTEMD_SERVICE_${PN} = "connman.service" | 77 | SYSTEMD_SERVICE:${PN} = "connman.service" |
68 | SYSTEMD_SERVICE_${PN}-vpn = "connman-vpn.service" | 78 | SYSTEMD_SERVICE:${PN}-vpn = "connman-vpn.service" |
69 | SYSTEMD_SERVICE_${PN}-wait-online = "connman-wait-online.service" | 79 | SYSTEMD_SERVICE:${PN}-wait-online = "connman-wait-online.service" |
70 | 80 | ||
71 | ALTERNATIVE_PRIORITY = "100" | 81 | ALTERNATIVE_PRIORITY = "100" |
72 | ALTERNATIVE_${PN} = "${@bb.utils.contains('DISTRO_FEATURES','systemd','resolv-conf','',d)}" | 82 | ALTERNATIVE:${PN} = "${@bb.utils.contains('DISTRO_FEATURES','systemd','resolv-conf','',d)}" |
73 | ALTERNATIVE_TARGET[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv-conf.connman','',d)}" | 83 | ALTERNATIVE_TARGET[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv-conf.connman','',d)}" |
74 | ALTERNATIVE_LINK_NAME[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv.conf','',d)}" | 84 | ALTERNATIVE_LINK_NAME[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv.conf','',d)}" |
75 | 85 | ||
76 | do_install_append() { | 86 | do_install:append() { |
77 | if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then | 87 | if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then |
78 | install -d ${D}${sysconfdir}/init.d | 88 | install -d ${D}${sysconfdir}/init.d |
79 | install -m 0755 ${WORKDIR}/connman ${D}${sysconfdir}/init.d/connman | 89 | install -m 0755 ${WORKDIR}/connman ${D}${sysconfdir}/init.d/connman |
@@ -100,7 +110,7 @@ do_install_append() { | |||
100 | } | 110 | } |
101 | 111 | ||
102 | # These used to be plugins, but now they are core | 112 | # These used to be plugins, but now they are core |
103 | RPROVIDES_${PN} = "\ | 113 | RPROVIDES:${PN} = "\ |
104 | connman-plugin-loopback \ | 114 | connman-plugin-loopback \ |
105 | connman-plugin-ethernet \ | 115 | connman-plugin-ethernet \ |
106 | ${@bb.utils.contains('PACKAGECONFIG', 'bluetooth','connman-plugin-bluetooth', '', d)} \ | 116 | ${@bb.utils.contains('PACKAGECONFIG', 'bluetooth','connman-plugin-bluetooth', '', d)} \ |
@@ -108,7 +118,7 @@ RPROVIDES_${PN} = "\ | |||
108 | ${@bb.utils.contains('PACKAGECONFIG', '3g','connman-plugin-ofono', '', d)} \ | 118 | ${@bb.utils.contains('PACKAGECONFIG', '3g','connman-plugin-ofono', '', d)} \ |
109 | " | 119 | " |
110 | 120 | ||
111 | RDEPENDS_${PN} = "\ | 121 | RDEPENDS:${PN} = "\ |
112 | dbus \ | 122 | dbus \ |
113 | " | 123 | " |
114 | 124 | ||
@@ -119,11 +129,11 @@ def add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, add_insane_skip): | |||
119 | if plugintype in depmap: | 129 | if plugintype in depmap: |
120 | rdepends = map(lambda x: multilib_prefix + x, \ | 130 | rdepends = map(lambda x: multilib_prefix + x, \ |
121 | depmap[plugintype].split()) | 131 | depmap[plugintype].split()) |
122 | d.setVar("RDEPENDS_%s" % pkg, " ".join(rdepends)) | 132 | d.setVar("RDEPENDS:%s" % pkg, " ".join(rdepends)) |
123 | if add_insane_skip: | 133 | if add_insane_skip: |
124 | d.appendVar("INSANE_SKIP_%s" % pkg, "dev-so") | 134 | d.appendVar("INSANE_SKIP:%s" % pkg, "dev-so") |
125 | 135 | ||
126 | python populate_packages_prepend() { | 136 | python populate_packages:prepend() { |
127 | depmap = dict(pppd="ppp") | 137 | depmap = dict(pppd="ppp") |
128 | multilib_prefix = (d.getVar("MLPREFIX") or "") | 138 | multilib_prefix = (d.getVar("MLPREFIX") or "") |
129 | 139 | ||
@@ -144,72 +154,72 @@ python populate_packages_prepend() { | |||
144 | 154 | ||
145 | PACKAGES =+ "${PN}-tools ${PN}-tests ${PN}-client" | 155 | PACKAGES =+ "${PN}-tools ${PN}-tests ${PN}-client" |
146 | 156 | ||
147 | FILES_${PN}-tools = "${bindir}/wispr" | 157 | FILES:${PN}-tools = "${bindir}/wispr" |
148 | RDEPENDS_${PN}-tools ="${PN}" | 158 | RDEPENDS:${PN}-tools ="${PN}" |
149 | 159 | ||
150 | FILES_${PN}-tests = "${bindir}/*-test" | 160 | FILES:${PN}-tests = "${bindir}/*-test" |
151 | 161 | ||
152 | FILES_${PN}-client = "${bindir}/connmanctl" | 162 | FILES:${PN}-client = "${bindir}/connmanctl" |
153 | RDEPENDS_${PN}-client ="${PN}" | 163 | RDEPENDS:${PN}-client ="${PN}" |
154 | 164 | ||
155 | FILES_${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \ | 165 | FILES:${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \ |
156 | ${libdir}/connman/plugins \ | 166 | ${libdir}/connman/plugins \ |
157 | ${sysconfdir} ${sharedstatedir} ${localstatedir} ${datadir} \ | 167 | ${sysconfdir} ${sharedstatedir} ${localstatedir} ${datadir} \ |
158 | ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} \ | 168 | ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} \ |
159 | ${datadir}/dbus-1/system-services/* \ | 169 | ${datadir}/dbus-1/system-services/* \ |
160 | ${sysconfdir}/tmpfiles.d/connman_resolvconf.conf" | 170 | ${sysconfdir}/tmpfiles.d/connman_resolvconf.conf" |
161 | 171 | ||
162 | FILES_${PN}-dev += "${libdir}/connman/*/*.la" | 172 | FILES:${PN}-dev += "${libdir}/connman/*/*.la" |
163 | 173 | ||
164 | PACKAGES =+ "${PN}-vpn ${PN}-wait-online" | 174 | PACKAGES =+ "${PN}-vpn ${PN}-wait-online" |
165 | 175 | ||
166 | SUMMARY_${PN}-vpn = "A daemon for managing VPN connections within embedded devices" | 176 | SUMMARY:${PN}-vpn = "A daemon for managing VPN connections within embedded devices" |
167 | DESCRIPTION_${PN}-vpn = "The ConnMan VPN provides a daemon for \ | 177 | DESCRIPTION:${PN}-vpn = "The ConnMan VPN provides a daemon for \ |
168 | managing VPN connections within embedded devices running the Linux \ | 178 | managing VPN connections within embedded devices running the Linux \ |
169 | operating system. The connman-vpnd handles all the VPN connections \ | 179 | operating system. The connman-vpnd handles all the VPN connections \ |
170 | and starts/stops VPN client processes when necessary. The connman-vpnd \ | 180 | and starts/stops VPN client processes when necessary. The connman-vpnd \ |
171 | provides a DBus API for managing VPN connections. All the different \ | 181 | provides a DBus API for managing VPN connections. All the different \ |
172 | VPN technogies are implemented using plug-ins." | 182 | VPN technogies are implemented using plug-ins." |
173 | FILES_${PN}-vpn += "${sbindir}/connman-vpnd \ | 183 | FILES:${PN}-vpn += "${sbindir}/connman-vpnd \ |
174 | ${sysconfdir}/dbus-1/system.d/connman-vpn-dbus.conf \ | 184 | ${sysconfdir}/dbus-1/system.d/connman-vpn-dbus.conf \ |
175 | ${datadir}/dbus-1/system-services/net.connman.vpn.service \ | 185 | ${datadir}/dbus-1/system-services/net.connman.vpn.service \ |
176 | ${systemd_unitdir}/system/connman-vpn.service" | 186 | ${systemd_system_unitdir}/connman-vpn.service" |
177 | 187 | ||
178 | SUMMARY_${PN}-wait-online = "A program that will return once ConnMan has connected to a network" | 188 | SUMMARY:${PN}-wait-online = "A program that will return once ConnMan has connected to a network" |
179 | DESCRIPTION_${PN}-wait-online = "A service that can be enabled so that \ | 189 | DESCRIPTION:${PN}-wait-online = "A service that can be enabled so that \ |
180 | the system waits until a network connection is established." | 190 | the system waits until a network connection is established." |
181 | FILES_${PN}-wait-online += "${sbindir}/connmand-wait-online \ | 191 | FILES:${PN}-wait-online += "${sbindir}/connmand-wait-online \ |
182 | ${systemd_unitdir}/system/connman-wait-online.service" | 192 | ${systemd_system_unitdir}/connman-wait-online.service" |
183 | 193 | ||
184 | SUMMARY_${PN}-plugin-vpn-openvpn = "An OpenVPN plugin for ConnMan VPN" | 194 | SUMMARY:${PN}-plugin-vpn-openvpn = "An OpenVPN plugin for ConnMan VPN" |
185 | DESCRIPTION_${PN}-plugin-vpn-openvpn = "The ConnMan OpenVPN plugin uses openvpn client \ | 195 | DESCRIPTION:${PN}-plugin-vpn-openvpn = "The ConnMan OpenVPN plugin uses openvpn client \ |
186 | to create a VPN connection to OpenVPN server." | 196 | to create a VPN connection to OpenVPN server." |
187 | FILES_${PN}-plugin-vpn-openvpn += "${libdir}/connman/scripts/openvpn-script \ | 197 | FILES:${PN}-plugin-vpn-openvpn += "${libdir}/connman/scripts/openvpn-script \ |
188 | ${libdir}/connman/plugins-vpn/openvpn.so" | 198 | ${libdir}/connman/plugins-vpn/openvpn.so" |
189 | RDEPENDS_${PN}-plugin-vpn-openvpn += "${PN}-vpn" | 199 | RDEPENDS:${PN}-plugin-vpn-openvpn += "${PN}-vpn" |
190 | RRECOMMENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG','openvpn','${PN}-plugin-vpn-openvpn', '', d)}" | 200 | RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','openvpn','${PN}-plugin-vpn-openvpn', '', d)}" |
191 | 201 | ||
192 | SUMMARY_${PN}-plugin-vpn-vpnc = "A vpnc plugin for ConnMan VPN" | 202 | SUMMARY:${PN}-plugin-vpn-vpnc = "A vpnc plugin for ConnMan VPN" |
193 | DESCRIPTION_${PN}-plugin-vpn-vpnc = "The ConnMan vpnc plugin uses vpnc client \ | 203 | DESCRIPTION:${PN}-plugin-vpn-vpnc = "The ConnMan vpnc plugin uses vpnc client \ |
194 | to create a VPN connection to Cisco3000 VPN Concentrator." | 204 | to create a VPN connection to Cisco3000 VPN Concentrator." |
195 | FILES_${PN}-plugin-vpn-vpnc += "${libdir}/connman/scripts/openconnect-script \ | 205 | FILES:${PN}-plugin-vpn-vpnc += "${libdir}/connman/scripts/openconnect-script \ |
196 | ${libdir}/connman/plugins-vpn/vpnc.so \ | 206 | ${libdir}/connman/plugins-vpn/vpnc.so \ |
197 | ${libdir}/connman/scripts/vpn-script" | 207 | ${libdir}/connman/scripts/vpn-script" |
198 | RDEPENDS_${PN}-plugin-vpn-vpnc += "${PN}-vpn" | 208 | RDEPENDS:${PN}-plugin-vpn-vpnc += "${PN}-vpn" |
199 | RRECOMMENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG','vpnc','${PN}-plugin-vpn-vpnc', '', d)}" | 209 | RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','vpnc','${PN}-plugin-vpn-vpnc', '', d)}" |
200 | 210 | ||
201 | SUMMARY_${PN}-plugin-vpn-l2tp = "A L2TP plugin for ConnMan VPN" | 211 | SUMMARY:${PN}-plugin-vpn-l2tp = "A L2TP plugin for ConnMan VPN" |
202 | DESCRIPTION_${PN}-plugin-vpn-l2tp = "The ConnMan L2TP plugin uses xl2tpd daemon \ | 212 | DESCRIPTION:${PN}-plugin-vpn-l2tp = "The ConnMan L2TP plugin uses xl2tpd daemon \ |
203 | to create a VPN connection to L2TP server." | 213 | to create a VPN connection to L2TP server." |
204 | FILES_${PN}-plugin-vpn-l2tp += "${libdir}/connman/scripts/libppp-plugin.so* \ | 214 | FILES:${PN}-plugin-vpn-l2tp += "${libdir}/connman/scripts/libppp-plugin.so* \ |
205 | ${libdir}/connman/plugins-vpn/l2tp.so" | 215 | ${libdir}/connman/plugins-vpn/l2tp.so" |
206 | RDEPENDS_${PN}-plugin-vpn-l2tp += "${PN}-vpn" | 216 | RDEPENDS:${PN}-plugin-vpn-l2tp += "${PN}-vpn" |
207 | RRECOMMENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG','l2tp','${PN}-plugin-vpn-l2tp', '', d)}" | 217 | RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','l2tp','${PN}-plugin-vpn-l2tp', '', d)}" |
208 | 218 | ||
209 | SUMMARY_${PN}-plugin-vpn-pptp = "A PPTP plugin for ConnMan VPN" | 219 | SUMMARY:${PN}-plugin-vpn-pptp = "A PPTP plugin for ConnMan VPN" |
210 | DESCRIPTION_${PN}-plugin-vpn-pptp = "The ConnMan PPTP plugin uses pptp-linux client \ | 220 | DESCRIPTION:${PN}-plugin-vpn-pptp = "The ConnMan PPTP plugin uses pptp-linux client \ |
211 | to create a VPN connection to PPTP server." | 221 | to create a VPN connection to PPTP server." |
212 | FILES_${PN}-plugin-vpn-pptp += "${libdir}/connman/scripts/libppp-plugin.so* \ | 222 | FILES:${PN}-plugin-vpn-pptp += "${libdir}/connman/scripts/libppp-plugin.so* \ |
213 | ${libdir}/connman/plugins-vpn/pptp.so" | 223 | ${libdir}/connman/plugins-vpn/pptp.so" |
214 | RDEPENDS_${PN}-plugin-vpn-pptp += "${PN}-vpn" | 224 | RDEPENDS:${PN}-plugin-vpn-pptp += "${PN}-vpn" |
215 | RRECOMMENDS_${PN} += "${@bb.utils.contains('PACKAGECONFIG','pptp','${PN}-plugin-vpn-pptp', '', d)}" | 225 | RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','pptp','${PN}-plugin-vpn-pptp', '', d)}" |