diff options
author | vvvv <vvvv@ydb.tech> | 2023-11-11 13:38:56 +0300 |
---|---|---|
committer | vvvv <vvvv@ydb.tech> | 2023-11-11 13:55:14 +0300 |
commit | cca50b7e187292196c112b36ecc0b41149afe800 (patch) | |
tree | 34e420cd1a27c802413cecd66cf569d73aca38d2 /contrib | |
parent | 1dcff447d644bab4412e9baad644bfc5bbb27f92 (diff) | |
download | ydb-cca50b7e187292196c112b36ecc0b41149afe800.tar.gz |
fixed syscall numbers for different platforms
https://github.com/torvalds/linux/blob/29dcea88779c856c7dc92040a0c01233263101d4/include/uapi/asm-generic/unistd.h#L707
https://gpages.juszkiewicz.com.pl/syscalls-table/syscalls.html
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/libs/libc_compat/random/sys/random.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/contrib/libs/libc_compat/random/sys/random.h b/contrib/libs/libc_compat/random/sys/random.h index fcd94856e2..c33843ea23 100644 --- a/contrib/libs/libc_compat/random/sys/random.h +++ b/contrib/libs/libc_compat/random/sys/random.h @@ -7,7 +7,19 @@ extern "C" { #include <sys/types.h> #if !defined(SYS_getrandom) - #define SYS_getrandom 318 +#if defined(__x86_64__) + #define SYS_getrandom 318 +#elif defined(__i386__) + #define SYS_getrandom 355 +#elif defined(__aarch64__) + #define SYS_getrandom 278 +#elif defined(__arm__) + #define SYS_getrandom 384 +#elif defined(__powerpc__) + #define SYS_getrandom 359 +#else +#error Unsupported platform +#endif #endif #define GRND_NONBLOCK 0x0001 |