常见的和普通的去除方法就不写了,网上有很多,写点遇到的小众问题。
1.Conflicting return type in implementation of 'supportedInterfaceOrientations': 'UIInterfaceOrientationMask' (aka 'enum UIInterfaceOrientationMask') vs 'NSUInteger' (aka 'unsigned long')
解决:
#if __IPHONE_OS_VERSION_MAX_ALLOWED < 90000
- (NSUInteger)supportedInterfaceOrientations
#else
- (UIInterfaceOrientationMask)supportedInterfaceOrientations
#endif
{
return UIInterfaceOrientationMaskPortrait;
}
2.'interfaceOrientation' is deprecated: first deprecated in iOS 8.0
解决:
self.interfaceOrientation
改成
[[UIApplication sharedApplication] statusBarOrientation]
3.pod 'UMengSocialCOM', '~> 5.2.1'命令重新安装友盟社会化组件.编译出现警告:
object file (Pods/UmengSocialCOM/Umeng_SDK_Social_iOS_ARM64_5.2.1/UMSocial_Sdk_Extra_Frameworks/AlipayShare/libAPOpenSdk.a(APOpenAPIObject.o)) was built for newer iOS version (8.1) than being linked (8.0)
解决:
Targets->Build Settings -> Other linker flags 里边添加-w即可
4.Cannot find protocol definition for 'TencentSessionDelegate'
在TencentOAuth.h类中#import "TencentApiInterface.h"