-
Notifications
You must be signed in to change notification settings - Fork 164
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
[6.1] Fix WASI build of _copyDirectoryMetadata
#1099
[6.1] Fix WASI build of _copyDirectoryMetadata
#1099
Conversation
Extended attributes don't exist in WASI, so we need to exclude the use of xattr-related APIs including `flistxattr`.
* Gate `fchown` and `fchmod` calls behind `os(WASI)` They are not available on WASI, so we gate them behind `os(WASI)`. * Add missing constant shims for wasi-libc * Use `futimens` instead of legacy `futimes` wasi-libc does not provide `futimes` as it is a legacy function. https://github.com/WebAssembly/wasi-libc/blob/574b88da481569b65a237cb80daf9a2d5aeaf82d/libc-top-half/musl/include/sys/time.h#L34
@swift-ci please test |
Anything holding this up? I need it for Android too. |
I'm waiting @parkera's approval just in case. |
@parkera, just need your approval here, can get this in. |
@kateinoigakukun, please add my Android change from main, 90700c1, to this pull, would like to get that into 6.1 also. |
Normal users don't have permission to change these, even for their own files.
@swift-ci test |
Thanks, Yuta. @itingliu, OK to merge? Most of this pull is gated to WASI and Android, other than the |
Explanation: Fix build issues in WASI platform, which are introduced in #1083
Scope: Impacts FileManager.copyItem(atPath:toPath:) on non-Windows platforms
Original PR: #1094 and #1095
Risk: Low - replace a legacy libc function call with a modern one, gate a few parts behind
os(WASI)
Testing: swift-ci testing
Reviewer: @jmschonfeld