diff --git a/.github/scripts/prebuild.sh b/.github/scripts/prebuild.sh new file mode 100755 index 000000000..9caba5565 --- /dev/null +++ b/.github/scripts/prebuild.sh @@ -0,0 +1,43 @@ +#!/bin/bash +##===----------------------------------------------------------------------===## +## +## This source file is part of the Swift open source project +## +## Copyright (c) 2025 Apple Inc. and the Swift project authors +## Licensed under Apache License v2.0 with Runtime Library Exception +## +## See http://swift.org/LICENSE.txt for license information +## See http://swift.org/CONTRIBUTORS.txt for the list of Swift project authors +## +##===----------------------------------------------------------------------===## + +set -e + +if command -v apt-get >/dev/null 2>&1 ; then # bookworm, noble, jammy + export DEBIAN_FRONTEND=noninteractive + + apt-get update -y + + # Build dependencies + apt-get install -y libsqlite3-dev libncurses-dev + + # Debug symbols + apt-get install -y libc6-dbg +elif command -v dnf >/dev/null 2>&1 ; then # rhel-ubi9 + dnf update -y + + # Build dependencies + dnf install -y sqlite-devel ncurses-devel + + # Debug symbols + dnf debuginfo-install -y glibc +elif command -v yum >/dev/null 2>&1 ; then # amazonlinux2 + yum update -y + + # Build dependencies + yum install -y sqlite-devel ncurses-devel + + # Debug symbols + yum install -y yum-utils + debuginfo-install -y glibc +fi diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index d1b882e8b..8f0799ef2 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -17,11 +17,10 @@ jobs: uses: swiftlang/github-workflows/.github/workflows/swift_package_test.yml@main with: linux_os_versions: '["jammy"]' + linux_pre_build_command: ./.github/scripts/prebuild.sh linux_swift_versions: '["nightly-main", "nightly-6.2"]' windows_swift_versions: '["nightly-main"]' windows_build_command: 'Invoke-Program swift test' - enable_linux_static_sdk_build: true - linux_static_sdk_build_command: SWIFTBUILD_STATIC_LINK=1 LLBUILD_STATIC_LINK=1 swift build enable_macos_checks: true macos_xcode_versions: "[\"26.0\"]" macos_build_command: swift test @@ -33,3 +32,7 @@ jobs: license_header_check_project_name: "Swift" api_breakage_check_enabled: false format_check_enabled: false + unacceptable_language_check_enabled: false + license_header_check_enabled: false + python_lint_check_enabled: false + yamllint_check_enabled: false diff --git a/Package.resolved b/Package.resolved index 921f0a2ad..659f77734 100644 --- a/Package.resolved +++ b/Package.resolved @@ -5,8 +5,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/apple/swift-argument-parser.git", "state" : { - "revision" : "011f0c765fb46d9cac61bca19be0527e99c98c8b", - "version" : "1.5.1" + "revision" : "cdd0ef3755280949551dc26dee5de9ddeda89f54", + "version" : "1.6.2" } }, { @@ -15,7 +15,7 @@ "location" : "https://github.com/swiftlang/swift-llbuild.git", "state" : { "branch" : "main", - "revision" : "f3b964914e4d941b83b566cae5746e995567d79d" + "revision" : "e38525ae3519021f014ad91e7bf86e7ae86044f5" } }, { @@ -23,8 +23,8 @@ "kind" : "remoteSourceControl", "location" : "https://github.com/swiftlang/swift-toolchain-sqlite", "state" : { - "revision" : "b626d3002773b1a1304166643e7f118f724b2132", - "version" : "1.0.4" + "revision" : "b45b80b943e88db3cb8ddea798fa3fa9912375ff", + "version" : "1.0.7" } }, { @@ -33,7 +33,7 @@ "location" : "https://github.com/swiftlang/swift-tools-support-core.git", "state" : { "branch" : "main", - "revision" : "f9b401016b70c6b8409e5c97e74d97513d1a8d02" + "revision" : "c3c31067a47b15b085d165f4cf7ef8aa8802d6e8" } } ], diff --git a/Package.swift b/Package.swift index b8ef72545..87c4ac315 100644 --- a/Package.swift +++ b/Package.swift @@ -139,7 +139,10 @@ let package = Package( // Do not enforce checks for LLVM's ABI-breaking build settings. // makeOptions runtime uses some header-only code from LLVM's ADT classes, // but we do not want to link libSupport into the executable. - cxxSettings: [.unsafeFlags(["-DLLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING=1"])]), + cxxSettings: [.unsafeFlags(["-DLLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING=1"])], + linkerSettings: [ + .linkedLibrary("swiftCore", .when(platforms: [.windows])), // for swift_addNewDSOImage + ]), ], cxxLanguageStandard: .cxx17 )