aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAric Belsito <lluixhi@gmail.com>2016-12-06 12:30:05 -0800
committerAric Belsito <lluixhi@gmail.com>2016-12-06 12:31:39 -0800
commit4502ed13d5cfad697d0d0da9f163e7460ff4b197 (patch)
tree03cb11bc231ddb57a159730335884e644792409b /net-misc/connman
parentmedia-sound/sox: Add current version (diff)
downloadmusl-4502ed13d5cfad697d0d0da9f163e7460ff4b197.tar.gz
musl-4502ed13d5cfad697d0d0da9f163e7460ff4b197.tar.bz2
musl-4502ed13d5cfad697d0d0da9f163e7460ff4b197.zip
net-misc/connman: Add stable and unstable version
Diffstat (limited to 'net-misc/connman')
-rw-r--r--net-misc/connman/Manifest16
-rw-r--r--net-misc/connman/connman-1.29.ebuild82
-rw-r--r--net-misc/connman/connman-1.33-r1.ebuild86
-rw-r--r--net-misc/connman/files/connman-1.29-musl-sockaddr.patch12
-rw-r--r--net-misc/connman/files/connman-1.31-xtables.patch54
-rw-r--r--net-misc/connman/files/connman-1.32-execinfo.patch27
-rw-r--r--net-misc/connman/files/connman-1.33-polkit-configure-check-fix.patch15
-rw-r--r--net-misc/connman/files/connman-1.33-resolv-conf-overwrite.patch6
-rw-r--r--net-misc/connman/files/connman-musl-libresolv.patch61
-rw-r--r--net-misc/connman/files/connman-musl-log.patch29
-rw-r--r--net-misc/connman/files/connman-musl.patch125
-rw-r--r--net-misc/connman/files/connman.confd15
-rw-r--r--net-misc/connman/files/connman.initd223
-rw-r--r--net-misc/connman/files/connman.service11
-rw-r--r--net-misc/connman/metadata.xml28
15 files changed, 590 insertions, 0 deletions
diff --git a/net-misc/connman/Manifest b/net-misc/connman/Manifest
new file mode 100644
index 00000000..36d63099
--- /dev/null
+++ b/net-misc/connman/Manifest
@@ -0,0 +1,16 @@
+AUX connman-1.29-musl-sockaddr.patch 527 SHA256 b180623f996e7f2c0dc053092fd1a00d51c3ac3ebc500bc282b338f69e94a3a2 SHA512 efde44cbd50d4eea4d87fe4bef0501920d6724de392838561cc04492d0525818754b94a1245a03639c34696b08e5b7f5bd5975c9f183416e208a3095c6d2d60a WHIRLPOOL 687d4c218aea253c56e05db092f75674edfd8341c7757a154784aa1aa41a9bedf4f8a87acbc9cbb3f1393d3a43f63f886ac5e3b478aa94bafa0235bcdf53d4c3
+AUX connman-1.31-xtables.patch 1367 SHA256 bcd01d1051bb7979a3a9f098bdbb027b3bd243f2e24a404bb57f1d62742c4108 SHA512 681615666a535fe0a60f1472768f63ecfadd974e2a39d38b1e229be00449d0acd24902fb674f6b6567bb0915c5b59adc0d76d5b886d50d59c776b239ecbb7c4d WHIRLPOOL 7b97159120f0bae83b5791a63c84bf1ce4b04a36f732f405af4dd57c5a0a70168226802cedc57c2f9f57e9e24f0fcf6d8b3e625dd5b055adad6cb20bbd6e6c17
+AUX connman-1.32-execinfo.patch 685 SHA256 2c58d60f2349648925e20cd9c2ff949dea9136e983c6a152115e581f5a0c0eab SHA512 b646dc610f2f1aa20ecadae293289e6c2fb1fc55c80b457a3230291112bf9700da620cb02267c1235b99b9eccc840d978a4392cbf51149982e9ce43bd18ff09c WHIRLPOOL db7f666230c5184dc08a339f38689927c8e9dad9858d77ce202255562046b7fc8de7f7714281b3245ad645260fdad1855856cce7696712c1561489f66da91a0f
+AUX connman-1.33-polkit-configure-check-fix.patch 665 SHA256 fb8397d2819948bbf2d72b231e7e74464c42fb9b4fa3face544a174ce4be7d59 SHA512 630ac9d147046f084a960795de87183c5c446006df7a6a74c02416e972a3bd55390e1ab9c3f0ea4449324d0fb7c271ebd6b64727ede834128ca8515853a9e905 WHIRLPOOL 179d83d01ccfedfcbfbdd6f8e425627fb865b4d4b2bfd1813af0950152bb922860fcb3b79047cf126d506eca36abc165d8df4dceb9ddd3e7ac719a6393283910
+AUX connman-1.33-resolv-conf-overwrite.patch 354 SHA256 97685a61de4081369a6422ba2cfe3a03dee3d2a8c4237c9016ea7ba35ba8d8dc SHA512 1998d0d2923f8dca3706c7c75ad87ffa2570a785ed3e5ec1c85cc539bbfb7ea9173dae5320c3f95fbeee9c9c72870607b8eb4b3fd2c36a1962ad8925d72e24e2 WHIRLPOOL 2429f8333d6f72197de3cfd7e6b752e5726d43c0bff84c264f82948724c1c3e28a978f133f126add5bd1cc6540588672413d00ecd01d6aa58ebebb80301cc49e
+AUX connman-musl-libresolv.patch 1554 SHA256 6a36a7d85d12d5ce927c741ca41ddb40a4eb5351dd0112cebc93134113641edb SHA512 c258e747e13b86c81ae96ac1743abf0c1461b9053c5b386d594a49f0b1890f10d89bea92610762ff609a4cc5fea04a43fab83894702f552b05af400f01cb011e WHIRLPOOL 0711be03da3573f39c4b8cd9d9752211c812a08afa4aa18cab164b3d78797703f709debdb95f4823e365439a1764e935a3e331a5b6a16b98f25080e92da923af
+AUX connman-musl-log.patch 661 SHA256 28fde16e9269239c1fde75ad518a2ee6afa2eef50bf48b266a331afff98e3514 SHA512 b0497136998034a119dd884d4a00dcde126b348b8c05fb5a5bc2c28b5d1199d5e2db5d935afb8236beb1e1c1d97870c89becd2545b3af1d4ec46790d881b321b WHIRLPOOL 49be9f8e931e277778fb8182df3991d42e455c38832450340d3d575fb370f56616a30f343ad49b7c6e5aad76ea2f5cd459f4d128490eb80acd5dbe49c17e14a8
+AUX connman-musl.patch 4198 SHA256 9643e6098f98d11c6cb9f8de30c83b52edec853bbd70dc05d73773f8e60988f8 SHA512 75a6f94ae701c7f6a1d76bd1311fc2a521a532f97dcc101bf9671b2bd93d5e0d509a92c499138304dcd74ee0a55531b50b3bbaaf9704a250dbc964a4a882dd92 WHIRLPOOL 7281c454f1785f59fae24db9b8a3200a33638da54278b0965eed9c1f12a369cf78cca3d3bc2d51c6a32ffcc5e40532422eb83f67ad9ef962cebec760c44aaada
+AUX connman.confd 728 SHA256 767a160c1b3392f0a12d3908a937548a2f604a9a121e744c309ee6f478420b02 SHA512 820511a1fa04ff2c07a26dd3c74c846e3a710e6d6b44c4adaa782f55c9818afd3b935ed30bf2dc287e54e924128c2c1d02b6c4c89b5b5b7d07a7f590d9963969 WHIRLPOOL 06098d2fcc27c1bf7dcf73167273cea5e83cc6a4bd5b4ce369974b7295fef6a8c268ea1f548b958c35a569c9c0634cb8ba1c1bc6386d02d02abb76ac396d385a
+AUX connman.initd2 490 SHA256 c4c21edcf04d7ce873a8075675b44af823175b133b41d2056ed9d1ea4c637c3f SHA512 73fa3e30c621efd57a78e9f28bdde1cd34c4bb938d027789a5e9ec32cb83443a3d1a9ef1eec21176bc795128050a41c196529321f6991ea83bec45c6fa00d651 WHIRLPOOL ad09083769e64efcc1b4ea22ce43779c61cbd39442b63cb61782e870b140d8ae09a6e7addc48d16260843bc014f4ad4e8142b86f876f4053c316b71480633925
+AUX connman.service 198 SHA256 746a4cb3d4a7083b3165dd69285df4a3f85ec5fd4556d805428b1c13dcd8f0d2 SHA512 a769961922c40b5ed3e5a09d08262b20b84aa27fc278678063b348431ba2976de9f2ebcd9f9b0afa6241540d255ba4cdf7120b75184510d41444b7dd3209b825 WHIRLPOOL 6c91e3fe0045eec718328c5eed31d6109485c41c46ebadf392ecad3c41e97d19e5430b3eaead45844e2364cb3fa9aad2aa904b2b345657f0531c4fc51ea294aa
+DIST connman-1.29.tar.xz 653324 SHA256 2a5a69693566f7fd59b2e677fa89356ada6d709998aa665caef8707b1e7a8594 SHA512 19f623dd23c6312f29bbd570dcb22d31154ffcd16ee66ed2280df3d9d844301f18538418363222d99eabdc33da0021488ed66ba2e4f88df30646004b724538ee WHIRLPOOL 9439cadeb20b72c922b1426da213f8567fe7b0da45f9a4abf270c38687a9d9161a8ee14250623344864d612e130e6f28926918468aaf4346a9e5ff41e6ad22bb
+DIST connman-1.33.tar.xz 669800 SHA256 bc8946036fa70124d663136f9f6b6238d897ca482782df907b07a428b09df5a0 SHA512 5670124d2e17ffde4bd5fb878198843b712a31f5840e8523e8247373c8547619e32a4d6dda9cf993eebd5c65bdd256cfc570708a79da1d10f969662b5b750566 WHIRLPOOL eda8176d0d6137b0b94581c9ace23367d7af5722b7d7ea53e173e9466b555f26c9a18a05a07c1533ab11e3197e4303c6c77685a214c3dec2de926d7924f019f2
+EBUILD connman-1.29.ebuild 2173 SHA256 b19090a2ecf61e56b11162fc1a7973903afa945761025e4eec95358dbcf9358c SHA512 41a90f46ef63f193ce1ef259aa8f2bf71d33c091d9344a72d751617d495eaf546cf2ba7182ca5c0e4478eeda78637b3b828c8f1ddd165389bbeac17517b03651 WHIRLPOOL 9ccea17bf40c3ada4418bdcbd56ffd751d0fb8a1587306404034fcfddc5eed46541f2255bde7e9c48368cf7ac5ac7dbc276dad99c7b25054105e452d05e26db8
+EBUILD connman-1.33-r1.ebuild 2346 SHA256 d13e25057bb764f699370f1d6c2308ec04bf722694f91efb8472ef02f5032007 SHA512 9b06ee9862fd024fcc91a4ac5e60648d603edf99f22e9c012bca41034784a1c38b0e7509e8d882c0aaa5d2bb54b7d78a199eecd2db12e56f7921e73108f1fb71 WHIRLPOOL 48535a3a4dc5f7a089eec0faddf0ce27f1b57cfb1b0a4bd4db815ece22742aa15cfd56b0f052ea832f74f2b174fcbcf9cf2cedebd055aa60362b303d9d60fc0e
+MISC metadata.xml 1209 SHA256 10c18254d687356bf3f67d888e3e3dbdf17992ec053262892f4ac952f0803b1e SHA512 ff0a18cb3529be65ff2f838d3e9f56a2e54359d72cc0bddb8f9df5d57a2453ac24cb2905844bce189d6b23bc933b526183e338b7c81115922db16c542ec8829e WHIRLPOOL 865b7aa5b5ed8ee7327e975eb6a342508b4733750f7b831dff27b5dff4cfb2957238ca15d992aadde9dcc574acdd390509eb81516fe7ce3ff9efb89732bc5129
diff --git a/net-misc/connman/connman-1.29.ebuild b/net-misc/connman/connman-1.29.ebuild
new file mode 100644
index 00000000..45660d36
--- /dev/null
+++ b/net-misc/connman/connman-1.29.ebuild
@@ -0,0 +1,82 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+inherit autotools base systemd
+
+DESCRIPTION="Provides a daemon for managing internet connections"
+HOMEPAGE="https://01.org/connman"
+SRC_URI="mirror://kernel/linux/network/${PN}/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 arm ppc ppc64 x86"
+IUSE="bluetooth debug doc examples +ethernet l2tp ofono openvpn openconnect pptp policykit tools vpnc +wifi wispr"
+
+RDEPEND=">=dev-libs/glib-2.16
+ >=sys-apps/dbus-1.2.24
+ >=net-firewall/iptables-1.4.8
+ bluetooth? ( net-wireless/bluez )
+ l2tp? ( net-dialup/xl2tpd )
+ ofono? ( net-misc/ofono )
+ openconnect? ( net-misc/openconnect )
+ openvpn? ( net-misc/openvpn )
+ policykit? ( sys-auth/polkit )
+ pptp? ( net-dialup/pptpclient )
+ vpnc? ( net-misc/vpnc )
+ wifi? ( >=net-wireless/wpa_supplicant-2.0[dbus] )
+ wispr? ( net-libs/gnutls )"
+
+DEPEND="${RDEPEND}
+ >=sys-kernel/linux-headers-2.6.39"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-musl.patch"
+ "${FILESDIR}/${PN}-musl-log.patch"
+ "${FILESDIR}/${PN}-musl-libresolv.patch"
+ "${FILESDIR}/${P}-musl-sockaddr.patch"
+)
+
+src_prepare() {
+ default
+
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ --localstatedir=/var \
+ --enable-client \
+ --enable-datafiles \
+ --enable-loopback=builtin \
+ $(use_enable examples test) \
+ $(use_enable ethernet ethernet builtin) \
+ $(use_enable wifi wifi builtin) \
+ $(use_enable bluetooth bluetooth builtin) \
+ $(use_enable l2tp l2tp builtin) \
+ $(use_enable ofono ofono builtin) \
+ $(use_enable openconnect openconnect builtin) \
+ $(use_enable openvpn openvpn builtin) \
+ $(use_enable policykit polkit builtin) \
+ $(use_enable pptp pptp builtin) \
+ $(use_enable vpnc vpnc builtin) \
+ $(use_enable wispr wispr builtin) \
+ $(use_enable debug) \
+ $(use_enable tools) \
+ --disable-iospm \
+ --disable-hh2serial-gps
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ dobin client/connmanctl || die "client installation failed"
+
+ if use doc; then
+ dodoc doc/*.txt
+ fi
+ keepdir /var/lib/${PN}
+ newinitd "${FILESDIR}"/${PN}.initd2 ${PN}
+ newconfd "${FILESDIR}"/${PN}.confd ${PN}
+ systemd_dounit "${FILESDIR}"/connman.service
+}
diff --git a/net-misc/connman/connman-1.33-r1.ebuild b/net-misc/connman/connman-1.33-r1.ebuild
new file mode 100644
index 00000000..a3b0739f
--- /dev/null
+++ b/net-misc/connman/connman-1.33-r1.ebuild
@@ -0,0 +1,86 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="6"
+inherit autotools systemd
+
+DESCRIPTION="Provides a daemon for managing internet connections"
+HOMEPAGE="https://01.org/connman"
+SRC_URI="mirror://kernel/linux/network/${PN}/${P}.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86"
+IUSE="bluetooth debug doc examples +ethernet l2tp ofono openvpn openconnect pptp policykit tools vpnc +wifi wispr"
+
+RDEPEND=">=dev-libs/glib-2.16
+ >=sys-apps/dbus-1.2.24
+ >=net-firewall/iptables-1.4.8
+ bluetooth? ( net-wireless/bluez )
+ l2tp? ( net-dialup/xl2tpd )
+ ofono? ( net-misc/ofono )
+ openconnect? ( net-misc/openconnect )
+ openvpn? ( net-misc/openvpn )
+ policykit? ( sys-auth/polkit )
+ pptp? ( net-dialup/pptpclient )
+ vpnc? ( net-misc/vpnc )
+ wifi? ( >=net-wireless/wpa_supplicant-2.0[dbus] )
+ wispr? ( net-libs/gnutls )"
+
+DEPEND="${RDEPEND}
+ >=sys-kernel/linux-headers-2.6.39
+ virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-musl.patch"
+ "${FILESDIR}/${PN}-1.32-execinfo.patch"
+ "${FILESDIR}/${PN}-musl-libresolv.patch"
+ "${FILESDIR}/${PN}-1.31-xtables.patch"
+ "${FILESDIR}/${PN}-1.33-polkit-configure-check-fix.patch"
+ "${FILESDIR}/${PN}-1.33-resolv-conf-overwrite.patch"
+)
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ --localstatedir=/var \
+ --with-systemdunitdir=$(systemd_get_systemunitdir) \
+ --with-tmpfilesdir=${EPREFIX}/usr/lib/tmpfiles.d \
+ --enable-client \
+ --enable-datafiles \
+ --enable-loopback=builtin \
+ $(use_enable examples test) \
+ $(use_enable ethernet ethernet builtin) \
+ $(use_enable wifi wifi builtin) \
+ $(use_enable bluetooth bluetooth builtin) \
+ $(use_enable l2tp l2tp builtin) \
+ $(use_enable ofono ofono builtin) \
+ $(use_enable openconnect openconnect builtin) \
+ $(use_enable openvpn openvpn builtin) \
+ $(use_enable policykit polkit builtin) \
+ $(use_enable pptp pptp builtin) \
+ $(use_enable vpnc vpnc builtin) \
+ $(use_enable wispr wispr builtin) \
+ $(use_enable debug) \
+ $(use_enable tools) \
+ --disable-iospm \
+ --disable-hh2serial-gps
+}
+
+src_install() {
+ default
+ dobin client/connmanctl
+
+ if use doc; then
+ dodoc doc/*.txt
+ fi
+ keepdir /usr/lib/${PN}/scripts
+ keepdir /var/lib/${PN}
+ newinitd "${FILESDIR}"/${PN}.initd2 ${PN}
+ newconfd "${FILESDIR}"/${PN}.confd ${PN}
+}
diff --git a/net-misc/connman/files/connman-1.29-musl-sockaddr.patch b/net-misc/connman/files/connman-1.29-musl-sockaddr.patch
new file mode 100644
index 00000000..a5eb6905
--- /dev/null
+++ b/net-misc/connman/files/connman-1.29-musl-sockaddr.patch
@@ -0,0 +1,12 @@
+diff -Naurw connman-1.29.orig/src/ntp.c connman-1.29/src/ntp.c
+--- connman-1.29.orig/src/ntp.c 2014-12-13 01:23:18.000000000 +0000
++++ connman-1.29/src/ntp.c 2015-08-12 16:17:19.636686053 +0000
+@@ -180,7 +180,7 @@
+ msg.xmttime.fraction = htonl(transmit_timeval.tv_usec * 1000);
+
+ len = sendto(fd, &msg, sizeof(msg), MSG_DONTWAIT,
+- &addr, sizeof(addr));
++ (struct sockaddr *) &addr, sizeof(addr));
+ if (len < 0) {
+ connman_error("Time request for server %s failed (%d/%s)",
+ server, errno, strerror(errno));
diff --git a/net-misc/connman/files/connman-1.31-xtables.patch b/net-misc/connman/files/connman-1.31-xtables.patch
new file mode 100644
index 00000000..84f4445e
--- /dev/null
+++ b/net-misc/connman/files/connman-1.31-xtables.patch
@@ -0,0 +1,54 @@
+--- connman-1.31/src/iptables.c.old 2016-03-22 20:12:47.829460752 -0700
++++ connman-1.31/src/iptables.c 2016-03-22 21:33:36.835384724 -0700
+@@ -28,11 +28,11 @@
+ #include <stdio.h>
+ #include <string.h>
+ #include <unistd.h>
+ #include <sys/errno.h>
+ #include <sys/socket.h>
+-#include <xtables.h>
++#include "connman_xtables.h"
+ #include <inttypes.h>
+
+ #include <linux/netfilter_ipv4/ip_tables.h>
+
+ #include "connman.h"
+--- connman-1.31/src/firewall.c.old 2016-03-22 21:29:01.959472262 -0700
++++ connman-1.31/src/firewall.c 2016-03-22 21:33:53.048144181 -0700
+@@ -23,11 +23,11 @@
+ #include <config.h>
+ #endif
+
+ #include <errno.h>
+
+-#include <xtables.h>
++#include "connman_xtables.h"
+ #include <linux/netfilter_ipv4/ip_tables.h>
+
+ #include "connman.h"
+
+ #define CHAIN_PREFIX "connman-"
+--- /dev/null 2016-03-18 06:21:16.372989086 -0700
++++ connman-1.31/include/connman_xtables.h 2016-03-22 21:32:21.349504786 -0700
+@@ -0,0 +1,21 @@
++#ifndef CONNMAN_XTABLES_H
++#define CONNMAN_XTABLES_H
++
++#include <linux/version.h>
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 5, 0) || \
++ LINUX_VERSION_CODE >= KERNEL_VERSION(4, 6, 0)
++#include <xtables.h>
++#else
++#ifdef __USE_MISC
++#define GENTOO_USE_MISC __USE_MISC
++#undef __USE_MISC
++#endif
++
++#include <xtables.h>
++
++#ifdef GENTOO_USE_MISC
++#define __USE_MISC GENTOO_USE_MISC
++#undef GENTOO_USE_MISC
++#endif
++#endif
++#endif
diff --git a/net-misc/connman/files/connman-1.32-execinfo.patch b/net-misc/connman/files/connman-1.32-execinfo.patch
new file mode 100644
index 00000000..66f91602
--- /dev/null
+++ b/net-misc/connman/files/connman-1.32-execinfo.patch
@@ -0,0 +1,27 @@
+diff -Naur connman-1.32/src/backtrace.c connman-1.32.new/src/backtrace.c
+--- connman-1.32/src/backtrace.c 2016-04-18 00:04:30.000000000 -0700
++++ connman-1.32.new/src/backtrace.c 2016-06-17 13:55:08.257320750 -0700
+@@ -29,7 +29,9 @@
+ #include <unistd.h>
+ #include <stdlib.h>
+ #include <string.h>
++#ifdef HAVE_EXECINFO_H
+ #include <execinfo.h>
++#endif
+ #include <dlfcn.h>
+
+ #include "connman.h"
+@@ -37,6 +39,7 @@
+ void print_backtrace(const char* program_path, const char* program_exec,
+ unsigned int offset)
+ {
++#ifdef HAVE_EXECINFO_H
+ void *frames[99];
+ size_t n_ptrs;
+ unsigned int i;
+@@ -135,4 +138,5 @@
+
+ close(outfd[1]);
+ close(infd[0]);
++#endif /* HAVE_EXECINFO_H */
+ }
diff --git a/net-misc/connman/files/connman-1.33-polkit-configure-check-fix.patch b/net-misc/connman/files/connman-1.33-polkit-configure-check-fix.patch
new file mode 100644
index 00000000..57ef5e8c
--- /dev/null
+++ b/net-misc/connman/files/connman-1.33-polkit-configure-check-fix.patch
@@ -0,0 +1,15 @@
+--- connman-1.33/configure.ac.old 2016-10-09 11:26:43.137856416 -0700
++++ connman-1.33/configure.ac 2016-10-09 11:26:52.819722799 -0700
+@@ -281,11 +281,11 @@ AM_CONDITIONAL(NMCOMPAT, test "${enable_
+
+ AC_ARG_ENABLE(polkit, AC_HELP_STRING([--enable-polkit],
+ [enable PolicyKit support]),
+ [enable_polkit=${enableval}], [enable_polkit="no"])
+ if (test "${enable_polkit}" != "no"); then
+- POLKIT_DATADIR="`$PKG_CONFIG --variable=actiondir polkit`"
++ POLKIT_DATADIR="`$PKG_CONFIG --variable=actiondir polkit-gobject-1`"
+ POLKIT_DATADIR=""
+ if (test -z "${POLKIT_DATADIR}"); then
+ POLKIT_DATADIR="${datadir}/polkit-1/actions"
+ fi
+ AC_SUBST(POLKIT_DATADIR)
diff --git a/net-misc/connman/files/connman-1.33-resolv-conf-overwrite.patch b/net-misc/connman/files/connman-1.33-resolv-conf-overwrite.patch
new file mode 100644
index 00000000..49bb8ba3
--- /dev/null
+++ b/net-misc/connman/files/connman-1.33-resolv-conf-overwrite.patch
@@ -0,0 +1,6 @@
+--- connman-1.33/scripts/connman_resolvconf.conf.in.old 2016-10-09 11:27:20.425341843 -0700
++++ connman-1.33/scripts/connman_resolvconf.conf.in 2016-10-09 11:27:10.662476565 -0700
+@@ -1,2 +1,2 @@
+ d @runstatedir@/connman - - - -
+-L+ /etc/resolv.conf - - - - @runstatedir@/connman/resolv.conf
++L /etc/resolv.conf - - - - @runstatedir@/connman/resolv.conf
diff --git a/net-misc/connman/files/connman-musl-libresolv.patch b/net-misc/connman/files/connman-musl-libresolv.patch
new file mode 100644
index 00000000..c28a7c1e
--- /dev/null
+++ b/net-misc/connman/files/connman-musl-libresolv.patch
@@ -0,0 +1,61 @@
+musl does not implement res_ninit
+
+diff --exclude '*.*o' -ru connman-1.24.orig/gweb/gresolv.c connman-1.24/gweb/gresolv.c
+--- connman-1.24.orig/gweb/gresolv.c 2014-07-18 20:17:25.000000000 -0300
++++ connman-1.24/gweb/gresolv.c 2014-07-18 20:24:01.874669130 -0300
+@@ -874,8 +874,6 @@
+ resolv->index = index;
+ resolv->nameserver_list = NULL;
+
+- res_ninit(&resolv->res);
+-
+ return resolv;
+ }
+
+@@ -915,8 +913,6 @@
+
+ flush_nameservers(resolv);
+
+- res_nclose(&resolv->res);
+-
+ g_free(resolv);
+ }
+
+@@ -1019,24 +1015,19 @@
+ debug(resolv, "hostname %s", hostname);
+
+ if (!resolv->nameserver_list) {
+- int i;
+-
+- for (i = 0; i < resolv->res.nscount; i++) {
+- char buf[100];
+- int family = resolv->res.nsaddr_list[i].sin_family;
+- void *sa_addr = &resolv->res.nsaddr_list[i].sin_addr;
+-
+- if (family != AF_INET &&
+- resolv->res._u._ext.nsaddrs[i]) {
+- family = AF_INET6;
+- sa_addr = &resolv->res._u._ext.nsaddrs[i]->sin6_addr;
++ FILE *f = fopen("/etc/resolv.conf", "r");
++ if (f) {
++ char line[256], *s;
++ int i;
++ while (fgets(line, sizeof(line), f)) {
++ if (strncmp(line, "nameserver", 10) || !isspace(line[10]))
++ continue;
++ for (s = &line[11]; isspace(s[0]); s++);
++ for (i = 0; s[i] && !isspace(s[i]); i++);
++ s[i] = 0;
++ g_resolv_add_nameserver(resolv, s, 53, 0);
+ }
+-
+- if (family != AF_INET && family != AF_INET6)
+- continue;
+-
+- if (inet_ntop(family, sa_addr, buf, sizeof(buf)))
+- g_resolv_add_nameserver(resolv, buf, 53, 0);
++ fclose(f);
+ }
+
+ if (!resolv->nameserver_list)
+
diff --git a/net-misc/connman/files/connman-musl-log.patch b/net-misc/connman/files/connman-musl-log.patch
new file mode 100644
index 00000000..42516c92
--- /dev/null
+++ b/net-misc/connman/files/connman-musl-log.patch
@@ -0,0 +1,29 @@
+diff -Naurw connman-1.31.orig/src/log.c connman-1.31/src/log.c
+--- connman-1.31.orig/src/log.c 2014-04-04 05:12:07.000000000 -0700
++++ connman-1.31/src/log.c 2016-02-01 11:25:11.137973207 -0800
+@@ -30,7 +30,9 @@
+ #include <stdlib.h>
+ #include <string.h>
+ #include <syslog.h>
++#ifdef HAVE_EXECINFO_H
+ #include <execinfo.h>
++#endif
+ #include <dlfcn.h>
+
+ #include "connman.h"
+@@ -112,6 +114,7 @@
+
+ static void print_backtrace(unsigned int offset)
+ {
++#ifdef HAVE_EXECINFO_H
+ void *frames[99];
+ size_t n_ptrs;
+ unsigned int i;
+@@ -210,6 +213,7 @@
+
+ close(outfd[1]);
+ close(infd[0]);
++#endif /* HAVE_EXECINFO_H */
+ }
+
+ static void signal_handler(int signo)
diff --git a/net-misc/connman/files/connman-musl.patch b/net-misc/connman/files/connman-musl.patch
new file mode 100644
index 00000000..18f40870
--- /dev/null
+++ b/net-misc/connman/files/connman-musl.patch
@@ -0,0 +1,125 @@
+diff -Naurw connman-1.31.orig/configure.ac connman-1.31/configure.ac
+--- connman-1.31.orig/configure.ac 2015-12-27 19:05:49.000000000 -0800
++++ connman-1.31/configure.ac 2016-02-01 11:22:09.576978370 -0800
+@@ -175,6 +175,8 @@
+ AM_CONDITIONAL(PPTP, test "${enable_pptp}" != "no")
+ AM_CONDITIONAL(PPTP_BUILTIN, test "${enable_pptp}" = "builtin")
+
++AC_CHECK_MEMBERS([struct in6_pktinfo.ipi6_addr], [], [], [[#include <netinet/in.h>]])
++AC_CHECK_HEADERS(execinfo.h)
+ AC_CHECK_HEADERS(resolv.h, dummy=yes,
+ AC_MSG_ERROR(resolver header files are required))
+ AC_CHECK_LIB(resolv, ns_initparse, dummy=yes, [
+diff -Naurw connman-1.31.orig/gdhcp/common.c connman-1.31/gdhcp/common.c
+--- connman-1.31.orig/gdhcp/common.c 2015-04-19 15:16:21.000000000 -0700
++++ connman-1.31/gdhcp/common.c 2016-02-01 11:22:46.169977330 -0800
+@@ -22,6 +22,7 @@
+ #include <config.h>
+ #endif
+
++#define _GNU_SOURCE
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <errno.h>
+@@ -31,7 +32,6 @@
+ #include <string.h>
+ #include <endian.h>
+ #include <net/if_arp.h>
+-#include <linux/if.h>
+ #include <netpacket/packet.h>
+ #include <net/ethernet.h>
+ #include <arpa/inet.h>
+@@ -40,6 +40,8 @@
+ #include "gdhcp.h"
+ #include "common.h"
+
++#include <linux/if.h>
++
+ static const DHCPOption client_options[] = {
+ { OPTION_IP, 0x01 }, /* subnet-mask */
+ { OPTION_IP | OPTION_LIST, 0x03 }, /* routers */
+diff -Naurw connman-1.31.orig/gdhcp/common.h connman-1.31/gdhcp/common.h
+--- connman-1.31.orig/gdhcp/common.h 2015-04-19 15:16:21.000000000 -0700
++++ connman-1.31/gdhcp/common.h 2016-02-01 11:29:53.731965170 -0800
+@@ -18,6 +18,9 @@
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
++#ifdef HAVE_CONFIG_H
++#include <config.h>
++#endif
+
+ #include <netinet/udp.h>
+ #include <netinet/ip.h>
+@@ -170,8 +173,8 @@
+ [OPTION_U32] = 4,
+ };
+
+-/* already defined within netinet/in.h if using GNU compiler */
+-#ifndef __USE_GNU
++/* already defined within netinet/in.h if using GNU compiler or musl libc */
++#ifndef HAVE_STRUCT_IN6_PKTINFO_IPI6_ADDR
+ struct in6_pktinfo {
+ struct in6_addr ipi6_addr; /* src/dst IPv6 address */
+ unsigned int ipi6_ifindex; /* send/recv interface index */
+diff -Naurw connman-1.31.orig/gweb/gresolv.c connman-1.31/gweb/gresolv.c
+--- connman-1.31.orig/gweb/gresolv.c 2014-04-04 05:12:07.000000000 -0700
++++ connman-1.31/gweb/gresolv.c 2016-02-01 11:27:46.207968797 -0800
+@@ -24,6 +24,7 @@
+ #endif
+
+ #include <errno.h>
++#include <stdio.h>
+ #include <unistd.h>
+ #include <stdarg.h>
+ #include <string.h>
+diff -Naurw connman-1.31.orig/plugins/wifi.c connman-1.31/plugins/wifi.c
+--- connman-1.31.orig/plugins/wifi.c 2015-12-27 19:05:49.000000000 -0800
++++ connman-1.31/plugins/wifi.c 2016-02-01 11:25:59.192971840 -0800
+@@ -30,9 +30,8 @@
+ #include <string.h>
+ #include <sys/ioctl.h>
+ #include <sys/socket.h>
+-#include <linux/if_arp.h>
+-#include <linux/wireless.h>
+ #include <net/ethernet.h>
++#include <linux/wireless.h>
+
+ #ifndef IFF_LOWER_UP
+ #define IFF_LOWER_UP 0x10000
+diff -Naurw connman-1.31.orig/src/tethering.c connman-1.31/src/tethering.c
+--- connman-1.31.orig/src/tethering.c 2015-12-27 19:05:49.000000000 -0800
++++ connman-1.31/src/tethering.c 2016-02-01 11:26:50.049970394 -0800
+@@ -31,10 +31,8 @@
+ #include <stdio.h>
+ #include <sys/ioctl.h>
+ #include <net/if.h>
+-#include <linux/sockios.h>
+ #include <string.h>
+ #include <fcntl.h>
+-#include <linux/if_tun.h>
+ #include <netinet/in.h>
+ #include <linux/if_bridge.h>
+
+diff -Naurw connman-1.31.orig/tools/dhcp-test.c connman-1.31/tools/dhcp-test.c
+--- connman-1.31.orig/tools/dhcp-test.c 2013-08-19 09:57:25.000000000 -0700
++++ connman-1.31/tools/dhcp-test.c 2016-02-01 11:25:21.907972901 -0800
+@@ -33,7 +33,6 @@
+ #include <arpa/inet.h>
+ #include <net/route.h>
+ #include <net/ethernet.h>
+-#include <linux/if_arp.h>
+
+ #include <gdhcp/gdhcp.h>
+
+diff -Naurw connman-1.31.orig/tools/dnsproxy-test.c connman-1.31/tools/dnsproxy-test.c
+--- connman-1.31.orig/tools/dnsproxy-test.c 2013-12-04 23:12:12.000000000 -0800
++++ connman-1.31/tools/dnsproxy-test.c 2016-02-01 11:27:04.525969982 -0800
+@@ -24,6 +24,7 @@
+ #endif
+
+ #include <errno.h>
++#include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+ #include <unistd.h>
diff --git a/net-misc/connman/files/connman.confd b/net-misc/connman/files/connman.confd
new file mode 100644
index 00000000..6d0c399e
--- /dev/null
+++ b/net-misc/connman/files/connman.confd
@@ -0,0 +1,15 @@
+# conf.d file for connman
+#
+# Please check connmand --help for more information.
+# Useful options are:
+# -c, --compat: enable NetworkManager compatibility mode.
+# -W, --wifi=NAME: select wpa_supplicant wifi driver to use.
+# This is useful if your wpa_supplicant is < 0.7
+# since connmand by default gives wpa_supplicant a
+# comma separated list of values and < 0.7 does not
+# understand or accept it.
+# -i, --device=DEV: force use of given interface name.
+# -I, --nodevice=DEV: force ignore of given interface name.
+# -p, --plugin=NAME: specify plugins to load.
+# -P, --noplugin=NAME: specify plugins not to load.
+CONNMAN_OPTS=""
diff --git a/net-misc/connman/files/connman.initd2 b/net-misc/connman/files/connman.initd2
new file mode 100644
index 00000000..7b14d074
--- /dev/null
+++ b/net-misc/connman/files/connman.initd2
@@ -0,0 +1,23 @@
+#!/sbin/openrc-run
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Purpose License v2
+# $Id$
+
+depend() {
+ need dbus
+ provide net
+}
+
+start() {
+ ebegin "Starting Connection Manager"
+ start-stop-daemon --start --quiet --exec /usr/sbin/connmand -- ${CONNMAN_OPTS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping Connection Manager"
+ start-stop-daemon --stop --quiet --exec /usr/sbin/connmand
+ eend $?
+}
+
+# vim: set ft=gentoo-init-d ts=3 sw=3 et:
diff --git a/net-misc/connman/files/connman.service b/net-misc/connman/files/connman.service
new file mode 100644
index 00000000..ece38a71
--- /dev/null
+++ b/net-misc/connman/files/connman.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=Network Connection Manager Daemon
+
+[Service]
+Type=dbus
+BusName=net.connman
+ExecStart=/usr/sbin/connmand --nodaemon
+
+[Install]
+WantedBy=multi-user.target
+Alias=net.connman.service
diff --git a/net-misc/connman/metadata.xml b/net-misc/connman/metadata.xml
new file mode 100644
index 00000000..824ff9e0
--- /dev/null
+++ b/net-misc/connman/metadata.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>nvinson234@gmail.com</email>
+ <name>Nicholas Vinson</name>
+ </maintainer>
+ <maintainer type="person">
+ <email>dlan@gentoo.org</email>
+ <name>Yixun Lan</name>
+ <description>Co Maintainer, CC bugs</description>
+ </maintainer>
+ <maintainer type="project">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
+ <use>
+ <flag name="ethernet">Enable ethernet support.</flag>
+ <flag name="l2tp">Use <pkg>net-dialup/xl2tpd</pkg> for L2TP VPN support.</flag>
+ <flag name="ofono">Use <pkg>net-misc/ofono</pkg> for telephony support.</flag>
+ <flag name="openconnect">Use <pkg>net-misc/openconnect</pkg> for VPN support.</flag>
+ <flag name="openvpn">Use <pkg>net-misc/openvpn</pkg> for openvpn support.</flag>
+ <flag name="pptp">Use <pkg>net-dialup/pptpclient</pkg> for PPTP VPN support.</flag>
+ <flag name="tools">Enable testing tools.</flag>
+ <flag name="vpnc">Use <pkg>net-misc/vpnc</pkg> for cisco VPN support.</flag>
+ <flag name="wispr">Enable support for WISPr hotspot logins.</flag>
+ </use>
+</pkgmetadata>