Skip to content

pod 三方库库开发时候,如果 依赖了Masonry,s.dependency 'Masonry' , '1.1.0',pod在 本地校验时候报错clang: error: SDK does not contain 'libarclite' #614

Open

Description

@chenchangjun321

我在LPSoundSDK.podspec 添加了对Masonry 的依赖:

依赖三方的库

s.dependency 'Masonry' , '1.1.0'
执行本地校验
pod spec lint LPSoundSDK.podspec --sources='https://github.com/CocoaPods/Specs.git,https://gitee.com/chen-changjun-code/lp-sdk-repo.git' --allow-warnings --verbose

时候,如下主要报错:

Ld /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry/Masonry.framework/Masonry normal (in target 'Masonry' from project 'Pods')
    cd /var/folders/mp/b477dn7d1x59zkv6p80krytw0000gn/T/CocoaPods-Lint-20250124-40920-7lh91a-LPSoundSDK/Pods
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -Xlinker -reproducible -target x86_64-apple-ios8.0-simulator -dynamiclib -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.2.sdk -Os -L/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/EagerLinkingTBDs/Release-iphonesimulator -L/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry -F/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/EagerLinkingTBDs/Release-iphonesimulator -F/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry -filelist /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/Masonry.build/Objects-normal/x86_64/Masonry.LinkFileList -install_name @rpath/Masonry.framework/Masonry -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -dead_strip -Xlinker -object_path_lto -Xlinker /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/Masonry.build/Objects-normal/x86_64/Masonry_lto.o -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -framework Foundation -framework UIKit -framework Foundation -framework UIKit -Xlinker -no_adhoc_codesign -compatibility_version 1 -current_version 1 -Xlinker -dependency_info -Xlinker /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/Masonry.build/Objects-normal/x86_64/Masonry_dependency_info.dat -o /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry/Masonry.framework/Masonry
clang: error: SDK does not contain 'libarclite' at the path '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a'; try increasing the minimum deployment target

note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'Pods-App' from project 'Pods')
note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'App' from project 'App')
note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'LPSoundSDK' from project 'Pods')
/var/folders/mp/b477dn7d1x59zkv6p80krytw0000gn/T/CocoaPods-Lint-20250124-40920-7lh91a-LPSoundSDK/Pods/Pods.xcodeproj: warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 12.0 to 18.2.99. (in target 'Masonry' from project 'Pods')
note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'Masonry' from project 'Pods')
note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'LPSoundSDK-LPSoundSDK' from project 'Pods')
** BUILD FAILED **


The following build commands failed:
	Ld /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry/Masonry.framework/Masonry normal (in target 'Masonry' from project 'Pods')
	Building workspace App with scheme App and configuration Release
(2 failures)

Testing with xcodebuild.
-> LPSoundSDK (0.6.0)
- WARN | summary: The summary is not meaningful.
- NOTE | url: The URL (https://gitee.com/chen-changjun-code/lpsound-sdk) is not reachable.
- ERROR | [iOS] xcodebuild: Returned an unsuccessful exit code.
- NOTE | xcodebuild: note: Using codesigning identity override: -
- NOTE | [iOS] xcodebuild: note: Building targets in dependency order
- NOTE | [iOS] xcodebuild: note: Target dependency graph (5 targets)
- NOTE | [iOS] xcodebuild: clang: error: SDK does not contain 'libarclite' at the path '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a'; try increasing the minimum deployment target
- NOTE | [iOS] xcodebuild: note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'Pods-App' from project 'Pods')
- NOTE | [iOS] xcodebuild: note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'App' from project 'App')
- NOTE | [iOS] xcodebuild: note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'LPSoundSDK' from project 'Pods')
- NOTE | [iOS] xcodebuild: Pods.xcodeproj: warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 12.0 to 18.2.99. (in target 'Masonry' from project 'Pods')
- NOTE | [iOS] xcodebuild: note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'Masonry' from project 'Pods')
- NOTE | [iOS] xcodebuild: note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'LPSoundSDK-LPSoundSDK' from project 'Pods')

Pods workspace available at /var/folders/mp/b477dn7d1x59zkv6p80krytw0000gn/T/CocoaPods-Lint-20250124-40920-7lh91a-LPSoundSDK/App.xcworkspace for inspection.

主要原因是:
clang: error: SDK does not contain 'libarclite' at the path '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a'; try increasing the minimum deployment target

是因为Masonry 支持 版本太低,新版本的XCode 已经没有 libarclite库了,所以无法校验通过

Activity

  1. chenchangjun321 commented on Jan 24, 2025

    @chenchangjun321
    Author

    作者能否发布一个新版本的,最低支持版本从12开始,9以前的老系统说实话,现在基本没有项目支持了

  2. mumugongzhu commented on Oct 16, 2025

    @mumugongzhu

    作者能否发布一个新版本的,最低支持版本从12开始,9以前的老系统说实话,现在基本没有项目支持

    我在LPSoundSDK.podspec 添加了对Masonry的依赖:

    依赖三方的库

    s.依赖性'Masonry','1.1.0'执行本地考试pod spec lint LPSoundSDK.podspec --sources='https://github.com/CocoaPods/Specs.git,https://gitee.com/chen-changjun-code/lp-sdk-repo.git' --allow-warnings --verbose

    时候,如下主要报错:

    Ld /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry/Masonry.framework/Masonry normal (in target 'Masonry' from project 'Pods')
        cd /var/folders/mp/b477dn7d1x59zkv6p80krytw0000gn/T/CocoaPods-Lint-20250124-40920-7lh91a-LPSoundSDK/Pods
        /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -Xlinker -reproducible -target x86_64-apple-ios8.0-simulator -dynamiclib -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.2.sdk -Os -L/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/EagerLinkingTBDs/Release-iphonesimulator -L/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry -F/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/EagerLinkingTBDs/Release-iphonesimulator -F/Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry -filelist /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/Masonry.build/Objects-normal/x86_64/Masonry.LinkFileList -install_name @rpath/Masonry.framework/Masonry -Xlinker -rpath -Xlinker @executable_path/Frameworks -Xlinker -rpath -Xlinker @loader_path/Frameworks -dead_strip -Xlinker -object_path_lto -Xlinker /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/Masonry.build/Objects-normal/x86_64/Masonry_lto.o -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -framework Foundation -framework UIKit -framework Foundation -framework UIKit -Xlinker -no_adhoc_codesign -compatibility_version 1 -current_version 1 -Xlinker -dependency_info -Xlinker /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Intermediates.noindex/Pods.build/Release-iphonesimulator/Masonry.build/Objects-normal/x86_64/Masonry_dependency_info.dat -o /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry/Masonry.framework/Masonry
    clang: error: SDK does not contain 'libarclite' at the path '/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a'; try increasing the minimum deployment target
    
    note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'Pods-App' from project 'Pods')
    note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'App' from project 'App')
    note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'LPSoundSDK' from project 'Pods')
    /var/folders/mp/b477dn7d1x59zkv6p80krytw0000gn/T/CocoaPods-Lint-20250124-40920-7lh91a-LPSoundSDK/Pods/Pods.xcodeproj: warning: The iOS Simulator deployment target 'IPHONEOS_DEPLOYMENT_TARGET' is set to 8.0, but the range of supported deployment target versions is 12.0 to 18.2.99. (in target 'Masonry' from project 'Pods')
    note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'Masonry' from project 'Pods')
    note: Disabling previews because SWIFT_VERSION is set and SWIFT_OPTIMIZATION_LEVEL=-O, expected -Onone (in target 'LPSoundSDK-LPSoundSDK' from project 'Pods')
    ** BUILD FAILED **
    
    
    The following build commands failed:
    	Ld /Users/chencj/Library/Developer/Xcode/DerivedData/App-cyfzhmonjjxdnycdmocixbmljvja/Build/Products/Release-iphonesimulator/Masonry/Masonry.framework/Masonry normal (in target 'Masonry' from project 'Pods')
    	Building workspace App with scheme App and configuration Release
    (2 failures)
    

    使用xcodebuild进行测试。-> LPSoundSDK(0.6.0)- 警告 | 摘要:摘要没有意义。- 注意 | url:无法访问网址(https://gitee.com/chen-changjun-code/lpsound-sdk)。- 错误 | [iOS] xcodebuild:返回一个失败的退出代码。- 注 | xcodebuild:注:使用共同设计身份覆盖:-- 注意 | [iOS] xcodebuild:注意:按依赖顺序构建目标- 注释 | [iOS] xcodebuild:注释:目标依赖图(5个目标)- 注意 | [iOS] xcodebuild:clang:错误:SDK在路径“/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a”中不包含“libarclite”;尝试增加最小部署目标- 注意 | [iOS] xcodebuild:注意:禁用预览,因为设置了SWIFT_VERSION和SWIFT_OPTIMIZATION_LEVEL=-O,预期-Onone(在项目“Pods”的目标“Pods-App”中)- 注意 | [iOS] xcodebuild:注意:禁用预览,因为设置了SWIFT_VERSION和SWIFT_OPTIMIZATION_LEVEL=-O,预期-Onone(在项目“应用程序”的目标“应用程序”中)- 注 | [iOS] xcodebuild:注:禁用预览,因为设置了SWIFT_VERSION,并且SWIFT_OPTIMIZATION_LEVEL=-O,预期-Onone(在项目“Pods”的目标“LPSoundSDK”中)- 注意 | [iOS] xcodebuild:Pods.xcodeproj:警告:iOS模拟器部署目标“IPHONEOS_DEPLOYMENT_TARGET”设置为8.0,但支持的部署目标版本范围为12.0到18.2.99。(在项目“Pods”的目标“Masonry”中)- 注意 | [iOS] xcodebuild:注意:禁用预览,因为设置了SWIFT_VERSION和SWIFT_OPTIMIZATION_LEVEL=-O,预期-Onone(在项目“Pods”的目标“Masonry”中)- 注意 | [iOS] xcodebuild:注意:禁用预览,因为SWIFT_VERSION已设置和SWIFT_OPTIMIZATION_LEVEL=-O,预期-Onone(在项目“Pods”的目标“LPSoundSDK-LPSDK”中)

    Pods工作区可在/var/folders/mp/b477dn7d1x59zkv6p80krytw0000gn/T/CocoaPods-Lint-20250124-40920-7lh91a-LPSoundSDK/App.xcworkspace进行检查。

    主要原因是:clang:错误:SDK在路径“/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/arc/libarclite_iphonesimulator.a”中不包含“libarclite”;尝试增加最低部署目标

    是因为Masonry支持版本太低,新版本的XCode已经没有libarclite库了,所以无法校验通过

    这个问题现在能解决吗?

  3. wangjiayu4657 commented on Dec 1, 2025

    @wangjiayu4657

    遇到了同样的问题, 通过 pod 'Masonry' 就会报这个错, 没办法暂时是将 Masonry 下载下来拖到项目中来解决

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions