Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ jobs:
name: Test
uses: swiftlang/github-workflows/.github/workflows/swift_package_test.yml@main
with:
linux_os_versions: '["amazonlinux2", "bookworm", "noble", "jammy", "rhel-ubi9"]'
linux_build_command: "swift build"
linux_exclude_swift_versions: '[{"swift_version": "5.8"}, {"swift_version": "5.9"}, {"swift_version": "5.10"}]'
windows_build_command: "Invoke-Program swift build"
Expand All @@ -22,6 +23,7 @@ jobs:
enable_ios_checks: true
enable_linux_static_sdk_build: true
enable_wasm_sdk_build: true
enable_embedded_wasm_sdk_build: true
enable_android_sdk_build: true

soundness:
Expand Down
21 changes: 15 additions & 6 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,27 @@ let package = Package(
.linkedLibrary("wasi-emulated-signal", .when(platforms: [.wasi])),
.linkedLibrary("wasi-emulated-process-clocks", .when(platforms: [.wasi])),
.linkedLibrary("wasi-emulated-getpid", .when(platforms: [.wasi])),
.linkedLibrary("dl", .when(platforms: [.linux])),
.linkedLibrary("m", .when(platforms: [.linux, .android])),
.linkedLibrary("pthread", .when(platforms: [.custom("freebsd")])),
.linkedLibrary("pthread", .when(platforms: [.linux, .custom("freebsd")])),
]
),
.target(
name: "SwiftToolchainCSQLite",
path: "Sources/CSQLite",
publicHeadersPath: "include",
linkerSettings: [
// Needed for swift_addNewDSOImage
.linkedLibrary("swiftCore", .when(platforms: [.windows, .wasi]))
]
publicHeadersPath: "include"
),
]
)

// Workaround for: undefined symbol: swift_addNewDSOImage
// (this should be resolved by Swift Build becoming the default build system)
if Context.environment["GITHUB_JOB"] != "embedded-wasm-sdk-build" {
for target in package.targets {
if target.name == "SwiftToolchainCSQLite" {
target.linkerSettings = [
.linkedLibrary("swiftCore", .when(platforms: [.windows, .wasi]))
]
}
}
}
Loading