Skip to content

Fix watchOS and visionOS for pread64 and pwrite64 calls#124089

Merged
bors merged 1 commit intorust-lang:masterfrom
simlay:fix-preadv64-and-pwritev64-link-for-watchos-and-visionos
Apr 21, 2024
Merged

Fix watchOS and visionOS for pread64 and pwrite64 calls#124089
bors merged 1 commit intorust-lang:masterfrom
simlay:fix-preadv64-and-pwritev64-link-for-watchos-and-visionos

Conversation

@simlay
Copy link
Copy Markdown
Contributor

@simlay simlay commented Apr 17, 2024

In #122880, links to preadv64 and pwritev64 were added for watchOS however the underlying weak! macro did not include target_os = "watchos".

This resulted in an xcodebuild error when targeting watchOS:

Undefined symbols for architecture arm64:
  "_preadv64", referenced from:
      __rust_extern_with_linkage_preadv64 in libliveview_native_core.a[274](std-324fdd8d31e8eaa2.std.e18cf7e8d0336778-cgu.08.rcgu.o)
  "_pwritev64", referenced from:
      __rust_extern_with_linkage_pwritev64 in libliveview_native_core.a[274](std-324fdd8d31e8eaa2.std.e18cf7e8d0336778-cgu.08.rcgu.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

So I added them. I also went ahead and added the same for visionOS because it's bound to create the same issue.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-meta Area: Issues & PRs about the rust-lang/rust repository itself O-unix Operating system: Unix-like S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants