gpt4 book ai didi

ios - iOS项目中架构x86_64的 undefined symbol

转载 作者:行者123 更新时间:2023-12-01 16:14:26 24 4
gpt4 key购买 nike

我正在尝试在我的iOS项目中将this Spotify SDK integration用于React Native。

我收到以下错误:

Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_SPTAudioStreamingController", referenced from:
objc-class-ref in libRCTSpotify.a(RCTSpotify.o)
"_OBJC_CLASS_$_SPTAuth", referenced from:
objc-class-ref in libRCTSpotify.a(RCTSpotify.o)
"_OBJC_CLASS_$_SPTDiskCache", referenced from:
objc-class-ref in libRCTSpotify.a(RCTSpotify.o)
"_OBJC_CLASS_$_SPTRequest", referenced from:
objc-class-ref in libRCTSpotify.a(RCTSpotify.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Libraries文件夹中 RCTSpotify.xcodeproj中有关体系结构的部分与其他所有部分一样,我找不到关于x86_64的任何内容,并且该错误以前从未出现在项目中。

RCTSpotify.xcodeproj architecture section

最佳答案

向上滚动并查看是否有另一个错误,然后再显示类似以下内容:
warning: skipping file '[FOLDER_PATH]/node_modules/rn-spotify-sdk/ios/external/SpotifySDK' (unexpected file type 'folder' in Frameworks & Libraries build phase)
如果是这样,您确实喜欢我,并直接遵循自述文件。您实际要做的是从该文件夹中添加三个框架,而不仅仅是SpotifySDK文件夹。

它们是SpotifyMetadata.frameworkSpotifyAuthentication.frameworkSpotifyAudioPlayer.framework。如果将这三个添加进去,那么它将正常工作。它们位于/node_modules/rn-spotify-sdk/ios/external/SpotifySDK/文件夹中。

应该最终看起来像这样:

this

关于ios - iOS项目中架构x86_64的 undefined symbol ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48395794/

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