The Swift Package Index logo.Swift Package Index

Build Information

Failed to build BaseMath with Swift 5.10 for Linux.

Build Command

bash -c docker run --rm -v "checkouts-4606859-1":/host -w "$workDir" registry.gitlab.com/finestructure/spi-images:basic-5.10-latest swift build 2>&1

Build Log

========================================
RunAll
========================================
Builder version: 4.29.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/jph00/basemath.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/jph00/basemath
 * branch            master     -> FETCH_HEAD
 * [new branch]      master     -> origin/master
HEAD is now at 5fd3d82 Update main.swift
Cloned https://github.com/jph00/basemath.git
Revision (git rev-parse @):
5fd3d82b6f342a90efaed26fae2c0de1b5f2edaa
SUCCESS checkout https://github.com/jph00/basemath.git at master
========================================
Build
========================================
Selected platform:         linux
Swift version:             5.10
Building package at path:  $workDir
https://github.com/jph00/basemath.git
Running build ...
bash -c docker run --rm -v "checkouts-4606859-1":/host -w "$workDir" registry.gitlab.com/finestructure/spi-images:basic-5.10-latest swift build 2>&1
Building for debugging...
[0/9] Write sources
[2/9] Compiling CBaseMath CBaseMath.cpp
[3/9] Write swift-version-24593BA9C3E375BF.txt
[4/9] Compiling CBaseMath CDistribution.cpp
[6/17] Compiling BaseMath Utils.swift
[7/17] Compiling BaseMath Storage.swift
/host/spi-builder-workspace/Sources/BaseMath/Storage.swift:11:59: warning: initialization of 'UnsafeMutablePointer<Element>' results in a dangling pointer
  public var p:UnsafeMutablePointer<Element> {get {return UnsafeMutablePointer(mutating: self)}}
                                                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/host/spi-builder-workspace/Sources/BaseMath/Storage.swift:11:90: note: implicit argument conversion from 'Array<Element>' to 'UnsafePointer<Element>' produces a pointer valid only for the duration of the call to 'init(mutating:)'
  public var p:UnsafeMutablePointer<Element> {get {return UnsafeMutablePointer(mutating: self)}}
                                                                                         ^~~~
/host/spi-builder-workspace/Sources/BaseMath/Storage.swift:11:90: note: use the 'withUnsafeBufferPointer' method on Array in order to explicitly convert argument to buffer pointer valid for a defined scope
  public var p:UnsafeMutablePointer<Element> {get {return UnsafeMutablePointer(mutating: self)}}
                                                                                         ^
[8/17] Emitting module BaseMath
[9/17] Compiling BaseMath BaseMath.swift
[10/17] Compiling BaseMath BaseVector.swift
[11/17] Compiling BaseMath BaseRand.swift
[12/17] Compiling BaseMath CBaseRand.swift
[13/17] Compiling BaseMath FloatVector.swift
[14/18] Wrapping AST for BaseMath for debugging
error: emit-module command failed with exit code 1 (use -v to see invocation)
[16/20] Emitting module bench
/host/spi-builder-workspace/Sources/bench/main.swift:113:27: error: cannot find 'sm_add_float' in scope
benchmark(title:"C add") {sm_add_float(ar1.p, 2.0, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:127:27: error: cannot find 'sm_sin_float' in scope
benchmark(title:"C sin") {sm_sin_float(ar1.p, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:136:35: error: cannot find 'smSum_sqr_float' in scope
benchmark(title:"c sumsqr") {a1 = smSum_sqr_float(ar1.p, ar1.c)}
                                  ^~~~~~~~~~~~~~~
[17/20] Compiling bench main.swift
/host/spi-builder-workspace/Sources/bench/main.swift:113:27: error: cannot find 'sm_add_float' in scope
benchmark(title:"C add") {sm_add_float(ar1.p, 2.0, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:127:27: error: cannot find 'sm_sin_float' in scope
benchmark(title:"C sin") {sm_sin_float(ar1.p, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:136:35: error: cannot find 'smSum_sqr_float' in scope
benchmark(title:"c sumsqr") {a1 = smSum_sqr_float(ar1.p, ar1.c)}
                                  ^~~~~~~~~~~~~~~
error: fatalError
[0/1] Planning build
Building for debugging...
[0/5] Write swift-version-24593BA9C3E375BF.txt
error: emit-module command failed with exit code 1 (use -v to see invocation)
[2/6] Emitting module bench
/host/spi-builder-workspace/Sources/bench/main.swift:113:27: error: cannot find 'sm_add_float' in scope
benchmark(title:"C add") {sm_add_float(ar1.p, 2.0, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:127:27: error: cannot find 'sm_sin_float' in scope
benchmark(title:"C sin") {sm_sin_float(ar1.p, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:136:35: error: cannot find 'smSum_sqr_float' in scope
benchmark(title:"c sumsqr") {a1 = smSum_sqr_float(ar1.p, ar1.c)}
                                  ^~~~~~~~~~~~~~~
[3/6] Compiling bench main.swift
/host/spi-builder-workspace/Sources/bench/main.swift:113:27: error: cannot find 'sm_add_float' in scope
benchmark(title:"C add") {sm_add_float(ar1.p, 2.0, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:127:27: error: cannot find 'sm_sin_float' in scope
benchmark(title:"C sin") {sm_sin_float(ar1.p, ar2.p, ar1.c)}
                          ^~~~~~~~~~~~
/host/spi-builder-workspace/Sources/bench/main.swift:136:35: error: cannot find 'smSum_sqr_float' in scope
benchmark(title:"c sumsqr") {a1 = smSum_sqr_float(ar1.p, ar1.c)}
                                  ^~~~~~~~~~~~~~~
error: fatalError
BUILD FAILURE 5.10 linux

Build Machine: Linux 1