Skip to content

Commit 4273db8

Browse files
committed
Fix compilation on Linux
1 parent fcc6077 commit 4273db8

9 files changed

Lines changed: 32 additions & 25 deletions

File tree

.github/workflows/build.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,9 @@ jobs:
8282
run: |
8383
sudo apt-get update -qq
8484
sudo apt-get install -y libsqlite3-dev
85-
- name: Test
85+
- name: Test (default trait)
86+
run: swift test
87+
- name: Test (SwiftToolchainCSQLite)
8688
run: swift test --traits SwiftToolchainCSQLite
8789
- name: "Run tests (SPM integration test)"
8890
env:

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
0.15.6 (28-01-2026), [diff][diff-0.15.6]
2+
========================================
3+
* Revert trait changes for Linux
4+
15
0.15.5 (22-01-2026), [diff][diff-0.15.5]
26
========================================
37
* Support more package traits ([#1341][]), including FTS5 ([#1343][])
@@ -190,6 +194,7 @@ For breaking changes, see [Upgrading.md](Documentation/Upgrading.md).
190194
[diff-0.15.3]: https://github.com/stephencelis/SQLite.swift/compare/0.15.2...0.15.3
191195
[diff-0.15.4]: https://github.com/stephencelis/SQLite.swift/compare/0.15.3...0.15.4
192196
[diff-0.15.5]: https://github.com/stephencelis/SQLite.swift/compare/0.15.4...0.15.5
197+
[diff-0.15.6]: https://github.com/stephencelis/SQLite.swift/compare/0.15.5...0.15.6
193198

194199
[#30]: https://github.com/stephencelis/SQLite.swift/issues/30
195200
[#142]: https://github.com/stephencelis/SQLite.swift/issues/142

Documentation/Index.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ process of downloading, compiling, and linking dependencies.
109109

110110
```swift
111111
dependencies: [
112-
.package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.5")
112+
.package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.6")
113113
]
114114
```
115115

@@ -127,7 +127,7 @@ SQLite.swift for different use cases.
127127
```swift
128128
dependencies: [
129129
.package(url: "https://github.com/stephencelis/SQLite.swift.git",
130-
from: "0.15.5",
130+
from: "0.15.6",
131131
traits: ["XXX"])
132132
]
133133
```
@@ -151,7 +151,7 @@ If you want to use [SQLCipher][] with SQLite.swift you can specify the `SQLCiphe
151151

152152
```swift
153153
depdencies: [
154-
.package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.5", traits: ["SQLCipher"])
154+
.package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.6", traits: ["SQLCipher"])
155155
]
156156
```
157157

@@ -181,7 +181,7 @@ let package = Package(
181181
dependencies: [
182182
.package(
183183
url: "https://github.com/stephencelis/SQLite.swift.git",
184-
from: "0.15.5",
184+
from: "0.15.6",
185185
traits: ["SQLCipher"])
186186
],
187187
targets: [
@@ -228,7 +228,7 @@ install SQLite.swift with Carthage:
228228
2. Update your Cartfile to include the following:
229229

230230
```ruby
231-
github "stephencelis/SQLite.swift" ~> 0.15.5
231+
github "stephencelis/SQLite.swift" ~> 0.15.6
232232
```
233233

234234
3. Run `carthage update` and [add the appropriate framework][Carthage Usage].
@@ -258,7 +258,7 @@ install SQLite.swift with Carthage:
258258
use_frameworks!
259259
260260
target 'YourAppTargetName' do
261-
pod 'SQLite.swift', '~> 0.15.5'
261+
pod 'SQLite.swift', '~> 0.15.6'
262262
end
263263
```
264264

@@ -272,7 +272,7 @@ with the OS you can require the `standalone` subspec:
272272

273273
```ruby
274274
target 'YourAppTargetName' do
275-
pod 'SQLite.swift/standalone', '~> 0.15.5'
275+
pod 'SQLite.swift/standalone', '~> 0.15.6'
276276
end
277277
```
278278

@@ -282,7 +282,7 @@ dependency to sqlite3 or one of its subspecs:
282282

283283
```ruby
284284
target 'YourAppTargetName' do
285-
pod 'SQLite.swift/standalone', '~> 0.15.5'
285+
pod 'SQLite.swift/standalone', '~> 0.15.6'
286286
pod 'sqlite3/fts5', '= 3.15.0' # SQLite 3.15.0 with FTS5 enabled
287287
end
288288
```

Documentation/Linux.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ embed SQLite:
1313
```swift
1414
dependencies: [
1515
.package(url: "https://github.com/stephencelis/SQLite.swift.git",
16-
from: "0.15.5",
16+
from: "0.15.6",
1717
traits: ["SwiftToolchainCSQLite"])
1818
]
1919
```

Package.swift

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,13 @@ let testTarget: Target = .testTarget(
2929
resources: [.copy("Resources")]
3030
)
3131

32+
let defaultTraits: Set<String>
33+
#if os(Linux)
34+
defaultTraits = ["SwiftToolchainCSQLite"]
35+
#else
36+
defaultTraits = ["SystemSQLite"]
37+
#endif
38+
3239
let package = Package(
3340
name: "SQLite.swift",
3441
platforms: [
@@ -56,7 +63,7 @@ let package = Package(
5663
description: "Enables SQLCipher encryption when a key is supplied to Connection"),
5764
.trait(name: "FTS5",
5865
description: "Enables FTS5 in the embedded SQLite (only supported by SQLiteSwiftCSQLite)"),
59-
.default(enabledTraits: ["SystemSQLite"])
66+
.default(enabledTraits: defaultTraits)
6067
],
6168
dependencies: [
6269
.package(url: "https://github.com/swiftlang/swift-toolchain-sqlite", from: "1.0.7"),

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ Swift code.
131131

132132
```swift
133133
dependencies: [
134-
.package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.5")
134+
.package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.6")
135135
]
136136
```
137137

@@ -155,7 +155,7 @@ install SQLite.swift with Carthage:
155155
2. Update your Cartfile to include the following:
156156

157157
```ruby
158-
github "stephencelis/SQLite.swift" ~> 0.15.5
158+
github "stephencelis/SQLite.swift" ~> 0.15.6
159159
```
160160

161161
3. Run `carthage update` and

SQLite.swift.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = "SQLite.swift"
3-
s.version = "0.15.5"
3+
s.version = "0.15.6"
44
s.summary = "A type-safe, Swift-language layer over SQLite3."
55

66
s.description = <<-DESC

SQLite.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1772,7 +1772,7 @@
17721772
GCC_WARN_UNUSED_VARIABLE = YES;
17731773
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
17741774
MACOSX_DEPLOYMENT_TARGET = 10.13;
1775-
MARKETING_VERSION = 0.15.5;
1775+
MARKETING_VERSION = 0.15.6;
17761776
MTL_ENABLE_DEBUG_INFO = YES;
17771777
ONLY_ACTIVE_ARCH = YES;
17781778
PRODUCT_NAME = "";
@@ -1832,7 +1832,7 @@
18321832
GCC_WARN_UNUSED_VARIABLE = YES;
18331833
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
18341834
MACOSX_DEPLOYMENT_TARGET = 10.13;
1835-
MARKETING_VERSION = 0.15.5;
1835+
MARKETING_VERSION = 0.15.6;
18361836
MTL_ENABLE_DEBUG_INFO = NO;
18371837
PRODUCT_NAME = "";
18381838
SDKROOT = iphoneos;

Tests/SPM/Package.swift

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,6 @@
33

44
import PackageDescription
55

6-
let traits: Set<Package.Dependency.Trait>
7-
#if os(Linux)
8-
traits = ["SwiftToolchainCSQLite"]
9-
#else
10-
traits = [.defaults]
11-
#endif
12-
136
let package = Package(
147
name: "test",
158
platforms: [
@@ -20,9 +13,9 @@ let package = Package(
2013
],
2114
dependencies: [
2215
// for testing from same repository
23-
.package(path: "../..", traits: traits)
16+
.package(path: "../..")
2417
// normally this would be:
25-
// .package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.5")
18+
// .package(url: "https://github.com/stephencelis/SQLite.swift.git", from: "0.15.6")
2619
],
2720
targets: [
2821
.executableTarget(name: "test", dependencies: [.product(name: "SQLite", package: "SQLite.swift")])

0 commit comments

Comments
 (0)