Xwift

Install

Download and install the Xwift 6.4.1 toolchain on macOS (Apple silicon), Linux (x86_64 and aarch64) and Windows x64.

Xwift 6.4.1 is based on Swift 6.4.1. It is available for macOS on Apple silicon, Linux on x86_64 and aarch64, and Windows x64.

Downloads

DownloadSize
macOS, Apple silicon (.pkg installer)
xwift-6.4.1-macos-arm64.pkg
976 MiB
macOS, Apple silicon (.tar.gz archive)
xwift-6.4.1-macos-arm64.tar.gz
976 MiB
Linux x86_64, Debian and Ubuntu (.deb)
xwift-toolchain_6.4.1_amd64.deb
865 MiB
Linux arm64, Debian and Ubuntu (.deb)
xwift-toolchain_6.4.1_arm64.deb
806 MiB
Linux x86_64, Fedora and RHEL (.rpm)
xwift-toolchain-6.4.1-1.x86_64.rpm
960 MiB
Linux aarch64, Fedora and RHEL (.rpm)
xwift-toolchain-6.4.1-1.aarch64.rpm
937 MiB
Linux x86_64, any distribution (.tar.gz)
xwift-6.4.1-linux-x86_64.tar.gz
1,196 MiB
Linux aarch64, any distribution (.tar.gz)
xwift-6.4.1-linux-aarch64.tar.gz
1,167 MiB
Windows x64 (.exe installer)
xwift-6.4.1-windows-x64-installer.exe
917 MiB

Unsigned builds

None of the downloads are signed. On macOS the .pkg is not notarised, so Gatekeeper will warn. On Windows, Microsoft SmartScreen may warn. The .deb and .rpm packages are not signed either. Check the checksums below before you install.

Install

Apple silicon only. There is no macOS x86_64 (Intel) build yet.

Installer (.pkg)

  1. Download xwift-6.4.1-macos-arm64.pkg.
  2. Open it. If Gatekeeper blocks it, open System Settings → Privacy & Security and choose Open Anyway.
  3. Choose Install for me only to install to ~/Library/Developer/Toolchains/xwift-6.4.1-RELEASE.xctoolchain, or install for all users to /Library/Developer/Toolchains.

Archive (.tar.gz)

Download xwift-6.4.1-macos-arm64.tar.gz. It contains the same Library/ tree, so extract it into your home folder:

tar -xzf xwift-6.4.1-macos-arm64.tar.gz -C ~

Use the toolchain

Select it with xcrun:

xcrun --toolchain xwift swift --version
xcrun --toolchain xwift swiftc hello.swift

To call the toolchain's swiftc directly, set SDKROOT first:

export SDKROOT=$(xcrun --show-sdk-path)
export PATH="$HOME/Library/Developer/Toolchains/xwift-6.4.1-RELEASE.xctoolchain/usr/bin:$PATH"

The toolchain also includes the xwift and xwiftc wrappers.

Check the version

swift --version
# Xwift version 6.4.1 (based on Swift version 6.4.1) (swift-6.4.1-RELEASE)

On macOS, run xcrun --toolchain xwift swift --version.

Checksums

ef7cc3485083d230e2eebde8c22bab19a61e2fb1064a06c9020c6804d2accfa3  xwift-6.4.1-macos-arm64.pkg
8690160b968f4e94c27526e17dd755c5da0e5070c2c60e098227c72348f64f2f  xwift-6.4.1-macos-arm64.tar.gz
bf07e0e8268bebee7d5d47765d284243e0029837c157eecb41bc0f24598b4a1b  xwift-toolchain_6.4.1_amd64.deb
b78d73af238b0120bcd87d111a4db5b881d34c0be83178963d1cb95f0eb816e7  xwift-toolchain_6.4.1_arm64.deb
98c338a7cbc7f29ac755287feb8c992c35b479c8fc4b880a11ece8c69919b29b  xwift-toolchain-6.4.1-1.x86_64.rpm
ee4ac229bc7a6d2429298b69af65797ba83b3a138f7c8374930f89648e3b6ef6  xwift-toolchain-6.4.1-1.aarch64.rpm
9875d9c51498e173d80cc57fa04041dbb07e54b284d73c78654ce084caa4509d  xwift-6.4.1-linux-x86_64.tar.gz
e07da82ac1d904c6dad3f4ea3c5ed1c79f4a34208b94be52c0f85d3a18297efb  xwift-6.4.1-linux-aarch64.tar.gz
8f659e0be7a0c9aac991621060aff363b51831ea7f828958bf904ddf3d6435f2  xwift-6.4.1-windows-x64-installer.exe

Check the macOS and Linux files against SHA256SUMS from the release:

shasum -a 256 -c SHA256SUMS --ignore-missing   # macOS
sha256sum -c SHA256SUMS --ignore-missing        # Linux

WebAssembly (optional)

The WebAssembly target was verified with the stock Swift 6.4.1 toolchain from swift.org, the Swift SDK for WebAssembly and wasmtime. These are the exact versions the proof of concept used:

ComponentVersion
Swift toolchain (swift.org)6.4.1 (from .swift-version)
Swift SDK for WebAssemblyswift-6.4.1-RELEASE_wasm
wasmtime38.0.1

Stock Swift 6.4.1

Install swiftly, the official Swift toolchain manager, then Swift 6.4.1:

curl -O https://download.swift.org/swiftly/darwin/swiftly.pkg && \
installer -pkg swiftly.pkg -target CurrentUserHomeDirectory && \
~/.swiftly/bin/swiftly init --quiet-shell-followup && \
. "${SWIFTLY_HOME_DIR:-$HOME/.swiftly}/env.sh" && \
hash -r
swiftly install 6.4.1 --use

Use the swift.org toolchain from swiftly rather than the one bundled with Xcode. The Swift SDK for WebAssembly must match the swift.org toolchain version exactly.

Swift SDK for WebAssembly

Install it with its checksum so the download is verified:

swift sdk install https://download.swift.org/swift-6.4.1-release/wasm-sdk/swift-6.4.1-RELEASE/swift-6.4.1-RELEASE_wasm.artifactbundle.tar.gz \
  --checksum 783e6128d174d9f975b4eda68be02a5960681b723ef372e6876a7c2543a365d8

Confirm it is available:

swift sdk list
# swift-6.4.1-RELEASE_wasm

wasmtime

wasmtime runs the compiled .wasm module. The proof of concept pinned version 38.0.1. On Linux x86_64 that is:

curl -sSfL "https://github.com/bytecodealliance/wasmtime/releases/download/v38.0.1/wasmtime-v38.0.1-x86_64-linux.tar.xz" | tar xJ
export PATH="$PWD/wasmtime-v38.0.1-x86_64-linux:$PATH"
wasmtime --version

For other platforms, download the matching archive from the wasmtime releases page.

Next steps

Continue with Getting started to build, test and run the package. A xwift CLI that manages toolchains and SDKs for you is planned.

On this page