Closed Timson020 closed 5 years ago
@Timson020 我本地尝试了react-native link aliyun-oss-react-native ,安卓这边编译是OK的,ios的确遇到了你说的这个问题,这个我在跟。 你可以先手动本地添加,是OK的。
手动添加,我这边是不行的喔。。。。 我看英文文档再试下
@Timson020 第三步的 copy items if need 选项勾选上
是的 我已经勾选了
第一步需要勾选么?
你xcode的版本是 9.4.1么
@Timson020 是的
。。。。 我的就是手动加入都不行 按照英文文档的来
如果方便的话 可以截图 整个步骤我看下么
@Timson020 ,你重新react-native init X ,然后这三步
example add path to Header Search Path
I add below line to my project's "Framework Search Path"
"$(SRCROOT)/../node_modules/aliyun-oss-react-native/ios/AliyunSDK"
Build is pass
一样的错误
ld: framework not found AliyunOSSiOS
clang: error: linker command failed with exit code 1 (use -v to see invocation)
终于调试出来的。我发现一个问题。 对比Example,我发现在Example中ios下面有一个AliyunOSSiOS.framework的文件夹,这个哪里来的?把他拷贝到我的项目中,然后在xcode添加这个文件夹,神奇的好了。
之前失败,我很确定按照步骤三种的做法,我选择了“select Copy items if needed”
In XCode, in the project navigator, right click Frameworks ➜ Add Files to [your project's name]. Go to node_modules ➜ aliyun-oss-react-native ➜ AliyunSDK. Add AliyunOSSiOS.framework, and select Copy items if needed in the pop-up box.
是不是这里没有生效导致的?XCode Version 9.4.1 (9F2000)
同样法来添加AliyunOSSiOS.framework, 1,添加demo中的AliyunOSSiOS.framework可以正常使用, 2,添加node_modules中的AliyunOSSiOS.framework,报错
ld: framework not found AliyunOSSiOS,
怀疑,发布的包有问题
AliyunOSSiOS.framework 这个东西是我们react-native Ios端依赖的原生ios oss sdk,这个东西其实我在项目里已经加入依赖。
Any updated news?
@luozhang002
终于调试出来的。我发现一个问题。 对比Example,我发现在Example中ios下面有一个AliyunOSSiOS.framework的文件夹,这个哪里来的?把他拷贝到我的项目中,然后在xcode添加这个文件夹,神奇的好了。
之前失败,我很确定按照步骤三种的做法,我选择了“select Copy items if needed”
In XCode, in the project navigator, right click Frameworks ➜ Add Files to [your project's name]. Go to node_modules ➜ aliyun-oss-react-native ➜ AliyunSDK. Add AliyunOSSiOS.framework, and select Copy items if needed in the pop-up box.
是不是这里没有生效导致的?XCode Version 9.4.1 (9F2000)
同样法来添加AliyunOSSiOS.framework, 1,添加demo中的AliyunOSSiOS.framework可以正常使用, 2,添加node_modules中的AliyunOSSiOS.framework,报错
ld: framework not found AliyunOSSiOS,
怀疑,发布的包有问题
也是遇到此問題,依 @kala888 方法,終於編譯成功...
按 @kala888 方法+添加ipv6那三个包,成功了
example add path to Header Search Path
I add below line to my project's "Framework Search Path"
"$(SRCROOT)/../node_modules/aliyun-oss-react-native/ios/AliyunSDK"
Build is pass
thanks, I followed your step and it works!
Xcode version is 9.4.1
Step
but can's run
Error