#[unsafe(link_section = ".init_array.00099")]static ARGV_INIT_ARRAY: extern "C" fn(c_int, *const *const u8, *const *const u8)
Available on Linux and GNU and (Linux or Android or FreeBSD or DragonFly BSD or NetBSD or OpenBSD or Cygwin or Solaris or illumos or Emscripten or Haiku or HermitCore or L4Re or Fuchsia or Redox or
target_os=vxworks
or target_os=horizon
or target_os=aix
or target_os=nto
or target_os=hurd
or target_os=rtems
or target_os=nuttx
) only.Expand description
glibc passes argc, argv, and envp to functions in .init_array, as a non-standard extension.
This allows std::env::args
to work even in a cdylib
, as it does on macOS and Windows.