From e76aadcbeb316a46535330ed846a54c226cea6f4 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 25 Aug 2025 15:41:19 -0700 Subject: [PATCH 01/24] Use config action for swift-argument-parser --- .github/workflows/swift-toolchain.yml | 49 +++++++++++++-------------- 1 file changed, 23 insertions(+), 26 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 3603ec372..abddaa010 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3501,32 +3501,29 @@ jobs: path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/Windows.platform - name: Configure swift-argument-parser - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-argument-parser ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-argument-parser + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-argument-parser + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-argument-parser + bin-dir: ${{ github.workspace }}/BinaryCache/swift-argument-parser + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'BUILD_TESTING' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + } - name: Build swift-argument-parser run: cmake --build ${{ github.workspace }}/BinaryCache/swift-argument-parser From 9840fa98fb180f418cad1522724d74356c01e3cf Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 25 Aug 2025 19:35:10 -0700 Subject: [PATCH 02/24] Use config action for swift-collections --- .github/workflows/swift-toolchain.yml | 48 ++++++++++++--------------- 1 file changed, 22 insertions(+), 26 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index abddaa010..e08aeb17b 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3528,32 +3528,28 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-argument-parser - name: Configure swift-collections - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-collections ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-collections + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-collections + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-collections + bin-dir: ${{ github.workspace }}/BinaryCache/swift-collections + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + } - name: Build swift-collections run: cmake --build ${{ github.workspace }}/BinaryCache/swift-collections From 15fb71cea041e48949f0947d7f919a9c65b9490a Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 25 Aug 2025 19:38:15 -0700 Subject: [PATCH 03/24] Use config action for swift-asn1 --- .github/workflows/swift-toolchain.yml | 39 ++++++++++++++------------- 1 file changed, 21 insertions(+), 18 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index e08aeb17b..6c03dd0ff 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3554,24 +3554,27 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-collections - name: Configure swift-asn1 - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-asn1 ` - -D BUILD_SHARED_LIBS=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-asn1 + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-asn1 + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-asn1 + bin-dir: ${{ github.workspace }}/BinaryCache/swift-asn1 + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + } - name: Build swift-asn1 run: cmake --build ${{ github.workspace }}/BinaryCache/swift-asn1 From ff654eeda274b912e24c07b80b97e1ff23d82c6a Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 25 Aug 2025 19:44:34 -0700 Subject: [PATCH 04/24] Use config action for swift-crypto --- .github/workflows/swift-toolchain.yml | 54 ++++++++++++--------------- 1 file changed, 23 insertions(+), 31 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 6c03dd0ff..152fbe8d3 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3579,37 +3579,29 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-asn1 - name: Configure swift-crypto - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-crypto ` - -D BUILD_SHARED_LIBS=NO ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_ASM_COMPILER=${CLANG_CL} ` - -D CMAKE_ASM_FLAGS="--target=${{ matrix.triple }}" ` - -D CMAKE_ASM_COMPILE_OPTIONS_MSVC_RUNTIME_LIBRARY_MultiThreadedDLL="/MD" ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-crypto ` - -D SwiftASN1_DIR=${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules - + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-crypto + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-crypto + bin-dir: ${{ github.workspace }}/BinaryCache/swift-crypto + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("ASM", "C", "CXX", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'SwiftASN1_DIR' = "${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules"; + } - name: Build swift-crypto run: cmake --build ${{ github.workspace }}/BinaryCache/swift-crypto From dfb08bc03810894881ffcda68264a7c2c3f9b764 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 25 Aug 2025 19:56:48 -0700 Subject: [PATCH 05/24] Use config action for swift-systems --- .github/workflows/swift-toolchain.yml | 48 ++++++++++++--------------- 1 file changed, 22 insertions(+), 26 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 152fbe8d3..1771e1fd3 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3639,32 +3639,28 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-llbuild - name: Configure swift-system - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-system ` - -D BUILD_SHARED_LIBS=NO ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-system + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-system + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-system + bin-dir: ${{ github.workspace }}/BinaryCache/swift-system + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + } - name: Build swift-system run: cmake --build ${{ github.workspace }}/BinaryCache/swift-system From 3531f391833ec82421b1220022952b97232d6271 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Mon, 25 Aug 2025 19:59:03 -0700 Subject: [PATCH 06/24] Use config action for swift-subprocess --- .github/workflows/swift-toolchain.yml | 49 ++++++++++++--------------- 1 file changed, 22 insertions(+), 27 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 1771e1fd3..4b7b18a97 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3665,33 +3665,28 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-system - name: Configure swift-subprocess - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-subprocess ` - -D BUILD_SHARED_LIBS=NO ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - -D CMAKE_STATIC_LIBRARY_PREFIX_Swift="lib" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-subprocess + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-subprocess + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-subprocess + bin-dir: ${{ github.workspace }}/BinaryCache/swift-subprocess + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + } - name: Build swift-subprocess run: cmake --build ${{ github.workspace }}/BinaryCache/swift-subprocess From 550f4467a7dfb2ae25648e31b958d8af380bc238 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 09:26:10 -0700 Subject: [PATCH 07/24] Setup sccache --- .github/workflows/swift-toolchain.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 4b7b18a97..86178881e 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3325,6 +3325,25 @@ jobs: with: setup-vs-dev-env: true host-arch: ${{ matrix.arch }} + - name: Compute workspace hash + if: matrix.os != 'Android' || inputs.build_android + id: workspace_hash + run: | + $stringAsStream = [System.IO.MemoryStream]::new() + $writer = [System.IO.StreamWriter]::new($stringAsStream) + $writer.write("${{ github.workspace }}") + $writer.Flush() + $stringAsStream.Position = 0 + $hash = (Get-FileHash -Algorithm SHA256 -InputStream $stringAsStream).Hash + echo "hash=$hash" >> $env:GITHUB_OUTPUT + - name: Setup sccache + uses: ./SourceCache/ci-build/.github/actions/setup-sccache + with: + s3-bucket: ${{ vars.SCCACHE_S3_BUCKET }} + aws-region: ${{ vars.SCCACHE_AWS_REGION }} + aws-arn: ${{ vars.SCCACHE_AWS_ARN }} + disk-max-size: 100M + disk-cache-key: ${{ steps.workspace_hash.outputs.hash }}-${{ matrix.os }}-${{ matrix.arch }}-devtools - uses: actions/download-artifact@v4 with: From be735380b220a34ef8f0544346c61e24dfd73b39 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 10:05:03 -0700 Subject: [PATCH 08/24] Use config action for swift-tools-support-core --- .github/workflows/swift-toolchain.yml | 53 ++++++++++++--------------- 1 file changed, 24 insertions(+), 29 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 86178881e..2d72ba996 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3710,35 +3710,30 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-subprocess - name: Configure swift-tools-support-core - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-tools-support-core ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-tools-support-core ` - -D SwiftSystem_DIR=${{ github.workspace }}/BinaryCache/swift-system/cmake/modules ` - -D SQLite3_LIBRARY=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib ` - -D SQLite3_INCLUDE_DIR=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-tools-support-core + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-tools-support-core + bin-dir: ${{ github.workspace }}/BinaryCache/swift-tools-support-core + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'Foundation_DIR' = "${{ github.workspace }}/BinaryCache/foundation/cmake/modules"; + 'XCTest_DIR' = "${{ github.workspace }}/BinaryCache/xctest/cmake/modules"; + } - name: Build swift-tools-support-core run: cmake --build ${{ github.workspace }}/BinaryCache/swift-tools-support-core From 7d63a819b062a1285f3bb5b6e6fbc149042b222a Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 10:11:23 -0700 Subject: [PATCH 09/24] Use config action for swift-llbuild --- .github/workflows/swift-toolchain.yml | 53 ++++++++++++--------------- 1 file changed, 24 insertions(+), 29 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 2d72ba996..e93592ebf 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3625,35 +3625,30 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-crypto - name: Configure swift-llbuild - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-llbuild ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-llbuild ` - -D LLBUILD_SUPPORT_BINDINGS=Swift ` - -D SQLite3_LIBRARY=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib ` - -D SQLite3_INCLUDE_DIR=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-llbuild + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-llbuild + bin-dir: ${{ github.workspace }}/BinaryCache/swift-llbuild + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("CXX", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'LLBUILD_SUPPORT_BINDINGS' = "Swift"; + 'SQLite3_INCLUDE_DIR' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; + 'SQLite3_LIBRARY' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; + } - name: Build swift-llbuild run: cmake --build ${{ github.workspace }}/BinaryCache/swift-llbuild From 6e17e2dc78d18b0f5814b55d858dddc684093ed9 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 10:25:55 -0700 Subject: [PATCH 10/24] Use config action for swift-driver --- .github/workflows/swift-toolchain.yml | 63 +++++++++++++-------------- 1 file changed, 31 insertions(+), 32 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index e93592ebf..723f3ceff 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3733,38 +3733,37 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-tools-support-core - name: Configure swift-driver - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-driver ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-driver ` - -D ArgumentParser_DIR=${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules ` - -D LLBuild_DIR=${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules ` - -D SwiftSystem_DIR=${{ github.workspace }}/BinaryCache/swift-system/cmake/modules ` - -D SQLite3_LIBRARY=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib ` - -D SQLite3_INCLUDE_DIR=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include ` - -D TSC_DIR=${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-driver + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-driver + bin-dir: ${{ github.workspace }}/BinaryCache/swift-driver + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "CXX", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'TSC_DIR'="${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules"; + 'LLBuild_DIR'="${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules"; + 'ArgumentParser_DIR'="${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; + 'SQLite3_INCLUDE_DIR'="${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; + 'SQLite3_LIBRARY'="${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; + 'SWIFT_DRIVER_BUILD_TOOLS' = "YES"; + 'LLVM_DIR' = "${{ github.workspace }}/BinaryCache/llvm/lib/cmake/llvm"; + 'Clang_DIR' = "${{ github.workspace }}/BinaryCache/llvm/lib/cmake/clang"; + 'Swift_DIR' = "${{ github.workspace }}/BinaryCache/llvm/tools/swift/lib/cmake/swift"; + } - name: Build swift-driver run: cmake --build ${{ github.workspace }}/BinaryCache/swift-driver From 447f5a7148b8347821e3aa08209c2697a5af5b7f Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 10:28:45 -0700 Subject: [PATCH 11/24] Use config action for swift-certificates --- .github/workflows/swift-toolchain.yml | 44 ++++++++++++++------------- 1 file changed, 23 insertions(+), 21 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 723f3ceff..c1275add2 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3768,27 +3768,29 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-driver - name: Configure swift-certificates - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-certificates ` - -D BUILD_SHARED_LIBS=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-certificates ` - -D SwiftASN1_DIR=${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules ` - -D SwiftCrypto_DIR=${{ github.workspace }}/BinaryCache/swift-crypto/cmake/modules + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-certificates + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-certificates + bin-dir: ${{ github.workspace }}/BinaryCache/swift-certificates + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'SwiftCrypto_DIR'="${{ github.workspace }}/BinaryCache/swift-crypto/cmake/modules"; + 'SwiftASN1_DIR'="${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules"; + } - name: Build swift-certificates run: cmake --build ${{ github.workspace }}/BinaryCache/swift-certificates From 5483b4f4a249e6d31143ca3135600e13fae37910 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 10:46:07 -0700 Subject: [PATCH 12/24] Use config action for swift-build --- .github/workflows/swift-toolchain.yml | 76 +++++++++++---------------- 1 file changed, 30 insertions(+), 46 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index c1275add2..01877c3cf 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3795,52 +3795,36 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-certificates - name: Configure swift-build - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - if ("${{ matrix.arch }}" -eq "arm64") { - # We use the lld linker to work around erratum 843419 on Cortex-A53 - # CPUs. Otherwise, this causes link.exe to fail with LNK1322. - # See https://github.com/swiftlang/swift/issues/79740 for details. - $ArchSpecificFlags = "-use-ld=lld-link" - } - - # `CMAKE_SHARED_LINKER_FLAGS` and `CMAKE_SHARED_LINKER_FLAGS_RELEASE` - # are set to empty string here to work around the fact that this - # project uses either swift.exe or link.exe as the linker. - # swift.exe cannot properly parse the link.exe flags directly. - # This should be fixed with CMake 4.0 by passing the linker flags with - # a `LINKER:` prefix, while setting `CMP0181` to `NEW`. - cmake -B ${{ github.workspace }}/BinaryCache/swift-build ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${ArchSpecificFlags} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -D CMAKE_SHARED_LINKER_FLAGS="" ` - -D CMAKE_SHARED_LINKER_FLAGS_RELEASE="" ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-build ` - -D ArgumentParser_DIR=${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules ` - -D LLBuild_DIR=${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules ` - -D SwiftDriver_DIR=${{ github.workspace }}/BinaryCache/swift-driver/cmake/modules ` - -D SwiftSystem_DIR=${{ github.workspace }}/BinaryCache/swift-system/cmake/modules ` - -D TSC_DIR=${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules ` - -D SQLite3_INCLUDE_DIR=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include ` - -D SQLite3_LIBRARY=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-build + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-build + bin-dir: ${{ github.workspace }}/BinaryCache/swift-build + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "CXX", "Swift")' + cmake-defines: | + (@{ + 'BUILD_SHARED_LIBS' = "YES"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'ArgumentParser_DIR' = "${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; + 'LLBuild_DIR' = "${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules"; + 'SwiftDriver_DIR' = "${{ github.workspace }}/BinaryCache/swift-driver/cmake/modules"; + 'SwiftSystem_DIR' = "${{ github.workspace }}/BinaryCache/swift-system/cmake/modules"; + 'TSC_DIR' = "${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules"; + 'SQLite3_INCLUDE_DIR' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; + 'SQLite3_LIBRARY' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; + 'CMAKE_Swift_FLAGS' = "-use-ld=lld-link"; + } + @{ ${{ matrix.arch == 'arm64' && 'CMAKE_Swift_FLAGS = "-use-ld=lld-link";' || '' }} }) - name: Build swift-build run: cmake --build ${{ github.workspace }}/BinaryCache/swift-build From 12601aea07fb3299e02b96c9a77af6377f3ecde1 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 14:09:46 -0700 Subject: [PATCH 13/24] Use config action for swift-package-manager --- .github/workflows/swift-toolchain.yml | 75 +++++++++++++-------------- 1 file changed, 36 insertions(+), 39 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 01877c3cf..11aec11d1 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3835,45 +3835,42 @@ jobs: (Get-Content $module).Replace('', "${bindir}") | Set-Content $module - name: Configure swift-package-manager - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-package-manager ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-package-manager ` - -D ArgumentParser_DIR=${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules ` - -D LLBuild_DIR=${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules ` - -D SQLite3_INCLUDE_DIR=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include ` - -D SQLite3_LIBRARY=${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib ` - -D SwiftASN1_DIR=${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules ` - -D SwiftBuild_DIR=${{ github.workspace }}/BinaryCache/swift-build/cmake/modules ` - -D SwiftCertificates_DIR=${{ github.workspace }}/BinaryCache/swift-certificates/cmake/modules ` - -D SwiftCollections_DIR=${{ github.workspace }}/BinaryCache/swift-collections/cmake/modules ` - -D SwiftCrypto_DIR=${{ github.workspace }}/BinaryCache/swift-crypto/cmake/modules ` - -D SwiftDriver_DIR=${{ github.workspace }}/BinaryCache/swift-driver/cmake/modules ` - -D SwiftSyntax_DIR=${{ github.workspace }}/BinaryCache/swift-syntax/cmake/modules ` - -D SwiftSystem_DIR=${{ github.workspace }}/BinaryCache/swift-system/cmake/modules ` - -D TSC_DIR=${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-package-manager + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-package-manager + bin-dir: ${{ github.workspace }}/BinaryCache/swift-package-manager + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'CMAKE_Swift_FLAGS' = @("-DCRYPTO_v2"); + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'SwiftSystem_DIR' = "${{ github.workspace }}/BinaryCache/swift-system/cmake/modules"; + 'TSC_DIR' = "${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules"; + 'LLBuild_DIR' = "${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules"; + 'ArgumentParser_DIR' = "${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; + 'SwiftDriver_DIR' = "${{ github.workspace }}/BinaryCache/swift-driver/cmake/modules"; + 'SwiftBuild_DIR' = "${{ github.workspace }}/BinaryCache/swift-build/cmake/modules"; + 'SwiftCrypto_DIR' = "${{ github.workspace }}/BinaryCache/swift-crypto/cmake/modules"; + 'SwiftCollections_DIR' = "${{ github.workspace }}/BinaryCache/swift-collections/cmake/modules"; + 'SwiftASN1_DIR' = "${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules"; + 'SwiftCertificates_DIR' = "${{ github.workspace }}/BinaryCache/swift-certificates/cmake/modules"; + 'SwiftSyntax_DIR' = "${{ github.workspace }}/BinaryCache/swift-syntax/cmake/modules" + 'SQLite3_INCLUDE_DIR' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; + 'SQLite3_LIBRARY' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; + } - name: Build swift-package-manager run: cmake --build ${{ github.workspace }}/BinaryCache/swift-package-manager From 4223adab27027f0bf27775b36419345cd64123d9 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 14:12:42 -0700 Subject: [PATCH 14/24] Use config action for swift-markdown --- .github/workflows/swift-toolchain.yml | 51 +++++++++++++-------------- 1 file changed, 24 insertions(+), 27 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 11aec11d1..590674934 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3875,33 +3875,30 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-package-manager - name: Configure Markdown - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-markdown ` - -D BUILD_SHARED_LIBS=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-markdown ` - -D ArgumentParser_DIR=${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules ` - -D cmark-gfm_DIR=${{ github.workspace }}/BinaryCache/Library/cmark-gfm-${{ inputs.swift_cmark_version }}/usr/lib/cmake + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-markdown + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-markdown + bin-dir: ${{ github.workspace }}/BinaryCache/swift-markdown + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'ArgumentParser_DIR' = "${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; + 'cmark-gfm_DIR' = "${{ github.workspace }}/BinaryCache/Library/cmark-gfm-${{ inputs.swift_cmark_version }}/usr/lib/cmake"; + } - name: Build Markdown run: cmake --build ${{ github.workspace }}/BinaryCache/swift-markdown From 0fdc4400f1cb57a7804fa4d71eb4fbdb56148065 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 14:20:14 -0700 Subject: [PATCH 15/24] Use config action for swift-format --- .github/workflows/swift-toolchain.yml | 54 +++++++++++++-------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 590674934..deb3c05ee 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3902,33 +3902,33 @@ jobs: - name: Build Markdown run: cmake --build ${{ github.workspace }}/BinaryCache/swift-markdown - - name: Configure Format - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-format ` - -D BUILD_SHARED_LIBS=YES ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-format ` - -D ArgumentParser_DIR=${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules ` - -D cmark-gfm_DIR=${{ github.workspace }}/BinaryCache/Library/cmark-gfm-${{ inputs.swift_cmark_version }}/usr/lib/cmake ` - -D SwiftMarkdown_DIR=${{ github.workspace }}/BinaryCache/swift-markdown/cmake/modules ` - -D SwiftSyntax_DIR=${{ github.workspace }}/BinaryCache/swift-syntax/cmake/modules + - name: Configure swift-format + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-format + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-format + bin-dir: ${{ github.workspace }}/BinaryCache/swift-format + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + msvc-compilers: '@("C")' + built-compilers: '@("Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "YES"; + 'ArgumentParser_DIR' = "${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; + 'SwiftMarkdown_DIR' = "${{ github.workspace }}/BinaryCache/swift-markdown/cmake/modules"; + 'SwiftSyntax_DIR' = "${{ github.workspace }}/BinaryCache/swift-syntax/cmake/modules"; + 'cmark-gfm_DIR' = "${{ github.workspace }}/BinaryCache/Library/cmark-gfm-${{ inputs.swift_cmark_version }}/usr/lib/cmake"; + } - name: Build swift-format run: cmake --build ${{ github.workspace }}/BinaryCache/swift-format From 8a5aa6bcedba0ee97daa6b0eaadc643b34ceef6e Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 14:22:17 -0700 Subject: [PATCH 16/24] Use config action for swift-lmdb --- .github/workflows/swift-toolchain.yml | 33 +++++++++++++-------------- 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index deb3c05ee..6a46d59e2 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3933,23 +3933,22 @@ jobs: run: cmake --build ${{ github.workspace }}/BinaryCache/swift-format - name: Configure swift-lmdb - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/swift-lmdb ` - -D BUILD_SHARED_LIBS=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/swift-lmdb + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: swift-lmdb + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/swift-lmdb + bin-dir: ${{ github.workspace }}/BinaryCache/swift-lmdb + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + msvc-compilers: '@("C")' - name: Build swift-lmdb run: cmake --build ${{ github.workspace }}/BinaryCache/swift-lmdb From e2ef42136a2045f1e2f99d6d97f5e398699c2a45 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 14:29:23 -0700 Subject: [PATCH 17/24] Use config action for indexstore-db --- .github/workflows/swift-toolchain.yml | 53 +++++++++++++-------------- 1 file changed, 25 insertions(+), 28 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 6a46d59e2..bf4b6cd2d 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3952,34 +3952,31 @@ jobs: - name: Build swift-lmdb run: cmake --build ${{ github.workspace }}/BinaryCache/swift-lmdb - - name: Configure IndexStoreDB - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/indexstore-db ` - -D BUILD_SHARED_LIBS=NO ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }} -I${env:SDKROOT}/usr/include -I${env:SDKROOT}/usr/include/Block" ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/indexstore-db ` - -D LMDB_DIR=${{ github.workspace }}/BinaryCache/swift-lmdb/cmake/modules + - name: Configure indexstore-db + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: indexstore-db + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/indexstore-db + bin-dir: ${{ github.workspace }}/BinaryCache/indexstore-db + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "CXX", "Swift")' + cmake-defines: | + @{ + 'BUILD_SHARED_LIBS' = "NO"; + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'CMAKE_C_FLAGS' = @("-I${env:SDKROOT}/usr/include -I${env:SDKROOT}/usr/include/Block"); + 'CMAKE_CXX_FLAGS' = @("-I${env:SDKROOT}/usr/include -I${env:SDKROOT}/usr/include/Block"); + 'LMDB_DIR' = "${{ github.workspace }}/BinaryCache/swift-lmdb/cmake/modules"; + } - name: Build indexstore-db run: cmake --build ${{ github.workspace }}/BinaryCache/indexstore-db From a4d6b50275f3eacaa6d61df1aed4e2797a9f652d Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 14:35:55 -0700 Subject: [PATCH 18/24] Use config action for sourcekit-lsp --- .github/workflows/swift-toolchain.yml | 75 +++++++++++++-------------- 1 file changed, 35 insertions(+), 40 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index bf4b6cd2d..2789c180c 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3980,46 +3980,41 @@ jobs: - name: Build indexstore-db run: cmake --build ${{ github.workspace }}/BinaryCache/indexstore-db - - name: Configure SourceKit-LSP - run: | - # Workaround CMake 3.20 issue - $CLANG_CL = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/clang-cl.exe - $SWIFTC = cygpath -m ${{ github.workspace }}/BinaryCache/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr/bin/swiftc.exe - - cmake -B ${{ github.workspace }}/BinaryCache/sourcekit-lsp ` - -D BUILD_SHARED_LIBS=YES ` - -D BUILD_TESTING=NO ` - -D CMAKE_BUILD_TYPE=Release ` - -D CMAKE_INSTALL_PREFIX=${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr ` - -D CMAKE_C_COMPILER=${CLANG_CL} ` - -D CMAKE_C_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_C_FLAGS="${{ inputs.WINDOWS_CMAKE_C_FLAGS }}" ` - -D CMAKE_CXX_COMPILER=${CLANG_CL} ` - -D CMAKE_CXX_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_CXX_FLAGS="${{ inputs.WINDOWS_CMAKE_CXX_FLAGS }}" ` - -D CMAKE_Swift_COMPILER=${SWIFTC} ` - -D CMAKE_Swift_COMPILER_TARGET=${{ matrix.triple }} ` - -D CMAKE_Swift_COMPILER_WORKS=YES ` - -D CMAKE_Swift_FLAGS="-sdk ${env:SDKROOT} ${{ inputs.CMAKE_Swift_FLAGS }}" ` - -D CMAKE_Swift_FLAGS_RELEASE="-O" ` - ${{ matrix.cmake_linker_flags }} ` - -D CMAKE_SYSTEM_NAME=Windows ` - -D CMAKE_SYSTEM_PROCESSOR=${{ matrix.cpu }} ` - -G Ninja ` - -S ${{ github.workspace }}/SourceCache/sourcekit-lsp ` - -D ArgumentParser_DIR=${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules ` - -D IndexStoreDB_DIR=${{ github.workspace }}/BinaryCache/indexstore-db/cmake/modules ` - -D LLBuild_DIR=${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules ` - -D SwiftASN1_DIR=${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules ` - -D SwiftCollections_DIR=${{ github.workspace }}/BinaryCache/swift-collections/cmake/modules ` - -D SwiftCrypto_DIR=${{ github.workspace }}/BinaryCache/swift-crypto/cmake/modules ` - -D SwiftPM_DIR=${{ github.workspace }}/BinaryCache/swift-package-manager/cmake/modules ` - -D SwiftSyntax_DIR=${{ github.workspace }}/BinaryCache/swift-syntax/cmake/modules ` - -D SwiftSystem_DIR=${{ github.workspace }}/BinaryCache/swift-system/cmake/modules ` - -D TSC_DIR=${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules ` - -D LMDB_DIR=${{ github.workspace }}/BinaryCache/swift-lmdb/cmake/modules - - name: Build SourceKit-LSP - run: cmake --build ${{ github.workspace }}/BinaryCache/SourceKit-LSP + - name: Configure sourcekit-lsp + uses: ./SourceCache/ci-build/.github/actions/configure-cmake-project + with: + project-name: sourcekit-lsp + swift-version: ${{ inputs.swift_version }} + enable-caching: true + debug-info: ${{ inputs.debug_info }} + build-os: ${{ inputs.build_os }} + build-arch: ${{ inputs.build_arch }} + os: ${{ matrix.os }} + arch: ${{ matrix.arch }} + src-dir: ${{ github.workspace }}/SourceCache/sourcekit-lsp + bin-dir: ${{ github.workspace }}/BinaryCache/sourcekit-lsp + install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr + android-api-level: ${{ inputs.ANDROID_API_LEVEL }} + android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} + swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk + built-compilers: '@("C", "Swift")' + cmake-defines: | + @{ + 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; + 'SwiftSyntax_DIR' = "${{ github.workspace }}/BinaryCache/swift-syntax/cmake/modules"; + 'TSC_DIR' = "${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules"; + 'LLBuild_DIR' = "${{ github.workspace }}/BinaryCache/swift-llbuild/cmake/modules"; + 'ArgumentParser_DIR' = "${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; + 'SwiftASN1_DIR' = "${{ github.workspace }}/BinaryCache/swift-asn1/cmake/modules"; + 'SwiftCrypto_DIR' = "${{ github.workspace }}/BinaryCache/swift-crypto/cmake/modules"; + 'SwiftCollections_DIR' = "${{ github.workspace }}/BinaryCache/swift-collections/cmake/modules"; + 'SwiftBuild_DIR' = "${{ github.workspace }}/BinaryCache/swift-build/cmake/modules"; + 'SwiftPM_DIR' = "${{ github.workspace }}/BinaryCache/swift-package-manager/cmake/modules"; + 'LMDB_DIR' = "${{ github.workspace }}/BinaryCache/swift-lmdb/cmake/modules"; + 'IndexStoreDB_DIR' = "${{ github.workspace }}/BinaryCache/indexstore-db/cmake/modules"; + } + - name: Build sourcekit-lsp + run: cmake --build ${{ github.workspace }}/BinaryCache/sourcekit-lsp - name: Install swift-argument-parser run: cmake --build ${{ github.workspace }}/BinaryCache/swift-argument-parser --target install From 8e1e17adbce16d5e1a1cbb8b0ebd82094aff7245 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Tue, 26 Aug 2025 17:18:07 -0700 Subject: [PATCH 19/24] Remove non-exisisting dirs --- .github/workflows/swift-toolchain.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 2789c180c..a1a9b5b22 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3760,9 +3760,6 @@ jobs: 'SQLite3_INCLUDE_DIR'="${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; 'SQLite3_LIBRARY'="${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; 'SWIFT_DRIVER_BUILD_TOOLS' = "YES"; - 'LLVM_DIR' = "${{ github.workspace }}/BinaryCache/llvm/lib/cmake/llvm"; - 'Clang_DIR' = "${{ github.workspace }}/BinaryCache/llvm/lib/cmake/clang"; - 'Swift_DIR' = "${{ github.workspace }}/BinaryCache/llvm/tools/swift/lib/cmake/swift"; } - name: Build swift-driver run: cmake --build ${{ github.workspace }}/BinaryCache/swift-driver From baee2ef5d04ee22abf382aef709df1efabc449da Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Fri, 29 Aug 2025 11:20:13 -0700 Subject: [PATCH 20/24] Do not build with SWIFT_DRIVER_BUILD_TOOLS = YES; --- .github/workflows/swift-toolchain.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index a1a9b5b22..0c171fa6d 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3759,7 +3759,7 @@ jobs: 'ArgumentParser_DIR'="${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; 'SQLite3_INCLUDE_DIR'="${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; 'SQLite3_LIBRARY'="${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; - 'SWIFT_DRIVER_BUILD_TOOLS' = "YES"; + 'SWIFT_DRIVER_BUILD_TOOLS' = "NO"; } - name: Build swift-driver run: cmake --build ${{ github.workspace }}/BinaryCache/swift-driver From 0f86a367d20fa3b1deb0c433eb1120572a4feed4 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Fri, 29 Aug 2025 15:38:05 -0700 Subject: [PATCH 21/24] Use CMake 3.29 --- .github/workflows/swift-toolchain.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 0c171fa6d..fca8283d4 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3326,7 +3326,6 @@ jobs: setup-vs-dev-env: true host-arch: ${{ matrix.arch }} - name: Compute workspace hash - if: matrix.os != 'Android' || inputs.build_android id: workspace_hash run: | $stringAsStream = [System.IO.MemoryStream]::new() @@ -3344,6 +3343,10 @@ jobs: aws-arn: ${{ vars.SCCACHE_AWS_ARN }} disk-max-size: 100M disk-cache-key: ${{ steps.workspace_hash.outputs.hash }}-${{ matrix.os }}-${{ matrix.arch }}-devtools + # FIXME(compnerd): workaround CMake 3.30+ issue + - uses: lukka/get-cmake@aa1df13cce8c30d2cb58efa871271c5a764623f8 # main + with: + cmakeVersion: 3.29.9 - uses: actions/download-artifact@v4 with: From aded9e3bf316e406a48e588c89e1a75b535d309d Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Fri, 29 Aug 2025 18:59:27 -0700 Subject: [PATCH 22/24] Fix flags --- .github/workflows/swift-toolchain.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index fca8283d4..4f3e8e535 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3813,7 +3813,7 @@ jobs: swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "CXX", "Swift")' cmake-defines: | - (@{ + @{ 'BUILD_SHARED_LIBS' = "YES"; 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; 'ArgumentParser_DIR' = "${{ github.workspace }}/BinaryCache/swift-argument-parser/cmake/modules"; @@ -3823,8 +3823,8 @@ jobs: 'TSC_DIR' = "${{ github.workspace }}/BinaryCache/swift-tools-support-core/cmake/modules"; 'SQLite3_INCLUDE_DIR' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/include"; 'SQLite3_LIBRARY' = "${{ github.workspace }}/BinaryCache/Library/sqlite-${{ inputs.swift_toolchain_sqlite_version }}/usr/lib/SQLite3.lib"; - 'CMAKE_Swift_FLAGS' = "-use-ld=lld-link"; - } + @{ ${{ matrix.arch == 'arm64' && 'CMAKE_Swift_FLAGS = "-use-ld=lld-link";' || '' }} }) + 'CMAKE_Swift_FLAGS' = "${{ matrix.arch == 'arm64' && '-use-ld=lld-link' || '' }}"; + } - name: Build swift-build run: cmake --build ${{ github.workspace }}/BinaryCache/swift-build From 5a3119ac51d51481b3b3e5a0350d2d4c516e6140 Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Sat, 30 Aug 2025 08:42:22 -0700 Subject: [PATCH 23/24] Do not use sdkroot in config task --- .github/workflows/swift-toolchain.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 4f3e8e535..837b0e537 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3973,8 +3973,12 @@ jobs: @{ 'BUILD_SHARED_LIBS' = "NO"; 'CMAKE_STATIC_LIBRARY_PREFIX_Swift' = "lib"; - 'CMAKE_C_FLAGS' = @("-I${env:SDKROOT}/usr/include -I${env:SDKROOT}/usr/include/Block"); - 'CMAKE_CXX_FLAGS' = @("-I${env:SDKROOT}/usr/include -I${env:SDKROOT}/usr/include/Block"); + 'CMAKE_C_FLAGS' = @( + "-I${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk/usr/include", + "-I${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk/usr/include/Block"); + 'CMAKE_CXX_FLAGS' = @( + "-I${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk/usr/include", + "-I${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk/usr/include/Block"); 'LMDB_DIR' = "${{ github.workspace }}/BinaryCache/swift-lmdb/cmake/modules"; } - name: Build indexstore-db From 2502d5d8e85a663ec021b9b6a0ccf35574faa37f Mon Sep 17 00:00:00 2001 From: Mohamed Hegazy Date: Sat, 30 Aug 2025 19:40:30 -0700 Subject: [PATCH 24/24] Remove andorid config --- .github/workflows/swift-toolchain.yml | 34 --------------------------- 1 file changed, 34 deletions(-) diff --git a/.github/workflows/swift-toolchain.yml b/.github/workflows/swift-toolchain.yml index 837b0e537..0d13b5783 100644 --- a/.github/workflows/swift-toolchain.yml +++ b/.github/workflows/swift-toolchain.yml @@ -3536,8 +3536,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-argument-parser bin-dir: ${{ github.workspace }}/BinaryCache/swift-argument-parser install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("Swift")' cmake-defines: | @@ -3563,8 +3561,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-collections bin-dir: ${{ github.workspace }}/BinaryCache/swift-collections install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: | @@ -3588,8 +3584,6 @@ jobs: arch: ${{ matrix.arch }} src-dir: ${{ github.workspace }}/SourceCache/swift-asn1 bin-dir: ${{ github.workspace }}/BinaryCache/swift-asn1 - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("Swift")' cmake-defines: | @@ -3614,8 +3608,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-crypto bin-dir: ${{ github.workspace }}/BinaryCache/swift-crypto install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("ASM", "C", "CXX", "Swift")' cmake-defines: | @@ -3641,8 +3633,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-llbuild bin-dir: ${{ github.workspace }}/BinaryCache/swift-llbuild install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("CXX", "Swift")' cmake-defines: | @@ -3669,8 +3659,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-system bin-dir: ${{ github.workspace }}/BinaryCache/swift-system install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: | @@ -3695,8 +3683,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-subprocess bin-dir: ${{ github.workspace }}/BinaryCache/swift-subprocess install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: | @@ -3721,8 +3707,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-tools-support-core bin-dir: ${{ github.workspace }}/BinaryCache/swift-tools-support-core install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: | @@ -3749,8 +3733,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-driver bin-dir: ${{ github.workspace }}/BinaryCache/swift-driver install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "CXX", "Swift")' cmake-defines: | @@ -3780,8 +3762,6 @@ jobs: arch: ${{ matrix.arch }} src-dir: ${{ github.workspace }}/SourceCache/swift-certificates bin-dir: ${{ github.workspace }}/BinaryCache/swift-certificates - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("Swift")' cmake-defines: | @@ -3808,8 +3788,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-build bin-dir: ${{ github.workspace }}/BinaryCache/swift-build install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "CXX", "Swift")' cmake-defines: | @@ -3848,8 +3826,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-package-manager bin-dir: ${{ github.workspace }}/BinaryCache/swift-package-manager install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: | @@ -3888,8 +3864,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-markdown bin-dir: ${{ github.workspace }}/BinaryCache/swift-markdown install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: | @@ -3916,8 +3890,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/swift-format bin-dir: ${{ github.workspace }}/BinaryCache/swift-format install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk msvc-compilers: '@("C")' built-compilers: '@("Swift")' @@ -3945,8 +3917,6 @@ jobs: arch: ${{ matrix.arch }} src-dir: ${{ github.workspace }}/SourceCache/swift-lmdb bin-dir: ${{ github.workspace }}/BinaryCache/swift-lmdb - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk msvc-compilers: '@("C")' - name: Build swift-lmdb @@ -3965,8 +3935,6 @@ jobs: arch: ${{ matrix.arch }} src-dir: ${{ github.workspace }}/SourceCache/indexstore-db bin-dir: ${{ github.workspace }}/BinaryCache/indexstore-db - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "CXX", "Swift")' cmake-defines: | @@ -3998,8 +3966,6 @@ jobs: src-dir: ${{ github.workspace }}/SourceCache/sourcekit-lsp bin-dir: ${{ github.workspace }}/BinaryCache/sourcekit-lsp install-dir: ${{ github.workspace }}/BuildRoot/Library/Developer/Toolchains/${{ inputs.swift_version }}+Asserts/usr - android-api-level: ${{ inputs.ANDROID_API_LEVEL }} - android-clang-version: ${{ inputs.ANDROID_CLANG_VERSION }} swift-sdk-path: ${{ github.workspace }}/BinaryCache/Library/Developer/Platforms/${{ matrix.os }}.platform/Developer/SDKs/${{ matrix.os }}.sdk built-compilers: '@("C", "Swift")' cmake-defines: |