Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable copy_file_range on FreeBSD #3023

Merged
merged 1 commit into from Dec 1, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions libc-test/build.rs
Expand Up @@ -2304,6 +2304,7 @@ fn test_freebsd(target: &str) {
"getlocalbase" if Some(13) > freebsd_ver => true,
"aio_readv" if Some(13) > freebsd_ver => true,
"aio_writev" if Some(13) > freebsd_ver => true,
"copy_file_range" if Some(13) > freebsd_ver => true,

_ => false,
}
Expand Down
1 change: 1 addition & 0 deletions libc-test/semver/freebsd.txt
Expand Up @@ -1517,6 +1517,7 @@ clearerr
clock_getcpuclockid
clock_getres
clock_settime
copy_file_range
cmsgcred
cmsghdr
cpuset
Expand Down
9 changes: 0 additions & 9 deletions src/unix/bsd/freebsdlike/freebsd/freebsd13/mod.rs
Expand Up @@ -527,15 +527,6 @@ extern "C" {
policy: ::c_int,
) -> ::c_int;

pub fn copy_file_range(
infd: ::c_int,
inoffp: *mut ::off_t,
outfd: ::c_int,
outoffp: *mut ::off_t,
len: ::size_t,
flags: ::c_uint,
) -> ::ssize_t;

pub fn dirname(path: *mut ::c_char) -> *mut ::c_char;
pub fn basename(path: *mut ::c_char) -> *mut ::c_char;
}
Expand Down
9 changes: 0 additions & 9 deletions src/unix/bsd/freebsdlike/freebsd/freebsd14/mod.rs
Expand Up @@ -527,15 +527,6 @@ extern "C" {
policy: ::c_int,
) -> ::c_int;

pub fn copy_file_range(
infd: ::c_int,
inoffp: *mut ::off_t,
outfd: ::c_int,
outoffp: *mut ::off_t,
len: ::size_t,
flags: ::c_uint,
) -> ::ssize_t;

pub fn dirname(path: *mut ::c_char) -> *mut ::c_char;
pub fn basename(path: *mut ::c_char) -> *mut ::c_char;
}
Expand Down
9 changes: 9 additions & 0 deletions src/unix/bsd/freebsdlike/freebsd/mod.rs
Expand Up @@ -3954,6 +3954,15 @@ extern "C" {
pub fn aio_write(aiocbp: *mut aiocb) -> ::c_int;
pub fn aio_writev(aiocbp: *mut ::aiocb) -> ::c_int;

pub fn copy_file_range(
infd: ::c_int,
inoffp: *mut ::off_t,
outfd: ::c_int,
outoffp: *mut ::off_t,
len: ::size_t,
flags: ::c_uint,
) -> ::ssize_t;

pub fn devname_r(
dev: ::dev_t,
mode: ::mode_t,
Expand Down