Skip to content

Remove inconv linking on apple #3526

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

Merged
merged 1 commit into from
Jan 7, 2024
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions libc-test/semver/apple.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1951,9 +1951,6 @@ getxattr
glob
glob_t
globfree
iconv
iconv_close
iconv_open
iconv_t
id_t
idtype_t
Expand Down
16 changes: 0 additions & 16 deletions src/unix/bsd/apple/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6492,22 +6492,6 @@ cfg_if! {
}
}

// These require a dependency on `libiconv`, and including this when built as
// part of `std` means every Rust program gets it. Ideally we would have a link
// modifier to only include these if they are used, but we do not.
#[cfg_attr(not(feature = "rustc-dep-of-std"), link(name = "iconv"))]
extern "C" {
pub fn iconv_open(tocode: *const ::c_char, fromcode: *const ::c_char) -> iconv_t;
pub fn iconv(
cd: iconv_t,
inbuf: *mut *mut ::c_char,
inbytesleft: *mut ::size_t,
outbuf: *mut *mut ::c_char,
outbytesleft: *mut ::size_t,
) -> ::size_t;
pub fn iconv_close(cd: iconv_t) -> ::c_int;
}

cfg_if! {
if #[cfg(target_pointer_width = "32")] {
mod b32;
Expand Down