diff --git a/src/unix/mod.rs b/src/unix/mod.rs index 446038241f5d4..d799ec13f3b70 100644 --- a/src/unix/mod.rs +++ b/src/unix/mod.rs @@ -335,6 +335,10 @@ extern { pub fn chdir(dir: *const c_char) -> ::c_int; pub fn chown(path: *const c_char, uid: uid_t, gid: gid_t) -> ::c_int; + #[cfg_attr(all(target_os = "macos", target_arch = "x86"), + link_name = "lchown$UNIX2003")] + pub fn lchown(path: *const c_char, uid: uid_t, + gid: gid_t) -> ::c_int; #[cfg_attr(all(target_os = "macos", target_arch = "x86"), link_name = "close$UNIX2003")] pub fn close(fd: ::c_int) -> ::c_int;