Skip to content

Commit 58bcfe8

Browse files
authored
Prefixed LiveKitWebRTC package & xcframework (livekit#339)
In addition to the ObjC symbol prefixing, this prefixes both package name and WebRTC.xcframework with `LiveKit`. I think @ _implementationOnly is not required any more, but it helps compiler to warn if any symbol is exported. Depends on https://github.com/livekit/webrtc-xcframework/releases/tag/114.5735.11
1 parent 21532fb commit 58bcfe8

File tree

65 files changed

+66
-66
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+66
-66
lines changed

Package.swift

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ let package = Package(
1717
],
1818
dependencies: [
1919
// LK-Prefixed Dynamic WebRTC XCFramework
20-
.package(name: "WebRTC", url: "https://github.com/livekit/webrtc-xcframework.git", .exact("114.5735.10")),
20+
.package(name: "LiveKitWebRTC", url: "https://github.com/livekit/webrtc-xcframework.git", .exact("114.5735.11")),
2121
.package(name: "SwiftProtobuf", url: "https://github.com/apple/swift-protobuf.git", .upToNextMajor(from: "1.25.2")),
2222
.package(url: "https://github.com/apple/swift-log.git", .upToNextMajor(from: "1.5.3")),
2323
.package(url: "https://github.com/apple/swift-docc-plugin", from: "1.3.0"),
@@ -28,7 +28,7 @@ let package = Package(
2828
name: "LiveKit",
2929
dependencies: [
3030
.target(name: "CHeaders"),
31-
"WebRTC",
31+
"LiveKitWebRTC",
3232
"SwiftProtobuf",
3333
.product(name: "Logging", package: "swift-log"),
3434
],

Sources/LiveKit/Broadcast/BroadcastScreenCapturer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
import UIKit
2323
#endif
2424

25-
@_implementationOnly import WebRTC
25+
@_implementationOnly import LiveKitWebRTC
2626

2727
class BroadcastScreenCapturer: BufferCapturer {
2828
static let kRTCScreensharingSocketFD = "rtc_SSFD"

Sources/LiveKit/Broadcast/SocketConnectionFrameReader.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import CoreImage
1818
import CoreVideo
1919
import Foundation
2020

21-
@_implementationOnly import WebRTC
21+
@_implementationOnly import LiveKitWebRTC
2222

2323
private class Message {
2424
// Initializing a CIContext object is costly, so we use a singleton instead

Sources/LiveKit/Core/DataChannelPairActor.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
actor DataChannelPairActor: NSObject, Loggable {
2222
// MARK: - Types

Sources/LiveKit/Core/Engine+SignalClientDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension Engine: SignalClientDelegate {
2222
func signalClient(_ signalClient: SignalClient, didUpdateConnectionState connectionState: ConnectionState, oldState: ConnectionState, disconnectError: LiveKitError?) async {

Sources/LiveKit/Core/Engine+TransportDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension RTCPeerConnectionState {
2222
var isConnected: Bool {

Sources/LiveKit/Core/Engine+WebRTC.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
private extension Array where Element: LKRTCVideoCodecInfo {
2222
func rewriteCodecsIfNeeded() -> [LKRTCVideoCodecInfo] {

Sources/LiveKit/Core/Engine.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import Foundation
2020
import Network
2121
#endif
2222

23-
@_implementationOnly import WebRTC
23+
@_implementationOnly import LiveKitWebRTC
2424

2525
class Engine: Loggable {
2626
// MARK: - Public

Sources/LiveKit/Core/Room+EngineDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension Room: EngineDelegate {
2222
func engine(_: Engine, didMutateState state: Engine.State, oldState: Engine.State) async {

Sources/LiveKit/Core/Room+SignalClientDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension Room: SignalClientDelegate {
2222
func signalClient(_: SignalClient, didReceiveLeave canReconnect: Bool, reason: Livekit_DisconnectReason) async {

Sources/LiveKit/Core/SignalClient.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
actor SignalClient: Loggable {
2222
// MARK: - Types

Sources/LiveKit/Core/Transport.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import Foundation
1818
import SwiftProtobuf
1919

20-
@_implementationOnly import WebRTC
20+
@_implementationOnly import LiveKitWebRTC
2121

2222
actor Transport: NSObject, Loggable {
2323
// MARK: - Types

Sources/LiveKit/E2EE/E2EEManager.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public class E2EEManager: NSObject, ObservableObject, Loggable {

Sources/LiveKit/E2EE/KeyProvider.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
public let defaultRatchetSalt: String = "LKFrameEncryptionKey"
2222
public let defaultMagicBytes: String = "LK-ROCKS"

Sources/LiveKit/E2EE/State.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public enum E2EEState: Int {

Sources/LiveKit/Errors.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
public enum LiveKitErrorType: Int {
2222
case unknown = 0

Sources/LiveKit/Extensions/CustomStringConvertible.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension TrackSettings: CustomStringConvertible {
2222
public var description: String {

Sources/LiveKit/Extensions/LKRTCRtpSender.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension LKRTCRtpSender: Loggable {
2222
// ...

Sources/LiveKit/Extensions/RTCConfiguration.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension LKRTCConfiguration {
2222
static func liveKitDefault() -> LKRTCConfiguration {

Sources/LiveKit/Extensions/RTCDataChannel+Util.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension LKRTCDataChannel {
2222
enum labels {

Sources/LiveKit/Extensions/RTCI420Buffer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension LKRTCI420Buffer {
2222
func toPixelBuffer() -> CVPixelBuffer? {

Sources/LiveKit/Extensions/RTCMediaConstraints.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension LKRTCMediaConstraints {
2222
// static let defaultOfferConstraints = RTCMediaConstraints(

Sources/LiveKit/Extensions/RTCRtpTransceiver.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
extension LKRTCRtpTransceiver: Loggable {
2222
/// Attempts to set preferred video codec.

Sources/LiveKit/Extensions/RTCVideoCapturerDelegate+Buffer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import Foundation
2020
import ReplayKit
2121
#endif
2222

23-
@_implementationOnly import WebRTC
23+
@_implementationOnly import LiveKitWebRTC
2424

2525
extension FixedWidthInteger {
2626
func roundUp(toMultipleOf powerOfTwo: Self) -> Self {

Sources/LiveKit/LiveKit.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616

1717
import Foundation
1818

19+
@_implementationOnly import LiveKitWebRTC
1920
@_implementationOnly import Logging
20-
@_implementationOnly import WebRTC
2121

2222
let logger = Logger(label: "LiveKitSDK")
2323

Sources/LiveKit/Participant/LocalParticipant.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import Foundation
2020
import ReplayKit
2121
#endif
2222

23-
@_implementationOnly import WebRTC
23+
@_implementationOnly import LiveKitWebRTC
2424

2525
@objc
2626
public class LocalParticipant: Participant {

Sources/LiveKit/Participant/Participant.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public class Participant: NSObject, ObservableObject, Loggable {

Sources/LiveKit/Participant/RemoteParticipant.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public class RemoteParticipant: Participant {

Sources/LiveKit/Protocols/AudioRenderer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import CoreMedia
1818
import Foundation
1919

20-
@_implementationOnly import WebRTC
20+
@_implementationOnly import LiveKitWebRTC
2121

2222
@objc
2323
public protocol AudioRenderer {

Sources/LiveKit/Protocols/EngineDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
protocol EngineDelegate: AnyObject {
2222
func engine(_ engine: Engine, didMutateState state: Engine.State, oldState: Engine.State) async

Sources/LiveKit/Protocols/SignalClientDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
protocol SignalClientDelegate: AnyObject {
2222
func signalClient(_ signalClient: SignalClient, didUpdateConnectionState newState: ConnectionState, oldState: ConnectionState, disconnectError: LiveKitError?) async

Sources/LiveKit/Protocols/TrackDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public protocol TrackDelegate: AnyObject {

Sources/LiveKit/Protocols/TransportDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
protocol TransportDelegate: AnyObject {
2222
func transport(_ transport: Transport, didUpdateState state: RTCPeerConnectionState) async

Sources/LiveKit/Protocols/VideoRenderer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public protocol VideoRenderer {

Sources/LiveKit/Protocols/VideoViewDelegate.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public protocol VideoViewDelegate: AnyObject {

Sources/LiveKit/Support/Utils.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
typealias DebouncFunc = () -> Void
2222

Sources/LiveKit/SwiftUI/SwiftUIAudioRoutePickerButton.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import AVKit
1818
import Foundation
1919
import SwiftUI
2020

21-
@_implementationOnly import WebRTC
21+
@_implementationOnly import LiveKitWebRTC
2222

2323
public struct SwiftUIAudioRoutePickerButton: NativeViewRepresentable {
2424
typealias ViewType = AVRoutePickerView

Sources/LiveKit/Track/AudioManager.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
// Wrapper for LKRTCAudioBuffer
2222
@objc

Sources/LiveKit/Track/AudioTrack.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
import Foundation
1818

19-
@_implementationOnly import WebRTC
19+
@_implementationOnly import LiveKitWebRTC
2020

2121
@objc
2222
public protocol AudioTrack where Self: Track {}

Sources/LiveKit/Track/Capturers/BufferCapturer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import CoreMedia
1818
import Foundation
1919

20-
@_implementationOnly import WebRTC
20+
@_implementationOnly import LiveKitWebRTC
2121

2222
/// A ``VideoCapturer`` that can capture ``CMSampleBuffer``s.
2323
///

Sources/LiveKit/Track/Capturers/CameraCapturer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import Foundation
2020
import ReplayKit
2121
#endif
2222

23-
@_implementationOnly import WebRTC
23+
@_implementationOnly import LiveKitWebRTC
2424

2525
public class CameraCapturer: VideoCapturer {
2626
@objc

Sources/LiveKit/Track/Capturers/InAppCapturer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import Foundation
2020
import ReplayKit
2121
#endif
2222

23-
@_implementationOnly import WebRTC
23+
@_implementationOnly import LiveKitWebRTC
2424

2525
@available(macOS 11.0, iOS 11.0, *)
2626
public class InAppScreenCapturer: VideoCapturer {

Sources/LiveKit/Track/Capturers/MacOSScreenCapturer.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import Foundation
2121
import ScreenCaptureKit
2222
#endif
2323

24-
@_implementationOnly import WebRTC
24+
@_implementationOnly import LiveKitWebRTC
2525

2626
#if os(macOS)
2727

0 commit comments

Comments
 (0)