From fcb037bdf0b27833980ac8836df1e65138e7bd26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gwendal=20Roue=CC=81?= Date: Sun, 21 Aug 2022 19:21:57 +0200 Subject: [PATCH] Swift 5.7 required: Bump deployment targets --- CHANGELOG.md | 5 +++++ Documentation/GRDB6MigrationGuide.md | 12 ++++++++++++ GRDB.swift.podspec | 6 +++--- GRDB/Record/EncodableRecord.swift | 2 +- Package.swift | 6 +++--- README.md | 9 +++++---- SQLiteCustom/GRDBDeploymentTarget.xcconfig | 6 +++--- Support/GRDBDeploymentTarget.xcconfig | 6 +++--- .../SQLCipher3/GRDBTests.xcodeproj/project.pbxproj | 4 ++-- Tests/CocoaPods/SQLCipher3/Podfile | 2 +- .../SQLCipher4/GRDBTests.xcodeproj/project.pbxproj | 4 ++-- Tests/CocoaPods/SQLCipher4/Podfile | 2 +- .../CustomSQLite.xcodeproj/project.pbxproj | 4 ++-- .../GRDBProfiling.xcodeproj/project.pbxproj | 4 ++-- .../SPM/PlainProject/Plain.xcodeproj/project.pbxproj | 4 ++-- 15 files changed, 47 insertions(+), 29 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 783f6a3ce..bef30f951 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -93,6 +93,11 @@ GRDB adheres to [Semantic Versioning](https://semver.org/), with one exception: --- +## 6.0.0 + +- **Breaking**: Swift 5.7+ and Xcode 14+ are required. +- **Breaking**: iOS 11.0+ / macOS 10.13+ / tvOS 11.0+ / watchOS 4.0+ are required. + ## 5.26.0 Released July 9, 2022 • [diff](https://github.com/groue/GRDB.swift/compare/v5.25.0...v5.26.0) diff --git a/Documentation/GRDB6MigrationGuide.md b/Documentation/GRDB6MigrationGuide.md index 836cdaa74..7df94ebe8 100644 --- a/Documentation/GRDB6MigrationGuide.md +++ b/Documentation/GRDB6MigrationGuide.md @@ -4,6 +4,7 @@ Migrating From GRDB 5 to GRDB 6 **This guide aims at helping you upgrading your applications from GRDB 5 to GRDB 6.** - [Preparing the Migration to GRDB 6](#preparing-the-migration-to-grdb-6) +- [New requirements](#new-requirements) ## Preparing the Migration to GRDB 6 @@ -11,3 +12,14 @@ Migrating From GRDB 5 to GRDB 6 If you haven't made it yet, upgrade to the [latest GRDB 5 release](https://github.com/groue/GRDB.swift/tags) first, and fix any deprecation warning prior to the GRDB 6 upgrade. You can then upgrade to GRDB 6. Due to the breaking changes, it is possible that your application code no longer compiles. Follow the fix-its that suggest simple syntactic changes. Other modifications that you need to apply are described below. + +## New requirements + +GRDB requirements have been bumped: + +- **Swift 5.7+** (was Swift 5.3+) +- **Xcode 14.0+** (was Xcode 12.0+) +- iOS 11.0+ (unchanged) +- **macOS 10.13+** (was macOS 10.10+) +- **tvOS 11.0+** (was tvOS 11.0+) +- **watchOS 4.0+** (was watchOS 2.0+) diff --git a/GRDB.swift.podspec b/GRDB.swift.podspec index e5112371e..6e664a7d3 100644 --- a/GRDB.swift.podspec +++ b/GRDB.swift.podspec @@ -11,9 +11,9 @@ Pod::Spec.new do |s| s.swift_versions = ['5.7'] s.ios.deployment_target = '11.0' - s.osx.deployment_target = '10.10' - s.watchos.deployment_target = '2.0' - s.tvos.deployment_target = '9.0' + s.osx.deployment_target = '10.13' + s.watchos.deployment_target = '4.0' + s.tvos.deployment_target = '11.0' s.default_subspec = 'standard' s.subspec 'standard' do |ss| diff --git a/GRDB/Record/EncodableRecord.swift b/GRDB/Record/EncodableRecord.swift index 1a02fe384..9a2c6a21b 100644 --- a/GRDB/Record/EncodableRecord.swift +++ b/GRDB/Record/EncodableRecord.swift @@ -67,7 +67,7 @@ public protocol EncodableRecord { /// - dataEncodingStrategy: .base64 /// - dateEncodingStrategy: .millisecondsSince1970 /// - nonConformingFloatEncodingStrategy: .throw - /// - outputFormatting: .sortedKeys (iOS 11.0+, macOS 10.13+, tvOS 11.0+, watchOS 4.0+) + /// - outputFormatting: .sortedKeys /// /// You can override those defaults: /// diff --git a/Package.swift b/Package.swift index 505b0f698..e003cb869 100644 --- a/Package.swift +++ b/Package.swift @@ -7,9 +7,9 @@ let package = Package( name: "GRDB", platforms: [ .iOS(.v11), - .macOS(.v10_10), - .tvOS(.v9), - .watchOS(.v2), + .macOS(.v10_13), + .tvOS(.v11), + .watchOS(.v4), ], products: [ .library(name: "GRDB", targets: ["GRDB"]), diff --git a/README.md b/README.md index 7c3cc6c1c..35be12298 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@

A toolkit for SQLite databases, with a focus on application development

- Swift 5.3 + Swift 5.7 Platforms License CI Status @@ -13,11 +13,12 @@ **Latest release**: July 9, 2022 • [version 5.26.0](https://github.com/groue/GRDB.swift/tree/v5.26.0) • [CHANGELOG](CHANGELOG.md) • [Migrating From GRDB 5 to GRDB 6](Documentation/GRDB6MigrationGuide.md) -**Requirements**: iOS 11.0+ / macOS 10.10+ / tvOS 9.0+ / watchOS 2.0+ • SQLite 3.8.5+ • Swift 5.3+ / Xcode 12+ +**Requirements**: iOS 11.0+ / macOS 10.13+ / tvOS 11.0+ / watchOS 4.0+ • SQLite 3.8.5+ • Swift 5.7+ / Xcode 14+ | Swift version | GRDB version | | -------------- | ----------------------------------------------------------- | -| **Swift 5.3+** | **v5.26.0** | +| **Swift 5.7+** | **v5.26.0** | +| Swift 5.3 | [v5.26.0](https://github.com/groue/GRDB.swift/tree/v5.26.0) | | Swift 5.2 | [v5.12.0](https://github.com/groue/GRDB.swift/tree/v5.12.0) | | Swift 5.1 | [v4.14.0](https://github.com/groue/GRDB.swift/tree/v4.14.0) | | Swift 5 | [v4.14.0](https://github.com/groue/GRDB.swift/tree/v4.14.0) | @@ -3126,7 +3127,7 @@ protocol EncodableRecord { } ``` -> :bulb: **Tip**: Make sure you set the JSONEncoder `sortedKeys` option, available from iOS 11.0+, macOS 10.13+, tvOS 9.0+ and watchOS 4.0+. This option makes sure that the JSON output is stable. This stability is required for [Record Comparison] to work as expected, and database observation tools such as [ValueObservation] to accurately recognize changed records. +> :bulb: **Tip**: Make sure you set the JSONEncoder `sortedKeys` option. This option makes sure that the JSON output is stable. This stability is required for [Record Comparison] to work as expected, and database observation tools such as [ValueObservation] to accurately recognize changed records. ### Column Names Coding Strategies diff --git a/SQLiteCustom/GRDBDeploymentTarget.xcconfig b/SQLiteCustom/GRDBDeploymentTarget.xcconfig index 28b7b90cc..904204125 100644 --- a/SQLiteCustom/GRDBDeploymentTarget.xcconfig +++ b/SQLiteCustom/GRDBDeploymentTarget.xcconfig @@ -1,4 +1,4 @@ IPHONEOS_DEPLOYMENT_TARGET = 11.0 -MACOSX_DEPLOYMENT_TARGET = 10.10 -TVOS_DEPLOYMENT_TARGET = 9.0 -WATCHOS_DEPLOYMENT_TARGET = 2.0 +MACOSX_DEPLOYMENT_TARGET = 10.13 +TVOS_DEPLOYMENT_TARGET = 11.0 +WATCHOS_DEPLOYMENT_TARGET = 4.0 diff --git a/Support/GRDBDeploymentTarget.xcconfig b/Support/GRDBDeploymentTarget.xcconfig index f074b7e79..a3458605c 100644 --- a/Support/GRDBDeploymentTarget.xcconfig +++ b/Support/GRDBDeploymentTarget.xcconfig @@ -1,7 +1,7 @@ IPHONEOS_DEPLOYMENT_TARGET = 11.0 -MACOSX_DEPLOYMENT_TARGET = 10.10 -TVOS_DEPLOYMENT_TARGET = 9.0 -WATCHOS_DEPLOYMENT_TARGET = 2.0 +MACOSX_DEPLOYMENT_TARGET = 10.13 +TVOS_DEPLOYMENT_TARGET = 11.0 +WATCHOS_DEPLOYMENT_TARGET = 4.0 //// Compile with all opt-in APIs //GCC_PREPROCESSOR_DEFINITIONS = $(inherited) GRDB_SQLITE_ENABLE_PREUPDATE_HOOK=1 diff --git a/Tests/CocoaPods/SQLCipher3/GRDBTests.xcodeproj/project.pbxproj b/Tests/CocoaPods/SQLCipher3/GRDBTests.xcodeproj/project.pbxproj index 239d10277..a731f80e8 100644 --- a/Tests/CocoaPods/SQLCipher3/GRDBTests.xcodeproj/project.pbxproj +++ b/Tests/CocoaPods/SQLCipher3/GRDBTests.xcodeproj/project.pbxproj @@ -1672,7 +1672,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; ONLY_ACTIVE_ARCH = YES; SWIFT_VERSION = 5.0; }; @@ -1706,7 +1706,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; SWIFT_VERSION = 5.0; }; name = Release; diff --git a/Tests/CocoaPods/SQLCipher3/Podfile b/Tests/CocoaPods/SQLCipher3/Podfile index 9d45a0d3e..c8066b3ae 100644 --- a/Tests/CocoaPods/SQLCipher3/Podfile +++ b/Tests/CocoaPods/SQLCipher3/Podfile @@ -1,4 +1,4 @@ -platform :macos, '10.10' +platform :macos, '10.13' use_frameworks! def common diff --git a/Tests/CocoaPods/SQLCipher4/GRDBTests.xcodeproj/project.pbxproj b/Tests/CocoaPods/SQLCipher4/GRDBTests.xcodeproj/project.pbxproj index dc6a20213..e5db016ea 100644 --- a/Tests/CocoaPods/SQLCipher4/GRDBTests.xcodeproj/project.pbxproj +++ b/Tests/CocoaPods/SQLCipher4/GRDBTests.xcodeproj/project.pbxproj @@ -1678,7 +1678,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; ONLY_ACTIVE_ARCH = YES; SWIFT_VERSION = 5.0; }; @@ -1712,7 +1712,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; SWIFT_VERSION = 5.0; }; name = Release; diff --git a/Tests/CocoaPods/SQLCipher4/Podfile b/Tests/CocoaPods/SQLCipher4/Podfile index d0124a874..d8cd6ce44 100644 --- a/Tests/CocoaPods/SQLCipher4/Podfile +++ b/Tests/CocoaPods/SQLCipher4/Podfile @@ -1,4 +1,4 @@ -platform :macos, '10.10' +platform :macos, '10.13' use_frameworks! def common diff --git a/Tests/CustomSQLite/CustomSQLite.xcodeproj/project.pbxproj b/Tests/CustomSQLite/CustomSQLite.xcodeproj/project.pbxproj index d74f142e8..4d0fd10cd 100644 --- a/Tests/CustomSQLite/CustomSQLite.xcodeproj/project.pbxproj +++ b/Tests/CustomSQLite/CustomSQLite.xcodeproj/project.pbxproj @@ -342,7 +342,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; @@ -397,7 +397,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; SDKROOT = macosx; diff --git a/Tests/Performance/GRDBProfiling/GRDBProfiling.xcodeproj/project.pbxproj b/Tests/Performance/GRDBProfiling/GRDBProfiling.xcodeproj/project.pbxproj index e8a1f3b3a..185eaeb97 100644 --- a/Tests/Performance/GRDBProfiling/GRDBProfiling.xcodeproj/project.pbxproj +++ b/Tests/Performance/GRDBProfiling/GRDBProfiling.xcodeproj/project.pbxproj @@ -363,7 +363,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = macosx; @@ -414,7 +414,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = macosx; SWIFT_VERSION = 5.0; diff --git a/Tests/SPM/PlainProject/Plain.xcodeproj/project.pbxproj b/Tests/SPM/PlainProject/Plain.xcodeproj/project.pbxproj index 74ef4a166..00bcf692e 100644 --- a/Tests/SPM/PlainProject/Plain.xcodeproj/project.pbxproj +++ b/Tests/SPM/PlainProject/Plain.xcodeproj/project.pbxproj @@ -187,7 +187,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.10; + MACOSX_DEPLOYMENT_TARGET = 10.13; MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; MTL_FAST_MATH = YES; ONLY_ACTIVE_ARCH = YES; @@ -241,7 +241,7 @@ GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; - MACOSX_DEPLOYMENT_TARGET = 10.14; + MACOSX_DEPLOYMENT_TARGET = 10.13; MTL_ENABLE_DEBUG_INFO = NO; MTL_FAST_MATH = YES; SDKROOT = macosx;