Skip to content

Build fails with MacOS 26 #578

Closed
Closed
@theoparis

Description

@theoparis
/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX26.0.sdk/System/Library/Frameworks/Foundation.framework/Modules/Foundation.swiftmodule/arm64e-apple-macos.swiftinterface:21692:18: error: 'init(__dsoHandle:)' is only available in macOS 26.0 or newer; clients of 'Foundation' may have a lower deployment target
21685 |   #endif
21686 | }
21687 | extension Foundation.Bundle {
      | `- note: add '@available' attribute to enclosing extension
21688 |   #if compiler(>=5.3) && $NonescapableTypes
21689 |   @available(macOS 12, iOS 15, tvOS 15, watchOS 8, visionOS 1, *)
21690 |   @_alwaysEmitIntoClient convenience public init?(_dsoHandle: Swift.UnsafeRawPointer) {
21691 |         if #available(macOS 16, iOS 19, tvOS 19, watchOS 9, visionOS 3, *) {
21692 |             self.init(__dsoHandle: _dsoHandle)
      |                  |- error: 'init(__dsoHandle:)' is only available in macOS 26.0 or newer; clients of 'Foundation' may have a lower deployment target
      |                  `- note: add 'if #available' version check
21693 |             return
21694 |         } in https://github.com/swiftlang/swift-driver.git
  1. Install macos 26 beta (and/or xcode beta 26)
  2. git clone https://github.com/swiftlang/swift-build
  3. swift build -c release

Someone seemed to have the same problem with containerization and I'm not really clear on what the correct solution is..
I tried both swift 6.1.2 and swift 6.2-dev (main-snapshot)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions