Build Information
Successful build of Cryptor with Swift 6.0 for macOS (SPM).
Swift 6 data race errors: 6
Build Command
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Build Log
========================================
RunAll
========================================
Builder version: 4.40.0
Interrupt handler set up.
========================================
Checkout
========================================
Clone URL: https://github.com/Kitura/BlueCryptor.git
Reference: master
Initialized empty Git repository in /Users/admin/builder/spi-builder-workspace/.git/
From https://github.com/Kitura/BlueCryptor
* branch master -> FETCH_HEAD
* [new branch] master -> origin/master
HEAD is now at cec97c2 silence compiler warnings (#74)
Cloned https://github.com/Kitura/BlueCryptor.git
Revision (git rev-parse @):
cec97c24b111351e70e448972a7d3fe68a756d6d
SUCCESS checkout https://github.com/Kitura/BlueCryptor.git at master
========================================
Build
========================================
Selected platform: macosSpm
Swift version: 6.0
Building package at path: $workDir
https://github.com/Kitura/BlueCryptor.git
Running build ...
env DEVELOPER_DIR=/Applications/Xcode-15.3.0.app xcrun --toolchain org.swift.600202405261a swift build --arch arm64 -Xswiftc -Xfrontend -Xswiftc -stats-output-dir -Xswiftc -Xfrontend -Xswiftc .stats -Xswiftc -strict-concurrency=complete
Building for debugging...
[0/2] Write sources
[1/2] Write swift-version-6F35C1178C84523A.txt
[3/13] Compiling Cryptor Updatable.swift
[4/14] Compiling Cryptor Status.swift
[5/14] Compiling Cryptor SSLPointerTricks.swift
[6/14] Compiling Cryptor Random.swift
[7/14] Compiling Cryptor Digest.swift
[8/14] Compiling Cryptor KeyDerivation.swift
[9/14] Compiling Cryptor Crypto.swift
[10/14] Compiling Cryptor Cryptor.swift
[11/14] Emitting module Cryptor
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/HMAC.swift:56:15: warning: static property 'fromNative' is not concurrency-safe because non-'Sendable' type '[CCHmacAlgorithm : HMAC.Algorithm]' (aka 'Dictionary<UInt32, HMAC.Algorithm>') may have shared mutable state; this is an error in the Swift 6 language mode
32 | /// Enumerates available algorithms.
33 | ///
34 | public enum Algorithm {
| `- note: consider making enum 'Algorithm' conform to the 'Sendable' protocol
35 |
36 | /// Message Digest 5
:
54 | #if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
55 |
56 | static let fromNative: [CCHmacAlgorithm: Algorithm] = [
| |- warning: static property 'fromNative' is not concurrency-safe because non-'Sendable' type '[CCHmacAlgorithm : HMAC.Algorithm]' (aka 'Dictionary<UInt32, HMAC.Algorithm>') may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'fromNative' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
57 | CCHmacAlgorithm(kCCHmacAlgSHA1): .sha1,
58 | CCHmacAlgorithm(kCCHmacAlgSHA1): .md5,
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/StreamCryptor.swift:188:21: warning: static property 'none' is not concurrency-safe because non-'Sendable' type 'StreamCryptor.Options' may have shared mutable state; this is an error in the Swift 6 language mode
170 | /// Maps CommonCryptoOptions onto a Swift struct.
171 | ///
172 | public struct Options: OptionSet {
| `- note: consider making struct 'Options' conform to the 'Sendable' protocol
173 |
174 | public typealias RawValue = Int
:
186 |
187 | /// No options
188 | public static let none = Options([])
| |- warning: static property 'none' is not concurrency-safe because non-'Sendable' type 'StreamCryptor.Options' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'none' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
189 |
190 | #if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/StreamCryptor.swift:193:22: warning: static property 'pkcs7Padding' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
191 |
192 | /// Use padding. Needed unless the input is a integral number of blocks long.
193 | public static var pkcs7Padding = Options(rawValue:kCCOptionPKCS7Padding)
| |- warning: static property 'pkcs7Padding' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'pkcs7Padding' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'pkcs7Padding' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
194 |
195 | /// Electronic Code Book Mode. Don't use this.
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/StreamCryptor.swift:196:22: warning: static property 'ecbMode' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
194 |
195 | /// Electronic Code Book Mode. Don't use this.
196 | public static var ecbMode = Options(rawValue:kCCOptionECBMode)
| |- warning: static property 'ecbMode' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'ecbMode' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'ecbMode' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
197 |
198 | #elseif os(Linux)
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/Utilities.swift:51:13: warning: static property 'fatalErrorClosure' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
49 | struct FatalErrorUtil {
50 |
51 | static var fatalErrorClosure: (String, StaticString, UInt) -> Never = defaultFatalErrorClosure
| |- warning: static property 'fatalErrorClosure' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'fatalErrorClosure' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'fatalErrorClosure' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
52 | private static let defaultFatalErrorClosure = { Swift.fatalError($0, file: $1, line: $2) }
53 | static func replaceFatalError(closure: @escaping (String, StaticString, UInt) -> Never) {
<unknown>:0: note: a function type must be marked '@Sendable' to conform to 'Sendable'
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/Utilities.swift:52:21: warning: static property 'defaultFatalErrorClosure' is not concurrency-safe because non-'Sendable' type '(String, StaticString, UInt) -> Never' may have shared mutable state; this is an error in the Swift 6 language mode
50 |
51 | static var fatalErrorClosure: (String, StaticString, UInt) -> Never = defaultFatalErrorClosure
52 | private static let defaultFatalErrorClosure = { Swift.fatalError($0, file: $1, line: $2) }
| |- warning: static property 'defaultFatalErrorClosure' is not concurrency-safe because non-'Sendable' type '(String, StaticString, UInt) -> Never' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'defaultFatalErrorClosure' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
53 | static func replaceFatalError(closure: @escaping (String, StaticString, UInt) -> Never) {
54 | fatalErrorClosure = closure
[12/14] Compiling Cryptor HMAC.swift
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/HMAC.swift:56:15: warning: static property 'fromNative' is not concurrency-safe because non-'Sendable' type '[CCHmacAlgorithm : HMAC.Algorithm]' (aka 'Dictionary<UInt32, HMAC.Algorithm>') may have shared mutable state; this is an error in the Swift 6 language mode
32 | /// Enumerates available algorithms.
33 | ///
34 | public enum Algorithm {
| `- note: consider making enum 'Algorithm' conform to the 'Sendable' protocol
35 |
36 | /// Message Digest 5
:
54 | #if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
55 |
56 | static let fromNative: [CCHmacAlgorithm: Algorithm] = [
| |- warning: static property 'fromNative' is not concurrency-safe because non-'Sendable' type '[CCHmacAlgorithm : HMAC.Algorithm]' (aka 'Dictionary<UInt32, HMAC.Algorithm>') may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'fromNative' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
57 | CCHmacAlgorithm(kCCHmacAlgSHA1): .sha1,
58 | CCHmacAlgorithm(kCCHmacAlgSHA1): .md5,
[13/14] Compiling Cryptor StreamCryptor.swift
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/StreamCryptor.swift:188:21: warning: static property 'none' is not concurrency-safe because non-'Sendable' type 'StreamCryptor.Options' may have shared mutable state; this is an error in the Swift 6 language mode
170 | /// Maps CommonCryptoOptions onto a Swift struct.
171 | ///
172 | public struct Options: OptionSet {
| `- note: consider making struct 'Options' conform to the 'Sendable' protocol
173 |
174 | public typealias RawValue = Int
:
186 |
187 | /// No options
188 | public static let none = Options([])
| |- warning: static property 'none' is not concurrency-safe because non-'Sendable' type 'StreamCryptor.Options' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'none' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
189 |
190 | #if os(macOS) || os(iOS) || os(tvOS) || os(watchOS)
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/StreamCryptor.swift:193:22: warning: static property 'pkcs7Padding' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
191 |
192 | /// Use padding. Needed unless the input is a integral number of blocks long.
193 | public static var pkcs7Padding = Options(rawValue:kCCOptionPKCS7Padding)
| |- warning: static property 'pkcs7Padding' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'pkcs7Padding' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'pkcs7Padding' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
194 |
195 | /// Electronic Code Book Mode. Don't use this.
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/StreamCryptor.swift:196:22: warning: static property 'ecbMode' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
194 |
195 | /// Electronic Code Book Mode. Don't use this.
196 | public static var ecbMode = Options(rawValue:kCCOptionECBMode)
| |- warning: static property 'ecbMode' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'ecbMode' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'ecbMode' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
197 |
198 | #elseif os(Linux)
[14/14] Compiling Cryptor Utilities.swift
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/Utilities.swift:51:13: warning: static property 'fatalErrorClosure' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
49 | struct FatalErrorUtil {
50 |
51 | static var fatalErrorClosure: (String, StaticString, UInt) -> Never = defaultFatalErrorClosure
| |- warning: static property 'fatalErrorClosure' is not concurrency-safe because it is non-isolated global shared mutable state; this is an error in the Swift 6 language mode
| |- note: convert 'fatalErrorClosure' to a 'let' constant to make 'Sendable' shared state immutable
| |- note: annotate 'fatalErrorClosure' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
52 | private static let defaultFatalErrorClosure = { Swift.fatalError($0, file: $1, line: $2) }
53 | static func replaceFatalError(closure: @escaping (String, StaticString, UInt) -> Never) {
<unknown>:0: note: a function type must be marked '@Sendable' to conform to 'Sendable'
/Users/admin/builder/spi-builder-workspace/Sources/Cryptor/Utilities.swift:52:21: warning: static property 'defaultFatalErrorClosure' is not concurrency-safe because non-'Sendable' type '(String, StaticString, UInt) -> Never' may have shared mutable state; this is an error in the Swift 6 language mode
50 |
51 | static var fatalErrorClosure: (String, StaticString, UInt) -> Never = defaultFatalErrorClosure
52 | private static let defaultFatalErrorClosure = { Swift.fatalError($0, file: $1, line: $2) }
| |- warning: static property 'defaultFatalErrorClosure' is not concurrency-safe because non-'Sendable' type '(String, StaticString, UInt) -> Never' may have shared mutable state; this is an error in the Swift 6 language mode
| |- note: annotate 'defaultFatalErrorClosure' with '@MainActor' if property should only be accessed from the main actor
| `- note: disable concurrency-safety checks if accesses are protected by an external synchronization mechanism
53 | static func replaceFatalError(closure: @escaping (String, StaticString, UInt) -> Never) {
54 | fatalErrorClosure = closure
Build complete! (22.27s)
Build complete.
{
"dependencies" : [
],
"manifest_display_name" : "Cryptor",
"name" : "Cryptor",
"path" : "/Users/admin/builder/spi-builder-workspace",
"platforms" : [
],
"products" : [
{
"name" : "Cryptor",
"targets" : [
"Cryptor"
],
"type" : {
"library" : [
"automatic"
]
}
}
],
"targets" : [
{
"c99name" : "CryptorTests",
"module_type" : "SwiftTarget",
"name" : "CryptorTests",
"path" : "Tests/CryptorTests",
"sources" : [
"CryptorTests.swift"
],
"target_dependencies" : [
"Cryptor"
],
"type" : "test"
},
{
"c99name" : "Cryptor",
"module_type" : "SwiftTarget",
"name" : "Cryptor",
"path" : "Sources/Cryptor",
"product_memberships" : [
"Cryptor"
],
"sources" : [
"Crypto.swift",
"Cryptor.swift",
"Digest.swift",
"HMAC.swift",
"KeyDerivation.swift",
"Random.swift",
"SSLPointerTricks.swift",
"Status.swift",
"StreamCryptor.swift",
"Updatable.swift",
"Utilities.swift"
],
"type" : "library"
}
],
"tools_version" : "5.0"
}
Done.