From 3e6cc891e1f566201cef813744240520a0186a0d Mon Sep 17 00:00:00 2001 From: David Jones Date: Fri, 27 Sep 2019 15:06:34 +0100 Subject: [PATCH 1/4] ci: Update to Swift 5.1 --- .swift-version | 2 +- .travis.yml | 18 ++++-------------- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/.swift-version b/.swift-version index a1ef0ca..a75b92f 100644 --- a/.swift-version +++ b/.swift-version @@ -1 +1 @@ -5.0.2 +5.1 diff --git a/.travis.yml b/.travis.yml index 478e699..3d39c46 100644 --- a/.travis.yml +++ b/.travis.yml @@ -31,24 +31,19 @@ matrix: sudo: required services: docker # Note: Ubuntu 16.04 - env: DOCKER_IMAGE=swift:5.0.2-xenial - - os: linux - dist: xenial - sudo: required - services: docker - # Note: Kitura-WebSocket-NIO requires zlib - env: DOCKER_IMAGE=swift:5.0.2-xenial KITURA_NIO=1 DOCKER_PACKAGES="libz-dev" + env: DOCKER_IMAGE=swift:5.0.3-xenial SWIFT_SNAPSHOT=5.0.3 - os: linux dist: xenial sudo: required services: docker # Note: Ubuntu 18.04 - env: DOCKER_IMAGE=swift:5.0.2 SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT + env: DOCKER_IMAGE=swift:5.1 - os: linux dist: xenial sudo: required services: docker - env: DOCKER_IMAGE=swift:5.0.2 SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT KITURA_NIO=1 DOCKER_PACKAGES="libz-dev" + # Note: Kitura-WebSocket-NIO requires zlib + env: DOCKER_IMAGE=swift:5.1 SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT KITURA_NIO=1 DOCKER_PACKAGES="libz-dev" - os: osx osx_image: xcode9.2 sudo: required @@ -65,14 +60,9 @@ matrix: osx_image: xcode10.2 sudo: required env: SWIFT_SNAPSHOT=5.0.1 JAZZY_ELIGIBLE=true - - os: osx - osx_image: xcode10.2 - sudo: required - env: SWIFT_SNAPSHOT=5.0.1 KITURA_NIO=1 - os: osx osx_image: xcode11 sudo: required - env: SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT - os: osx osx_image: xcode11 sudo: required From 65f61e8b845528e2cf8410180fd5b802760c2d5c Mon Sep 17 00:00:00 2001 From: David Jones Date: Fri, 4 Oct 2019 14:20:42 +0100 Subject: [PATCH 2/4] workaround: Use master branch of appid --- Package.swift | 7 ++++++- Package@swift-4.swift | 2 ++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Package.swift b/Package.swift index c7b8d8d..a42d846 100644 --- a/Package.swift +++ b/Package.swift @@ -44,8 +44,13 @@ var targetDependencies: [Target.Dependency] = [ "Kitura", "CloudEnvironment","Sw // targetDependencies.append("SwiftKueryPostgreSQL") // IBMCloudAppID requires OpenSSL that is not included on Mac by default. +// We only include the appid example on Linux to ensure Kitura-Sample works +// out-of-the-box on macOS. +// +// TODO: stop using master branch once Swift 5.1 support has been tagged. +// #if os(Linux) -dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", from: "5.1.0")) +dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", .branch("master"))) targetDependencies.append("IBMCloudAppID") #endif diff --git a/Package@swift-4.swift b/Package@swift-4.swift index df44c7c..9b055ce 100644 --- a/Package@swift-4.swift +++ b/Package@swift-4.swift @@ -44,6 +44,8 @@ var targetDependencies: [Target.Dependency] = [ "Kitura", "CloudEnvironment","Sw // targetDependencies.append("SwiftKueryPostgreSQL") // IBMCloudAppID requires OpenSSL that is not included on Mac by default. +// We only include the appid example on Linux to ensure Kitura-Sample works +// out-of-the-box on macOS. #if os(Linux) && swift(>=4.2) dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", from: "5.1.0")) targetDependencies.append("IBMCloudAppID") From a65cdecf86ae2a448219b75bc464ba7596b25832 Mon Sep 17 00:00:00 2001 From: David Jones Date: Mon, 7 Oct 2019 10:31:18 +0100 Subject: [PATCH 3/4] Disable dev snapshot due to compiler crash --- .travis.yml | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 3d39c46..306dee7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -43,7 +43,10 @@ matrix: sudo: required services: docker # Note: Kitura-WebSocket-NIO requires zlib - env: DOCKER_IMAGE=swift:5.1 SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT KITURA_NIO=1 DOCKER_PACKAGES="libz-dev" + env: DOCKER_IMAGE=swift:5.1 KITURA_NIO=1 DOCKER_PACKAGES="libz-dev" + # Disabling snapshot due to crash during compilation (2019-09-30-a) + # TODO: re-enable once dev snapshots are functioning + #SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT - os: osx osx_image: xcode9.2 sudo: required @@ -66,7 +69,10 @@ matrix: - os: osx osx_image: xcode11 sudo: required - env: SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT KITURA_NIO=1 + env: KITURA_NIO=1 + # Disabling snapshot due to crash during compilation (2019-09-30-a) + # TODO: re-enable once dev snapshots are functioning + #SWIFT_SNAPSHOT=$SWIFT_DEVELOPMENT_SNAPSHOT before_install: - git clone https://github.com/IBM-Swift/Package-Builder.git From 25358e604090230534c814ac672f9aa46cd1c84a Mon Sep 17 00:00:00 2001 From: David Jones Date: Thu, 10 Oct 2019 10:17:09 +0100 Subject: [PATCH 4/4] Update to appid 6.0.0 --- Package.swift | 5 +---- Package@swift-4.swift | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Package.swift b/Package.swift index a42d846..846f01b 100644 --- a/Package.swift +++ b/Package.swift @@ -46,11 +46,8 @@ var targetDependencies: [Target.Dependency] = [ "Kitura", "CloudEnvironment","Sw // IBMCloudAppID requires OpenSSL that is not included on Mac by default. // We only include the appid example on Linux to ensure Kitura-Sample works // out-of-the-box on macOS. -// -// TODO: stop using master branch once Swift 5.1 support has been tagged. -// #if os(Linux) -dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", .branch("master"))) +dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", from: "6.0.0")) targetDependencies.append("IBMCloudAppID") #endif diff --git a/Package@swift-4.swift b/Package@swift-4.swift index 9b055ce..a8aa487 100644 --- a/Package@swift-4.swift +++ b/Package@swift-4.swift @@ -47,7 +47,7 @@ var targetDependencies: [Target.Dependency] = [ "Kitura", "CloudEnvironment","Sw // We only include the appid example on Linux to ensure Kitura-Sample works // out-of-the-box on macOS. #if os(Linux) && swift(>=4.2) -dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", from: "5.1.0")) +dependencies.append(.package(url: "https://github.com/ibm-cloud-security/appid-serversdk-swift", from: "6.0.0")) targetDependencies.append("IBMCloudAppID") #endif