You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

升级Xcode16与iOS18后Linphone SDK库加载失败求助

解决Xcode 16 + iOS 18下Linphone SDK加载liblibbelle-sip-tester.dylib失败问题

针对你遇到的加载失败问题,结合你已尝试的方案,给出以下针对性解决步骤:

1. 排除测试库依赖(核心方案)

报错的liblibbelle-sip-tester.dylib是Linphone的测试组件库,正式应用无需引入。修改Podfile,指定Linphone SDK仅加载核心非测试组件:

platform :ios, '16.0'
source "https://gitlab.linphone.org/BC/public/podspec.git"
source "https://github.com/CocoaPods/Specs.git"

def basic_pods
    # 仅引入核心XCFramework,排除测试相关组件
    pod 'linphone-sdk/XCFramework', '> 5.4.0-alpha'
end

target 'MyApp' do
  use_frameworks!
  use_modular_headers! # 确保CocoaPods正确处理模块化框架
  
  pod 'SQLite.swift', '~> 0.14.0'
  
  basic_pods
  
  pod 'ModalPresenter'
  pod "Firebase"
  pod 'Firebase/Core'
  pod 'Firebase/Messaging'
end

2. 彻底清理并重新安装依赖

执行以下步骤清除残留的测试库文件:

  • 终端运行 pod deintegrate 移除所有Pod依赖
  • 清理Xcode缓存:按下Command+Shift+K清理构建文件夹,再按Command+Option+Shift+K清理派生数据
  • 终端运行 pod install 重新安装依赖

3. 验证Xcode构建配置

  • Frameworks, Libraries, and Embedded Content:进入项目General标签,确认只有linphone-sdk.xcframework被设置为Embed & Sign,若存在linphonetester.xcframework直接移除
  • Runpath Search Paths:在Build Settings中,确保包含@executable_path/Frameworks和@loader_path/Frameworks,并勾选"inherit from parent or project settings"
  • Framework Search Paths:添加$(inherited)和$(PODS_ROOT)/linphone-sdk,设置为递归(Recursive)

4. iOS 18兼容性调整

  • 将iOS部署目标暂时提升至16.0(Xcode 16对iOS 15的兼容性支持可能存在变动)
  • 在Build Settings中,将Build Libraries for Distribution设置为YES
  • 确认Valid Architectures仅保留arm64(适配iOS 18设备架构)

完成以上步骤后重新编译运行,可解决测试库加载失败问题。

内容的提问来源于stack exchange,提问作者Mr Hery

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.15 20:55:09