summaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb
diff options
context:
space:
mode:
authorChristophe Vu-Brugier <christophe.vu-brugier@seagate.com>2024-06-11 20:17:22 +0200
committerKhem Raj <raj.khem@gmail.com>2024-06-11 15:40:17 -0700
commit91274486931089418e59b5f0dcb28f6c472ac881 (patch)
tree683d14cacf19c46ca18ebb2d1d3dcd006f5b4b4a /meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb
parent45f1bd0933a0766b59d0fc3a1c3150ddcf8ffbf4 (diff)
downloadmeta-openembedded-91274486931089418e59b5f0dcb28f6c472ac881.tar.gz
usbguard: upgrade 1.1.2 -> 1.1.3
Drop patch 0001-include-missing-cstdint.patch because it was merged upstream. See this commit in usbguard: * 22b1e08 Fix build for GCC 13 + make GitHub Actions cover build with GCC 13 (#586) Signed-off-by: Christophe Vu-Brugier <christophe.vu-brugier@seagate.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb')
-rw-r--r--meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb69
1 files changed, 69 insertions, 0 deletions
diff --git a/meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb b/meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb
new file mode 100644
index 0000000000..752938057a
--- /dev/null
+++ b/meta-oe/recipes-security/usbguard/usbguard_1.1.3.bb
@@ -0,0 +1,69 @@
1# Copyright (c) 2021 Koninklijke Philips N.V.
2#
3# SPDX-License-Identifier: MIT
4#
5SUMMARY = "USBGuard daemon for blacklisting and whitelisting of USB devices"
6DESCRIPTION = "The USBGuard software framework helps to protect your computer against \
7rogue USB devices (a.k.a. Bad USB) by implementing basic whitelisting and blacklisting \
8capabilities based on device attributes. This recipe takes OpenSSL as crypto-backend for \
9computing device hashes (Supported values are sodium, gcrypt, openssl)."
10HOMEPAGE = "https://usbguard.github.io/"
11LICENSE = "GPL-2.0-only"
12LIC_FILES_CHKSUM = "file://LICENSE;md5=b234ee4d69f5fce4486a80fdaf4a4263"
13
14SRC_URI = "https://github.com/USBGuard/usbguard/releases/download/${BPN}-${PV}/${BPN}-${PV}.tar.gz \
15 file://0001-Add-and-use-pkgconfig-instead-of-libgcrypt-config.patch"
16
17SRC_URI[sha256sum] = "707dad2938923202697f636c2b4e0be80f192242039a2af3fc7ac35d03f78551"
18
19inherit autotools-brokensep bash-completion pkgconfig systemd github-releases
20
21DEPENDS = "glib-2.0-native libcap-ng libqb libxml2-native libxslt-native protobuf protobuf-native xmlto-native"
22
23UPSTREAM_CHECK_REGEX = "releases/tag/usbguard-(?P<pver>\d+(\.\d+)+)"
24
25EXTRA_OECONF += "\
26 --with-bundled-catch \
27 --with-bundled-pegtl \
28"
29
30PACKAGECONFIG ?= "\
31 openssl \
32 ${@bb.utils.filter('DISTRO_FEATURES', 'polkit', d)} \
33 ${@bb.utils.filter('DISTRO_FEATURES', 'seccomp', d)} \
34 ${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} \
35"
36
37# USBGuard has made polkit mandatory to configure with-dbus
38PACKAGECONFIG[dbus] = "--with-dbus,--without-dbus,dbus-glib polkit"
39PACKAGECONFIG[libgcrypt] = "--with-crypto-library=gcrypt,,libgcrypt,,,libsodium openssl"
40PACKAGECONFIG[libsodium] = "--with-crypto-library=sodium,,libsodium,,,libgcrypt openssl"
41PACKAGECONFIG[openssl] = "--with-crypto-library=openssl,,openssl,,,libgcrypt libsodium"
42PACKAGECONFIG[polkit] = "--with-polkit,--without-polkit,polkit"
43PACKAGECONFIG[seccomp] = "--enable-seccomp,--disable-seccomp,libseccomp"
44PACKAGECONFIG[systemd] = "--enable-systemd,--disable-systemd,systemd"
45
46SYSTEMD_PACKAGES = "${PN}"
47
48SYSTEMD_SERVICE:${PN} = "usbguard.service ${@bb.utils.contains('PACKAGECONFIG', 'dbus', 'usbguard-dbus.service', '', d)}"
49
50FILES:${PN} += "\
51 ${systemd_unitdir}/system/usbguard.service \
52 ${systemd_unitdir}/system/usbguard-dbus.service \
53 ${datadir}/polkit-1 \
54 ${datadir}/dbus-1 \
55 ${nonarch_libdir}/tmpfiles.d \
56"
57
58do_install:append() {
59# Create /var/log/usbguard in runtime.
60 if [ "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)}" ]; then
61 install -d ${D}${nonarch_libdir}/tmpfiles.d
62 echo "d ${localstatedir}/log/${BPN} 0755 root root -" > ${D}${nonarch_libdir}/tmpfiles.d/${BPN}.conf
63 fi
64 if [ "${@bb.utils.filter('DISTRO_FEATURES', 'sysvinit', d)}" ]; then
65 install -d ${D}${sysconfdir}/default/volatiles
66 echo "d root root 0755 ${localstatedir}/log/${BPN} none" > ${D}${sysconfdir}/default/volatiles/99_${BPN}
67 fi
68 rm -rf ${D}${localstatedir}/log
69}