Module auxv::getauxval
[−]
[src]
Read auxv entries one at a time via getauxval
.
Because the underlying getauxval
C function is weakly linked, and only available on Linux,
access to it is done via the trait Getauxval
to provide some indirection. On
target_os="linux"
, the struct NativeGetauxval
will be available, and that will call through
to getauxval
if it is available and return an appropriate error if it is not. That means it
should be safe to try it if you're not sure your glibc has the function, etc.
On all OSs, if you want a no-op sort of implementation (for use on non-Linux OSs, etc), you can
use NotAvailableGetauxval
. It (surprise!) always returns the error that indicates that
getauxval
function was not found. Of course, you can also use write your own stub
implementation of the trait for testing.
Structs
NotAvailableGetauxval |
A stub implementation that always returns |
Enums
GetauxvalError |
Errors from invoking |
Traits
Getauxval |
On Linux, you will probably want |