-
Notifications
You must be signed in to change notification settings - Fork 87
/
Package.swift
107 lines (101 loc) · 4.15 KB
/
Package.swift
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
// swift-tools-version: 5.6
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
let package = Package(
name: "SFBAudioEngine",
platforms: [
.macOS(.v11),
.iOS(.v15),
.tvOS(.v15),
],
products: [
.library(
name: "SFBAudioEngine",
targets: [
"CSFBAudioEngine",
"SFBAudioEngine",
]),
],
dependencies: [
.package(url: "https://github.com/sbooth/CXXAudioUtilities", from: "0.1.0"),
.package(url: "https://github.com/sbooth/AVFAudioExtensions", from: "0.1.0"),
// Standalone dependencies from source
.package(url: "https://github.com/sbooth/CDUMB", from: "2.0.3"),
.package(url: "https://github.com/sbooth/CXXMonkeysAudio", from: "10.71.0"),
.package(url: "https://github.com/sbooth/CXXTagLib", from: "2.0.1"),
// Standalone dependencies not easily packaged using SPM
.package(url: "https://github.com/sbooth/wavpack-binary-xcframework", from: "0.1.0"),
// Xiph ecosystem
.package(url: "https://github.com/sbooth/ogg-binary-xcframework", from: "0.1.1"),
// flac-binary-xcframework requires ogg-binary-xcframework
.package(url: "https://github.com/sbooth/flac-binary-xcframework", from: "0.1.2"),
// opus-binary-xcframework requires ogg-binary-xcframework
.package(url: "https://github.com/sbooth/opus-binary-xcframework", from: "0.2.1"),
// vorbis-binary-xcframework requires ogg-binary-xcframework
.package(url: "https://github.com/sbooth/vorbis-binary-xcframework", from: "0.1.1"),
// libspeex does not depend on libogg
.package(url: "https://github.com/sbooth/CSpeex", from: "1.2.1"),
// LGPL bits
.package(url: "https://github.com/sbooth/lame-binary-xcframework", from: "0.1.1"),
// Technically only the musepack *encoder* is LGPL'd but for now the decoder and encoder are packaged together
.package(url: "https://github.com/sbooth/mpc-binary-xcframework", from: "0.1.1"),
.package(url: "https://github.com/sbooth/mpg123-binary-xcframework", from: "0.2.1"),
// sndfile-binary-xcframework requires ogg-binary-xcframework, flac-binary-xcframework, opus-binary-xcframework, and vorbis-binary-xcframework
.package(url: "https://github.com/sbooth/sndfile-binary-xcframework", from: "0.1.1"),
.package(url: "https://github.com/sbooth/tta-cpp-binary-xcframework", from: "0.1.1"),
],
targets: [
.target(
name: "CSFBAudioEngine",
dependencies: [
.product(name: "CXXAudioUtilities", package: "CXXAudioUtilities"),
.product(name: "AVFAudioExtensions", package: "AVFAudioExtensions"),
// Standalone dependencies
.product(name: "dumb", package: "CDUMB"),
.product(name: "MAC", package: "CXXMonkeysAudio"),
.product(name: "taglib", package: "CXXTagLib"),
.product(name: "wavpack", package: "wavpack-binary-xcframework"),
// Xiph ecosystem
.product(name: "ogg", package: "ogg-binary-xcframework"),
.product(name: "FLAC", package: "flac-binary-xcframework"),
.product(name: "opus", package: "opus-binary-xcframework"),
.product(name: "vorbis", package: "vorbis-binary-xcframework"),
.product(name: "speex", package: "CSpeex"),
// LGPL bits
.product(name: "lame", package: "lame-binary-xcframework"),
.product(name: "mpc", package: "mpc-binary-xcframework"),
.product(name: "mpg123", package: "mpg123-binary-xcframework"),
.product(name: "sndfile", package: "sndfile-binary-xcframework"),
.product(name: "tta-cpp", package: "tta-cpp-binary-xcframework"),
],
cSettings: [
.headerSearchPath("include/SFBAudioEngine"),
.headerSearchPath("Input"),
.headerSearchPath("Decoders"),
.headerSearchPath("Player"),
.headerSearchPath("Output"),
.headerSearchPath("Encoders"),
.headerSearchPath("Utilities"),
.headerSearchPath("Analysis"),
.headerSearchPath("Metadata"),
.headerSearchPath("Conversion"),
],
linkerSettings: [
.linkedFramework("CoreServices"),
.linkedFramework("Foundation"),
.linkedFramework("AVFAudio"),
]),
.target(
name: "SFBAudioEngine",
dependencies: [
"CSFBAudioEngine",
]),
.testTarget(
name: "SFBAudioEngineTests",
dependencies: [
"SFBAudioEngine",
])
],
cLanguageStandard: .c11,
cxxLanguageStandard: .cxx17
)