首页 文章

Xcode 7 Swift Framework无法导入正在编译的模块

提问于
浏览
0

我的框架WebCoreDataStaticLibrary在Xcode 6.3中与ios 8.3一起工作正常 . 在我更新到ios 9和Xcode 7后,我无法编译我的框架 . 该框架包含swift和Objective C类 .

我已经通过Xcode转换为To Latest Swift语法

在我导入WebCoreDataStaticLibrary的任何swift类中,它的来源无法导入模块 .

import WebCoreDataStaticLibrary Cannot import module being compiled

因此,我无法构建框架因此导致此致命错误 .

fatal error: lipo: can't open input file: /*/Developer/Xcode/DerivedData/A3WebCoreDataStaticLibrary-ctaegtiwmwhrsdeggeswpkjvucua/Build/Products/Debug-iphonesimulator/A3WebCoreDataStaticLibrary.framework/A3WebCoreDataStaticLibrary (No such file or directory) Command /bin/sh emitted errors but did not return a nonzero exit code to indicate failure

enter image description here

项目设置

enter image description here

1 回答

  • 1

    它's telling you the problem. It can'找到了 A3WebCoreDataStaticLibrary.framework/A3WebCoreDataStaticLibrary .

    我甚至知道为什么 . 您的文件系统上没有名为 /*/ 的目录 .

    项目设置中的某些内容设置错误 . 我的猜测是你的框架搜索路径是错误的,或者Link Binary With Libraries部分是错误的 . 在不知道项目设置中有什么的情况下,很难说清楚 .


    UPDATE 屏幕截图显示的错误与描述不同 .

    此时,您需要开始挖掘 . 转到该目录 . 确保该文件存在 .

    如果该文件不存在,您需要查看 A3WebCoreDataStaticLibrary 目标,看看为什么它没有构建您期望的框架 .

    如果文件确实存在,那么您需要检查构建顺序 . 它可能在尝试构建您的应用程序后构建框架 .

相关问题