From 4607c9e68788230a646b35ccebd5176499bd333d Mon Sep 17 00:00:00 2001 From: "Jesse L. Zamora" Date: Tue, 2 Dec 2025 13:17:25 +0000 Subject: [PATCH 1/3] Add support for Debian Trixie distribution - Add specific gcc and icu versions to package list. --- .../PlatformModels/LinuxDistribution.swift | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Sources/SwiftSDKGenerator/PlatformModels/LinuxDistribution.swift b/Sources/SwiftSDKGenerator/PlatformModels/LinuxDistribution.swift index 9f9cd96..c82835b 100644 --- a/Sources/SwiftSDKGenerator/PlatformModels/LinuxDistribution.swift +++ b/Sources/SwiftSDKGenerator/PlatformModels/LinuxDistribution.swift @@ -93,11 +93,13 @@ public enum LinuxDistribution: Hashable, Sendable { public enum Debian: String, Sendable { case bullseye case bookworm + case trixie init(version: String) throws { switch version { case "11": self = .bullseye case "12": self = .bookworm + case "13": self = .trixie default: throw GeneratorError.unknownLinuxDistribution( name: LinuxDistribution.Name.debian.rawValue, @@ -110,6 +112,7 @@ public enum LinuxDistribution: Hashable, Sendable { switch self { case .bullseye: return "11" case .bookworm: return "12" + case .trixie: return "13" } } @@ -142,6 +145,13 @@ public enum LinuxDistribution: Hashable, Sendable { "libicu-dev", "libstdc++-12-dev", ] + case .trixie: + return commonPackages + [ + "libgcc-14-dev", + "libicu76", + "libicu-dev", + "libstdc++-14-dev", + ] } } } From b18b55a0f9dc6e270c94d6f9d6e93c4920c18137 Mon Sep 17 00:00:00 2001 From: "Jesse L. Zamora" Date: Tue, 2 Dec 2025 13:17:52 +0000 Subject: [PATCH 2/3] Add compat for debian 13 - can be used with ubuntu 24.04 toolchain --- .../PlatformModels/VersionsConfiguration.swift | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Sources/SwiftSDKGenerator/PlatformModels/VersionsConfiguration.swift b/Sources/SwiftSDKGenerator/PlatformModels/VersionsConfiguration.swift index 3459126..65586e9 100644 --- a/Sources/SwiftSDKGenerator/PlatformModels/VersionsConfiguration.swift +++ b/Sources/SwiftSDKGenerator/PlatformModels/VersionsConfiguration.swift @@ -50,6 +50,9 @@ public struct VersionsConfiguration: Sendable { } else if self.swiftVersion.hasPrefix("5.9") || self.swiftVersion == "5.10" { // Ubuntu 22.04 toolchain is binary compatible with Debian 12 return "ubuntu22.04" + } else if debian.version == "13" { + // Ubuntu 24.04 toolchain is binary compatible with Debian 13 + return "ubuntu24.04" } return "debian\(debian.version)" case let .rhel(rhel): From 6b2797e79bc4e1061ef8863282f2e71f81a9e760 Mon Sep 17 00:00:00 2001 From: "Jesse L. Zamora" Date: Thu, 4 Dec 2025 02:22:49 +0000 Subject: [PATCH 3/3] Add EndToEndTests for Debian Trixie --- .../EndToEndTests.swift | 72 ++++++++++++++++--- 1 file changed, 64 insertions(+), 8 deletions(-) diff --git a/Tests/SwiftSDKGeneratorTests/EndToEndTests.swift b/Tests/SwiftSDKGeneratorTests/EndToEndTests.swift index f15a9b3..3d4e64c 100644 --- a/Tests/SwiftSDKGeneratorTests/EndToEndTests.swift +++ b/Tests/SwiftSDKGeneratorTests/EndToEndTests.swift @@ -679,8 +679,22 @@ final class Swift510_DebianEndToEndTests: XCTestCase { ) } - // NOTE: Debian 11 containers do not exist for Swift, and the generator does not support - // generating this container for you automatically, so we do not test this scenario. + func testTrixieAarch64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("aarch64") + ) + } + + func testTrixieX86_64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("x86_64") + ) + } + + // NOTE: Debian 11 and 13 containers do not exist for Swift, and the generator does not + // support creating this container for you automatically, so we do not test this scenario. } final class Swift60_DebianEndToEndTests: XCTestCase { @@ -726,8 +740,22 @@ final class Swift60_DebianEndToEndTests: XCTestCase { ) } - // NOTE: Debian 11 containers do not exist for Swift, and the generator does not support - // generating this container for you automatically, so we do not test this scenario. + func testTrixieAarch64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("aarch64") + ) + } + + func testTrixieX86_64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("x86_64") + ) + } + + // NOTE: Debian 11 and 13 containers do not exist for Swift, and the generator does not + // support creating this container for you automatically, so we do not test this scenario. } final class Swift61_DebianEndToEndTests: XCTestCase { @@ -773,8 +801,22 @@ final class Swift61_DebianEndToEndTests: XCTestCase { ) } - // NOTE: Debian 11 containers do not exist for Swift, and the generator does not support - // generating this container for you automatically, so we do not test this scenario. + func testTrixieAarch64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("aarch64") + ) + } + + func testTrixieX86_64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("x86_64") + ) + } + + // NOTE: Debian 11 and 13 containers do not exist for Swift, and the generator does not + // support creating this container for you automatically, so we do not test this scenario. } final class Swift62_DebianEndToEndTests: XCTestCase { @@ -820,8 +862,22 @@ final class Swift62_DebianEndToEndTests: XCTestCase { ) } - // NOTE: Debian 11 containers do not exist for Swift, and the generator does not support - // generating this container for you automatically, so we do not test this scenario. + func testTrixieAarch64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("aarch64") + ) + } + + func testTrixieX86_64Direct() async throws { + try skipSlow() + try await buildTestcases( + config: config.withLinuxDistributionVersion("13").withArchitecture("x86_64") + ) + } + + // NOTE: Debian 11 and 13 containers do not exist for Swift, and the generator does not + // support creating this container for you automatically, so we do not test this scenario. } final class Swift59_RHELEndToEndTests: XCTestCase {