mirror of
https://github.com/apple/swift-system
synced 2026-11-26 04:57:54 +00:00
v2: Use statfs on Linux and Android, make StatFS unavailable on WASI, omit Linux flags the kernel never reports, add descriptions for MountFlags and FileSystemID, and back-deploy CInterop.StatFS with CInterop.statfs(_:_:) for migration
This commit is contained in:
16 files changed
+958
-627
No files matched your search
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
This source file is part of the Swift System open source project
|
||||
|
||||
Copyright (c) 2026 Apple Inc. and the Swift System project authors
|
||||
Licensed under Apache License v2.0 with Runtime Library Exception
|
||||
|
||||
See https://swift.org/LICENSE.txt for license information
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
// Unlike the Musl and Android modules, Glibc doesn't export <sys/vfs.h>,
|
||||
// which declares `struct statfs` and `statfs()`/`fstatfs()`. SystemPackage
|
||||
// re-exports this module on glibc platforms so that clients can use the
|
||||
// raw `CInterop.StatFS` value under MemberImportVisibility.
|
||||
#if defined(__linux__) && !defined(__ANDROID__)
|
||||
#include <sys/vfs.h>
|
||||
#endif
|
||||
Reference in new issue
Block a user