The Swift Package Index logo.Swift Package Index

Has it really been five years since Swift Package Index launched? Read our anniversary blog post!

Build Information

Failed to build PythonKit, reference master (d5ba1b), with Swift 6.2 (beta) for Android on 23 Jun 2025 06:57:49 UTC.

Build Command

bash -c docker run --pull=always --rm -v "checkouts-4609320-3":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.2-latest swift build --swift-sdk aarch64-unknown-linux-android28 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.64.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/pvieito/PythonKit.git
Reference: master
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/pvieito/PythonKit
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at d5ba1b3 Use dlerror() when dlopen() fails.
Cloned https://github.com/pvieito/PythonKit.git
Revision (git rev-parse @):
d5ba1b3b4834e8c47e0cdf0989f458bc59ab0b45
SUCCESS checkout https://github.com/pvieito/PythonKit.git at master
========================================
Build
========================================
Selected platform:         android
Swift version:             6.2
Building package at path:  $PWD
https://github.com/pvieito/PythonKit.git
Running build ...
bash -c docker run --pull=always --rm -v "checkouts-4609320-3":/host -w "$PWD" registry.gitlab.com/finestructure/spi-images:android-6.2-latest swift build --swift-sdk aarch64-unknown-linux-android28 2>&1
android-6.2-latest: Pulling from finestructure/spi-images
Digest: sha256:b7c4a6b4153ff40ef9277e2157e708f835b8eb011095d53bd8db4594eb2b7798
Status: Image is up to date for registry.gitlab.com/finestructure/spi-images:android-6.2-latest
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-8C5A4AE7A8CE2BA.txt
[3/7] Compiling PythonKit PythonLibrary+Symbols.swift
[4/7] Compiling PythonKit PythonLibrary.swift
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:120:34: error: cannot find 'librarySearchPaths' in scope
118 |     private static let libraryPaths: [String] = {
119 |         var libraryPaths: [String] = []
120 |         for librarySearchPath in librarySearchPaths {
    |                                  `- error: cannot find 'librarySearchPaths' in scope
121 |             for libraryName in libraryNames {
122 |                 for libraryPathExtension in libraryPathExtensions {
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:121:32: error: cannot find 'libraryNames' in scope
119 |         var libraryPaths: [String] = []
120 |         for librarySearchPath in librarySearchPaths {
121 |             for libraryName in libraryNames {
    |                                `- error: cannot find 'libraryNames' in scope
122 |                 for libraryPathExtension in libraryPathExtensions {
123 |                     let libraryPath =
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:122:45: error: cannot find 'libraryPathExtensions' in scope
120 |         for librarySearchPath in librarySearchPaths {
121 |             for libraryName in libraryNames {
122 |                 for libraryPathExtension in libraryPathExtensions {
    |                                             `- error: cannot find 'libraryPathExtensions' in scope
123 |                     let libraryPath =
124 |                     librarySearchPath + libraryName + libraryPathExtension
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:141:20: error: cannot find 'dlsym' in scope
139 |             return unsafeBitCast(moduleSymbol, to: UnsafeMutableRawPointer?.self)
140 | #else
141 |             return dlsym(libraryHandle, name)
    |                    `- error: cannot find 'dlsym' in scope
142 | #endif
143 |         }
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:194:36: error: cannot find 'libraryVersionSeparator' in scope
192 |             let libraryVersionString = versionString
193 |                 .split(separator: PythonVersion.versionSeparator)
194 |                 .joined(separator: libraryVersionSeparator)
    |                                    `- error: cannot find 'libraryVersionSeparator' in scope
195 |             let path = path.split(separator: libraryPathVersionCharacter)
196 |                 .joined(separator: libraryVersionString)
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:207:35: error: cannot find 'dlopen' in scope
205 |         // Must be RTLD_GLOBAL because subsequent .so files from the imported python
206 |         // modules may depend on this .so file.
207 |         let pythonLibraryHandle = dlopen(path, RTLD_LAZY | RTLD_GLOBAL)
    |                                   `- error: cannot find 'dlopen' in scope
208 |         if pythonLibraryHandle == nil {
209 |             self.log("Failed to load library at '\(path)'.")
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:207:48: error: cannot find 'RTLD_LAZY' in scope
205 |         // Must be RTLD_GLOBAL because subsequent .so files from the imported python
206 |         // modules may depend on this .so file.
207 |         let pythonLibraryHandle = dlopen(path, RTLD_LAZY | RTLD_GLOBAL)
    |                                                `- error: cannot find 'RTLD_LAZY' in scope
208 |         if pythonLibraryHandle == nil {
209 |             self.log("Failed to load library at '\(path)'.")
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:207:60: error: cannot find 'RTLD_GLOBAL' in scope
205 |         // Must be RTLD_GLOBAL because subsequent .so files from the imported python
206 |         // modules may depend on this .so file.
207 |         let pythonLibraryHandle = dlopen(path, RTLD_LAZY | RTLD_GLOBAL)
    |                                                            `- error: cannot find 'RTLD_GLOBAL' in scope
208 |         if pythonLibraryHandle == nil {
209 |             self.log("Failed to load library at '\(path)'.")
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:210:35: error: cannot find 'dlerror' in scope
208 |         if pythonLibraryHandle == nil {
209 |             self.log("Failed to load library at '\(path)'.")
210 |             if let errorCString = dlerror() {
    |                                   `- error: cannot find 'dlerror' in scope
211 |                 let errorString = String(cString: errorCString)
212 |                 self.log("Reason for failure: \(errorString)")
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:294:33: error: cannot find 'getenv' in scope
292 |
293 |         var value: String? {
294 |             guard let cString = getenv(key) else { return nil }
    |                                 `- error: cannot find 'getenv' in scope
295 |             let value = String(cString: cString)
296 |             guard !value.isEmpty else { return nil }
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:304:13: error: cannot find 'setenv' in scope
302 |             _putenv_s(key, value)
303 | #else
304 |             setenv(key, value, 1)
    |             `- error: cannot find 'setenv' in scope
305 | #endif
306 |         }
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:314:9: error: cannot find 'fputs' in scope
312 |     private static func log(_ message: String) {
313 |         guard Environment.loaderLogging.value != nil else { return }
314 |         fputs(message + "\n", stderr)
    |         `- error: cannot find 'fputs' in scope
315 |     }
316 | }
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:314:31: error: cannot find 'stderr' in scope
312 |     private static func log(_ message: String) {
313 |         guard Environment.loaderLogging.value != nil else { return }
314 |         fputs(message + "\n", stderr)
    |                               `- error: cannot find 'stderr' in scope
315 |     }
316 | }
error: emit-module command failed with exit code 1 (use -v to see invocation)
[5/7] Compiling PythonKit NumpyConversion.swift
[6/7] Emitting module PythonKit
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:120:34: error: cannot find 'librarySearchPaths' in scope
118 |     private static let libraryPaths: [String] = {
119 |         var libraryPaths: [String] = []
120 |         for librarySearchPath in librarySearchPaths {
    |                                  `- error: cannot find 'librarySearchPaths' in scope
121 |             for libraryName in libraryNames {
122 |                 for libraryPathExtension in libraryPathExtensions {
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:121:32: error: cannot find 'libraryNames' in scope
119 |         var libraryPaths: [String] = []
120 |         for librarySearchPath in librarySearchPaths {
121 |             for libraryName in libraryNames {
    |                                `- error: cannot find 'libraryNames' in scope
122 |                 for libraryPathExtension in libraryPathExtensions {
123 |                     let libraryPath =
/host/spi-builder-workspace/PythonKit/PythonLibrary.swift:122:45: error: cannot find 'libraryPathExtensions' in scope
120 |         for librarySearchPath in librarySearchPaths {
121 |             for libraryName in libraryNames {
122 |                 for libraryPathExtension in libraryPathExtensions {
    |                                             `- error: cannot find 'libraryPathExtensions' in scope
123 |                     let libraryPath =
124 |                     librarySearchPath + libraryName + libraryPathExtension
[7/7] Compiling PythonKit Python.swift
BUILD FAILURE 6.2 android