d6aeede2bc
从桌面工程复制而来,作为本仓库的 Xuxucheck/ 子目录。 为控制仓库体积做了两处删减: - 移除 Frameworks/opencv2.xcframework 下的两个 visionOS 切片 (xros-arm64、xros-arm64-simulator,合计约 106 MB),并同步删掉该 xcframework 内 Info.plist 里对应的两条 AvailableLibraries 记录, 只保留 ios-arm64 与 ios-arm64_x86_64-simulator。 - 移除全部 .DS_Store 与 xcuserdata/。 已用 xcodebuild 从本目录完整编译验证:BUILD SUCCEEDED, ProcessXCFramework 以 --platform ios 成功选中框架,产物含 3699 个 cv:: 符号 (OpenCV 确实链入),嵌入 framework 3 个,与移除无用 pod 之后的状态一致。 仓库约 206 MB,其中 OpenCV 203 MB、其余源码与依赖约 3 MB。
47 lines
2.0 KiB
Ruby
47 lines
2.0 KiB
Ruby
# Uncomment the next line to define a global platform for your project
|
|
# 注意:这个值不能低于 15.0 —— Xcode 27 只接受 15.0~27.0 的 IPHONEOS_DEPLOYMENT_TARGET,
|
|
# 它决定 Pods 聚合 target 的取值。原来的 13.0 是老 Xcode 时代的产物。
|
|
platform :ios, '15.6'
|
|
|
|
target 'XuXuCheck' do
|
|
# Comment the next line if you don't want to use dynamic frameworks
|
|
pod 'Alamofire'
|
|
pod 'AlamofireObjectMapper', '~> 5.2'
|
|
# 以下三个原先作为依赖引入,但 App 代码从未 import 过(全仓 grep 零引用)。
|
|
# use_frameworks! 会把每个 pod 都做成动态 framework 并嵌进 .app,所以它们
|
|
# 既拖慢每次构建,又多占 3.7MB(嵌入框架共 6.4MB)。已移除。
|
|
# 注意:SDWebImage 是 SDWebImageSwiftUI 的传递依赖,随之一起消失;
|
|
# ObjectMapper 仍由 AlamofireObjectMapper 带入,代码里的 import 不受影响。
|
|
use_frameworks!
|
|
|
|
# Pods for XuXuCheck
|
|
|
|
target 'XuXuCheckTests' do
|
|
inherit! :search_paths
|
|
# Pods for testing
|
|
end
|
|
|
|
target 'XuXuCheckUITests' do
|
|
# Pods for testing
|
|
end
|
|
|
|
end
|
|
|
|
# 各 pod 的 podspec 自己声明的最低部署目标是 8.0(Alamofire / AlamofireObjectMapper /
|
|
# ObjectMapper),而 Xcode 27 只接受 15.0~27.0 —— 低于 15.0 会直接报错,一个编译步都跑不起来。
|
|
#
|
|
# 原先这个项目是靠手工把 Pods.xcodeproj 里 22 处 IPHONEOS_DEPLOYMENT_TARGET 改成 15.6
|
|
# 才能编译的,而手工改动会在每次 pod install 重新生成时被覆盖 —— 所以"跑一次 pod install
|
|
# 就编译不过"是本来就会发生的事,只是以前没人跑过。
|
|
# 放在 post_install 里统一设置,重新生成也不会丢,并在 README 里记了原因。
|
|
post_install do |installer|
|
|
installer.pods_project.targets.each do |target|
|
|
target.build_configurations.each do |config|
|
|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '15.6'
|
|
end
|
|
end
|
|
installer.pods_project.build_configurations.each do |config|
|
|
config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '15.6'
|
|
end
|
|
end
|