diff --git a/.github/workflows/containerization-build-template.yml b/.github/workflows/containerization-build-template.yml index 9f9f538e..dc0bd2f9 100644 --- a/.github/workflows/containerization-build-template.yml +++ b/.github/workflows/containerization-build-template.yml @@ -15,7 +15,7 @@ on: jobs: buildAndTest: name: Build and Test repo - timeout-minutes: 90 + timeout-minutes: 60 runs-on: [self-hosted, macos, sequoia, ARM64] permissions: contents: read @@ -36,25 +36,25 @@ jobs: git diff if ! git diff --quiet ; then echo the following files require formatting or license headers: ; git diff --name-only ; false ; fi env: - DEVELOPER_DIR: "/Applications/Xcode_16.3.app/Contents/Developer" + DEVELOPER_DIR: "/Applications/Xcode_26.b1.app/Contents/Developer" - name: Check protobufs run: | make protos if ! git diff --quiet ; then echo the following files require formatting or license headers: ; git diff --name-only ; false ; fi env: - DEVELOPER_DIR: "/Applications/Xcode_16.3.app/Contents/Developer" + DEVELOPER_DIR: "/Applications/Xcode_26.b1.app/Contents/Developer" CURRENT_SDK: y - name: Make containerization and docs run: | make clean containerization docs tar cfz _site.tgz _site env: - DEVELOPER_DIR: "/Applications/Xcode_16.3.app/Contents/Developer" + DEVELOPER_DIR: "/Applications/Xcode_26.b1.app/Contents/Developer" CURRENT_SDK: y - name: Make vminitd image run: | source /opt/swiftly/env.sh - make -C vminitd linux-sdk + make -C vminitd swift linux-sdk make init env: CURRENT_SDK: y @@ -65,7 +65,7 @@ jobs: env: REGISTRY_TOKEN: ${{ secrets.GITHUB_TOKEN }} REGISTRY_USERNAME: ${{ github.actor }} - DEVELOPER_DIR: "/Applications/Xcode_16.3.app/Contents/Developer" + DEVELOPER_DIR: "/Applications/Xcode_26.b1.app/Contents/Developer" CURRENT_SDK: y - name: Push vminitd image if: ${{ inputs.release }} diff --git a/.swift-version b/.swift-version index 358e78e6..f202027f 100644 --- a/.swift-version +++ b/.swift-version @@ -1 +1 @@ -6.1.0 \ No newline at end of file +6.2-snapshot \ No newline at end of file diff --git a/Package.resolved b/Package.resolved index 324d8d01..c33895ac 100644 --- a/Package.resolved +++ b/Package.resolved @@ -1,5 +1,5 @@ { - "originHash" : "25d5d51d209538c87dc4d10dfb4a86bcaea48115381c502d5b148608a8edecf2", + "originHash" : "ecb02e8bd5413f5287d7c7f236deef981e66bfaad51251787d448507e6ed2c17", "pins" : [ { "identity" : "async-http-client", @@ -60,8 +60,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/apple/swift-atomics.git", "state" : { - "revision" : "cd142fd2f64be2100422d658e7411e39489da985", - "version" : "1.2.0" + "revision" : "b601256eab081c0f92f059e12818ac1d4f178ff7", + "version" : "1.3.0" } }, { @@ -213,8 +213,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/swiftlang/swift-syntax.git", "state" : { - "revision" : "0687f71944021d616d34d922343dcef086855920", - "version" : "600.0.1" + "revision" : "0dff260d3d1bb99c382d8dfcd6bb093e5e9cbd36", + "version" : "602.0.0-prerelease-2025-05-29" } }, { diff --git a/Package.swift b/Package.swift index 93c6fac5..db7f5237 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version: 6.0 +// swift-tools-version: 6.2 //===----------------------------------------------------------------------===// // Copyright © 2025 Apple Inc. and the Containerization project authors. All rights reserved. // @@ -54,7 +54,7 @@ let package = Package( .package(url: "https://github.com/apple/swift-nio.git", from: "2.80.0"), .package(url: "https://github.com/swift-server/async-http-client.git", from: "1.20.1"), .package(url: "https://github.com/apple/swift-system.git", from: "1.4.0"), - .package(url: "https://github.com/swiftlang/swift-syntax.git", "600.0.0"..<"603.0.0"), + .package(url: "https://github.com/swiftlang/swift-syntax.git", "602.0.0-latest"..<"603.0.0"), .package(url: "https://github.com/swiftlang/swift-docc-plugin", from: "1.1.0"), ], targets: [ diff --git a/vminitd/Makefile b/vminitd/Makefile index 6be52ff6..43b816a8 100644 --- a/vminitd/Makefile +++ b/vminitd/Makefile @@ -15,13 +15,13 @@ BUILD_CONFIGURATION := debug SWIFT_CONFIGURATION := --swift-sdk aarch64-swift-linux-musl -# The Static Linux SDK version should match the latest released version on https://www.swift.org/install/macos/ -SWIFT_SDK_URL = https://download.swift.org/swift-6.1-release/static-sdk/swift-6.1-RELEASE/swift-6.1-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz -SWIFT_SDK_CHECKSUM = 111c6f7d280a651208b8c74c0521dd99365d785c1976a6e23162f55f65379ac6 +SWIFT_VERSION = 6.2-snapshot +SWIFT_SDK_URL = https://download.swift.org/swift-6.2-branch/static-sdk/swift-6.2-DEVELOPMENT-SNAPSHOT-2025-06-12-a/swift-6.2-DEVELOPMENT-SNAPSHOT-2025-06-12-a_static-linux-0.0.1.artifactbundle.tar.gz SWIFT_SDK_PATH = /tmp/$(notdir $(SWIFT_SDK_URL)) SWIFTLY_URL := https://download.swift.org/swiftly/darwin/swiftly.pkg SWIFTLY_FILENAME = $(notdir $(SWIFTLY_URL)) +SWIFTLY_BIN_DIR ?= ~/.swiftly/bin/ VMINITD_BIN_PATH := $(shell swift build -c $(BUILD_CONFIGURATION) $(SWIFT_CONFIGURATION) --show-bin-path) MACOS_VERSION := $(shell sw_vers -productVersion) @@ -41,23 +41,30 @@ all: @install $(VMINITD_BIN_PATH)/vmexec ./bin/vmexec .PHONY: cross-prep -cross-prep: swiftly linux-sdk macos-sdk +cross-prep: swiftly swift linux-sdk macos-sdk .PHONY: swiftly swiftly: - @curl -o /var/tmp/$(SWIFTLY_FILENAME) $(SWIFTLY_URL) && \ - installer -pkg /var/tmp/$(SWIFTLY_FILENAME) -target CurrentUserHomeDirectory && \ - ~/.swiftly/bin/swiftly init --quiet-shell-followup && \ - . ~/.swiftly/env.sh && \ - hash -r - @rm /var/tmp/$(SWIFTLY_FILENAME) - @~/.swiftly/bin/swiftly install 6.1.0 + @if ! command -v ${SWIFTLY_BIN_DIR}/swiftly > /dev/null 2>&1; then \ + echo "Installing Swiftly..."; \ + curl -o /var/tmp/$(SWIFTLY_FILENAME) $(SWIFTLY_URL) && \ + installer -pkg /var/tmp/$(SWIFTLY_FILENAME) -target CurrentUserHomeDirectory && \ + ${SWIFTLY_BIN_DIR}/swiftly init --quiet-shell-followup --skip-install && \ + . ~/.swiftly/env.sh && \ + hash -r && \ + rm /var/tmp/$(SWIFTLY_FILENAME); \ + fi + +.PHONY: swift +swift: + @echo Installing Swift $(SWIFT_VERSION)... + @${SWIFTLY_BIN_DIR}/swiftly install $(SWIFT_VERSION) .PHONY: linux-sdk linux-sdk: @echo Installing Static Linux SDK... @curl -L -o $(SWIFT_SDK_PATH) $(SWIFT_SDK_URL) - -@swift sdk install $(SWIFT_SDK_PATH) --checksum $(SWIFT_SDK_CHECKSUM) + -@swift sdk install $(SWIFT_SDK_PATH) @rm $(SWIFT_SDK_PATH) .PHONY: macos-sdk @@ -75,7 +82,7 @@ xcode-cli: .PHONY: xcode xcode: - @echo Please install the latest version of Xcode 26. + @echo "Please install the latest version of Xcode 26 and set the path for the active developer directory using \`sudo xcode-select -s \`". .PHONY: clean clean: diff --git a/vminitd/Package.resolved b/vminitd/Package.resolved index aca72c38..d6d1812d 100644 --- a/vminitd/Package.resolved +++ b/vminitd/Package.resolved @@ -1,5 +1,5 @@ { - "originHash" : "6e2ebffe6ab16e6cb5829cd13344d9d00525e38000a34566e8120f7eb9993d28", + "originHash" : "e23def1de0482fe4a24b05d4808321638c41eab7d1ce2039d94cac24f8f4b2fc", "pins" : [ { "identity" : "async-http-client", @@ -195,8 +195,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/swiftlang/swift-syntax.git", "state" : { - "revision" : "0687f71944021d616d34d922343dcef086855920", - "version" : "600.0.1" + "revision" : "0dff260d3d1bb99c382d8dfcd6bb093e5e9cbd36", + "version" : "602.0.0-prerelease-2025-05-29" } }, { diff --git a/vminitd/Package.swift b/vminitd/Package.swift index f22d6455..6568fbd0 100644 --- a/vminitd/Package.swift +++ b/vminitd/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version: 6.0 +// swift-tools-version: 6.2 //===----------------------------------------------------------------------===// // Copyright © 2025 Apple Inc. and the Containerization project authors. All rights reserved. //