-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathPackage.swift
More file actions
46 lines (37 loc) · 1.09 KB
/
Package.swift
File metadata and controls
46 lines (37 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
// swift-tools-version:5.5
import PackageDescription
#if arch(x86_64)
let macOS = SupportedPlatform.macOS(.v10_10)
let macCatalyst = SupportedPlatform.macCatalyst(.v13)
#else
let macOS = SupportedPlatform.macOS(.v11)
let macCatalyst = SupportedPlatform.macCatalyst(.v14)
#endif
#if (os(macOS) || targetEnvironment(macCatalyst)) && arch(x86_64)
// We still need Half
let halfTarget: [Target.Dependency] = ["Half"]
#else
let halfTarget: [Target.Dependency] = []
#endif
let halfPackage: [Package.Dependency] = [
.package(url: "https://github.com/SomeRandomiOSDev/Half", from: "1.3.1")
]
let package = Package(
name: "CBORCoding",
platforms: [
.iOS(.v14),
macOS,
.tvOS(.v14),
.watchOS(.v7),
macCatalyst
],
products: [
.library(name: "CBORCoding", targets: ["CBORCoding"])
],
dependencies: halfPackage,
targets: [
.target(name: "CBORCoding", dependencies: halfTarget),
.testTarget(name: "CBORCodingTests", dependencies: ["CBORCoding"] + halfTarget)
],
swiftLanguageVersions: [.version("4.2"), .version("5")]
)