我正在使用RMAppReceipt来验证我的应用程序中的应用程序购买,在更新到XCode 9之前,这一切都运行良好。我已经按照www.example.com页面的指示将RMAppReceipt. h、RMAppReceipt.m、RMAppStoreReceiptVerifier. h和RMAppStoreReceiptVerifier.m文件添加到我的项目中https://github.com/robotmedia/RMStore/wiki/Receipt-verification#adding-openssl,并添加了“OpenSSL-通用”pod。
这在XCode 8.3中运行良好,但在ProjectNameUITests文件夹中将代码更新为Swift 4.0后,出现了以下错误:
Apple Mach-O链接器(Id)错误:
Undefined symbols for architecture arm64:
"_X509_STORE_add_cert", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_ASN1_get_object", referenced from:
+[RMAppReceipt enumerateASN1Attributes:length:usingBlock:] in RMAppReceipt.o
_RMASN1ReadInteger in RMAppReceipt.o
_RMASN1ReadOctectString in RMAppReceipt.o
_RMASN1ReadString in RMAppReceipt.o
"_BIO_new", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_X509_free", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_d2i_X509", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_d2i_PKCS7_fp", referenced from:
+[RMAppReceipt dataFromPCKS7Path:] in RMAppReceipt.o
"_PKCS7_verify", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_X509_STORE_free", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_BIO_free", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_EVP_cleanup", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_X509_STORE_new", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_OBJ_obj2nid", referenced from:
+[RMAppReceipt dataFromPCKS7Path:] in RMAppReceipt.o
"_BIO_s_mem", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_OpenSSL_add_all_digests", referenced from:
+[RMAppReceipt verifyPCKS7:withCertificateData:] in RMAppReceipt.o
"_PKCS7_free", referenced from:
+[RMAppReceipt dataFromPCKS7Path:] in RMAppReceipt.o
"_SHA1", referenced from:
-[RMAppReceipt verifyReceiptHash] in RMAppReceipt.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
1条答案
按热度按时间krugob8w1#
对我有效:
项目〉生成设置〉搜索:“标题搜索路径”
删除:
插入: