The Swift Package Index logo.Swift Package Index

Build Information

Failed to build UniSocket, reference 0.14.0 (1785e4), with Swift 6.3 for Wasm on 11 Apr 2026 09:05:27 UTC.

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4609320-2":/host -w "$PWD" -e JAVA_HOME="/root/.sdkman/candidates/java/current" -e SPI_BUILD="1" -e SPI_PROCESSING="1" registry.gitlab.com/swiftpackageindex/spi-images:wasm-6.3-latest swift build --swift-sdk swift-6.3-RELEASE_wasm 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.70.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/seznam/swift-unisocket.git
Reference: 0.14.0
Initialized empty Git repository in /host/spi-builder-workspace/.git/
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: 	git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: 	git branch -m <name>
From https://github.com/seznam/swift-unisocket
 * tag               0.14.0     -> FETCH_HEAD
HEAD is now at 1785e43 Update README.md.
Cloned https://github.com/seznam/swift-unisocket.git
Revision (git rev-parse @):
1785e432fb8497265a38712cdb9584c429ca3f96
SUCCESS checkout https://github.com/seznam/swift-unisocket.git at 0.14.0
========================================
Build
========================================
Selected platform:         wasm
Swift version:             6.3
Building package at path:  $PWD
https://github.com/seznam/swift-unisocket.git
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-2":/host -w "$PWD" -e JAVA_HOME="/root/.sdkman/candidates/java/current" -e SPI_BUILD="1" -e SPI_PROCESSING="1" registry.gitlab.com/swiftpackageindex/spi-images:wasm-6.3-latest swift build --swift-sdk swift-6.3-RELEASE_wasm 2>&1
wasm-6.3-latest: Pulling from swiftpackageindex/spi-images
Digest: sha256:d69f4e7582c319245442d62a08b2d7c7fd5a0c0c69f5d2ef11d1530cd8d3329b
Status: Image is up to date for registry.gitlab.com/swiftpackageindex/spi-images:wasm-6.3-latest
Fetching https://github.com/Bouke/DNS.git
[1/908] Fetching dns
Fetched https://github.com/Bouke/DNS.git from cache (0.41s)
Computing version for https://github.com/Bouke/DNS.git
Computed https://github.com/Bouke/DNS.git at 1.2.0 (2.92s)
Creating working copy for https://github.com/Bouke/DNS.git
Working copy of https://github.com/Bouke/DNS.git resolved at 1.2.0
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-24593BA9C3E375BF.txt
error: emit-module command failed with exit code 1 (use -v to see invocation)
[3/4] Emitting module UniSocket
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:73:50: error: cannot find type 'addrinfo' in scope
 71 | 	private let fdmask_bits: Int
 72 | 	private let peer: String
 73 | 	private var peer_addrinfo: UnsafeMutablePointer<addrinfo>
    |                                                  `- error: cannot find type 'addrinfo' in scope
 74 | 	private var peer_local = sockaddr_un()
 75 | 	private var buffer: UnsafeMutablePointer<UInt8>
[4/4] Compiling UniSocket UniSocket.swift
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:73:50: error: cannot find type 'addrinfo' in scope
 71 | 	private let fdmask_bits: Int
 72 | 	private let peer: String
 73 | 	private var peer_addrinfo: UnsafeMutablePointer<addrinfo>
    |                                                  `- error: cannot find type 'addrinfo' in scope
 74 | 	private var peer_local = sockaddr_un()
 75 | 	private var buffer: UnsafeMutablePointer<UInt8>
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:85:30: error: cannot find type 'fdmask' in scope
 83 | 		self.timeout = timeout
 84 | 		self.peer = peer
 85 | 		fdmask_size = MemoryLayout<fdmask>.size
    |                              `- error: cannot find type 'fdmask' in scope
 86 | 		fdmask_bits = fdmask_size * 8
 87 | 		buffer = UnsafeMutablePointer<UInt8>.allocate(capacity: bufferSize)
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:88:40: error: cannot find type 'addrinfo' in scope
 86 | 		fdmask_bits = fdmask_size * 8
 87 | 		buffer = UnsafeMutablePointer<UInt8>.allocate(capacity: bufferSize)
 88 | 		peer_addrinfo = UnsafeMutablePointer<addrinfo>.allocate(capacity: 1)
    |                                        `- error: cannot find type 'addrinfo' in scope
 89 | 		memset(peer_addrinfo, 0, MemoryLayout<addrinfo>.size)
 90 | 		if type == .local {
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:89:41: error: cannot find type 'addrinfo' in scope
 87 | 		buffer = UnsafeMutablePointer<UInt8>.allocate(capacity: bufferSize)
 88 | 		peer_addrinfo = UnsafeMutablePointer<addrinfo>.allocate(capacity: 1)
 89 | 		memset(peer_addrinfo, 0, MemoryLayout<addrinfo>.size)
    |                                         `- error: cannot find type 'addrinfo' in scope
 90 | 		if type == .local {
 91 | 			peer_local.sun_family = sa_family_t(AF_UNIX)
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:92:49: error: value of type 'sockaddr_un' has no member 'sun_path'
 90 | 		if type == .local {
 91 | 			peer_local.sun_family = sa_family_t(AF_UNIX)
 92 | 			_ = withUnsafeMutablePointer(to: &peer_local.sun_path.0) { ptr in
    |                                                 `- error: value of type 'sockaddr_un' has no member 'sun_path'
 93 | 				_ = peer.withCString {
 94 | 					strcpy(ptr, $0)
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:97:38: error: cannot find 'PF_LOCAL' in scope
 95 | 				}
 96 | 			}
 97 | 			peer_addrinfo.pointee.ai_family = PF_LOCAL
    |                                      `- error: cannot find 'PF_LOCAL' in scope
 98 | #if os(macOS) || os(iOS) || os(tvOS)
 99 | 			peer_addrinfo.pointee.ai_socktype = SOCK_STREAM
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:134:34: error: cannot find type 'addrinfo' in scope
132 | 				throw UniSocketError.error(detail: "unsupported socket type \(type)")
133 | 			}
134 | 			var ptr: UnsafeMutablePointer<addrinfo>? = peer_addrinfo
    |                                  `- error: cannot find type 'addrinfo' in scope
135 | 			peer_addrinfo.deallocate()
136 | 			rc = getaddrinfo(peer, String(p), &hints, &ptr)
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:136:9: error: cannot find 'getaddrinfo' in scope
134 | 			var ptr: UnsafeMutablePointer<addrinfo>? = peer_addrinfo
135 | 			peer_addrinfo.deallocate()
136 | 			rc = getaddrinfo(peer, String(p), &hints, &ptr)
    |         `- error: cannot find 'getaddrinfo' in scope
137 | 			if rc != 0 {
138 | 				if rc == EAI_SYSTEM {
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:136:39: error: cannot find 'hints' in scope
134 | 			var ptr: UnsafeMutablePointer<addrinfo>? = peer_addrinfo
135 | 			peer_addrinfo.deallocate()
136 | 			rc = getaddrinfo(peer, String(p), &hints, &ptr)
    |                                       `- error: cannot find 'hints' in scope
137 | 			if rc != 0 {
138 | 				if rc == EAI_SYSTEM {
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:138:14: error: cannot find 'EAI_SYSTEM' in scope
136 | 			rc = getaddrinfo(peer, String(p), &hints, &ptr)
137 | 			if rc != 0 {
138 | 				if rc == EAI_SYSTEM {
    |              `- error: cannot find 'EAI_SYSTEM' in scope
139 | 					errstr = String(validatingUTF8: strerror(errno)) ?? "unknown error code"
140 | 				} else {
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:141:38: error: cannot find 'gai_strerror' in scope
139 | 					errstr = String(validatingUTF8: strerror(errno)) ?? "unknown error code"
140 | 				} else {
141 | 					errstr = String(validatingUTF8: gai_strerror(rc)) ?? "unknown error code"
    |                                      `- error: cannot find 'gai_strerror' in scope
142 | 				}
143 | 				throw UniSocketError.error(detail: "failed to resolve '\(peer)', \(errstr)")
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:155:4: error: cannot find 'freeaddrinfo' in scope
153 | 			peer_addrinfo.deallocate()
154 | 		} else {
155 | 			freeaddrinfo(peer_addrinfo)
    |    `- error: cannot find 'freeaddrinfo' in scope
156 | 		}
157 | 	}
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:162:13: error: cannot find type 'fdmask' in scope
160 | 		let index = Int(fd) / fdmask_bits
161 | 		let bit = Int(fd) % fdmask_bits
162 | 		var mask: fdmask = 1 << bit
    |             `- error: cannot find type 'fdmask' in scope
163 | 		_ = withUnsafePointer(to: &mask) { src in
164 | 			_ = withUnsafeMutablePointer(to: &fdset) { dst in
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:162:24: error: no '<<' candidates produce the expected contextual result type '_'
160 | 		let index = Int(fd) / fdmask_bits
161 | 		let bit = Int(fd) % fdmask_bits
162 | 		var mask: fdmask = 1 << bit
    |                        `- error: no '<<' candidates produce the expected contextual result type '_'
163 | 		_ = withUnsafePointer(to: &mask) { src in
164 | 			_ = withUnsafeMutablePointer(to: &fdset) { dst in
Swift.BinaryInteger.<<:2:13: note: '<<' produces '_', not the expected contextual result type '_'
1 | protocol BinaryInteger {
2 | static func << <RHS>(lhs: Self, rhs: RHS) -> Self where RHS : BinaryInteger}
  |             |- note: '<<' produces '_', not the expected contextual result type '_'
  |             `- note: '<<' produces 'Int', not the expected contextual result type '_'
3 |
Swift.FixedWidthInteger.<<:2:20: note: '<<' produces '_', not the expected contextual result type '_'
1 | protocol FixedWidthInteger {
2 | public static func << <Other>(lhs: Self, rhs: Other) -> Self where Other : BinaryInteger}
  |                    |- note: '<<' produces '_', not the expected contextual result type '_'
  |                    `- note: '<<' produces 'Int', not the expected contextual result type '_'
3 |
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:177:32: error: cannot find type 'addrinfo' in scope
175 | 		var rc: Int32
176 | 		var errstr: String? = ""
177 | 		var ai: UnsafeMutablePointer<addrinfo>? = peer_addrinfo
    |                                `- error: cannot find type 'addrinfo' in scope
178 | 		while ai != nil {
179 | 			fd = system_socket(ai!.pointee.ai_family, ai!.pointee.ai_socktype, ai!.pointee.ai_protocol)
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:179:9: error: cannot find 'system_socket' in scope
177 | 		var ai: UnsafeMutablePointer<addrinfo>? = peer_addrinfo
178 | 		while ai != nil {
179 | 			fd = system_socket(ai!.pointee.ai_family, ai!.pointee.ai_socktype, ai!.pointee.ai_protocol)
    |         `- error: cannot find 'system_socket' in scope
180 | 			if fd == -1 {
181 | 				ai = ai?.pointee.ai_next
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:186:47: error: cannot find 'O_NONBLOCK' in scope
184 | 			FD_SET()
185 | 			let flags = fcntl(fd, F_GETFL)
186 | 			if flags != -1, fcntl(fd, F_SETFL, flags | O_NONBLOCK) == 0 {
    |                                               `- error: cannot find 'O_NONBLOCK' in scope
187 | 				if type == .udp {
188 | 					status = .stateless
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:191:10: error: cannot find 'system_connect' in scope
189 | 					return
190 | 				}
191 | 				rc = system_connect(fd, ai!.pointee.ai_addr, ai!.pointee.ai_addrlen)
    |          `- error: cannot find 'system_connect' in scope
192 | 				if rc == 0 {
193 | 					break
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:205:8: error: cannot find 'system_close' in scope
203 | 				errstr = String(validatingUTF8: strerror(errno)) ?? "unknown error code"
204 | 			}
205 | 			_ = system_close(fd)
    |        `- error: cannot find 'system_close' in scope
206 | 			fd = -1
207 | 			ai = ai?.pointee.ai_next
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:217:23: error: cannot find 'SHUT_RDWR' in scope
215 | 	public func close() throws -> Void {
216 | 		if status == .connected {
217 | 			shutdown(fd, Int32(SHUT_RDWR))
    |                       `- error: cannot find 'SHUT_RDWR' in scope
218 | 			usleep(10000)
219 | 		}
/root/.swiftpm/swift-sdks/swift-6.3-RELEASE_wasm.artifactbundle/swift-6.3-RELEASE_wasm/wasm32-unknown-wasip1/WASI.sdk/include/wasm32-wasip1/__header_sys_socket.h:13:9: note: macro 'SHUT_RDWR' unavailable: structure not supported
11 | #define SHUT_RD __WASI_SDFLAGS_RD
12 | #define SHUT_WR __WASI_SDFLAGS_WR
13 | #define SHUT_RDWR (SHUT_RD | SHUT_WR)
   |         `- note: macro 'SHUT_RDWR' unavailable: structure not supported
14 |
15 | #ifdef __wasilibc_use_wasip2
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:221:8: error: cannot find 'system_close' in scope
219 | 		}
220 | 		if fd != -1 {
221 | 			_ = system_close(fd)
    |        `- error: cannot find 'system_close' in scope
222 | 			fd = -1
223 | 		}
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:257:31: error: cannot find 'SO_ERROR' in scope
255 | 		} else if rc == 0 {
256 | 			var len = socklen_t(MemoryLayout<Int32>.size)
257 | 			getsockopt(fd, SOL_SOCKET, SO_ERROR, &rc, &len)
    |                               `- error: cannot find 'SO_ERROR' in scope
258 | 			if rc == 0 {
259 | 				rc = ETIMEDOUT
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:281:9: error: cannot find 'system_recv' in scope
279 | 				limit = m - data.count
280 | 			}
281 | 			rc = system_recv(fd, buffer, limit, 0)
    |         `- error: cannot find 'system_recv' in scope
282 | 			if rc == 0 {
283 | 				try? close()
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:314:86: error: cannot find 'system_sendto' in scope
312 | 			}
313 | 			if status == .stateless {
314 | 				rc = bufferLeft.withUnsafeBytes { (ptr: UnsafeRawBufferPointer) -> Int in return system_sendto(fd, ptr.baseAddress, bytesLeft, 0, peer_addrinfo.pointee.ai_addr, peer_addrinfo.pointee.ai_addrlen) }
    |                                                                                      `- error: cannot find 'system_sendto' in scope
315 | 			} else {
316 | 				rc = bufferLeft.withUnsafeBytes { (ptr: UnsafeRawBufferPointer) -> Int in return system_send(fd, ptr.baseAddress, bytesLeft, 0) }
/host/spi-builder-workspace/Sources/UniSocket/UniSocket.swift:316:86: error: cannot find 'system_send' in scope
314 | 				rc = bufferLeft.withUnsafeBytes { (ptr: UnsafeRawBufferPointer) -> Int in return system_sendto(fd, ptr.baseAddress, bytesLeft, 0, peer_addrinfo.pointee.ai_addr, peer_addrinfo.pointee.ai_addrlen) }
315 | 			} else {
316 | 				rc = bufferLeft.withUnsafeBytes { (ptr: UnsafeRawBufferPointer) -> Int in return system_send(fd, ptr.baseAddress, bytesLeft, 0) }
    |                                                                                      `- error: cannot find 'system_send' in scope
317 | 			}
318 | 			if rc == -1 {
BUILD FAILURE 6.3 wasm