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

Unix: Support more platforms with preadv and pwritev #122880

Merged
merged 1 commit into from
Mar 27, 2024

Conversation

a1phyr
Copy link
Contributor

@a1phyr a1phyr commented Mar 22, 2024

  • aix, dragonfly and openbsd with direct call
  • watchos with weak linkage

cc #89517

@rustbot
Copy link
Collaborator

rustbot commented Mar 22, 2024

r? @ChrisDenton

rustbot has assigned @ChrisDenton.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added O-unix Operating system: Unix-like S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Mar 22, 2024
@workingjubilee
Copy link
Contributor

Trading with Chris for some Unix API reviews now for Windows API reviews later. :^)

r? @workingjubilee

@workingjubilee
Copy link
Contributor

@a1phyr Could you document which WatchOS version has these calls, please? So we can make them unconditional in the future, potentially. Thanks!

@workingjubilee
Copy link
Contributor

I assume the version for the rest introducing them is "since basically forever" but if you happen to know a version number attaching those would be good too, since we don't explicitly document a specific version supported for OpenBSD or DragonflyBSD.

@workingjubilee
Copy link
Contributor

Thanks!

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Mar 26, 2024

📌 Commit ff6d9f7 has been approved by workingjubilee

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 26, 2024
workingjubilee added a commit to workingjubilee/rustc that referenced this pull request Mar 26, 2024
…kingjubilee

Unix: Support more platforms with `preadv` and `pwritev`

- `aix`, `dragonfly` and `openbsd` with direct call
- `watchos` with weak linkage

cc rust-lang#89517
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 27, 2024
…iaskrgr

Rollup of 7 pull requests

Successful merges:

 - rust-lang#122439 (match lowering: build the `Place` instead of keeping a `PlaceBuilder` around)
 - rust-lang#122880 (Unix: Support more platforms with `preadv` and `pwritev`)
 - rust-lang#123038 (std library thread.rs: fix NetBSD code for ILP32 CPUs.)
 - rust-lang#123084 (`UnixStream`: override `read_buf`)
 - rust-lang#123102 (RustWrapper: update call for llvm/llvm-project@44d037cc258dcf179d2c48…)
 - rust-lang#123107 (Implement `Vec::pop_if`)
 - rust-lang#123118 (Update `RwLock` deadlock example to not use shadowing)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 4bdf171 into rust-lang:master Mar 27, 2024
11 checks passed
@rustbot rustbot added this to the 1.79.0 milestone Mar 27, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Mar 27, 2024
Rollup merge of rust-lang#122880 - a1phyr:preadv_more_platform, r=workingjubilee

Unix: Support more platforms with `preadv` and `pwritev`

- `aix`, `dragonfly` and `openbsd` with direct call
- `watchos` with weak linkage

cc rust-lang#89517
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Apr 21, 2024
…link-for-watchos-and-visionos, r=workingjubilee

Fix watchOS and visionOS for pread64 and pwrite64 calls

In rust-lang#122880, links to `preadv64` and `pwritev64` were added for `watchOS` however the underlying [`weak!` macro did not include `target_os = "watchos"`](https://github.com/rust-lang/rust/blob/c45dee5efd0c042e9d1e24559ebd0d6424d8aa70/library/std/src/sys/pal/unix/weak.rs#L30-L74).

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.
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Apr 21, 2024
Rollup merge of rust-lang#124089 - simlay:fix-preadv64-and-pwritev64-link-for-watchos-and-visionos, r=workingjubilee

Fix watchOS and visionOS for pread64 and pwrite64 calls

In rust-lang#122880, links to `preadv64` and `pwritev64` were added for `watchOS` however the underlying [`weak!` macro did not include `target_os = "watchos"`](https://github.com/rust-lang/rust/blob/c45dee5efd0c042e9d1e24559ebd0d6424d8aa70/library/std/src/sys/pal/unix/weak.rs#L30-L74).

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.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

None yet

5 participants