@@ -46,7 +46,8 @@ let package = Package(
4646 ] ,
4747 dependencies: [
4848 . package ( url: " https://github.com/apple/swift-nio.git " , from: " 2.55.0 " ) ,
49- . package ( url: " https://github.com/swift-server/swift-service-lifecycle.git " , from: " 2.0.0-beta.1 " ) ,
49+ . package ( url: " https://github.com/apple/swift-nio-ssl " , from: " 2.25.0 " ) ,
50+ . package ( url: " https://github.com/swift-server/swift-service-lifecycle.git " , from: " 2.1.0 " ) ,
5051 . package ( url: " https://github.com/apple/swift-log.git " , from: " 1.0.0 " ) ,
5152 // The zstd Swift package produces warnings that we cannot resolve:
5253 // https://github.com/facebook/zstd/issues/3328
@@ -56,7 +57,7 @@ let package = Package(
5657 . target(
5758 name: " Crdkafka " ,
5859 dependencies: [
59- " COpenSSL " ,
60+ . product ( name : " NIOSSL " , package : " swift-nio-ssl " ) ,
6061 . product( name: " libzstd " , package : " zstd " ) ,
6162 ] ,
6263 exclude: rdkafkaExclude,
@@ -65,7 +66,9 @@ let package = Package(
6566 cSettings: [
6667 // dummy folder, because config.h is included as "../config.h" in librdkafka
6768 . headerSearchPath( " ./custom/config/dummy " ) ,
69+ . headerSearchPath( " ./custom/include " ) ,
6870 . headerSearchPath( " ./librdkafka/src " ) ,
71+ . define( " _GNU_SOURCE " , to: " 1 " ) , // Fix build error for Swift 5.9 onwards
6972 ] ,
7073 linkerSettings: [
7174 . linkedLibrary( " curl " ) ,
@@ -88,14 +91,6 @@ let package = Package(
8891 " Kafka " ,
8992 ]
9093 ) ,
91- . systemLibrary(
92- name: " COpenSSL " ,
93- pkgConfig: " openssl " ,
94- providers: [
95- . brew( [ " libressl " ] ) ,
96- . apt( [ " libssl-dev " ] ) ,
97- ]
98- ) ,
9994 . testTarget(
10095 name: " KafkaTests " ,
10196 dependencies: [ " Kafka " ]
0 commit comments