Skip to content

Xcode 12.5 #1053

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 18, 2021
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
3 changes: 0 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,4 @@ before_install:
- brew update
- brew outdated carthage || brew upgrade carthage
script:
# Workaround for Xcode 10.2/tvOS 9.1 bug (This is an outdated workaround; commenting out.)
# See https://stackoverflow.com/questions/55389080/xcode-10-2-failed-to-run-app-on-simulator-with-ios-10
# - sudo mkdir /Library/Developer/CoreSimulator/Profiles/Runtimes/tvOS\ 9.1.simruntime/Contents/Resources/RuntimeRoot/usr/lib/swift
- ./run-tests.sh
14 changes: 7 additions & 7 deletions SQLite.swift.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ Pod::Spec.new do |s|
s.swift_versions = ['4.2', '5']


ios_deployment_target = '8.0'
ios_deployment_target = '9.0'
tvos_deployment_target = '9.1'
osx_deployment_target = '10.10'
watchos_deployment_target = '2.2'
watchos_deployment_target = '3.0'

s.ios.deployment_target = ios_deployment_target
s.tvos.deployment_target = tvos_deployment_target
Expand All @@ -32,7 +32,7 @@ Pod::Spec.new do |s|
s.subspec 'standard' do |ss|
ss.source_files = 'Sources/{SQLite,SQLiteObjc}/**/*.{c,h,m,swift}'
ss.exclude_files = 'Sources/**/Cipher.swift'
ss.private_header_files = 'Sources/SQLiteObjc/*.h'
ss.private_header_files = 'Sources/SQLiteObjc/fts3_tokenizer.h'
ss.library = 'sqlite3'

ss.test_spec 'tests' do |test_spec|
Expand All @@ -47,7 +47,7 @@ Pod::Spec.new do |s|
s.subspec 'standalone' do |ss|
ss.source_files = 'Sources/{SQLite,SQLiteObjc}/**/*.{c,h,m,swift}'
ss.exclude_files = 'Sources/**/Cipher.swift'
ss.private_header_files = 'Sources/SQLiteObjc/*.h'
ss.private_header_files = 'Sources/SQLiteObjc/fts3_tokenizer.h'

ss.xcconfig = {
'OTHER_SWIFT_FLAGS' => '$(inherited) -DSQLITE_SWIFT_STANDALONE',
Expand All @@ -66,12 +66,12 @@ Pod::Spec.new do |s|

s.subspec 'SQLCipher' do |ss|
ss.source_files = 'Sources/{SQLite,SQLiteObjc}/**/*.{c,h,m,swift}'
ss.private_header_files = 'Sources/SQLiteObjc/*.h'
ss.private_header_files = 'Sources/SQLiteObjc/fts3_tokenizer.h'
ss.xcconfig = {
'OTHER_SWIFT_FLAGS' => '$(inherited) -DSQLITE_SWIFT_SQLCIPHER',
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SQLITE_HAS_CODEC=1'
'GCC_PREPROCESSOR_DEFINITIONS' => '$(inherited) SQLITE_HAS_CODEC=1 SQLITE_SWIFT_SQLCIPHER=1'
}
ss.dependency 'SQLCipher', '>= 3.4.0'
ss.dependency 'SQLCipher', '>= 4.0.0'

ss.test_spec 'tests' do |test_spec|
test_spec.resources = 'Tests/SQLiteTests/fixtures/*'
Expand Down
8 changes: 4 additions & 4 deletions SQLite.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1099,7 +1099,7 @@
SDKROOT = watchos;
SKIP_INSTALL = YES;
TARGETED_DEVICE_FAMILY = 4;
WATCHOS_DEPLOYMENT_TARGET = 2.2;
WATCHOS_DEPLOYMENT_TARGET = 3.0;
};
name = Debug;
};
Expand All @@ -1121,7 +1121,7 @@
SDKROOT = watchos;
SKIP_INSTALL = YES;
TARGETED_DEVICE_FAMILY = 4;
WATCHOS_DEPLOYMENT_TARGET = 2.2;
WATCHOS_DEPLOYMENT_TARGET = 3.0;
};
name = Release;
};
Expand Down Expand Up @@ -1174,7 +1174,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.3;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MACOSX_DEPLOYMENT_TARGET = 10.15;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
Expand Down Expand Up @@ -1231,7 +1231,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 12.3;
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
MACOSX_DEPLOYMENT_TARGET = 10.15;
MTL_ENABLE_DEBUG_INFO = NO;
PRODUCT_NAME = "";
Expand Down
2 changes: 2 additions & 0 deletions Sources/SQLiteObjc/SQLiteObjc.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
@import Foundation;
#if defined(SQLITE_SWIFT_STANDALONE)
@import sqlite3;
#elif defined(SQLITE_SWIFT_SQLCIPHER)
@import SQLCipher;
#else
@import SQLite3;
#endif
Expand Down
7 changes: 0 additions & 7 deletions Sources/SQLiteObjc/include/README.md

This file was deleted.

36 changes: 0 additions & 36 deletions Sources/SQLiteObjc/include/SQLiteObjc.h

This file was deleted.

2 changes: 1 addition & 1 deletion Tests/CocoaPods/Gemfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
source 'https://rubygems.org'

gem 'cocoapods', '~> 1.6.1'
gem 'cocoapods', '~> 1.10.1'
gem 'minitest'
83 changes: 50 additions & 33 deletions Tests/CocoaPods/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,77 +1,94 @@
GEM
remote: https://rubygems.org/
specs:
CFPropertyList (3.0.0)
activesupport (4.2.11)
i18n (~> 0.7)
CFPropertyList (3.0.3)
activesupport (5.2.6)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
thread_safe (~> 0.3, >= 0.3.4)
tzinfo (~> 1.1)
addressable (2.7.0)
public_suffix (>= 2.0.2, < 5.0)
algoliasearch (1.27.5)
httpclient (~> 2.8, >= 2.8.3)
json (>= 1.5.1)
atomos (0.1.3)
claide (1.0.2)
cocoapods (1.6.0.beta.2)
activesupport (>= 4.0.2, < 5)
claide (1.0.3)
cocoapods (1.10.1)
addressable (~> 2.6)
claide (>= 1.0.2, < 2.0)
cocoapods-core (= 1.6.0.beta.2)
cocoapods-deintegrate (>= 1.0.2, < 2.0)
cocoapods-downloader (>= 1.2.2, < 2.0)
cocoapods-core (= 1.10.1)
cocoapods-deintegrate (>= 1.0.3, < 2.0)
cocoapods-downloader (>= 1.4.0, < 2.0)
cocoapods-plugins (>= 1.0.0, < 2.0)
cocoapods-search (>= 1.0.0, < 2.0)
cocoapods-stats (>= 1.0.0, < 2.0)
cocoapods-trunk (>= 1.3.1, < 2.0)
cocoapods-trunk (>= 1.4.0, < 2.0)
cocoapods-try (>= 1.1.0, < 2.0)
colored2 (~> 3.1)
escape (~> 0.0.4)
fourflusher (~> 2.0.1)
fourflusher (>= 2.3.0, < 3.0)
gh_inspector (~> 1.0)
molinillo (~> 0.6.6)
nap (~> 1.0)
ruby-macho (~> 1.3, >= 1.3.1)
xcodeproj (>= 1.7.0, < 2.0)
cocoapods-core (1.6.0.beta.2)
activesupport (>= 4.0.2, < 6)
ruby-macho (~> 1.4)
xcodeproj (>= 1.19.0, < 2.0)
cocoapods-core (1.10.1)
activesupport (> 5.0, < 6)
addressable (~> 2.6)
algoliasearch (~> 1.0)
concurrent-ruby (~> 1.1)
fuzzy_match (~> 2.0.4)
nap (~> 1.0)
cocoapods-deintegrate (1.0.2)
cocoapods-downloader (1.2.2)
netrc (~> 0.11)
public_suffix
typhoeus (~> 1.0)
cocoapods-deintegrate (1.0.4)
cocoapods-downloader (1.4.0)
cocoapods-plugins (1.0.0)
nap
cocoapods-search (1.0.0)
cocoapods-stats (1.0.0)
cocoapods-trunk (1.3.1)
cocoapods-trunk (1.5.0)
nap (>= 0.8, < 2.0)
netrc (~> 0.11)
cocoapods-try (1.1.0)
cocoapods-try (1.2.0)
colored2 (3.1.2)
concurrent-ruby (1.1.4)
concurrent-ruby (1.1.9)
escape (0.0.4)
fourflusher (2.0.1)
ethon (0.14.0)
ffi (>= 1.15.0)
ffi (1.15.3)
fourflusher (2.3.1)
fuzzy_match (2.0.4)
gh_inspector (1.1.3)
i18n (0.9.5)
httpclient (2.8.3)
i18n (1.8.10)
concurrent-ruby (~> 1.0)
minitest (5.11.3)
json (2.5.1)
minitest (5.14.4)
molinillo (0.6.6)
nanaimo (0.2.6)
nanaimo (0.3.0)
nap (1.1.0)
netrc (0.11.0)
ruby-macho (1.3.1)
public_suffix (4.0.6)
ruby-macho (1.4.0)
thread_safe (0.3.6)
tzinfo (1.2.5)
typhoeus (1.4.0)
ethon (>= 0.9.0)
tzinfo (1.2.9)
thread_safe (~> 0.1)
xcodeproj (1.7.0)
xcodeproj (1.19.0)
CFPropertyList (>= 2.3.3, < 4.0)
atomos (~> 0.1.3)
claide (>= 1.0.2, < 2.0)
colored2 (~> 3.1)
nanaimo (~> 0.2.6)
nanaimo (~> 0.3.0)

PLATFORMS
ruby

DEPENDENCIES
cocoapods (~> 1.6.0beta2)
cocoapods (~> 1.10.1)
minitest

BUNDLED WITH
1.17.1
1.17.3
37 changes: 1 addition & 36 deletions Tests/CocoaPods/integration_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ def test_validate_project
private

def validator
@validator ||= CustomValidator.new(podspec, ['https://github.com/CocoaPods/Specs.git']).tap do |validator|
@validator ||= Pod::Validator.new(podspec, ['https://github.com/CocoaPods/Specs.git']).tap do |validator|
validator.config.verbose = true
validator.no_clean = true
validator.use_frameworks = true
Expand All @@ -32,39 +32,4 @@ def validator
def podspec
File.expand_path(File.dirname(__FILE__) + '/../../SQLite.swift.podspec')
end


class CustomValidator < Pod::Validator
def test_pod
# https://github.com/CocoaPods/CocoaPods/issues/7009
super unless consumer.platform_name == :watchos
end

def xcodebuild(action, scheme, configuration)
require 'fourflusher'
command = %W(#{action} -workspace #{File.join(validation_dir, 'App.xcworkspace')} -scheme #{scheme} -configuration #{configuration})
case consumer.platform_name
when :osx, :macos
command += %w(CODE_SIGN_IDENTITY=)
when :ios
command += %w(CODE_SIGN_IDENTITY=- -sdk iphonesimulator)
command += Fourflusher::SimControl.new.destination(nil, 'iOS', deployment_target)
when :watchos
command += %w(CODE_SIGN_IDENTITY=- -sdk watchsimulator)
command += Fourflusher::SimControl.new.destination(:oldest, 'watchOS', deployment_target)
when :tvos
command += %w(CODE_SIGN_IDENTITY=- -sdk appletvsimulator)
command += Fourflusher::SimControl.new.destination(:oldest, 'tvOS', deployment_target)
end

begin
_xcodebuild(command, true)
rescue => e
message = 'Returned an unsuccessful exit code.'
message += ' You can use `--verbose` for more information.' unless config.verbose?
error('xcodebuild', message)
e.message
end
end
end
end
6 changes: 4 additions & 2 deletions Tests/SQLiteTests/ConnectionTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,14 @@ class ConnectionTests : SQLiteTestCase {

func test_init_withURI_returnsURIConnection() {
let db = try! Connection(.uri("\(NSTemporaryDirectory())/SQLite.swift Tests.sqlite3"))
XCTAssertEqual("\(NSTemporaryDirectory())/SQLite.swift Tests.sqlite3", db.description)
let url = URL(fileURLWithPath: db.description)
XCTAssertEqual(url.lastPathComponent, "SQLite.swift Tests.sqlite3")
}

func test_init_withString_returnsURIConnection() {
let db = try! Connection("\(NSTemporaryDirectory())/SQLite.swift Tests.sqlite3")
XCTAssertEqual("\(NSTemporaryDirectory())/SQLite.swift Tests.sqlite3", db.description)
let url = URL(fileURLWithPath: db.description)
XCTAssertEqual(url.lastPathComponent, "SQLite.swift Tests.sqlite3")
}

func test_readonly_returnsFalseOnReadWriteConnections() {
Expand Down