TOP

10分钟搞定支付宝支付 的 各种填坑(一)
2017-10-13 10:33:47 】 浏览:10549
Tags:10分钟 搞定 支付 各种

填坑
支付宝填坑是每个接入支付宝必经之路,下面是我接入支付宝遇到的问题汇总,希望大家在接入的路上少一点弯路

问题1. Util/base64.h:63:21: Cannot find interface declaration for ‘NSObject’, superclass of ‘Base64’

解决办法:
这是base64.h中没有加入#import <Foundation/Foundation.h> 系统库文件导致,这个错误报错方法直接想喷它一脸。报错方式太恶心。

问题2.截图告知你什么问题


530EA189-0A5A-4AEB-82BF-E30B99F5418B.png
解决办法:
这个问题可以同上的,心情好,截图再次说明下,在 openssl_wrapper.h中#import <Foundation/Foundation.h> 库即可

问题3.Util/openssl_wrapper.m:11:9: ‘rsa.h’ file not found

解决办法:
(1),万年老坑,只要你接入支付宝百分百要遇到的问题,所以习以为常吧 (2),在Build setting中搜索search,找到Header Search Paths,添加$(PROJECT_DIR)/openssl和$(PROJECT_DIR) 如下图: (3),重要 问题说三遍,这是网络找到的到答案后继续有同样的坑,自己的解决方案, Header Search Paths $(PROJECT_DIR)/ali中输入这个 Framework Search Paths 和 Library Search Paths 继续是$(inherited) 和 $(PROJECT_DIR)/ali ‘rsa.h’ file not found 的解决方案 (4),由于后期多项目的接入,让我知道一个算是万能方法吧,就是始终保持Header Search Paths 和 Library Search Paths 都能找到你导入的openssl的正确路径即可,已尝试多遍,是能解决以上问题(求黑)

EB1487E2-FFA9-494B-923D-C5F7CD1AF1FC.png

5C736AB8-F0FB-423C-973D-3ED9301E27C0.png

问题4.这类错很多,大概有这些:这些可能是库文件没有导入,导致的

“_CNCopyCurrentNetworkInfo”, referenced from:
Undefined symbols for architecture x86_64:
"CNCopyCurrentNetworkInfo", referenced from:
-[APayReachability wifiInterface] in AlipaySDK
+[internal_DeviceInfo getSSIDInfo] in AlipaySDK
+[internal_DeviceInfo getNetworkInfo] in AlipaySDK
"_CNCopySupportedInterfaces", referenced from:
-[APayReachability wifiInterface] in AlipaySDK
+[internal_DeviceInfo getSSIDInfo] in AlipaySDK
+[internal_DeviceInfo getNetworkInfo] in AlipaySDK
"_CTRadioAccessTechnologyCDMA1x", referenced from:
-[AliSecXReachability networkStatusForFlags:] in AlipaySDK
"_CTRadioAccessTechnologyEdge", referenced from:
-[AliSecXReachability networkStatusForFlags:] in AlipaySDK
"_CTRadioAccessTechnologyGPRS", referenced from:
-[AliSecXReachability networkStatusForFlags:] in AlipaySDK
"_CTRadioAccessTechnologyLTE", referenced from:
-[AliSecXReachability networkStatusForFlags:] in AlipaySDK
"_OBJC_CLASS
$_CMMotionManager", referenced from:
objc-class-ref in AlipaySDK
"OBJC_CLASS$_CTTelephonyNetworkInfo", referenced from:
objc-class-ref in AlipaySDK
"SCNetworkReachabilityCreateWithAddress", referenced from:
+[APayReachability reachabilityWithAddress:] in AlipaySDK
+[AliSecXReachability reachabilityWithAddress:] in AlipaySDK
"_SCNetworkReachabilityCreateWithName", referenced from:
+[APayReachability reachabilityWithHostname:] in AlipaySDK
+[AliSecXReachability reachabilityWithHostName:] in AlipaySDK
"_SCNetworkReachabilityGetFlags", referenced from:
-[APayReachability isReachable] in AlipaySDK
-[APayReachability isReachableViaWWAN] in AlipaySDK
-[APayReachability isReachableViaWiFi] in AlipaySDK
-[APayReachability connectionRequired] in AlipaySDK
-[APayReachability isConnectionOnDemand] in AlipaySDK
-[APayReachability isInterventionRequired] in AlipaySDK
-[APayReachability reachabilityFlags] in AlipaySDK
...
"_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
-[AliSecXReachability startNotifier] in AlipaySDK
"_SCNetworkReachabilitySetCallback", referenced from:
-[APayReachability sta
10分钟搞定支付宝支付 的 各种填坑(一) https://www.cppentry.com/bencandy.php?fid=99&id=162544

首页 上一页 1 2 3 下一页 尾页 1/3/3
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
上一篇IOS开发基础知识--碎片39 下一篇一天 V1.1