sinaweibosdk / weibo_ios_sdk

新浪微博 IOS SDK
http://weibo.com
Other
1.44k stars 565 forks source link

在 Swift 中,基层 WeiboSDK 出现警告⚠️ “ WeiboSDK-Prefix.pch.pch: No such file or directory” #155

Closed ihomway closed 4 years ago

ihomway commented 8 years ago

warning: /var/folders/1n/49myhky1215gnqd43rvhl7cw0000gn/C/com.apple.DeveloperTools/7.0-7A220/Xcode/SharedPrecompiledHeaders/WeiboSDK-Prefix-asyrxfcfwkohdsbbizoeuisplmqo/WeiboSDK-Prefix.pch.pch: No such file or directory

newbdez33 commented 8 years ago

现在解决了么?

sdyxch commented 8 years ago

同问。。

soulmercy commented 8 years ago

还有很多其他的,如下: while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: /var/folders/1n/49myhky1215gnqd43rvhl7cw0000gn/C/com.apple.DeveloperTools/7.1-7B91b/Xcode/SharedPrecompiledHeaders/WeiboSDK-Prefix-cafhnsmhqecobwdsowlqwfibcwye/WeiboSDK-Prefix.pch.pch: No such file or directory while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: /var/folders/1n/49myhky1215gnqd43rvhl7cw0000gn/C/com.apple.DeveloperTools/7.1-7B91b/Xcode/SharedPrecompiledHeaders/WeiboSDK-Prefix-cafhnsmhqecobwdsowlqwfibcwye/WeiboSDK-Prefix.pch.pch: No object file for requested architecture while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSObject while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSDictionary while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSString while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSObject while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSUndoManager while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSObject while processing /Users/wangjunwu/Workspace/Inagora/phoenix/Wonderfull/Wonderfull/Libraries/SinaWeibo/libWeiboSDK.a(WBSDKNormalWebViewController.o): warning: Could not resolve external type c:objc(cs)NSArray

soulmercy commented 8 years ago

不回复的人抢不到火车票

newbdez33 commented 8 years ago

在Build Settings里,修改Debug Information Format项,注意有Debug和Release两个,分别设置: Debug: DWARF Release: DWARF with dSYM File

这里我们在debug里不需要生dSYM,也就算把这些警告暂时绕过去了吧。

soulmercy commented 8 years ago

@newbdez33 这个解决办法看到过,但是在进行测试时,还是需要dSYM进行对出现的crash进行跟踪,没有dSYM还是不行的

newbdez33 commented 8 years ago

debug是联机调试啊。至少我想不出debug时哪里会用到

2015年12月8日星期二,Jeffery Wang notifications@github.com 写道:

@newbdez33 https://github.com/newbdez33 这个解决办法看到过,但是在进行测试时,还是需要dSYM进行对出现的crash进行跟踪,没有dSYM还是不行的

— Reply to this email directly or view it on GitHub https://github.com/sinaweibosdk/weibo_ios_sdk/issues/155#issuecomment-162915250 .

Regards, Jacky

soulmercy commented 8 years ago

@newbdez33 也没错,改个编译选项确实是眼不见心不烦。不过sdk本身的问题,还是应该尽快解决。看到从九月底就有人反映问题到现在,也近一个半月了。不知道开发组修复这个问题的难处在哪里,希望能跟大家说一下

sum123 commented 8 years ago

同问

ogres commented 8 years ago

这将有助于。 https://github.com/zendesk/zendesk_sdk_ios/issues/79

zqqf16 commented 8 years ago

这个问题是由于 libWeiboSDK.a 里面包含调试信息,而这个库编译的时候依赖了 pch 文件,所以在生成应用的 dSYM 文件时,会去查找这个 pch,找不到就出错了。 可以用 strip -S libWeiboSDK.a 命令把这个库里面的调试信息去掉,好处是消除了 warning,减少了体积,坏处是一担这个库有问题,定位不到具体原因。

northwind commented 8 years ago

@zqqf16 可以给出具体的操作流程吗?在什么位置增加strip -S libWeiboSDK.a

zqqf16 commented 8 years ago

@northwind 在终端执行这个命令就可以了

soulmercy commented 8 years ago

@northwind 把这个工程git clone下来后,在terminal切换到libWeiboSDK.a这个文件的目录(或者copy出来到另一个目录),然后执行这句。之后文件就不会包含调测信息了,也就不会再有以上warning。 我新建了一个pod,做这件事。SMWeiboSDK

sencho commented 7 years ago

微博的人都去哪里了,这个Issue已经是15年的了,太不重视自己的产品了