X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Fbasic%2Fmissing.h;h=19f41e87193b9974615aca1e9ca3dd6484dbc1d5;hp=d539ed00e4065e576ac67bc565df97c064580013;hb=838a00617ac09fbc0cb96d9117c87316b2a38e19;hpb=eaca07ccfdf5d7dabc50afc7e539c2413dd69d3e diff --git a/src/basic/missing.h b/src/basic/missing.h index d539ed00e..19f41e871 100644 --- a/src/basic/missing.h +++ b/src/basic/missing.h @@ -38,6 +38,8 @@ #include #include +#include "musl_missing.h" + #ifdef HAVE_AUDIT #include #endif @@ -131,6 +133,10 @@ #define NETLINK_LIST_MEMBERSHIPS 9 #endif +#ifndef SOL_SCTP +#define SOL_SCTP 132 +#endif + #if !HAVE_DECL_PIVOT_ROOT static inline int pivot_root(const char *new_root, const char *put_old) { return syscall(SYS_pivot_root, new_root, put_old); @@ -257,6 +263,7 @@ static inline int getrandom(void *buffer, size_t count, unsigned flags) { #define BTRFS_QGROUP_LEVEL_SHIFT 48 #endif +#if 0 /// UNNEEDED by elogind (It can not support BTRFS at all) #ifndef HAVE_LINUX_BTRFS_H struct btrfs_ioctl_vol_args { int64_t fd; @@ -507,6 +514,8 @@ struct btrfs_ioctl_quota_ctl_args { #define BTRFS_SUPER_MAGIC 0x9123683E #endif +#endif // 0 + #ifndef CGROUP_SUPER_MAGIC #define CGROUP_SUPER_MAGIC 0x27e0eb #endif @@ -970,6 +979,10 @@ static inline int setns(int fd, int nstype) { #define IFA_FLAGS 8 #endif +#ifndef IFA_F_MANAGETEMPADDR +#define IFA_F_MANAGETEMPADDR 0x100 +#endif + #ifndef IFA_F_NOPREFIXROUTE #define IFA_F_NOPREFIXROUTE 0x200 #endif @@ -1024,8 +1037,11 @@ static inline pid_t raw_getpid(void) { #endif } +#if 0 /// UNNEEDED by elogind + #if !HAVE_DECL_RENAMEAT2 + #ifndef __NR_renameat2 # if defined __x86_64__ # define __NR_renameat2 316 @@ -1125,3 +1141,4 @@ static inline key_serial_t request_key(const char *type, const char *description #ifndef KEY_SPEC_USER_KEYRING #define KEY_SPEC_USER_KEYRING -4 #endif +#endif // 0