Skip to content

Commit

Permalink
freebsd adding execvpe support from 14.1 release
Browse files Browse the repository at this point in the history
  • Loading branch information
devnexen committed Aug 12, 2024
1 parent e209061 commit 67d062f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libc-test/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2489,6 +2489,8 @@ fn test_freebsd(target: &str) {
cfg.skip_fn(move |name| {
// skip those that are manually verified
match name {
// This is introduced in FreeBSD 14.1
"execvpe" => true,
// The `uname` function in the `utsname.h` FreeBSD header is a C
// inline function (has no symbol) that calls the `__xuname` symbol.
// Therefore the function pointer comparison does not make sense for it.
Expand Down
1 change: 1 addition & 0 deletions libc-test/semver/freebsd.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1873,6 +1873,7 @@ eui64_hostton
eui64_ntoa
eui64_ntohost
exect
execvpe
execvP
explicit_bzero
extattr_delete_fd
Expand Down
6 changes: 6 additions & 0 deletions src/unix/bsd/freebsdlike/freebsd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5534,6 +5534,12 @@ extern "C" {
idx1: ::c_ulong,
idx2: ::c_ulong,
) -> ::c_int;

pub fn execvpe(
file: *const ::c_char,
argv: *const *const ::c_char,
envp: *const *const ::c_char,
) -> ::c_int;
}

#[link(name = "memstat")]
Expand Down

0 comments on commit 67d062f

Please sign in to comment.