From 26d2561f326378e55ca37668a6df0ee0601f3eb4 Mon Sep 17 00:00:00 2001 From: Melissa Kilby Date: Thu, 4 Sep 2025 13:59:41 -0700 Subject: [PATCH 1/3] update[static-sdk]: expand installation section Signed-off-by: Melissa Kilby --- .../articles/static-linux-getting-started.md | 84 +++++++++++++------ 1 file changed, 57 insertions(+), 27 deletions(-) diff --git a/documentation/articles/static-linux-getting-started.md b/documentation/articles/static-linux-getting-started.md index b6f1831e1..48da7c82d 100644 --- a/documentation/articles/static-linux-getting-started.md +++ b/documentation/articles/static-linux-getting-started.md @@ -108,55 +108,85 @@ and can be installed by simply copying. ### Installing the SDK -Before you start, it's important to note: +#### (1) Prerequisites -* You will need to [install an Open Source toolchain from - swift.org](/install/). +Before starting, please note the following requirements: -* You cannot use the toolchain provided with Xcode to build programs - using the SDK. +* You need to install an open-source [Swift toolchain](/install/) from + swift.org. -* If you are using macOS, you will also need to ensure that you use - the Swift compiler from this toolchain by [following the - instructions - here](/install/macos/package_installer/). +* If you are using macOS, note that you cannot use the toolchain + provided with Xcode to build programs using the SDK. Instead, just + to remind you, you must use the Swift compiler from the open-source + toolchain (see above). -* The toolchain must match the version of the Static Linux SDK that - you install. The Static Linux SDK includes the corresponding Swift - version in its filename to help identify the correct version of the - SDK. +#### (2) Pre-Installation Notes -* When installing Swift SDKs from remote URLs, you have to pass a - `--checksum` option with the corresponding checksum provided by the - author of the Swift SDK. +Please be aware of: -Once that is out of the way, actually installing the Static Linux SDK -is easy; at a prompt, enter +* Version compatibility: The Swift toolchain must match the version of + the Static Linux SDK that you install. + +* Clean installation: If you previously installed an SDK for a + different Swift toolchain version, remove the old one before + installing the new one (see management commands below). + +* Checksum verification: When installing Swift SDKs from remote URLs, + you must pass a `--checksum` option with the corresponding checksum + provided by the SDK author. + +* Command pattern: The installation follows the pattern described in + the next sections. + +#### (3) Download and Install the Static Linux SDK + +To obtain the Static Linux SDK: + +* Visit the swift.org [installation + page](https://www.swift.org/install) for complete Static Linux SDK + installation instructions, where you can download directly or click + "Copy install command". + +* For previous releases, navigate to "Previous Releases" on the + installation page. + +* For development snapshots, access the static-sdk YAML file for your + target branch (e.g., swift-6.2-branch snapshots + [here](https://github.com/swiftlang/swift-org-website/blob/main/_data/builds/swift-6_2-branch/static-sdk.yml)) + to quickly construct the install command (following the pattern + explained below) by browsing the available checksums. + +#### (4) Installation Commands Pattern + +The basic installation command follows this pattern: ```console $ swift sdk install [--checksum ] ``` -giving the URL (and a corresponding checksum) or filename at which the SDK can be found. +You can provide either a URL (with corresponding checksum) or a local +filename where the SDK can be found. -For instance, assuming you have installed the -`swift-6.0-DEVELOPMENT-SNAPSHOT-2024-07-02-a` toolchain, you would -need to enter +For example, if you have installed the `swift-6.1.2-RELEASE` toolchain, you would enter: ```console -$ swift sdk install https://download.swift.org/swift-6.0-branch/static-sdk/swift-6.0-DEVELOPMENT-SNAPSHOT-2024-07-02-a/swift-6.0-DEVELOPMENT-SNAPSHOT-2024-07-02-a_static-linux-0.0.1.artifactbundle.tar.gz --checksum 42a361e1a240e97e4bb3a388f2f947409011dcd3d3f20b396c28999e9736df36 +$ swift sdk install https://download.swift.org/swift-6.1.2-release/static-sdk/swift-6.1.2-RELEASE/swift-6.1.2-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz --checksum df0b40b9b582598e7e3d70c82ab503fd6fbfdff71fd17e7f1ab37115a0665b3b ``` -to install the corresponding Static Linux SDK. +This will download and install the corresponding Static Linux SDK on +your system. + +#### (5) Managing Installed SDKs + +After installation, you can manage your SDKs using these commands: -Swift will download and install the SDK on your system. You can get a -list of installed SDKs with +List all installed SDKs: ```console $ swift sdk list ``` -and it's also possible to remove them using +Remove an SDK: ```console $ swift sdk remove From a08b4a13faf0cbb741e9cb2b2c0206736cdaa25a Mon Sep 17 00:00:00 2001 From: Melissa Kilby Date: Fri, 5 Sep 2025 12:51:30 -0700 Subject: [PATCH 2/3] update[static-sdk]: apply reviewers suggestions Co-authored-by: Alastair Houghton Signed-off-by: Melissa Kilby --- documentation/articles/static-linux-getting-started.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/documentation/articles/static-linux-getting-started.md b/documentation/articles/static-linux-getting-started.md index 48da7c82d..d26fe8cc3 100644 --- a/documentation/articles/static-linux-getting-started.md +++ b/documentation/articles/static-linux-getting-started.md @@ -116,9 +116,9 @@ Before starting, please note the following requirements: swift.org. * If you are using macOS, note that you cannot use the toolchain - provided with Xcode to build programs using the SDK. Instead, just - to remind you, you must use the Swift compiler from the open-source - toolchain (see above). + provided with Xcode to build programs using the SDK. Instead, you + must use the Swift compiler from the open-source toolchain (see + above). #### (2) Pre-Installation Notes From b8a367cbdea576e9bd14ea10129bc8414cdc5bb8 Mon Sep 17 00:00:00 2001 From: Melissa Kilby Date: Tue, 16 Sep 2025 17:48:05 -0700 Subject: [PATCH 3/3] update[static-sdk]: apply reviewers suggestions Co-authored-by: Mishal Shah Signed-off-by: Melissa Kilby --- .../articles/static-linux-getting-started.md | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/documentation/articles/static-linux-getting-started.md b/documentation/articles/static-linux-getting-started.md index d26fe8cc3..f5fa427b1 100644 --- a/documentation/articles/static-linux-getting-started.md +++ b/documentation/articles/static-linux-getting-started.md @@ -150,11 +150,6 @@ To obtain the Static Linux SDK: * For previous releases, navigate to "Previous Releases" on the installation page. -* For development snapshots, access the static-sdk YAML file for your - target branch (e.g., swift-6.2-branch snapshots - [here](https://github.com/swiftlang/swift-org-website/blob/main/_data/builds/swift-6_2-branch/static-sdk.yml)) - to quickly construct the install command (following the pattern - explained below) by browsing the available checksums. #### (4) Installation Commands Pattern @@ -167,10 +162,20 @@ $ swift sdk install [--checksum + +For example, if you have installed the {{ tag }} toolchain, you would enter: ```console -$ swift sdk install https://download.swift.org/swift-6.1.2-release/static-sdk/swift-6.1.2-RELEASE/swift-6.1.2-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz --checksum df0b40b9b582598e7e3d70c82ab503fd6fbfdff71fd17e7f1ab37115a0665b3b +$ {{ command }} ``` This will download and install the corresponding Static Linux SDK on