You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
1.1 KiB

// swift-tools-version: 5.9
import PackageDescription
let package = Package(
name: "ble_service",
platforms: [.iOS("16.0")],
products: [
.library(name: "ble-service", targets: ["ble_service"])
],
dependencies: [
],
targets: [
.target(
name: "ble_service",
dependencies: [
"opus"
// 注:JLAudioUnitKit 已移除 —— ble_service 整体在向 device_jieli
// 迁移,PCM→OPUS 编码路径砍掉以解开 SPM "Multiple commands produce
// JLAudioUnitKit.framework" 冲突(device_jieli 已经 vendor 同名 framework)。
// 详见 Sources/ble_service/SwiftOpusAudioProcessor.swift 顶部注释。
],
path: "Sources/ble_service",
linkerSettings: [
.linkedFramework("AVFoundation"),
.linkedFramework("AudioToolbox"),
.linkedFramework("CoreBluetooth")
]
),
// 本地opus框架作为二进制目标(使用xcframework格式)
.binaryTarget(
name: "opus", // 改为与 xcframework 内部模块名称一致
path: "opus.xcframework"
)
]
)