From patchwork Thu Apr 3 10:52:54 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Kiernan X-Patchwork-Id: 60660 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9CF99C369A0 for ; Thu, 3 Apr 2025 10:53:20 +0000 (UTC) Received: from mail-wr1-f44.google.com (mail-wr1-f44.google.com [209.85.221.44]) by mx.groups.io with SMTP id smtpd.web10.10567.1743677592290578295 for ; Thu, 03 Apr 2025 03:53:12 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=aNx7ngF7; spf=pass (domain: gmail.com, ip: 209.85.221.44, mailfrom: alex.kiernan@gmail.com) Received: by mail-wr1-f44.google.com with SMTP id ffacd0b85a97d-39c1ef4ae3aso442407f8f.1 for ; Thu, 03 Apr 2025 03:53:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1743677590; x=1744282390; darn=lists.openembedded.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=WsV9f6pXmepEenpurvxBt/Y7ViRLfkqxuHUJIYo2gpM=; b=aNx7ngF78xsZwqfh6CzopasGqreLIw0gnuMxdmCJdcb4KjtTRc//2HMILtto2id/3i gmBdYPkpUuo6bnBuTYskWLaBVciHDn7dZJEpR0srUc8ENHVaq3Ho+jhyAJ1KaF/bvuM/ qOH0rfUuWhIh2WDyCS2ZZlDl+8Cekdpo9q9Np1qWhR4NqlN8smVtLBzton9IU6pBME7M mh5kJF4sOzeDzXFJdK5+Y0Xq0Vugh7r4TxisuOoslxODGVCrWbSnRFnHol4MLn4idxJo a6hf55ySJ0qqStuiyaCBMHZCb8lYMBqWLAp+R2GWUsjf4g98EJuD4EV2mmVQmJ3jzCU+ pj5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743677590; x=1744282390; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=WsV9f6pXmepEenpurvxBt/Y7ViRLfkqxuHUJIYo2gpM=; b=fBqsjPohojXd8JbVrYigQCZ0xkHmeVC7o46gSP6qLzb1OGFpAdvecLDlCp8WHbWQJ4 AfIpIw3pxD3hsuV64l9zFGtJ+P4ib2VTth3zDY+tuwOCubf9u8LidbkIjNObwk3hLzr6 fbMaOOIRirg9YK+iBAeGYm9da98VJ5L8bPGd+gZkKGDyEhkrUarp6jx6+zZj7kmcPTPs tUdothGITgsXPb0aEmgccc/LIJh9Z0JFcuxIZHIYS8yo22tRIC8d7Aq6oN0UVqoXTiGM Rfg6eVPeAIzBRz9WAxuiwau45lynK1cTa2MvPFWtZiyfchnG9USxXrP5wymQNuFINNVk zqkQ== X-Gm-Message-State: AOJu0YwJhEzLl/TsskJkZw10UVODCDqH4wwIodW5vfRk3G8871YKVnv7 4+u78cfLbhV8G2qToLKGrZk+cY29BDMAETzpYYHOq90KHikvqF88jEu5+Mf9 X-Gm-Gg: ASbGnctaHx77gbvc4AP8Ai6hoQORo69ppY81fwmkH50I2l5GfqNLFxQ4Qy4EgB6AZUr q7A+JbxYjM7KpMP85HO0yQJJsS1QD+CP59mwpZ+OLCpfF9w6xwQC6NbHIrIdfwLGM9p+oHDgPI7 z8AGT52PJJsNeM2EUABdr+NtGnGIZT8TgWt+04Fg+zBzxNZcM9nhjobFDzraXkLH+twAE+A6Qia HI660jnsMXpxDJcx2bS82wxvNPol2guDYxgvUQmYFNjqUjKXIq/QKuOxDon3C8UzVnPptj+uoB1 thT53hbbh8nfmEGXtsYr8j2iNTmcFqPgPSDSTBwpBQdBJeodFtUcr9t65cZ+tCzenS0sQUD5mkI Vi23BEo/5IVo= X-Google-Smtp-Source: AGHT+IFA4/8PsxxaLlFkylkqDCS3ZMxKFLkvdkAy45A9kEL1TkOBbrUAy9ER/25GF4MLcP2a5349vw== X-Received: by 2002:a05:6000:2211:b0:391:3207:2e68 with SMTP id ffacd0b85a97d-39c2e611194mr2295260f8f.9.1743677589463; Thu, 03 Apr 2025 03:53:09 -0700 (PDT) Received: from ip-10-0-0-134.eu-west-1.compute.internal ([2a05:d018:db1:fb00:c4f8:7a97:b7aa:1bfd]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43ec1630ddesm18346865e9.5.2025.04.03.03.53.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 03:53:09 -0700 (PDT) From: Alex Kiernan Date: Thu, 03 Apr 2025 10:52:54 +0000 Subject: [PATCH OE-Core v2 1/6] connman: Merge .inc into .bb MIME-Version: 1.0 Message-Id: <20250403-connman-v2-1-8bb637312ba8@gmail.com> References: <20250403-connman-v2-0-8bb637312ba8@gmail.com> In-Reply-To: <20250403-connman-v2-0-8bb637312ba8@gmail.com> To: openembedded-core@lists.openembedded.org Cc: Alex Kiernan X-Mailer: b4 0.14.2 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 03 Apr 2025 10:53:20 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/214312 No functional changes. Signed-off-by: Alex Kiernan --- meta/recipes-connectivity/connman/connman.inc | 221 --------------------- meta/recipes-connectivity/connman/connman_1.44.bb | 223 +++++++++++++++++++++- 2 files changed, 221 insertions(+), 223 deletions(-) diff --git a/meta/recipes-connectivity/connman/connman.inc b/meta/recipes-connectivity/connman/connman.inc deleted file mode 100644 index 804c2db9a7eeae2a294e3ae64b86b3e3fe344c35..0000000000000000000000000000000000000000 --- a/meta/recipes-connectivity/connman/connman.inc +++ /dev/null @@ -1,221 +0,0 @@ -SUMMARY = "A daemon for managing internet connections within embedded devices" -DESCRIPTION = "The ConnMan project provides a daemon for managing \ -internet connections within embedded devices running the Linux \ -operating system. The Connection Manager is designed to be slim and \ -to use as few resources as possible, so it can be easily integrated. \ -It is a fully modular system that can be extended, through plug-ins, \ -to support all kinds of wired or wireless technologies. Also, \ -configuration methods, like DHCP and domain name resolving, are \ -implemented using plug-ins." -HOMEPAGE = "http://connman.net/" -BUGTRACKER = "https://01.org/jira/browse/CM" -LICENSE = "GPL-2.0-only" -LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ - file://src/main.c;beginline=1;endline=20;md5=486a279a6ab0c8d152bcda3a5b5edc36" - -inherit autotools pkgconfig systemd update-rc.d update-alternatives - -CVE_PRODUCT = "connman connection_manager" - -DEPENDS = "dbus glib-2.0 ppp" - -EXTRA_OECONF += "\ - ac_cv_path_WPASUPPLICANT=${sbindir}/wpa_supplicant \ - ac_cv_path_PPPD=${sbindir}/pppd \ - --enable-debug \ - --enable-loopback \ - --enable-ethernet \ - --enable-tools \ - --disable-polkit \ - --runstatedir=/run \ -" -# For smooth operation it would be best to start only one wireless daemon at a time. -# If wpa-supplicant is running, connman will use it preferentially. -# Select either wpa-supplicant or iwd -WIRELESS_DAEMON ??= "wpa-supplicant" - -PACKAGECONFIG ??= "wispr iptables client\ - ${@bb.utils.filter('DISTRO_FEATURES', '3g systemd', d)} \ - ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \ - ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'wifi ${WIRELESS_DAEMON}', '', d)} \ -" - -# If you want ConnMan to support VPN, add following statement into -# local.conf or distro config -# PACKAGECONFIG:append:pn-connman = " openvpn vpnc l2tp pptp" - -PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_system_unitdir}/ --with-tmpfilesdir=${sysconfdir}/tmpfiles.d/,--with-systemdunitdir='' --with-tmpfilesdir=''" -PACKAGECONFIG[wifi] = "--enable-wifi, --disable-wifi" -PACKAGECONFIG[bluez] = "--enable-bluetooth, --disable-bluetooth, bluez5, bluez5" -PACKAGECONFIG[3g] = "--enable-ofono, --disable-ofono, ofono, ofono" -PACKAGECONFIG[wpa-supplicant] = ",,wpa-supplicant,wpa-supplicant" -PACKAGECONFIG[iwd] = "--enable-iwd,--disable-iwd,,iwd" -PACKAGECONFIG[tist] = "--enable-tist,--disable-tist," -PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" -PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" -PACKAGECONFIG[l2tp] = "--enable-l2tp --with-l2tp=${sbindir}/xl2tpd,--disable-l2tp,,xl2tpd" -PACKAGECONFIG[pptp] = "--enable-pptp --with-pptp=${sbindir}/pptp,--disable-pptp,,pptp-linux" -# WISPr support for logging into hotspots, requires TLS -PACKAGECONFIG[wispr] = "--enable-wispr,--disable-wispr,gnutls," -PACKAGECONFIG[nftables] = "--with-firewall=nftables ,,libmnl libnftnl,,kernel-module-nf-tables kernel-module-nft-chain-nat-ipv4 kernel-module-nft-chain-route-ipv4 kernel-module-nft-masq-ipv4 kernel-module-nft-nat" -PACKAGECONFIG[iptables] = "--with-firewall=iptables ,,iptables,iptables" -PACKAGECONFIG[nfc] = "--enable-neard, --disable-neard, neard, neard" -PACKAGECONFIG[client] = "--enable-client,--disable-client,readline" -PACKAGECONFIG[wireguard] = "--enable-wireguard,--disable-wireguard,libmnl" - -INITSCRIPT_NAME = "connman" -INITSCRIPT_PARAMS = "start 05 5 2 3 . stop 22 0 1 6 ." - -python __anonymous () { - systemd_packages = "${PN} ${PN}-wait-online" - pkgconfig = d.getVar('PACKAGECONFIG') - if ('openvpn' or 'vpnc' or 'l2tp' or 'pptp') in pkgconfig.split(): - systemd_packages += " ${PN}-vpn" - d.setVar('SYSTEMD_PACKAGES', systemd_packages) -} - -SYSTEMD_SERVICE:${PN} = "connman.service" -SYSTEMD_SERVICE:${PN}-vpn = "connman-vpn.service" -SYSTEMD_SERVICE:${PN}-wait-online = "connman-wait-online.service" - -ALTERNATIVE_PRIORITY = "100" -ALTERNATIVE:${PN} = "${@bb.utils.contains('DISTRO_FEATURES','systemd','resolv-conf','',d)}" -ALTERNATIVE_TARGET[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv-conf.connman','',d)}" -ALTERNATIVE_LINK_NAME[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv.conf','',d)}" - -do_install:append() { - if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then - install -d ${D}${sysconfdir}/init.d - install -m 0755 ${UNPACKDIR}/connman ${D}${sysconfdir}/init.d/connman - sed -i s%@DATADIR@%${datadir}% ${D}${sysconfdir}/init.d/connman - fi - - install -d ${D}${bindir} - install -m 0755 ${B}/tools/*-test ${D}${bindir} - if [ -e ${B}/tools/wispr ]; then - install -m 0755 ${B}/tools/wispr ${D}${bindir} - fi - - # We don't need to package an empty directory - rmdir --ignore-fail-on-non-empty ${D}${libdir}/connman/scripts - - # Automake 1.12 won't install empty directories, but we need the - # plugins directory to be present for ownership - mkdir -p ${D}${libdir}/connman/plugins - - # For read-only filesystem, do not create links during bootup - if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then - ln -sf ../run/connman/resolv.conf ${D}${sysconfdir}/resolv-conf.connman - fi -} - -# These used to be plugins, but now they are core -RPROVIDES:${PN} = "\ - connman-plugin-loopback \ - connman-plugin-ethernet \ - ${@bb.utils.contains('PACKAGECONFIG', 'bluetooth','connman-plugin-bluetooth', '', d)} \ - ${@bb.utils.contains('PACKAGECONFIG', 'wifi','connman-plugin-wifi', '', d)} \ - ${@bb.utils.contains('PACKAGECONFIG', '3g','connman-plugin-ofono', '', d)} \ - " - -PACKAGES_DYNAMIC += "^${PN}-plugin-.*" - -def add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, add_insane_skip): - plugintype = pkg.split( '-' )[-1] - if plugintype in depmap: - rdepends = map(lambda x: multilib_prefix + x, \ - depmap[plugintype].split()) - d.setVar("RDEPENDS:%s" % pkg, " ".join(rdepends)) - if add_insane_skip: - d.appendVar("INSANE_SKIP:%s" % pkg, "dev-so") - -python populate_packages:prepend() { - depmap = dict(pppd="ppp") - multilib_prefix = (d.getVar("MLPREFIX") or "") - - hook = lambda file,pkg,x,y,z: \ - add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, False) - plugin_dir = d.expand('${libdir}/connman/plugins/') - plugin_name = d.expand('${PN}-plugin-%s') - do_split_packages(d, plugin_dir, r'^(.*).so$', plugin_name, \ - '${PN} plugin for %s', extra_depends='', hook=hook, prepend=True ) - - hook = lambda file,pkg,x,y,z: \ - add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, True) - plugin_dir = d.expand('${libdir}/connman/plugins-vpn/') - plugin_name = d.expand('${PN}-plugin-vpn-%s') - do_split_packages(d, plugin_dir, r'^(.*).so$', plugin_name, \ - '${PN} VPN plugin for %s', extra_depends='', hook=hook, prepend=True ) -} - -PACKAGES =+ "${PN}-tools ${PN}-tests ${PN}-client" - -FILES:${PN}-tools = "${bindir}/wispr" -RDEPENDS:${PN}-tools = "${PN}" - -FILES:${PN}-tests = "${bindir}/*-test" - -FILES:${PN}-client = "${bindir}/connmanctl" -RDEPENDS:${PN}-client = "${PN}" - -FILES:${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \ - ${libdir}/connman/plugins \ - ${sysconfdir} ${sharedstatedir} ${localstatedir} ${datadir} \ - ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} \ - ${datadir}/dbus-1/system-services/* \ - ${sysconfdir}/tmpfiles.d/connman_resolvconf.conf" - -FILES:${PN}-dev += "${libdir}/connman/*/*.la" - -PACKAGES =+ "${PN}-vpn ${PN}-wait-online" - -SUMMARY:${PN}-vpn = "A daemon for managing VPN connections within embedded devices" -DESCRIPTION:${PN}-vpn = "The ConnMan VPN provides a daemon for \ -managing VPN connections within embedded devices running the Linux \ -operating system. The connman-vpnd handles all the VPN connections \ -and starts/stops VPN client processes when necessary. The connman-vpnd \ -provides a DBus API for managing VPN connections. All the different \ -VPN technogies are implemented using plug-ins." -FILES:${PN}-vpn += "${sbindir}/connman-vpnd \ - ${sysconfdir}/dbus-1/system.d/connman-vpn-dbus.conf \ - ${datadir}/dbus-1/system-services/net.connman.vpn.service \ - ${systemd_system_unitdir}/connman-vpn.service" - -SUMMARY:${PN}-wait-online = "A program that will return once ConnMan has connected to a network" -DESCRIPTION:${PN}-wait-online = "A service that can be enabled so that \ -the system waits until a network connection is established." -FILES:${PN}-wait-online += "${sbindir}/connmand-wait-online \ - ${systemd_system_unitdir}/connman-wait-online.service" - -SUMMARY:${PN}-plugin-vpn-openvpn = "An OpenVPN plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-openvpn = "The ConnMan OpenVPN plugin uses openvpn client \ -to create a VPN connection to OpenVPN server." -FILES:${PN}-plugin-vpn-openvpn += "${libdir}/connman/scripts/openvpn-script \ - ${libdir}/connman/plugins-vpn/openvpn.so" -RDEPENDS:${PN}-plugin-vpn-openvpn += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','openvpn','${PN}-plugin-vpn-openvpn', '', d)}" - -SUMMARY:${PN}-plugin-vpn-vpnc = "A vpnc plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-vpnc = "The ConnMan vpnc plugin uses vpnc client \ -to create a VPN connection to Cisco3000 VPN Concentrator." -FILES:${PN}-plugin-vpn-vpnc += "${libdir}/connman/scripts/openconnect-script \ - ${libdir}/connman/plugins-vpn/vpnc.so \ - ${libdir}/connman/scripts/vpn-script" -RDEPENDS:${PN}-plugin-vpn-vpnc += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','vpnc','${PN}-plugin-vpn-vpnc', '', d)}" - -SUMMARY:${PN}-plugin-vpn-l2tp = "A L2TP plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-l2tp = "The ConnMan L2TP plugin uses xl2tpd daemon \ -to create a VPN connection to L2TP server." -FILES:${PN}-plugin-vpn-l2tp += "${libdir}/connman/scripts/libppp-plugin.so* \ - ${libdir}/connman/plugins-vpn/l2tp.so" -RDEPENDS:${PN}-plugin-vpn-l2tp += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','l2tp','${PN}-plugin-vpn-l2tp', '', d)}" - -SUMMARY:${PN}-plugin-vpn-pptp = "A PPTP plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-pptp = "The ConnMan PPTP plugin uses pptp-linux client \ -to create a VPN connection to PPTP server." -FILES:${PN}-plugin-vpn-pptp += "${libdir}/connman/scripts/libppp-plugin.so* \ - ${libdir}/connman/plugins-vpn/pptp.so" -RDEPENDS:${PN}-plugin-vpn-pptp += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','pptp','${PN}-plugin-vpn-pptp', '', d)}" diff --git a/meta/recipes-connectivity/connman/connman_1.44.bb b/meta/recipes-connectivity/connman/connman_1.44.bb index 396d8bc5ce2c1a00e7fce1c7322b0f938de3c11c..1cd97d342f894bcffa6a7ed80ac8dc23e6a0565d 100644 --- a/meta/recipes-connectivity/connman/connman_1.44.bb +++ b/meta/recipes-connectivity/connman/connman_1.44.bb @@ -1,4 +1,23 @@ -require connman.inc +SUMMARY = "A daemon for managing internet connections within embedded devices" +DESCRIPTION = "The ConnMan project provides a daemon for managing \ +internet connections within embedded devices running the Linux \ +operating system. The Connection Manager is designed to be slim and \ +to use as few resources as possible, so it can be easily integrated. \ +It is a fully modular system that can be extended, through plug-ins, \ +to support all kinds of wired or wireless technologies. Also, \ +configuration methods, like DHCP and domain name resolving, are \ +implemented using plug-ins." +HOMEPAGE = "http://connman.net/" +BUGTRACKER = "https://01.org/jira/browse/CM" +LICENSE = "GPL-2.0-only" +LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ + file://src/main.c;beginline=1;endline=20;md5=486a279a6ab0c8d152bcda3a5b5edc36" + +inherit autotools pkgconfig systemd update-rc.d update-alternatives + +CVE_PRODUCT = "connman connection_manager" + +DEPENDS = "dbus glib-2.0 ppp" SRC_URI = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \ file://0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch \ @@ -8,8 +27,208 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \ file://0002-resolve-musl-does-not-implement-res_ninit.patch \ " - SRC_URI[sha256sum] = "2be2b00321632b775f9eff713acd04ef21e31fbf388f6ebf45512ff4289574ff" RRECOMMENDS:${PN} = "connman-conf" RCONFLICTS:${PN} = "networkmanager" + +EXTRA_OECONF += "\ + ac_cv_path_WPASUPPLICANT=${sbindir}/wpa_supplicant \ + ac_cv_path_PPPD=${sbindir}/pppd \ + --enable-debug \ + --enable-loopback \ + --enable-ethernet \ + --enable-tools \ + --disable-polkit \ + --runstatedir=/run \ +" +# For smooth operation it would be best to start only one wireless daemon at a time. +# If wpa-supplicant is running, connman will use it preferentially. +# Select either wpa-supplicant or iwd +WIRELESS_DAEMON ??= "wpa-supplicant" + +PACKAGECONFIG ??= "wispr iptables client\ + ${@bb.utils.filter('DISTRO_FEATURES', '3g systemd', d)} \ + ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \ + ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'wifi ${WIRELESS_DAEMON}', '', d)} \ +" + +# If you want ConnMan to support VPN, add following statement into +# local.conf or distro config +# PACKAGECONFIG:append:pn-connman = " openvpn vpnc l2tp pptp" + +PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_system_unitdir}/ --with-tmpfilesdir=${sysconfdir}/tmpfiles.d/,--with-systemdunitdir='' --with-tmpfilesdir=''" +PACKAGECONFIG[wifi] = "--enable-wifi, --disable-wifi" +PACKAGECONFIG[bluez] = "--enable-bluetooth, --disable-bluetooth, bluez5, bluez5" +PACKAGECONFIG[3g] = "--enable-ofono, --disable-ofono, ofono, ofono" +PACKAGECONFIG[wpa-supplicant] = ",,wpa-supplicant,wpa-supplicant" +PACKAGECONFIG[iwd] = "--enable-iwd,--disable-iwd,,iwd" +PACKAGECONFIG[tist] = "--enable-tist,--disable-tist," +PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" +PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" +PACKAGECONFIG[l2tp] = "--enable-l2tp --with-l2tp=${sbindir}/xl2tpd,--disable-l2tp,,xl2tpd" +PACKAGECONFIG[pptp] = "--enable-pptp --with-pptp=${sbindir}/pptp,--disable-pptp,,pptp-linux" +# WISPr support for logging into hotspots, requires TLS +PACKAGECONFIG[wispr] = "--enable-wispr,--disable-wispr,gnutls," +PACKAGECONFIG[nftables] = "--with-firewall=nftables ,,libmnl libnftnl,,kernel-module-nf-tables kernel-module-nft-chain-nat-ipv4 kernel-module-nft-chain-route-ipv4 kernel-module-nft-masq-ipv4 kernel-module-nft-nat" +PACKAGECONFIG[iptables] = "--with-firewall=iptables ,,iptables,iptables" +PACKAGECONFIG[nfc] = "--enable-neard, --disable-neard, neard, neard" +PACKAGECONFIG[client] = "--enable-client,--disable-client,readline" +PACKAGECONFIG[wireguard] = "--enable-wireguard,--disable-wireguard,libmnl" + +INITSCRIPT_NAME = "connman" +INITSCRIPT_PARAMS = "start 05 5 2 3 . stop 22 0 1 6 ." + +python __anonymous () { + systemd_packages = "${PN} ${PN}-wait-online" + pkgconfig = d.getVar('PACKAGECONFIG') + if ('openvpn' or 'vpnc' or 'l2tp' or 'pptp') in pkgconfig.split(): + systemd_packages += " ${PN}-vpn" + d.setVar('SYSTEMD_PACKAGES', systemd_packages) +} + +SYSTEMD_SERVICE:${PN} = "connman.service" +SYSTEMD_SERVICE:${PN}-vpn = "connman-vpn.service" +SYSTEMD_SERVICE:${PN}-wait-online = "connman-wait-online.service" + +ALTERNATIVE_PRIORITY = "100" +ALTERNATIVE:${PN} = "${@bb.utils.contains('DISTRO_FEATURES','systemd','resolv-conf','',d)}" +ALTERNATIVE_TARGET[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv-conf.connman','',d)}" +ALTERNATIVE_LINK_NAME[resolv-conf] = "${@bb.utils.contains('DISTRO_FEATURES','systemd','${sysconfdir}/resolv.conf','',d)}" + +do_install:append() { + if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','true','false',d)}; then + install -d ${D}${sysconfdir}/init.d + install -m 0755 ${UNPACKDIR}/connman ${D}${sysconfdir}/init.d/connman + sed -i s%@DATADIR@%${datadir}% ${D}${sysconfdir}/init.d/connman + fi + + install -d ${D}${bindir} + install -m 0755 ${B}/tools/*-test ${D}${bindir} + if [ -e ${B}/tools/wispr ]; then + install -m 0755 ${B}/tools/wispr ${D}${bindir} + fi + + # We don't need to package an empty directory + rmdir --ignore-fail-on-non-empty ${D}${libdir}/connman/scripts + + # Automake 1.12 won't install empty directories, but we need the + # plugins directory to be present for ownership + mkdir -p ${D}${libdir}/connman/plugins + + # For read-only filesystem, do not create links during bootup + if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then + ln -sf ../run/connman/resolv.conf ${D}${sysconfdir}/resolv-conf.connman + fi +} + +# These used to be plugins, but now they are core +RPROVIDES:${PN} = "\ + connman-plugin-loopback \ + connman-plugin-ethernet \ + ${@bb.utils.contains('PACKAGECONFIG', 'bluetooth','connman-plugin-bluetooth', '', d)} \ + ${@bb.utils.contains('PACKAGECONFIG', 'wifi','connman-plugin-wifi', '', d)} \ + ${@bb.utils.contains('PACKAGECONFIG', '3g','connman-plugin-ofono', '', d)} \ + " + +PACKAGES_DYNAMIC += "^${PN}-plugin-.*" + +def add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, add_insane_skip): + plugintype = pkg.split( '-' )[-1] + if plugintype in depmap: + rdepends = map(lambda x: multilib_prefix + x, \ + depmap[plugintype].split()) + d.setVar("RDEPENDS:%s" % pkg, " ".join(rdepends)) + if add_insane_skip: + d.appendVar("INSANE_SKIP:%s" % pkg, "dev-so") + +python populate_packages:prepend() { + depmap = dict(pppd="ppp") + multilib_prefix = (d.getVar("MLPREFIX") or "") + + hook = lambda file,pkg,x,y,z: \ + add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, False) + plugin_dir = d.expand('${libdir}/connman/plugins/') + plugin_name = d.expand('${PN}-plugin-%s') + do_split_packages(d, plugin_dir, r'^(.*).so$', plugin_name, \ + '${PN} plugin for %s', extra_depends='', hook=hook, prepend=True ) + + hook = lambda file,pkg,x,y,z: \ + add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, True) + plugin_dir = d.expand('${libdir}/connman/plugins-vpn/') + plugin_name = d.expand('${PN}-plugin-vpn-%s') + do_split_packages(d, plugin_dir, r'^(.*).so$', plugin_name, \ + '${PN} VPN plugin for %s', extra_depends='', hook=hook, prepend=True ) +} + +PACKAGES =+ "${PN}-tools ${PN}-tests ${PN}-client" + +FILES:${PN}-tools = "${bindir}/wispr" +RDEPENDS:${PN}-tools = "${PN}" + +FILES:${PN}-tests = "${bindir}/*-test" + +FILES:${PN}-client = "${bindir}/connmanctl" +RDEPENDS:${PN}-client = "${PN}" + +FILES:${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \ + ${libdir}/connman/plugins \ + ${sysconfdir} ${sharedstatedir} ${localstatedir} ${datadir} \ + ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} \ + ${datadir}/dbus-1/system-services/* \ + ${sysconfdir}/tmpfiles.d/connman_resolvconf.conf" + +FILES:${PN}-dev += "${libdir}/connman/*/*.la" + +PACKAGES =+ "${PN}-vpn ${PN}-wait-online" + +SUMMARY:${PN}-vpn = "A daemon for managing VPN connections within embedded devices" +DESCRIPTION:${PN}-vpn = "The ConnMan VPN provides a daemon for \ +managing VPN connections within embedded devices running the Linux \ +operating system. The connman-vpnd handles all the VPN connections \ +and starts/stops VPN client processes when necessary. The connman-vpnd \ +provides a DBus API for managing VPN connections. All the different \ +VPN technogies are implemented using plug-ins." +FILES:${PN}-vpn += "${sbindir}/connman-vpnd \ + ${sysconfdir}/dbus-1/system.d/connman-vpn-dbus.conf \ + ${datadir}/dbus-1/system-services/net.connman.vpn.service \ + ${systemd_system_unitdir}/connman-vpn.service" + +SUMMARY:${PN}-wait-online = "A program that will return once ConnMan has connected to a network" +DESCRIPTION:${PN}-wait-online = "A service that can be enabled so that \ +the system waits until a network connection is established." +FILES:${PN}-wait-online += "${sbindir}/connmand-wait-online \ + ${systemd_system_unitdir}/connman-wait-online.service" + +SUMMARY:${PN}-plugin-vpn-openvpn = "An OpenVPN plugin for ConnMan VPN" +DESCRIPTION:${PN}-plugin-vpn-openvpn = "The ConnMan OpenVPN plugin uses openvpn client \ +to create a VPN connection to OpenVPN server." +FILES:${PN}-plugin-vpn-openvpn += "${libdir}/connman/scripts/openvpn-script \ + ${libdir}/connman/plugins-vpn/openvpn.so" +RDEPENDS:${PN}-plugin-vpn-openvpn += "${PN}-vpn" +RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','openvpn','${PN}-plugin-vpn-openvpn', '', d)}" + +SUMMARY:${PN}-plugin-vpn-vpnc = "A vpnc plugin for ConnMan VPN" +DESCRIPTION:${PN}-plugin-vpn-vpnc = "The ConnMan vpnc plugin uses vpnc client \ +to create a VPN connection to Cisco3000 VPN Concentrator." +FILES:${PN}-plugin-vpn-vpnc += "${libdir}/connman/scripts/openconnect-script \ + ${libdir}/connman/plugins-vpn/vpnc.so \ + ${libdir}/connman/scripts/vpn-script" +RDEPENDS:${PN}-plugin-vpn-vpnc += "${PN}-vpn" +RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','vpnc','${PN}-plugin-vpn-vpnc', '', d)}" + +SUMMARY:${PN}-plugin-vpn-l2tp = "A L2TP plugin for ConnMan VPN" +DESCRIPTION:${PN}-plugin-vpn-l2tp = "The ConnMan L2TP plugin uses xl2tpd daemon \ +to create a VPN connection to L2TP server." +FILES:${PN}-plugin-vpn-l2tp += "${libdir}/connman/scripts/libppp-plugin.so* \ + ${libdir}/connman/plugins-vpn/l2tp.so" +RDEPENDS:${PN}-plugin-vpn-l2tp += "${PN}-vpn" +RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','l2tp','${PN}-plugin-vpn-l2tp', '', d)}" + +SUMMARY:${PN}-plugin-vpn-pptp = "A PPTP plugin for ConnMan VPN" +DESCRIPTION:${PN}-plugin-vpn-pptp = "The ConnMan PPTP plugin uses pptp-linux client \ +to create a VPN connection to PPTP server." +FILES:${PN}-plugin-vpn-pptp += "${libdir}/connman/scripts/libppp-plugin.so* \ + ${libdir}/connman/plugins-vpn/pptp.so" +RDEPENDS:${PN}-plugin-vpn-pptp += "${PN}-vpn" +RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','pptp','${PN}-plugin-vpn-pptp', '', d)}" From patchwork Thu Apr 3 10:52:55 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Kiernan X-Patchwork-Id: 60662 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id A8997C369A1 for ; Thu, 3 Apr 2025 10:53:20 +0000 (UTC) Received: from mail-wr1-f46.google.com (mail-wr1-f46.google.com [209.85.221.46]) by mx.groups.io with SMTP id smtpd.web10.10568.1743677593569600118 for ; Thu, 03 Apr 2025 03:53:13 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=JfMP1xCc; spf=pass (domain: gmail.com, ip: 209.85.221.46, mailfrom: alex.kiernan@gmail.com) Received: by mail-wr1-f46.google.com with SMTP id ffacd0b85a97d-39c0dfba946so475169f8f.3 for ; Thu, 03 Apr 2025 03:53:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1743677591; x=1744282391; darn=lists.openembedded.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=3+ExCSaBoAh+/mXbdaTN4cSKKmQrfZ8zHmaTB/V4Umg=; b=JfMP1xCctf5FMhKVxk3JriKqbQcHMqPTno0HLL7tFdF7S8t9Pxxf0Om5DsqoUbW75R p2Apv/V0G3FM/j9fGTLkBld0ot4PBnZDEr9i9lhsIX4KHTbi+0H8LruTIy7get5oRpuQ wiGBfc3tWKhUcE4T71a+McJqgJAsedoiNvqcmQllL3WmfV8bWhga7VIh37I9S+MWgyej /B60LPENLFTAjFF0/8aYHJi9KAMW7YzL7tLqYZ9zZLlC1jkCidwyGPpLSc7Q/kjp/64y 9UC9xMCPb9bu0C6NplG/j1sEpkkO1gGl/DDSuRk/BdSm0rN+/G9DywsbvH9EQ3Mf2brY 7Hnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743677591; x=1744282391; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3+ExCSaBoAh+/mXbdaTN4cSKKmQrfZ8zHmaTB/V4Umg=; b=j0S9ig1KomsowXjeFXAsnK3AFdwjsPpgrDBkv9BVwFs19vUmCbZHAN/h7tDMgw8g0/ aElIkbq5id8jo+3klWiLnBd/z5KijC8VG96cgi5W3wetE6svweDdADVdZmZM11xA3OSS 5on+uMBEhEsTsxQ93AzdR7rReXGQbz+awAdEq3xlS0o41AxcjALy0MXRD/barpM3wIBF 53gsLO2rCHJdOURMI5pL2YNPi6LP9NqJlzaA6wtyOiDrmnGHzkF81LtJo+a9o1wiQHmT +e0Kf4TBTtdvYEGNOCapNWCU2jBDfG9zEn8KM2zMUh4TvizYYAqWKfRf+pBlpZZwpp6t xbMQ== X-Gm-Message-State: AOJu0YzikQFuklO4WB3g6OIBgqGSHxPEytSRnOVAp8t5JP6U5ZPaPufx aWHczRlbpi7hDQYv5zifIUh0tDwAjy6F30E9BRVyZHSuu8S6ds4LFJ+5TyRy X-Gm-Gg: ASbGncvZ38Q8fb9BLFLGremGNl2EUP6jw64OfEESSkPvIp96Y4fMfnkbm6/81FtkQRv k690qxkY4V8SYxHX1YqY0lfObFoBypKFMtm6yGX0bIFh6UXHdEqsX50e3qWE9EiZtaqiGR52U/+ mf7rGiDS5aJzvN5aTHfPwBnWYHMFt8P6jQxHrr34WoSp7lNMXd68R19jz6W7CTUJ06av4y/6WFY Woef3PCKjiyKiQEZJYJ6nd//9GSKSgYE3DUzdqo4rh15j8CZs2b2cyMaN2/TMjr6y+l4GX71Jca v9q3PTeupmVI3GmrNOTs/DAGz0UabLDWBeAE5he5TvRECb/S3xfCCD8mGs6YFd4hTLms4mztO3U HvTMv/fUEq7o= X-Google-Smtp-Source: AGHT+IEpUycGvi6J3+QwqYOCZHSXnlrnSL0jLSMlrYZrOdqNs8BHA4RG8f09YLS/c/31KVQg4AO0Qg== X-Received: by 2002:a05:6000:290a:b0:39c:1f0f:382a with SMTP id ffacd0b85a97d-39c2f8e6c33mr2174555f8f.35.1743677591438; Thu, 03 Apr 2025 03:53:11 -0700 (PDT) Received: from ip-10-0-0-134.eu-west-1.compute.internal ([2a05:d018:db1:fb00:c4f8:7a97:b7aa:1bfd]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43ec1630ddesm18346865e9.5.2025.04.03.03.53.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 03:53:09 -0700 (PDT) From: Alex Kiernan Date: Thu, 03 Apr 2025 10:52:55 +0000 Subject: [PATCH OE-Core v2 2/6] connman: Delete patches for gold and MIPS binutils fix MIME-Version: 1.0 Message-Id: <20250403-connman-v2-2-8bb637312ba8@gmail.com> References: <20250403-connman-v2-0-8bb637312ba8@gmail.com> In-Reply-To: <20250403-connman-v2-0-8bb637312ba8@gmail.com> To: openembedded-core@lists.openembedded.org Cc: Alex Kiernan X-Mailer: b4 0.14.2 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 03 Apr 2025 10:53:20 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/214313 gold is no longer built/supported. The workaround for binutils on MIPS no longer appears to be required. Also fix up tabs/whitespace in shell functions, correct HOMEPAGE, drop broken BUGTRACKER link. Signed-off-by: Alex Kiernan --- ...ange-visibility-to-default-for-debug-symb.patch | 31 -------------- .../connman/connman/no-version-scripts.patch | 47 ---------------------- meta/recipes-connectivity/connman/connman_1.44.bb | 13 +++--- 3 files changed, 5 insertions(+), 86 deletions(-) diff --git a/meta/recipes-connectivity/connman/connman/0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch b/meta/recipes-connectivity/connman/connman/0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch deleted file mode 100644 index a68707b2fa62a6e1ac37e05b8706908c456cec02..0000000000000000000000000000000000000000 --- a/meta/recipes-connectivity/connman/connman/0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch +++ /dev/null @@ -1,31 +0,0 @@ -From c254226d4ebbd846c1f8169d70413a0d32d7ae77 Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Sat, 7 Apr 2012 18:52:12 -0700 -Subject: [PATCH] plugin.h: Change visibility to default for debug symbols - -gold refuses to link in undefined weak symbols which -have hidden visibility - -Signed-off-by: Khem Raj - -Upstream-Status: Pending ---- - include/plugin.h | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/include/plugin.h b/include/plugin.h -index 8d2bb08..a12a6be 100644 ---- a/include/plugin.h -+++ b/include/plugin.h -@@ -89,9 +89,9 @@ struct connman_plugin_desc { - #else - #define CONNMAN_PLUGIN_DEFINE(name, description, version, priority, init, exit) \ - extern struct connman_debug_desc __start___debug[] \ -- __attribute__ ((weak, visibility("hidden"))); \ -+ __attribute__ ((weak, visibility("default"))); \ - extern struct connman_debug_desc __stop___debug[] \ -- __attribute__ ((weak, visibility("hidden"))); \ -+ __attribute__ ((weak, visibility("default"))); \ - extern struct connman_plugin_desc connman_plugin_desc \ - __attribute__ ((visibility("default"))); \ - struct connman_plugin_desc connman_plugin_desc = { \ diff --git a/meta/recipes-connectivity/connman/connman/no-version-scripts.patch b/meta/recipes-connectivity/connman/connman/no-version-scripts.patch deleted file mode 100644 index 3667a166f69346c3ca3592d179cc1baaa16cb1b4..0000000000000000000000000000000000000000 --- a/meta/recipes-connectivity/connman/connman/no-version-scripts.patch +++ /dev/null @@ -1,47 +0,0 @@ -From 67f37aafcc8ef5d2eb006387e7bec21f74518727 Mon Sep 17 00:00:00 2001 -From: Ross Burton -Date: Tue, 9 Aug 2016 12:12:02 +0100 -Subject: [PATCH] connman: disable version-scripts to fix crashes at startup - -With binutils 2.27 on at least MIPS, connmand will crash on startup. This -appears to be due to the symbol visibilty scripts hiding symbols that stdio -looks up at runtime, resulting in it segfaulting. - -This certainly appears to be a bug in binutils 2.27 although the problem has -been known about for some time: - -https://sourceware.org/bugzilla/show_bug.cgi?id=17908 - -As the version scripts are only used to hide symbols from plugins we can safely -remove the scripts to work around the problem until binutils is fixed. - -Upstream-Status: Inappropriate -Signed-off-by: Ross Burton ---- - Makefile.am | 6 ++---- - 1 file changed, 2 insertions(+), 4 deletions(-) - -diff --git a/Makefile.am b/Makefile.am -index 3dc3bb5..3be5ccb 100644 ---- a/Makefile.am -+++ b/Makefile.am -@@ -143,8 +143,7 @@ src_connmand_LDADD = gdbus/libgdbus-internal.la $(builtin_libadd) \ - @GIO_LIBS@ @GLIB_LIBS@ @DBUS_LIBS@ @GNUTLS_LIBS@ \ - -lresolv -ldl -lrt - --src_connmand_LDFLAGS = -Wl,--export-dynamic \ -- -Wl,--version-script=$(srcdir)/src/connman.ver -+src_connmand_LDFLAGS = -Wl,--export-dynamic - - src_connmand_wait_online_SOURCES = src/connmand-wait-online.c - -@@ -187,8 +186,7 @@ vpn_connman_vpnd_LDADD = gdbus/libgdbus-internal.la $(builtin_vpn_libadd) \ - @GIO_LIBS@ @GLIB_LIBS@ @DBUS_LIBS@ @GNUTLS_LIBS@ \ - -lresolv -ldl - --vpn_connman_vpnd_LDFLAGS = -Wl,--export-dynamic \ -- -Wl,--version-script=$(srcdir)/vpn/vpn.ver -+vpn_connman_vpnd_LDFLAGS = -Wl,--export-dynamic - endif - - BUILT_SOURCES = $(local_headers) src/builtin.h $(service_files) \ diff --git a/meta/recipes-connectivity/connman/connman_1.44.bb b/meta/recipes-connectivity/connman/connman_1.44.bb index 1cd97d342f894bcffa6a7ed80ac8dc23e6a0565d..553a377684c67190bbf274a28759bc1825b21d75 100644 --- a/meta/recipes-connectivity/connman/connman_1.44.bb +++ b/meta/recipes-connectivity/connman/connman_1.44.bb @@ -7,8 +7,7 @@ It is a fully modular system that can be extended, through plug-ins, \ to support all kinds of wired or wireless technologies. Also, \ configuration methods, like DHCP and domain name resolving, are \ implemented using plug-ins." -HOMEPAGE = "http://connman.net/" -BUGTRACKER = "https://01.org/jira/browse/CM" +HOMEPAGE = "https://web.git.kernel.org/pub/scm/network/connman/connman.git/about/" LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ file://src/main.c;beginline=1;endline=20;md5=486a279a6ab0c8d152bcda3a5b5edc36" @@ -20,10 +19,8 @@ CVE_PRODUCT = "connman connection_manager" DEPENDS = "dbus glib-2.0 ppp" SRC_URI = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \ - file://0001-plugin.h-Change-visibility-to-default-for-debug-symb.patch \ file://0001-connman.service-stop-systemd-resolved-when-we-use-co.patch \ file://connman \ - file://no-version-scripts.patch \ file://0002-resolve-musl-does-not-implement-res_ninit.patch \ " @@ -116,10 +113,10 @@ do_install:append() { # plugins directory to be present for ownership mkdir -p ${D}${libdir}/connman/plugins - # For read-only filesystem, do not create links during bootup - if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then - ln -sf ../run/connman/resolv.conf ${D}${sysconfdir}/resolv-conf.connman - fi + # For read-only filesystem, do not create links during bootup + if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then + ln -sf ../run/connman/resolv.conf ${D}${sysconfdir}/resolv-conf.connman + fi } # These used to be plugins, but now they are core From patchwork Thu Apr 3 10:52:56 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Kiernan X-Patchwork-Id: 60661 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id AC5F7C3601E for ; Thu, 3 Apr 2025 10:53:20 +0000 (UTC) Received: from mail-wm1-f41.google.com (mail-wm1-f41.google.com [209.85.128.41]) by mx.groups.io with SMTP id smtpd.web11.10509.1743677594853640776 for ; Thu, 03 Apr 2025 03:53:15 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=iSi/UiJ4; spf=pass (domain: gmail.com, ip: 209.85.128.41, mailfrom: alex.kiernan@gmail.com) Received: by mail-wm1-f41.google.com with SMTP id 5b1f17b1804b1-43ce71582e9so4746055e9.1 for ; Thu, 03 Apr 2025 03:53:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1743677592; x=1744282392; darn=lists.openembedded.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=LQ2Smdhos5X/wqThW34tLKDGw8QfTTCTTVTEeJECMyo=; b=iSi/UiJ4dLDxJ1N+9d4Al3IcIOZFk2DS6zNj+Kr191byP3APoLyNHQGrXp9jcF6vou j+gXKSmES7/InOWWfKaGRsaCYSzqVBMAaNxcFXieRwqdHVqhkIUkNocDgkY6twYQhW2R aUrA/6IBqmDl8fMIpSI5Q/NXvZCFvdioBHL4mnPhrRHij6mMLAAkugbqua/l00G5nROW bI2drixKYGwA93fe9zKZziZ2AWar62/IuRJpSu/MOhTc8lkEM+arZX0AFWScspa+Zsyh oPPR5AiOgh+wsHbb0PfpPhJNZfQT8/rrDh7NDCqr4SlY31nScW9rrli68UsH/Qj1Yhg5 lNbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743677592; x=1744282392; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LQ2Smdhos5X/wqThW34tLKDGw8QfTTCTTVTEeJECMyo=; b=OkgwcxEiiGKaGcjkezZ4ISnMsJZ0g4XHVoJoz160uluIurLGvWUnwWxzLAt+ju80PN C3YvacJQahGlfKGBzZlstZI+vSU6PSn29AVsdNOS1LMWc5mXogzFuBp5bgJsbm70xCyG Ah3ZXzWQoLsmuDpV9SbSz2f0USFNtQz8aG8NTmXW2lN04bebuFri5k4m0+6WkHoDWfak OVXG50OVzgeiI8QpoHwMSJjq8qHpAkBxiiN+KyDu2iiITOl6cY+QJb5D5D8eCp1m75ce CMkMc2FxTbFL2OqZN8ExzRNmIzH/Si4VU1fecAKg/YF8F6cOl1k1mklaAM3NGTZYYE81 Ig/Q== X-Gm-Message-State: AOJu0YyHRdU9D+cKBfLoLsLQrP48p7YLm14ttwGKH6SzeNXwBwoNSSUj yI+rmbtIjKrHxmEao2zJP+eI/Hab/w7ZD3BRMqqZUGW33cB4LamJBVWVf+VN X-Gm-Gg: ASbGnct8Y7kaYMKSHOC7Jnddl7tVjsxmajBxNsMQZrv5pkb4+gQOASuu9uKocdSFvWN kly6CITN7alPK8kB6EX033Rdpn5UDhd1/g82WBN2sZmZALdtndJpmedOWnuCDxvZgfkRZQ756eY vnWzQ/P0rdZq5oDohiwEqLMQTl4pyi3LzPB2BJZC80zauFDgk+UCZ/AlSFn8LuzfPXBBF8v9XDi ueQnmcJ0raAS/ELA+aWD9Rfm/ioEialey9ZG7ln3C4FPx/UwuGVfJ76HhjBQoPtgKXfEreqtubc UP/ZrmGj2+e6cQaivn6RQC9cseu5KYNvQ4wEwkmhHCeZBgdZ9zJrBfi5PktSHhVpc4xSuD7pftc MDtUX/pNrK/MW3h/XyCVXjQ== X-Google-Smtp-Source: AGHT+IH9FKGwNoRSxt3PTMCtrR/nVKYAKD/tL0IFDnGakAgCAHqiXfof0wkBAB5ajgT9kAyx8gaCwg== X-Received: by 2002:a05:600c:8705:b0:43d:2313:7b4a with SMTP id 5b1f17b1804b1-43db61b33b9mr233194975e9.3.1743677592143; Thu, 03 Apr 2025 03:53:12 -0700 (PDT) Received: from ip-10-0-0-134.eu-west-1.compute.internal ([2a05:d018:db1:fb00:c4f8:7a97:b7aa:1bfd]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43ec1630ddesm18346865e9.5.2025.04.03.03.53.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 03:53:11 -0700 (PDT) From: Alex Kiernan Date: Thu, 03 Apr 2025 10:52:56 +0000 Subject: [PATCH OE-Core v2 3/6] connman: Move ppp from DEPENDS to PACKAGECONFIG MIME-Version: 1.0 Message-Id: <20250403-connman-v2-3-8bb637312ba8@gmail.com> References: <20250403-connman-v2-0-8bb637312ba8@gmail.com> In-Reply-To: <20250403-connman-v2-0-8bb637312ba8@gmail.com> To: openembedded-core@lists.openembedded.org Cc: Alex Kiernan X-Mailer: b4 0.14.2 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 03 Apr 2025 10:53:20 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/214314 ppp is only required by connman when building the L2TP or PPTP plugins. Move it from DEPENDS to PACKAGECONFIG so it's only there when required. Signed-off-by: Alex Kiernan --- meta/recipes-connectivity/connman/connman_1.44.bb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meta/recipes-connectivity/connman/connman_1.44.bb b/meta/recipes-connectivity/connman/connman_1.44.bb index 553a377684c67190bbf274a28759bc1825b21d75..aa9da070dec1b4aac02019ae9c3158256b534c61 100644 --- a/meta/recipes-connectivity/connman/connman_1.44.bb +++ b/meta/recipes-connectivity/connman/connman_1.44.bb @@ -16,7 +16,7 @@ inherit autotools pkgconfig systemd update-rc.d update-alternatives CVE_PRODUCT = "connman connection_manager" -DEPENDS = "dbus glib-2.0 ppp" +DEPENDS = "dbus glib-2.0" SRC_URI = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \ file://0001-connman.service-stop-systemd-resolved-when-we-use-co.patch \ @@ -63,8 +63,8 @@ PACKAGECONFIG[iwd] = "--enable-iwd,--disable-iwd,,iwd" PACKAGECONFIG[tist] = "--enable-tist,--disable-tist," PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" -PACKAGECONFIG[l2tp] = "--enable-l2tp --with-l2tp=${sbindir}/xl2tpd,--disable-l2tp,,xl2tpd" -PACKAGECONFIG[pptp] = "--enable-pptp --with-pptp=${sbindir}/pptp,--disable-pptp,,pptp-linux" +PACKAGECONFIG[l2tp] = "--enable-l2tp --with-l2tp=${sbindir}/xl2tpd,--disable-l2tp,ppp,xl2tpd" +PACKAGECONFIG[pptp] = "--enable-pptp --with-pptp=${sbindir}/pptp,--disable-pptp,ppp,pptp-linux" # WISPr support for logging into hotspots, requires TLS PACKAGECONFIG[wispr] = "--enable-wispr,--disable-wispr,gnutls," PACKAGECONFIG[nftables] = "--with-firewall=nftables ,,libmnl libnftnl,,kernel-module-nf-tables kernel-module-nft-chain-nat-ipv4 kernel-module-nft-chain-route-ipv4 kernel-module-nft-masq-ipv4 kernel-module-nft-nat" From patchwork Thu Apr 3 10:52:57 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Kiernan X-Patchwork-Id: 60664 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id B9C81C369A2 for ; Thu, 3 Apr 2025 10:53:20 +0000 (UTC) Received: from mail-wm1-f41.google.com (mail-wm1-f41.google.com [209.85.128.41]) by mx.groups.io with SMTP id smtpd.web10.10570.1743677595466333171 for ; Thu, 03 Apr 2025 03:53:15 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=OvMTJN4/; spf=pass (domain: gmail.com, ip: 209.85.128.41, mailfrom: alex.kiernan@gmail.com) Received: by mail-wm1-f41.google.com with SMTP id 5b1f17b1804b1-43cf628cb14so13185135e9.1 for ; Thu, 03 Apr 2025 03:53:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1743677593; x=1744282393; darn=lists.openembedded.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=dKgHRp+KCryu1tfaIr4ltsx6sA1HvJeCrPE078aMM0U=; b=OvMTJN4/mcOaWTW3GRxeeb6f4AnamLoRgc3fSjh+qtNxsgi5RrAgQA2Wbof18lL9Q2 zCA3MZiL2kl4NURdXOZtNsios1CB6xwikxhlTgalfAahkowTAqKFoP5bgPzDG+qMaJ3g iYv5Qminw9Agm9YSpqYEPSwPmUNn/iN9uraaHDlC1j/TpSXohTJqw/qh+FH6IosHi/xd IuFCWT7Fmty8WZbZgROxQC+eaiBOiqBIiDDrNV/Xv4mEUvpauNorg7J2QLZqNZrbObi7 +r3iFGkgj+069cDNacD5N/5MFniB1+9w3JOlan1lfSUqqCzEH58Vds+OsIJL+mCMGs3o x/BA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743677593; x=1744282393; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dKgHRp+KCryu1tfaIr4ltsx6sA1HvJeCrPE078aMM0U=; b=OgDXhxIy+clRRBhsvO3t4EJtlNRDjwJhuE4Pu/USqyeUGbN5Rvc+1BQsfnmJ9UB5h6 xJKuWfJ8RomTRrfJWJDj0UxMdDBYlUCoABwHKtlM7641YNTidMsq8MIh4hhNZhWU14UV KJ5t5VJZQn4IHRe0MdijH5Qid3hQ1lMF4LM6+LYejs0vMfmBquE5hLVL9ARDp/cnKxXr L/iPpbhM06xNpiEISrtjY7Pk2jCq6imrGhOHkhxOpCoBVc1axtizaldc5NU3LBCDKvCU BXR5qt2gxJY6gtmRmk/paBsx80s4ET4bGEzG5YQmEhd/rqyu8yVwIWTe8TZOkddOcAGT LI5Q== X-Gm-Message-State: AOJu0Yw4A0lv4RvWS57/K2yN4+T+mX5A4soLVyslTL50zyZlDJpM8pwF eZwhQrw/53GUda7uuBt0WzCyofJHCacl4pwCkNQ3zs0bULyMBWzROGHbCjsw X-Gm-Gg: ASbGncsMJA0Y/RH/oGsgmp6qfIrZjQzrV9zUiXjMY2l/A6S2+7od5mYY3muJaeModr4 VeUodokBWZeiJ85cBLPW+HI19lk5rkRne0QycBHMi9cVdrjnHGc5PMJ4iYZsfTRvQiYtJ7ezlzp wkSsIWWEzoO0St0KjMNTJoWw95brGUJC8HK96vPMokzfWAx8Ot6gWSoRtK9GcVKjto6jTT3x0DA FNK91EKher2JWj10FvzxSlKPAWOEVQP1l1G0HqXFhJCh21G3ghkyX1PsG0OeAXeUiE1+2jbHiOl /x1DLNAGDtmRXIk9PXppu5iDM9GAvopIlPzuISgZNjd5SiczykfLZMzY0uUeFEd88ziQD6y5p3O m+q8vVIH7og0= X-Google-Smtp-Source: AGHT+IF3ucxeWHSWRNlgn8sI/iZVaw+O+JBPDFb2CWKB7NRc6sLbDrH8y73sFw2cGHzBU6w308GaCg== X-Received: by 2002:a05:6000:240a:b0:391:bc8:564a with SMTP id ffacd0b85a97d-39c2e6510f0mr2814808f8f.22.1743677592795; Thu, 03 Apr 2025 03:53:12 -0700 (PDT) Received: from ip-10-0-0-134.eu-west-1.compute.internal ([2a05:d018:db1:fb00:c4f8:7a97:b7aa:1bfd]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43ec1630ddesm18346865e9.5.2025.04.03.03.53.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 03:53:12 -0700 (PDT) From: Alex Kiernan Date: Thu, 03 Apr 2025 10:52:57 +0000 Subject: [PATCH OE-Core v2 4/6] connman: Add all build options as PACKAGECONFIG MIME-Version: 1.0 Message-Id: <20250403-connman-v2-4-8bb637312ba8@gmail.com> References: <20250403-connman-v2-0-8bb637312ba8@gmail.com> In-Reply-To: <20250403-connman-v2-0-8bb637312ba8@gmail.com> To: openembedded-core@lists.openembedded.org Cc: Alex Kiernan X-Mailer: b4 0.14.2 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 03 Apr 2025 10:53:20 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/214315 Add all missing build options as PACKAGECONFIG items. Add CONNMAN_FIREWALL to select iptables or nftables (one is required). Set dns-backend automatically based on systemd-resolved in DISTRO_FEATURES, then drop "connman.service: stop systemd-resolved when we use connman" as we now use connman's systemd-resolved support. Signed-off-by: Alex Kiernan --- ...vice-stop-systemd-resolved-when-we-use-co.patch | 26 ------- meta/recipes-connectivity/connman/connman_1.44.bb | 85 +++++++++++++--------- 2 files changed, 50 insertions(+), 61 deletions(-) diff --git a/meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-resolved-when-we-use-co.patch b/meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-resolved-when-we-use-co.patch deleted file mode 100644 index 4597fe68fcdf6f301247747c52b1d4636ebec631..0000000000000000000000000000000000000000 --- a/meta/recipes-connectivity/connman/connman/0001-connman.service-stop-systemd-resolved-when-we-use-co.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 19aff57e4da920d9ca972903582305b4efe81ef3 Mon Sep 17 00:00:00 2001 -From: "Maxin B. John" -Date: Mon, 12 Jun 2017 16:52:39 +0300 -Subject: [PATCH] connman.service: stop systemd-resolved when we use connman - -Stop systemd-resolved service when we use connman as network manager. - -Upstream-Status: Inappropriate [configuration] - -Signed-off-by: Maxin B. John ---- - src/connman.service.in | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/connman.service.in b/src/connman.service.in -index 7376346..79e75d6 100644 ---- a/src/connman.service.in -+++ b/src/connman.service.in -@@ -6,6 +6,7 @@ RequiresMountsFor=@localstatedir@/lib/connman - After=dbus.service network-pre.target systemd-sysusers.service - Before=network.target multi-user.target shutdown.target - Wants=network.target -+Conflicts=systemd-resolved.service - - [Service] - Type=dbus diff --git a/meta/recipes-connectivity/connman/connman_1.44.bb b/meta/recipes-connectivity/connman/connman_1.44.bb index aa9da070dec1b4aac02019ae9c3158256b534c61..f9c3291b5c4d234f08d17dcb06d93e69aeaf85f5 100644 --- a/meta/recipes-connectivity/connman/connman_1.44.bb +++ b/meta/recipes-connectivity/connman/connman_1.44.bb @@ -12,65 +12,79 @@ LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e \ file://src/main.c;beginline=1;endline=20;md5=486a279a6ab0c8d152bcda3a5b5edc36" -inherit autotools pkgconfig systemd update-rc.d update-alternatives - CVE_PRODUCT = "connman connection_manager" DEPENDS = "dbus glib-2.0" SRC_URI = "${KERNELORG_MIRROR}/linux/network/${BPN}/${BP}.tar.xz \ - file://0001-connman.service-stop-systemd-resolved-when-we-use-co.patch \ file://connman \ file://0002-resolve-musl-does-not-implement-res_ninit.patch \ - " +" SRC_URI[sha256sum] = "2be2b00321632b775f9eff713acd04ef21e31fbf388f6ebf45512ff4289574ff" +inherit autotools pkgconfig systemd update-rc.d update-alternatives + +RDEPENDS:${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'wifi', '${WIRELESS_DAEMON}', '', d)}" RRECOMMENDS:${PN} = "connman-conf" -RCONFLICTS:${PN} = "networkmanager" EXTRA_OECONF += "\ - ac_cv_path_WPASUPPLICANT=${sbindir}/wpa_supplicant \ - ac_cv_path_PPPD=${sbindir}/pppd \ - --enable-debug \ - --enable-loopback \ - --enable-ethernet \ + --enable-datafiles \ --enable-tools \ - --disable-polkit \ - --runstatedir=/run \ + --runstatedir='${runtimedir}' \ + --with-dns-backend='${@bb.utils.contains("DISTRO_FEATURES", "systemd-resolved", "systemd-resolved", "internal", d)}' \ + ac_cv_path_IP6TABLES_SAVE=${sbindir}/ip6tables-save \ + ac_cv_path_IPTABLES_SAVE=${sbindir}/iptables-save \ + ac_cv_path_PPPD=${sbindir}/pppd \ + ac_cv_path_WPASUPPLICANT=${sbindir}/wpa_supplicant \ " + # For smooth operation it would be best to start only one wireless daemon at a time. # If wpa-supplicant is running, connman will use it preferentially. # Select either wpa-supplicant or iwd WIRELESS_DAEMON ??= "wpa-supplicant" -PACKAGECONFIG ??= "wispr iptables client\ - ${@bb.utils.filter('DISTRO_FEATURES', '3g systemd', d)} \ - ${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', 'bluez', '', d)} \ - ${@bb.utils.contains('DISTRO_FEATURES', 'wifi', 'wifi ${WIRELESS_DAEMON}', '', d)} \ +# Choose "iptables" or "nftables" +CONNMAN_FIREWALL ??= "iptables" + +# Default is 16kB +CONNMAN_STATS_MAX_FILE_SIZE ??= "16384" + +PACKAGECONFIG ??= "client ethernet loopback wispr ${CONNMAN_FIREWALL} \ + ${@bb.utils.filter('DISTRO_FEATURES', '3g bluetooth nfc polkit selinux systemd usbgadget wifi', d)} \ + ${@bb.utils.filter('WIRELESS_DAEMON', 'iwd', d)} \ " -# If you want ConnMan to support VPN, add following statement into -# local.conf or distro config -# PACKAGECONFIG:append:pn-connman = " openvpn vpnc l2tp pptp" - -PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_system_unitdir}/ --with-tmpfilesdir=${sysconfdir}/tmpfiles.d/,--with-systemdunitdir='' --with-tmpfilesdir=''" -PACKAGECONFIG[wifi] = "--enable-wifi, --disable-wifi" -PACKAGECONFIG[bluez] = "--enable-bluetooth, --disable-bluetooth, bluez5, bluez5" -PACKAGECONFIG[3g] = "--enable-ofono, --disable-ofono, ofono, ofono" -PACKAGECONFIG[wpa-supplicant] = ",,wpa-supplicant,wpa-supplicant" -PACKAGECONFIG[iwd] = "--enable-iwd,--disable-iwd,,iwd" -PACKAGECONFIG[tist] = "--enable-tist,--disable-tist," -PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" -PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" +PACKAGECONFIG[3g] = "--enable-ofono,--disable-ofono,ofono" +PACKAGECONFIG[bluetooth] = "--enable-bluetooth,--disable-bluetooth,bluez5,bluez5" +PACKAGECONFIG[client] = "--enable-client,--disable-client,readline" +PACKAGECONFIG[dundee] = "--enable-dundee,--disable-dundee" +PACKAGECONFIG[ethernet] = "--enable-ethernet,--disable-ethernet" +PACKAGECONFIG[hh2serial-gps] = "--enable-hh2serial-gps,--disable-hh2serial-gps" +PACKAGECONFIG[iospm] = "--enable-iospm,--disable-iospm" +PACKAGECONFIG[iptables] = "--with-firewall=iptables,,iptables,,,nftables" +PACKAGECONFIG[iwd] = "--enable-iwd,--disable-iwd" +PACKAGECONFIG[loopback] = "--enable-loopback,--disable-loopback" +PACKAGECONFIG[nfc] = "--enable-neard,--disable-neard,neard" +PACKAGECONFIG[nftables] = "--with-firewall=nftables,,libmnl libnftnl,,kernel-module-nf-tables kernel-module-nft-chain-nat-ipv4 kernel-module-nft-chain-route-ipv4 kernel-module-nft-masq-ipv4 kernel-module-nft-nat,iptables" +PACKAGECONFIG[nmcompat] = "--enable-nmcompat,--disable-nmcompat" +PACKAGECONFIG[pacrunner] = "--enable-pacrunner,--disable-pacrunner" +PACKAGECONFIG[polkit] = "--enable-polkit,--disable-polkit,polkit" +PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux" +PACKAGECONFIG[session-policy-local] = "--enable-session-policy-local,--disable-session-policy-local" +PACKAGECONFIG[stats] = "--enable-stats --with-stats-max-file-size=${CONNMAN_STATS_MAX_FILE_SIZE},--disable-stats" +PACKAGECONFIG[systemd] = "--with-systemdunitdir=${systemd_system_unitdir}/ --with-tmpfilesdir=${nonarch_libdir}/tmpfiles.d/,--with-systemdunitdir='' --with-tmpfilesdir=''" +PACKAGECONFIG[test] = "--enable-test,--disable-test" +PACKAGECONFIG[tist] = "--enable-tist,--disable-tist" +PACKAGECONFIG[usbgadget] = "--enable-gadget,--disable-gadget" +PACKAGECONFIG[wifi] = "--enable-wifi,--disable-wifi" +PACKAGECONFIG[wispr] = "--enable-wispr,--disable-wispr,gnutls" + PACKAGECONFIG[l2tp] = "--enable-l2tp --with-l2tp=${sbindir}/xl2tpd,--disable-l2tp,ppp,xl2tpd" +PACKAGECONFIG[openconnect] = "--enable-openconnect --with-openconnect=${sbindir}/openconnect,--disable-openconnect,openconnect,openconnect" +PACKAGECONFIG[openvpn] = "--enable-openvpn --with-openvpn=${sbindir}/openvpn,--disable-openvpn,,openvpn" PACKAGECONFIG[pptp] = "--enable-pptp --with-pptp=${sbindir}/pptp,--disable-pptp,ppp,pptp-linux" -# WISPr support for logging into hotspots, requires TLS -PACKAGECONFIG[wispr] = "--enable-wispr,--disable-wispr,gnutls," -PACKAGECONFIG[nftables] = "--with-firewall=nftables ,,libmnl libnftnl,,kernel-module-nf-tables kernel-module-nft-chain-nat-ipv4 kernel-module-nft-chain-route-ipv4 kernel-module-nft-masq-ipv4 kernel-module-nft-nat" -PACKAGECONFIG[iptables] = "--with-firewall=iptables ,,iptables,iptables" -PACKAGECONFIG[nfc] = "--enable-neard, --disable-neard, neard, neard" -PACKAGECONFIG[client] = "--enable-client,--disable-client,readline" +PACKAGECONFIG[vpnc] = "--enable-vpnc --with-vpnc=${sbindir}/vpnc,--disable-vpnc,,vpnc" PACKAGECONFIG[wireguard] = "--enable-wireguard,--disable-wireguard,libmnl" INITSCRIPT_NAME = "connman" @@ -115,6 +129,7 @@ do_install:append() { # For read-only filesystem, do not create links during bootup if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then + install -d ${D}${sysconfdir} ln -sf ../run/connman/resolv.conf ${D}${sysconfdir}/resolv-conf.connman fi } From patchwork Thu Apr 3 10:52:58 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Kiernan X-Patchwork-Id: 60659 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 99BDDC3600C for ; Thu, 3 Apr 2025 10:53:20 +0000 (UTC) Received: from mail-wm1-f51.google.com (mail-wm1-f51.google.com [209.85.128.51]) by mx.groups.io with SMTP id smtpd.web10.10571.1743677596863841219 for ; Thu, 03 Apr 2025 03:53:17 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=FUp9tyn4; spf=pass (domain: gmail.com, ip: 209.85.128.51, mailfrom: alex.kiernan@gmail.com) Received: by mail-wm1-f51.google.com with SMTP id 5b1f17b1804b1-43948021a45so6774225e9.1 for ; Thu, 03 Apr 2025 03:53:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1743677595; x=1744282395; darn=lists.openembedded.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=P5bF+fYFKwfiX0xZLU99gbhSGjmBzx/avz7t1eKdXUg=; b=FUp9tyn4BU9ZusPQgeRfZMV7Z3URrDW/o7zNDXkJbF/eq3zGKzfhfcWqP/2N6VEBYX o0Vs6fa+gw7kjwydyVSdzFmfudKQJivePCCrrE3uwQgNiMytcNGyGKkFq6es3Lsb81xs MzrPRy+OmwtwDDGrwcevCBbFciu2niyv16uA9ji6d8MkLFUd9PMHqT7BPjxycOX7unSx B6apg85hH0R7kQbzPkL3DJgPfXagG+x3dbKPEnvsYnSKCK09OVZKAiYI+8dO1yWNw0ek wk7UTvgSbTaLRuGm62lQx3LlOVAWCfSi2SCUG25VLdzDgD0/DpwMENywS/fjTC9U3I1l 8qvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743677595; x=1744282395; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=P5bF+fYFKwfiX0xZLU99gbhSGjmBzx/avz7t1eKdXUg=; b=fJuIcnbtvgP40tR1BVluMBYT7m9kW18h9W2S1aEyTKcUOWXPQPOYJKQ5PRmkfj52LM pl6wOBbMirWRHMIatmZXCRv+PNBoX+u1fjLVv72y5VvuONwdQ0YZiTSyXSjlf+IEF3wv HF8vWMt/23dKGhiLBuUElf3N4kbF6DrScDInNFTViaDJM1vvkaGo4r93xDdqSR+xBjsD S98MQzIt0Au1vS2T5prub5kazNU4sZm0ZgEOSCNyT1XNnYxojJYrJ9cEOrWhb7hyhiez MOsqpL6aK/voh8IQbgzjKXHxotZPpOlq0mQVhZ2zeRPRoKBoAiqOri/PJUAEOENBHtoh JJqA== X-Gm-Message-State: AOJu0YxyXf7LuqzTRoo7iU+8jYWrkSZxcNeTNbJwD1HfoCADcc0M/uHY 9QXYVANC57VNb5BbXLB+8KwxBJcxepYdrmB5AdCLb/ZSU72xDanHldM2cUKO X-Gm-Gg: ASbGnctWmkyQ27Ze8CtvuTvc5VzyknAyUzrsdOusSPNBVAMGQw53WlbPy00C/oHeZW9 vSNbzaidLOnd2ryej+3GkohQ0pVZk182vFh4llwUwyN0ALBM+08O5x1Pjju4ZVBSscmbClx+oU2 ayyCFUR3GGHUdJlsNHAGVUbn4uqHxvpVxOHYxk1qLGS5/e2MW+X2hHo5J1GDmncJs2FjTDdlHrP BB8SI/GtOAEB5CqlE+U5ABhlKU1tsNRzyfvi3PAE/pH78YvYuk+v6upEbxXa3f+mzFjXSPCG20J 2HrEj8/u6u7rEHRV72oFisLrJnByV1pjw4EnNFZeSahlyY/QOIRHcJhTLQ2AyVOc7liE43sETSo ZY6tYeHsTNv8= X-Google-Smtp-Source: AGHT+IGSRRJu5lH2+ZvGeR9tC5piVOx92OtA8ul9u5tV+S9tHh7EpCfcANmTT4iptwoid6PuXHCJXg== X-Received: by 2002:a05:600c:1ca9:b0:43c:fbbf:7bf1 with SMTP id 5b1f17b1804b1-43db62bf861mr227029865e9.30.1743677594580; Thu, 03 Apr 2025 03:53:14 -0700 (PDT) Received: from ip-10-0-0-134.eu-west-1.compute.internal ([2a05:d018:db1:fb00:c4f8:7a97:b7aa:1bfd]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43ec1630ddesm18346865e9.5.2025.04.03.03.53.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 03:53:12 -0700 (PDT) From: Alex Kiernan Date: Thu, 03 Apr 2025 10:52:58 +0000 Subject: [PATCH OE-Core v2 5/6] build-appliance-image: Drop connman-plugin-ethernet MIME-Version: 1.0 Message-Id: <20250403-connman-v2-5-8bb637312ba8@gmail.com> References: <20250403-connman-v2-0-8bb637312ba8@gmail.com> In-Reply-To: <20250403-connman-v2-0-8bb637312ba8@gmail.com> To: openembedded-core@lists.openembedded.org Cc: Alex Kiernan X-Mailer: b4 0.14.2 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 03 Apr 2025 10:53:20 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/214316 connman-plugin-ethernet is just a legacy alias for connman. Ethernet support, if built, is always part of core connman. Signed-off-by: Alex Kiernan --- meta/recipes-core/images/build-appliance-image_15.0.0.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/recipes-core/images/build-appliance-image_15.0.0.bb b/meta/recipes-core/images/build-appliance-image_15.0.0.bb index 03f02d14ae87fad9c3c11938c29b9bb35ab823e3..c5ddea79005ea0464201a6ab70cd75bc541e0ebb 100644 --- a/meta/recipes-core/images/build-appliance-image_15.0.0.bb +++ b/meta/recipes-core/images/build-appliance-image_15.0.0.bb @@ -6,7 +6,7 @@ LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" IMAGE_INSTALL = "packagegroup-core-boot packagegroup-core-ssh-openssh packagegroup-self-hosted \ - kernel-dev kernel-devsrc connman connman-plugin-ethernet dhcpcd \ + kernel-dev kernel-devsrc connman dhcpcd \ tzdata python3-pip perl-misc" IMAGE_FEATURES += "x11-base package-management splash" From patchwork Thu Apr 3 10:52:59 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Kiernan X-Patchwork-Id: 60663 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id BB396C369A3 for ; Thu, 3 Apr 2025 10:53:20 +0000 (UTC) Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) by mx.groups.io with SMTP id smtpd.web11.10512.1743677597745516118 for ; Thu, 03 Apr 2025 03:53:18 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20230601 header.b=ieIAHh+4; spf=pass (domain: gmail.com, ip: 209.85.221.50, mailfrom: alex.kiernan@gmail.com) Received: by mail-wr1-f50.google.com with SMTP id ffacd0b85a97d-3995ff6b066so406117f8f.3 for ; Thu, 03 Apr 2025 03:53:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1743677595; x=1744282395; darn=lists.openembedded.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=/wL+JCTFwfUlAvTGjEUi/1fzrvwyxMqJwGBM6Qiyr2g=; b=ieIAHh+4z/x6ohoOfo/9vv9B/kMlD0v2EAom69NHu64jNjI24s8ZQI49z/gBiJ+f8W YVNcqhYn5aUgZhiF2YkUWtfhGslf4ckLIrFaxKgQKq/WUtWiW47UyJEBzjH8/TT0Q1g7 qLgMK7g1HHIrsU7YuWbTDcIJLoSGekOaHK/NMHaTgPgJnH4vOA64JeI4O/g5JAJ0edQL JfqteiZu26XCjO/G+vmlhuG16toY8Uu70A7cH5Cb+i8EkpLZ3d2lJqGpZlbEIuvnDcLp KXVfB2UGbLx7MVW/CPG1GTt1Eb155ioDCkk3OSkTuN1xhRwvcgxcHCXMDlqhQKtLjLrS jCfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743677595; x=1744282395; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/wL+JCTFwfUlAvTGjEUi/1fzrvwyxMqJwGBM6Qiyr2g=; b=OK7vgpS4QUQViPtMhsKHZqjDQv7OKm88Yas5rjDAW+xcSc5WtcS06tL4bQoaygYKfK B/o6T5pQ+rTmEO43b8A7sTjzle+WGRckucwApWF/1ZpiTIiIDPRAgXa/+J9Y3fqE5vKv IfJLL0zIn/QWXb1VJHIWOEHuUNgIif0Q1KmVgJQdj5dRPT4ojymztO4n4KRhhdwO3vvN sk4IiA8OU7/pf4rQRBWkW7AQh6ECrw+tuIMmPfTnK2mUzQPWPuKimXZE3NUQgCOKks2n cS13XYdgzwT/Yt+ILrkxY9abPB2tTu3jGWh8QHlThUKT9pm7N5PvKQTJxgT7gALEXUI/ ypGQ== X-Gm-Message-State: AOJu0YyBgGs4A0HmfDaF7bDGE9bu61iuVQ3xI8YgL5ZzFlBhYsz7xSdi PK8oqe39hfWnszjlqgPefzRN1M/zy1ckpnGvNE0lqoJH9fgs88pJLCUkZoWw X-Gm-Gg: ASbGncvOSnXRPbbgA0/2Dpv2GvwWkk3vOeyqq4FGlkvMt1OC2flwGe2Sdc6iL8punPK YZp5Hn+kJPACbkvVzNtb9WbuPvfj2yuic9q9lo/7cU/s3sX5xyJ6EF1iDBX0D2Eg5ZFepO9ZYtD UYPZvnsBj3guOl8jXjW6DGWLzuAKdkbU0ri2CvysUHGWwLyLPy99dzl6KblnXCVPoZ00Hyfb4Ua 8xRMqt+xSN1noo6py8rK+vQqLxF7IMofxTnLJPpZ95m/LI6wg0TYsfxByrnHoJuEMb6a84G2peg OMw3N/IOCzYjmjTbCTo6BBehlWc4W5PIBO2mJxLjS4nsimDeuYySmWo5VlWGS0FpuA2OLdiRN2W GyOpsF2oQ7bYVQaTmUO3xBg== X-Google-Smtp-Source: AGHT+IEcoi4l3p7e5WOozSS1AntvXfIiSzZQhvNeRw7LLsov9lPBOV3c9Gw4PzAHYPTLSQX7ITKopg== X-Received: by 2002:adf:e952:0:b0:391:3028:c779 with SMTP id ffacd0b85a97d-39c2f9444ecmr1548864f8f.45.1743677595164; Thu, 03 Apr 2025 03:53:15 -0700 (PDT) Received: from ip-10-0-0-134.eu-west-1.compute.internal ([2a05:d018:db1:fb00:c4f8:7a97:b7aa:1bfd]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-43ec1630ddesm18346865e9.5.2025.04.03.03.53.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 03:53:14 -0700 (PDT) From: Alex Kiernan Date: Thu, 03 Apr 2025 10:52:59 +0000 Subject: [PATCH OE-Core v2 6/6] connman: Rework to avoid splitting into many single binary packages MIME-Version: 1.0 Message-Id: <20250403-connman-v2-6-8bb637312ba8@gmail.com> References: <20250403-connman-v2-0-8bb637312ba8@gmail.com> In-Reply-To: <20250403-connman-v2-0-8bb637312ba8@gmail.com> To: openembedded-core@lists.openembedded.org Cc: Alex Kiernan X-Mailer: b4 0.14.2 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Thu, 03 Apr 2025 10:53:20 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/214317 This recipe predates PACKAGECONFIG (or maybe widespread usage?) and so to use the VPN options they had to be both enabled at the PACKAGECONFIG level and then included as a separate package. In addition the list of VPN packages has drifted so (for example) wireguard was not delivered this way. Remove most of the subordinate packages and just populate the main connman package based on PACKAGECONFIG. Keep connman-client separate as `connmanctl` has a dependency on readline (which is GPLv3 licensed) and separate out connman-tools for `stats-tool` and connman-tests for all the test binaries (which possibly in the future could be used as the basis of a ptest package). Signed-off-by: Alex Kiernan --- meta/recipes-connectivity/connman/connman_1.44.bb | 161 +++++----------------- 1 file changed, 36 insertions(+), 125 deletions(-) diff --git a/meta/recipes-connectivity/connman/connman_1.44.bb b/meta/recipes-connectivity/connman/connman_1.44.bb index f9c3291b5c4d234f08d17dcb06d93e69aeaf85f5..92641d36792fd3aedafc1a52f2e376fdcb9f40db 100644 --- a/meta/recipes-connectivity/connman/connman_1.44.bb +++ b/meta/recipes-connectivity/connman/connman_1.44.bb @@ -90,17 +90,11 @@ PACKAGECONFIG[wireguard] = "--enable-wireguard,--disable-wireguard,libmnl" INITSCRIPT_NAME = "connman" INITSCRIPT_PARAMS = "start 05 5 2 3 . stop 22 0 1 6 ." -python __anonymous () { - systemd_packages = "${PN} ${PN}-wait-online" - pkgconfig = d.getVar('PACKAGECONFIG') - if ('openvpn' or 'vpnc' or 'l2tp' or 'pptp') in pkgconfig.split(): - systemd_packages += " ${PN}-vpn" - d.setVar('SYSTEMD_PACKAGES', systemd_packages) -} - -SYSTEMD_SERVICE:${PN} = "connman.service" -SYSTEMD_SERVICE:${PN}-vpn = "connman-vpn.service" -SYSTEMD_SERVICE:${PN}-wait-online = "connman-wait-online.service" +SYSTEMD_SERVICE:${PN} = "\ + connman.service \ + connman-wait-online.service \ + ${@bb.utils.contains_any('PACKAGECONFIG', ['openconnect', 'openvpn', 'vpnc', 'l2tp', 'pptp', 'wireguard'], 'connman-vpn.service', '', d)} \ +" ALTERNATIVE_PRIORITY = "100" ALTERNATIVE:${PN} = "${@bb.utils.contains('DISTRO_FEATURES','systemd','resolv-conf','',d)}" @@ -114,18 +108,15 @@ do_install:append() { sed -i s%@DATADIR@%${datadir}% ${D}${sysconfdir}/init.d/connman fi - install -d ${D}${bindir} - install -m 0755 ${B}/tools/*-test ${D}${bindir} - if [ -e ${B}/tools/wispr ]; then - install -m 0755 ${B}/tools/wispr ${D}${bindir} - fi + for noinst_program in ${NOINST_TESTS} ${NOINST_TOOLS}; do + if [ -r "${B}/$noinst_program" ]; then + install -d ${D}${bindir} + install -m 0755 "${B}/$noinst_program" ${D}${bindir} + fi + done # We don't need to package an empty directory - rmdir --ignore-fail-on-non-empty ${D}${libdir}/connman/scripts - - # Automake 1.12 won't install empty directories, but we need the - # plugins directory to be present for ownership - mkdir -p ${D}${libdir}/connman/plugins + rmdir --ignore-fail-on-non-empty ${D}${libdir}/connman/scripts ${D}${libdir}/connman # For read-only filesystem, do not create links during bootup if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then @@ -134,113 +125,33 @@ do_install:append() { fi } -# These used to be plugins, but now they are core -RPROVIDES:${PN} = "\ - connman-plugin-loopback \ - connman-plugin-ethernet \ - ${@bb.utils.contains('PACKAGECONFIG', 'bluetooth','connman-plugin-bluetooth', '', d)} \ - ${@bb.utils.contains('PACKAGECONFIG', 'wifi','connman-plugin-wifi', '', d)} \ - ${@bb.utils.contains('PACKAGECONFIG', '3g','connman-plugin-ofono', '', d)} \ - " - -PACKAGES_DYNAMIC += "^${PN}-plugin-.*" - -def add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, add_insane_skip): - plugintype = pkg.split( '-' )[-1] - if plugintype in depmap: - rdepends = map(lambda x: multilib_prefix + x, \ - depmap[plugintype].split()) - d.setVar("RDEPENDS:%s" % pkg, " ".join(rdepends)) - if add_insane_skip: - d.appendVar("INSANE_SKIP:%s" % pkg, "dev-so") - -python populate_packages:prepend() { - depmap = dict(pppd="ppp") - multilib_prefix = (d.getVar("MLPREFIX") or "") - - hook = lambda file,pkg,x,y,z: \ - add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, False) - plugin_dir = d.expand('${libdir}/connman/plugins/') - plugin_name = d.expand('${PN}-plugin-%s') - do_split_packages(d, plugin_dir, r'^(.*).so$', plugin_name, \ - '${PN} plugin for %s', extra_depends='', hook=hook, prepend=True ) - - hook = lambda file,pkg,x,y,z: \ - add_rdepends(bb, d, file, pkg, depmap, multilib_prefix, True) - plugin_dir = d.expand('${libdir}/connman/plugins-vpn/') - plugin_name = d.expand('${PN}-plugin-vpn-%s') - do_split_packages(d, plugin_dir, r'^(.*).so$', plugin_name, \ - '${PN} VPN plugin for %s', extra_depends='', hook=hook, prepend=True ) -} - -PACKAGES =+ "${PN}-tools ${PN}-tests ${PN}-client" +NOINST_TESTS = "tools/supplicant-test tools/dhcp-test tools/dhcp-server-test \ + tools/addr-test tools/web-test tools/resolv-test tools/dbus-test \ + tools/polkit-test tools/wpad-test tools/private-network-test \ + tools/session-test tools/dnsproxy-test tools/iptables-test tools/ip6tables-test \ + tools/iptables-unit tools/dnsproxy-standalone \ + unit/test-ippool unit/test-iptables \ +" +NOINST_TOOLS = "tools/stats-tool tools/wispr" -FILES:${PN}-tools = "${bindir}/wispr" -RDEPENDS:${PN}-tools = "${PN}" +PACKAGE_BEFORE_PN = "${PN}-client ${PN}-tests ${PN}-tools" -FILES:${PN}-tests = "${bindir}/*-test" +FILES:${PN} += " \ + ${datadir}/dbus-1/system-services \ + ${datadir}/dbus-1/system.d \ + ${datadir}/polkit-1 \ + ${nonarch_libdir}/tmpfiles.d/*.conf \ +" FILES:${PN}-client = "${bindir}/connmanctl" RDEPENDS:${PN}-client = "${PN}" -FILES:${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*.so.* \ - ${libdir}/connman/plugins \ - ${sysconfdir} ${sharedstatedir} ${localstatedir} ${datadir} \ - ${base_bindir}/* ${base_sbindir}/* ${base_libdir}/*.so* ${datadir}/${PN} \ - ${datadir}/dbus-1/system-services/* \ - ${sysconfdir}/tmpfiles.d/connman_resolvconf.conf" - -FILES:${PN}-dev += "${libdir}/connman/*/*.la" - -PACKAGES =+ "${PN}-vpn ${PN}-wait-online" - -SUMMARY:${PN}-vpn = "A daemon for managing VPN connections within embedded devices" -DESCRIPTION:${PN}-vpn = "The ConnMan VPN provides a daemon for \ -managing VPN connections within embedded devices running the Linux \ -operating system. The connman-vpnd handles all the VPN connections \ -and starts/stops VPN client processes when necessary. The connman-vpnd \ -provides a DBus API for managing VPN connections. All the different \ -VPN technogies are implemented using plug-ins." -FILES:${PN}-vpn += "${sbindir}/connman-vpnd \ - ${sysconfdir}/dbus-1/system.d/connman-vpn-dbus.conf \ - ${datadir}/dbus-1/system-services/net.connman.vpn.service \ - ${systemd_system_unitdir}/connman-vpn.service" - -SUMMARY:${PN}-wait-online = "A program that will return once ConnMan has connected to a network" -DESCRIPTION:${PN}-wait-online = "A service that can be enabled so that \ -the system waits until a network connection is established." -FILES:${PN}-wait-online += "${sbindir}/connmand-wait-online \ - ${systemd_system_unitdir}/connman-wait-online.service" - -SUMMARY:${PN}-plugin-vpn-openvpn = "An OpenVPN plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-openvpn = "The ConnMan OpenVPN plugin uses openvpn client \ -to create a VPN connection to OpenVPN server." -FILES:${PN}-plugin-vpn-openvpn += "${libdir}/connman/scripts/openvpn-script \ - ${libdir}/connman/plugins-vpn/openvpn.so" -RDEPENDS:${PN}-plugin-vpn-openvpn += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','openvpn','${PN}-plugin-vpn-openvpn', '', d)}" - -SUMMARY:${PN}-plugin-vpn-vpnc = "A vpnc plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-vpnc = "The ConnMan vpnc plugin uses vpnc client \ -to create a VPN connection to Cisco3000 VPN Concentrator." -FILES:${PN}-plugin-vpn-vpnc += "${libdir}/connman/scripts/openconnect-script \ - ${libdir}/connman/plugins-vpn/vpnc.so \ - ${libdir}/connman/scripts/vpn-script" -RDEPENDS:${PN}-plugin-vpn-vpnc += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','vpnc','${PN}-plugin-vpn-vpnc', '', d)}" - -SUMMARY:${PN}-plugin-vpn-l2tp = "A L2TP plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-l2tp = "The ConnMan L2TP plugin uses xl2tpd daemon \ -to create a VPN connection to L2TP server." -FILES:${PN}-plugin-vpn-l2tp += "${libdir}/connman/scripts/libppp-plugin.so* \ - ${libdir}/connman/plugins-vpn/l2tp.so" -RDEPENDS:${PN}-plugin-vpn-l2tp += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','l2tp','${PN}-plugin-vpn-l2tp', '', d)}" - -SUMMARY:${PN}-plugin-vpn-pptp = "A PPTP plugin for ConnMan VPN" -DESCRIPTION:${PN}-plugin-vpn-pptp = "The ConnMan PPTP plugin uses pptp-linux client \ -to create a VPN connection to PPTP server." -FILES:${PN}-plugin-vpn-pptp += "${libdir}/connman/scripts/libppp-plugin.so* \ - ${libdir}/connman/plugins-vpn/pptp.so" -RDEPENDS:${PN}-plugin-vpn-pptp += "${PN}-vpn" -RRECOMMENDS:${PN} += "${@bb.utils.contains('PACKAGECONFIG','pptp','${PN}-plugin-vpn-pptp', '', d)}" +FILES:${PN}-tests = "${@ ' '.join([os.path.join('${bindir}', os.path.basename(noinst_program)) for noinst_program in NOINST_TESTS.split()]) }" +RDEPENDS:${PN}-tests = "${PN} \ + ${@bb.utils.contains('PACKAGECONFIG', 'iptables', 'iptables', '', d)} \ +" +ALLOW_EMPTY:${PN}-tests = "1" + +FILES:${PN}-tools = "${@ ' '.join([os.path.join('${bindir}', os.path.basename(noinst_program)) for noinst_program in NOINST_TOOLS.split()]) }" +RDEPENDS:${PN}-tools = "${PN}" +ALLOW_EMPTY:${PN}-tools = "1"