11 Commits

Author SHA1 Message Date
Khem Raj 9c02e30bef usbguard: fix bundled PEGTL demangle static_assert with GCC 16
The bundled PEGTL parses __PRETTY_FUNCTION__ at compile time and trips a
static_assert under GCC 16:

  src/ThirdParty/PEGTL/include/tao/pegtl/demangle.hpp:118:23:
  error: static assertion failed

usbguard demangles PEGTL rules built from ascii::one<'\000', '\012'>,
i.e. types with a char non-type template parameter whose value is '\0'.
GCC 16 renders such a parameter as a literal NUL byte and truncates
__PRETTY_FUNCTION__ there:

  constexpr std::string_view demangle() [with T = seq<one<'

so the trailing "; std::string_view = ...]" and even the closing ']' are
gone, and rfind(';')/rfind(']') both return npos.

Patch demangle() to fall back to the remainder of the string when no
';'/']' terminator survives, instead of failing the build; the demangled
name is only used for tracing diagnostics. Type names without a '\0' char
parameter are unaffected.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
2026-06-28 00:59:28 -07:00
Wang Mingyu c4b9a59fb4 usbguard: upgrade 1.1.3 -> 1.1.4
0001-Adapt-for-protobuf-30.0-API-changes.patch
removed since it's included in 1.1.4

Signed-off-by: Wang Mingyu <wangmy@fujitsu.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-07-30 16:40:03 -07:00
Khem Raj fc05019734 usbguard: Patch for protobuf 30.0 API changes
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2025-03-13 09:50:12 -07:00
Khem Raj 8bbdd8fe2d usbguard: Link with libatomic on rv32
Provides needed atomic intrinsics that compiler needs.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2024-09-17 07:50:22 -07:00
Christophe Vu-Brugier 9127448693 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>
2024-06-11 15:40:17 -07:00
Khem Raj 8744c20fc0 usbguard: Enable seccomp if distro features have it
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2023-09-10 06:49:11 -07:00
Khem Raj 87bf350726 usbguard: Fix build with gcc13
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2023-01-27 17:06:52 -08:00
Alex Kiernan ee624a6a7f usbguard: Upgrade 1.1.1 -> 1.1.2
Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2023-01-06 11:38:16 -08:00
Alex Kiernan f91cf84bda usbguard: Remove pegtl from DEPENDS
Using `DEPENDS = "pegtl"` with `--with-bundled-pegtl` doesn't make
sense, so drop the DEPENDS.

Also add github-releases checking for newer versions.

Drop redundant setting of `S` to the default.

Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2023-01-06 11:38:16 -08:00
Anu Deepthika, Nandipati 144a7fff1e usbguard: package simplification
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2022-03-29 08:28:38 -07:00
Anu Deepthika, Nandipati f6a753022f usbguard: Add inital recipe
Set one crypto-backend library at a time
OpenSSL is the crypto-backend library set for device hashing
Override PACKAGECONFIG to replace it with libsodium or libgcrypt

Signed-off-by: Anu Deepthika, Nandipati <Nandipati.AnuDeepthika@philips.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2022-03-24 09:45:25 -07:00