--- openssl-1.1.1-pre8/crypto/rand/rand_unix.c.ori 2018-06-27 10:55:09.600476831 +0200 +++ openssl-1.1.1-pre8/providers/implementations/rands/seeding/rand_unix.c 2018-06-27 10:58:04.060361489 +0200 @@ -33,6 +33,26 @@ # include # include +#if defined(__linux) +#include +#if !defined(SYS_getrandom) +#if !defined(__NR_getrandom) +#if defined(__powerpc__) || defined(__powerpc64__) +#define __NR_getrandom 236 +#elif defined(__sparc__) || defined(__sparc64__) +#define __NR_getrandom 347 +#elif defined(__x86_64__) +#define __NR_getrandom 318 +#elif defined (__i386__) +#define __NR_getrandom 355 +#elif defined (__s390__) || defined(__s390x__) +#define __NR_getrandom 249 +#endif /* $arch */ +#endif /* __NR_getrandom */ +#define SYS_getrandom __NR_getrandom +#endif +#endif + static uint64_t get_time_stamp(void); static uint64_t get_timer_bits(void);