gpt4 book ai didi

ios - 来自 iTC 的无效 bundle 错误,无法提交应用程序 - 因为 4 个 swift dylibs 无法嵌入

转载 作者:IT王子 更新时间:2023-10-29 05:39:41 26 4
gpt4 key购买 nike

我的应用程序在设备和模拟器上运行良好,但是当我提交它时,我得到了无效的 bundle - 一个或多个您的应用程序引用的动态库不存在于 dylib 搜索路径中上传成功完成约半小时后,错误通过电子邮件发送给我。

遵循关于此主题的建议 here ,即运行 otool -L ,我可以看到该应用程序的主要可执行文件具有其所有 @rpath/...dylib Frameworks/ 中的文件文件夹,但是,appex 的可执行文件缺少一些 Swift 库。

这是 otool -L 的输出在附录上:

Watch Extension:
/System/Library/Frameworks/WatchKit.framework/WatchKit (compatibility version 1.0.0, current version 1.0.0)
/System/Library/Frameworks/Foundation.framework/Foundation (compatibility version 300.0.0, current version 1349.0.0)
/usr/lib/libobjc.A.dylib (compatibility version 1.0.0, current version 228.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1238.0.0)
/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation (compatibility version 150.0.0, current version 1348.0.0)
/System/Library/Frameworks/UIKit.framework/UIKit (compatibility version 1.0.0, current version 3599.4.0)
/System/Library/Frameworks/WatchConnectivity.framework/WatchConnectivity (compatibility version 1.0.0, current version 116.0.0)
@rpath/libswiftCore.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftCoreGraphics.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftCoreLocation.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftDarwin.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftDispatch.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftFoundation.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftHomeKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftObjectiveC.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftSceneKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftUIKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftWatchKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftsimd.dylib (compatibility version 1.0.0, current version 800.0.46)

以下内容不在 Frameworks/ 中文件夹(但所有其他文件夹都是):

    @rpath/libswiftHomeKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftSceneKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftWatchKit.dylib (compatibility version 1.0.0, current version 800.0.46)
@rpath/libswiftsimd.dylib (compatibility version 1.0.0, current version 800.0.46)

这是为什么?我通过 pod install 重新生成了我的 pods 项目,没有改变任何东西。我没有看到任何警告。我检查了构建(存档)的日志输出,那里也没有警告。我怎样才能让它们按应有的方式包含在内?

在我的主要应用程序目标中,始终嵌入 Swift 标准库 设置为是。在 Watch 和 Watch Appex 目标中,这被设置为 no 以避免因重复而被拒绝(好)。我尝试设置 EMBEDDED_CONTENT_CONTAINS_SWIFT如其他线程中所述,在我的附录中为是,但这没有任何区别。

更新 1 - 我也无法从 xcode 管理器导出为 ADHOC 构建,它在“编译位码”步骤中出于同样的原因失败。运行时搜索路径设置如下:

Runtime search paths in build settings

这是导出失败的日志片段,有什么解决办法吗?我看不出缺少这些库的原因。

    Debug: Command took 0 seconds
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/System/Library/Frameworks/WatchKit.framework/WatchKit.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/System/Library/Frameworks/Foundation.framework/Foundation.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/usr/lib/libobjc.A.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/usr/lib/libSystem.B.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/System/Library/Frameworks/UIKit.framework/UIKit.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/System/Library/Frameworks/WatchConnectivity.framework/WatchConnectivity.tbd
Debug: Found framework/dylib: /Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/usr/lib/libobjc.A.tbd
Debug: Search Path: ['/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/clang/8.0.0/lib/darwin', '/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/usr/lib', '/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Developer/SDKs/WatchOS3.0.sdk/System/Library/Frameworks']
error: libswiftCore.dylib not found in dylib search path


Stderr:
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1974:in `block in CompileOrStripBitcodeInBundle'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1931:in `each'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1931:in `CompileOrStripBitcodeInBundle'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1921:in `block in CompileOrStripBitcodeInBundle'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1920:in `each'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:1920:in `CompileOrStripBitcodeInBundle'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2106:in `ProcessIPA'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:2674:in `<main>'
2016-09-14 15:33:40 +0000 /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool exited with 1
2016-09-14 15:33:40 +0000 ipatool JSON: {
alerts = (
{
code = 2554;
description = "Configuration issue: platform AppleTVSimulator.platform doesn't have any non-simulator SDKs; ignoring it";
info = {
};
level = WARN;
},
{
code = 2554;
description = "Configuration issue: platform iPhoneSimulator.platform doesn't have any non-simulator SDKs; ignoring it";
info = {
};
level = WARN;
},
{
code = 2554;
description = "Configuration issue: platform WatchSimulator.platform doesn't have any non-simulator SDKs; ignoring it";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftCore.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftCore.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftCoreGraphics.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftCoreGraphics.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftCoreLocation.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftCoreLocation.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftDarwin.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftDarwin.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftDispatch.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftDispatch.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftFoundation.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftFoundation.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftHomeKit.dylib: Could not resolve @rpath in @rpath/libswiftHomeKit.dylib from Watch Extension";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftObjectiveC.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftObjectiveC.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftSceneKit.dylib: Could not resolve @rpath in @rpath/libswiftSceneKit.dylib from Watch Extension";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftUIKit.dylib: Could not find image to link for armv7k in /private/var/folders/yl/mw_r1p4j3vj2mfp32rqs0y7r0000gn/T/XcodeDistPipeline.6Tu/Root/Payload/Photobooth.app/Frameworks/libswiftUIKit.dylib";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftWatchKit.dylib: Could not resolve @rpath in @rpath/libswiftWatchKit.dylib from Watch Extension";
info = {
};
level = WARN;
},
{
code = 284;
description = "Failed to resolve linkage dependency Watch Extension armv7k -> @rpath/libswiftsimd.dylib: Could not resolve @rpath in @rpath/libswiftsimd.dylib from Watch Extension";
info = {
};
level = WARN;
},

最佳答案

解决这个问题花了 12 个小时,但这就是解决问题的方法——像这样更改 ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES build设置:

App target(主要目标)——设置为 NO(我的是 YES)

观察目标 -- 设置为 YES(我的是 NO)

Watch App Extension 目标 -- 设置为 NO(我的是 YES)

编辑:我通过在 xcode 8 中创建一个新的空 watch 项目,并交叉引用新的 xcode 8 模板项目中的build设置与我的旧模板项目之间的差异来解决这个问题古老的项目。上面的设置是xcode 8 模板工程的内容。

关于ios - 来自 iTC 的无效 bundle 错误,无法提交应用程序 - 因为 4 个 swift dylibs 无法嵌入,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39481174/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com