diff options
author | Khem Raj <raj.khem@gmail.com> | 2022-08-06 21:15:41 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-08 15:41:37 +0100 |
commit | e9eecb01c6742411531af1e269de467dcc8ef794 (patch) | |
tree | 7998c9bbef32bae182b75c5273352ac3eba31fd5 /meta/recipes-bsp | |
parent | a9136a30c56ff1d63043558b9cbaaae3e302aef7 (diff) | |
download | openembedded-core-e9eecb01c6742411531af1e269de467dcc8ef794.tar.gz |
efivar: Fix build with glibc 2.36
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-bsp')
-rw-r--r-- | meta/recipes-bsp/efivar/efivar/0001-Fix-glibc-2.36-build-mount.h-conflicts.patch | 60 | ||||
-rw-r--r-- | meta/recipes-bsp/efivar/efivar_38.bb | 1 |
2 files changed, 61 insertions, 0 deletions
diff --git a/meta/recipes-bsp/efivar/efivar/0001-Fix-glibc-2.36-build-mount.h-conflicts.patch b/meta/recipes-bsp/efivar/efivar/0001-Fix-glibc-2.36-build-mount.h-conflicts.patch new file mode 100644 index 0000000000..28dadabe6b --- /dev/null +++ b/meta/recipes-bsp/efivar/efivar/0001-Fix-glibc-2.36-build-mount.h-conflicts.patch @@ -0,0 +1,60 @@ +From 7b0e7ba674321ec1ddd6b9cbb419e5fb44f88bb3 Mon Sep 17 00:00:00 2001 +From: Robbie Harwood <rharwood@redhat.com> +Date: Thu, 28 Jul 2022 16:11:24 -0400 +Subject: [PATCH] Fix glibc 2.36 build (mount.h conflicts) + +glibc has decided that sys/mount.h and linux/mount.h are no longer +usable at the same time. This broke the build, since linux/fs.h itself +includes linux/mount.h. For now, fix the build by only including +sys/mount.h where we need it. + +See-also: https://sourceware.org/glibc/wiki/Release/2.36#Usage_of_.3Clinux.2Fmount.h.3E_and_.3Csys.2Fmount.h.3E +Resolves: #227 + +Upstream-Status: Backport [https://github.com/rhboot/efivar/commit/bc65d63ebf8fe6ac8a099ff15ca200986dba1565] +Signed-off-by: Robbie Harwood <rharwood@redhat.com> +--- + src/gpt.c | 1 + + src/linux.c | 1 + + src/util.h | 1 - + 3 files changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/gpt.c b/src/gpt.c +index 1eda049..21413c3 100644 +--- a/src/gpt.c ++++ b/src/gpt.c +@@ -17,6 +17,7 @@ + #include <stdio.h> + #include <stdlib.h> + #include <string.h> ++#include <sys/mount.h> + #include <sys/param.h> + #include <sys/stat.h> + #include <sys/utsname.h> +diff --git a/src/linux.c b/src/linux.c +index 47e45ae..1780816 100644 +--- a/src/linux.c ++++ b/src/linux.c +@@ -20,6 +20,7 @@ + #include <stdbool.h> + #include <stdio.h> + #include <sys/ioctl.h> ++#include <sys/mount.h> + #include <sys/socket.h> + #include <sys/sysmacros.h> + #include <sys/types.h> +diff --git a/src/util.h b/src/util.h +index 3300666..1e67e44 100644 +--- a/src/util.h ++++ b/src/util.h +@@ -23,7 +23,6 @@ + #include <stdio.h> + #include <string.h> + #include <sys/ioctl.h> +-#include <sys/mount.h> + #include <sys/stat.h> + #include <sys/types.h> + #include <tgmath.h> +-- +2.37.1 + diff --git a/meta/recipes-bsp/efivar/efivar_38.bb b/meta/recipes-bsp/efivar/efivar_38.bb index 42625fa041..6a6918931b 100644 --- a/meta/recipes-bsp/efivar/efivar_38.bb +++ b/meta/recipes-bsp/efivar/efivar_38.bb @@ -12,6 +12,7 @@ SRC_URI = "git://github.com/rhinstaller/efivar.git;branch=main;protocol=https \ file://0001-src-Makefile-build-util.c-separately-for-makeguids.patch \ file://efisecdb-fix-build-with-musl-libc.patch \ file://0001-Fix-invalid-free-in-main.patch \ + file://0001-Fix-glibc-2.36-build-mount.h-conflicts.patch \ " SRCREV = "1753149d4176ebfb2b135ac0aaf79340bf0e7a93" |