mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-12-21 09:33:57 +03:00
glibc: Conditionally #include <linux/fs.h> to resolve fsconfig_command/mount_attr conflict with glibc 2.36
Co-authored-by: Frantisek Sumsal <frantisek@sumsal.cz> (cherry picked from commit1bb6ba08b1
) (cherry picked from commita8b9c4766d
) (cherry picked from commitf048fba73f
)
This commit is contained in:
parent
1adad5d279
commit
078ce6450a
@ -5,3 +5,4 @@ modifications are applied:
|
||||
- btrfs.h: drop '__user' attributes
|
||||
- if.h: drop '#include <linux/compiler.h>' and '__user' attributes
|
||||
- stddef.h: drop '#include <linux/compiler_types.h>'
|
||||
- guard linux/fs.h include to avoid conflict with glibc 2.36
|
||||
|
@ -26,7 +26,9 @@ extern "C" {
|
||||
|
||||
#include <linux/types.h>
|
||||
#include <linux/ioctl.h>
|
||||
#if WANT_LINUX_FS_H
|
||||
#include <linux/fs.h>
|
||||
#endif
|
||||
|
||||
#define BTRFS_IOCTL_MAGIC 0x94
|
||||
#define BTRFS_VOL_NAME_MAX 255
|
||||
|
@ -7,4 +7,5 @@ for i in *.h */*.h; do
|
||||
curl --fail "https://raw.githubusercontent.com/torvalds/linux/master/include/uapi/linux/$i" -o "$i"
|
||||
|
||||
sed -r -i -e 's/__user //g' -e '/^#include <linux\/compiler(_types)?.h>/ d' "$i"
|
||||
sed -r -i 's/^(#include <linux\/fs\.h>)/#if WANT_LINUX_FS_H\n\1\n#endif/' "$i"
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user