Skip to content
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: 3 additions & 0 deletions Sources/System/Internals/CInterop.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ import Glibc
import Musl
#elseif canImport(WASILibc)
import WASILibc
#elseif canImport(Bionic)
@_implementationOnly import CSystem
import Bionic
#else
#error("Unsupported Platform")
#endif
Expand Down
2 changes: 2 additions & 0 deletions Sources/System/Internals/Constants.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ import Musl
#elseif canImport(WASILibc)
import CSystem
import WASILibc
#elseif canImport(Android)
import Android
#else
#error("Unsupported Platform")
#endif
Expand Down
8 changes: 8 additions & 0 deletions Sources/System/Internals/Exports.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ import Glibc
import Musl
#elseif canImport(WASILibc)
import WASILibc
#elseif canImport(Android)
@_implementationOnly import CSystem
import Android
#else
#error("Unsupported Platform")
#endif
Expand Down Expand Up @@ -65,6 +68,11 @@ internal var system_errno: CInt {
get { WASILibc.errno }
set { WASILibc.errno = newValue }
}
#elseif canImport(Android)
internal var system_errno: CInt {
get { Android.errno }
set { Android.errno = newValue }
}
#endif

// MARK: C stdlib decls
Expand Down
2 changes: 2 additions & 0 deletions Sources/System/Internals/Syscalls.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ import Musl
import WASILibc
#elseif os(Windows)
import ucrt
#elseif canImport(Android)
import Android
#else
#error("Unsupported Platform")
#endif
Expand Down