33import PackageDescription
44import class Foundation. ProcessInfo
55
6- var dependencies : [ Target . Dependency ] = {
6+ let packages : [ Package . Dependency ] = {
7+ var dependencies : [ Package . Dependency ] = [
8+ . package ( url: " https://github.com/apple/swift-collections.git " , from: " 1.0.0 " ) ,
9+ . package ( url: " https://github.com/apple/swift-async-algorithms " , from: " 0.1.0 " ) ,
10+ ]
11+
12+ if ProcessInfo . processInfo. environment [ " ASYNCOBJECTS_ENABLE_DEV " ] != nil {
13+ dependencies. append ( contentsOf: [
14+ . package ( url: " https://github.com/apple/swift-docc-plugin " , from: " 1.0.0 " ) ,
15+ . package ( url: " https://github.com/apple/swift-format " , from: " 0.50700.0 " ) ,
16+ ] )
17+ }
18+
19+ if ProcessInfo . processInfo. environment [ " ASYNCOBJECTS_ENABLE_LOGGING_LEVEL " ] != nil {
20+ dependencies. append (
21+ . package ( url: " https://github.com/apple/swift-log.git " , from: " 1.0.0 " )
22+ )
23+ }
24+
25+ return dependencies
26+ } ( )
27+
28+ let dependencies : [ Target . Dependency ] = {
729 var dependencies : [ Target . Dependency ] = [
830 . product( name: " OrderedCollections " , package : " swift-collections " ) ,
931 . product( name: " AsyncAlgorithms " , package : " swift-async-algorithms " ) ,
@@ -16,7 +38,7 @@ var dependencies: [Target.Dependency] = {
1638 return dependencies
1739} ( )
1840
19- var settings : [ SwiftSetting ] = {
41+ let settings : [ SwiftSetting ] = {
2042 var settings : [ SwiftSetting ] = [ ]
2143
2244 if ProcessInfo . processInfo. environment [ " SWIFTCI_CONCURRENCY_CHECKS " ] != nil {
@@ -26,7 +48,7 @@ var settings: [SwiftSetting] = {
2648 " -warn-concurrency " ,
2749 " -enable-actor-data-race-checks " ,
2850 " -require-explicit-sendable " ,
29- " -strict-concurrency=complete "
51+ // "-strict-concurrency=complete"
3052 ] )
3153 )
3254 }
@@ -63,13 +85,7 @@ let package = Package(
6385 products: [
6486 . library( name: " AsyncObjects " , targets: [ " AsyncObjects " ] ) ,
6587 ] ,
66- dependencies: [
67- . package ( url: " https://github.com/apple/swift-collections.git " , from: " 1.0.0 " ) ,
68- . package ( url: " https://github.com/apple/swift-async-algorithms " , from: " 0.1.0 " ) ,
69- . package ( url: " https://github.com/apple/swift-docc-plugin " , from: " 1.0.0 " ) ,
70- . package ( url: " https://github.com/apple/swift-format " , from: " 0.50700.0 " ) ,
71- . package ( url: " https://github.com/apple/swift-log.git " , from: " 1.0.0 " ) ,
72- ] ,
88+ dependencies: packages,
7389 targets: [
7490 . target( name: " AsyncObjects " , dependencies: dependencies, swiftSettings: settings) ,
7591 . testTarget( name: " AsyncObjectsTests " , dependencies: [ " AsyncObjects " ] ) ,
0 commit comments