diff options
Diffstat (limited to 'usr/include/sys/auxv.h')
-rw-r--r-- | usr/include/sys/auxv.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/usr/include/sys/auxv.h b/usr/include/sys/auxv.h new file mode 100644 index 0000000..fc98ed4 --- /dev/null +++ b/usr/include/sys/auxv.h @@ -0,0 +1,17 @@ +#ifndef _SYS_AUXV_H +#define _SYS_AUXV_H + +#include <klibc/compiler.h> +#include <klibc/extern.h> +#include <elf.h> + +#define _AUXVAL_MAX AT_SYSINFO_EHDR + +__extern unsigned long __auxval[_AUXVAL_MAX]; + +__static_inline unsigned long getauxval(unsigned long __t) +{ + return (__t >= _AUXVAL_MAX) ? 0 : __auxval[__t]; +} + +#endif /* _SYS_AUXV_H */ |