架构i386的未定义符号和架构i386未找到符号

时间:2014-04-19 05:16:14

标签: ios objective-c ios7 ios7.1

我正在开发一个虚假的静态框架。我构建它并包含它另一个示例应用程序。示例应用程序在iPhone(ios 7.1)上正常运行,但是当我在模拟器上运行它时会出现以下错误

ld: warning: ignoring file /Users/awsuser8/Desktop/Test.framework/Test, file was built for archive which is not the architecture being linked (i386): /Users/awsuser8/Desktop/Test.framework/Test
Undefined symbols for architecture i386:
  "_OBJC_CLASS_$_Test", referenced from:
      objc-class-ref in ViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

1 个答案:

答案 0 :(得分:1)

您可以为iOS模拟器重建库,并使用lipo和库的ARM构建将其组合。然后该库也将支持x86构建。