VIRTUAL-RUNTIME_init_manager = "systemd"
VIRTUAL-RUNTIME_initscripts = ""
+# network manager to use (possible values: systemd, connman)
+VIRTUAL-RUNTIME_net_manager = "connman"
+
# Override these in poky based distros
AGL_DEFAULT_DISTRO_FEATURES = "systemd opengl wayland pam bluetooth bluez5"
AGL_DEFAULT_EXTRA_RDEPENDS = "packagegroup-core-boot"
--- /dev/null
+SUMMARY = "A simple ncurses interface for connman"
+DESCRIPTION = "A simple ncurses interface for connman"
+HOMEPAGE = "https://gitlab.com/iotbzh/connman-json-client"
+
+SECTION = "console/network"
+
+DEPENDS = "dbus ncurses connman json-c"
+
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8c16666ae6c159876a0ba63099614381"
+
+SRC_URI = "git://gitlab.com/iotbzh/connman-json-client.git;protocol=https;rev=ad4261a2f87c914667b1f6841c913f6b08d373e2"
+
+inherit autotools pkgconfig
+
+EXTRA_AUTORECONF += " -i"
+EXTRA_OECONF += " --disable-optimization --enable-debug"
+
+S = "${WORKDIR}/git"
+
+do_install () {
+ install -dm755 ${D}${bindir}
+ install -Dm755 connman_ncurses ${D}${bindir}
+}
+
+FILES_${PN} = "${bindir}/connman_ncurses"
RDEPENDS_${PN} += "\
dhcp-server \
+ ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','connman','connman connman-client connman-tests connman-tools connman-ncurses','',d)} \
"
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
SRC_URI += "file://e2fsck.conf \
- file://wired.network \
+ ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','systemd','file://wired.network','',d)} \
"
# enable networkd/resolved support
-PACKAGECONFIG_append_pn-systemd = " networkd resolved"
+PACKAGECONFIG_append_pn-systemd = " \
+ ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','systemd','networkd resolved','',d)} \
+"
do_install_append() {
# Install /etc/e2fsck.conf to avoid boot stuck by wrong clock time
install -m 644 -p -D ${WORKDIR}/e2fsck.conf ${D}${sysconfdir}/e2fsck.conf
- # Install DHCP configuration for Ethernet adapters
- install -m 644 ${WORKDIR}/wired.network ${D}${sysconfdir}/systemd/network
+
+ if ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','systemd','true','false',d)}; then
+ # Install DHCP configuration for Ethernet adapters
+ install -m 644 ${WORKDIR}/wired.network ${D}${sysconfdir}/systemd/network
+ fi
}
FILES_${PN} += "${sysconfdir}/e2fsck.conf "