mirror of
https://codeberg.org/libreboot/lbmk.git
synced 2026-07-11 05:52:36 +02:00
util/nvmutil: enable arc4random on linux
not available on older systems. can just pass the relevant flag in the compiler: HAVE_ARC4RANDOM_BUF=0 at build time if you need the fallback. Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
@@ -15,8 +15,14 @@
|
||||
* -Os -Wall -Wextra -Werror -pedantic -std=c90
|
||||
*/
|
||||
|
||||
/*
|
||||
* NOTE: older Linux lacked arc4random.
|
||||
* added in glibc 2.36. Just pass HAVE_ARC4RANDOM_BUF=0
|
||||
* at build time if you need old Linux / other libc.
|
||||
*/
|
||||
#if defined(__OpenBSD__) || defined(__FreeBSD__) || \
|
||||
defined(__NetBSD__) || defined(__APPLE__)
|
||||
defined(__NetBSD__) || defined(__APPLE__) || \
|
||||
defined(__linux__)
|
||||
#ifndef HAVE_ARC4RANDOM_BUF
|
||||
#define HAVE_ARC4RANDOM_BUF 1
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user