@@ -46,8 +46,7 @@ let package = Package(
46
46
] ,
47
47
dependencies: [
48
48
. package ( url: " https://github.com/apple/swift-nio.git " , from: " 2.55.0 " ) ,
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 " ) ,
49
+ . package ( url: " https://github.com/swift-server/swift-service-lifecycle.git " , from: " 2.0.0-beta.1 " ) ,
51
50
. package ( url: " https://github.com/apple/swift-log.git " , from: " 1.0.0 " ) ,
52
51
// The zstd Swift package produces warnings that we cannot resolve:
53
52
// https://github.com/facebook/zstd/issues/3328
@@ -57,7 +56,7 @@ let package = Package(
57
56
. target(
58
57
name: " Crdkafka " ,
59
58
dependencies: [
60
- . product ( name : " NIOSSL " , package : " swift-nio-ssl " ) ,
59
+ " COpenSSL " ,
61
60
. product( name: " libzstd " , package : " zstd " ) ,
62
61
] ,
63
62
exclude: rdkafkaExclude,
@@ -66,9 +65,7 @@ let package = Package(
66
65
cSettings: [
67
66
// dummy folder, because config.h is included as "../config.h" in librdkafka
68
67
. headerSearchPath( " ./custom/config/dummy " ) ,
69
- . headerSearchPath( " ./custom/include " ) ,
70
68
. headerSearchPath( " ./librdkafka/src " ) ,
71
- . define( " _GNU_SOURCE " , to: " 1 " ) , // Fix build error for Swift 5.9 onwards
72
69
] ,
73
70
linkerSettings: [
74
71
. linkedLibrary( " curl " ) ,
@@ -91,6 +88,14 @@ let package = Package(
91
88
" Kafka " ,
92
89
]
93
90
) ,
91
+ . systemLibrary(
92
+ name: " COpenSSL " ,
93
+ pkgConfig: " openssl " ,
94
+ providers: [
95
+ . brew( [ " libressl " ] ) ,
96
+ . apt( [ " libssl-dev " ] ) ,
97
+ ]
98
+ ) ,
94
99
. testTarget(
95
100
name: " KafkaTests " ,
96
101
dependencies: [ " Kafka " ]
0 commit comments