我有一个自定义框架,它使用manuel创建的module.modulemap
中的一些模块: -
module SQLite [system] {
header "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/include/sqlite3.h"
export *
}
module zlib [system] {
header "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/include/zlib.h"
export *
}
当我构建我的框架时,新的module.modulemap
文件会自动生成如下: -
framework module MyFramework{
umbrella header "MyFramework.h"
export *
module * { export * }
}
module MyFramework.Swift {
header "MyFramework-Swift.h"
}
当我将我的框架导入新项目时,我错过了所需的模块" sqlite"," zlib"错误。 我尝试用这样的texteditor编辑自动生成的模块映射文件;
framework module MyFramework{
umbrella header "MyFramework.h"
export *
module * { export * }
}
module MyFramework.Swift {
header "MyFramework-Swift.h"
}
module SQLite [system] {
header "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/include/sqlite3.h"
export *
}
module zlib [system] {
header "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/include/zlib.h"
export *
}
它有效。
如何自动将模块导入自动生成的模块图?或者我如何修复"缺少必需的模块" sqlite"," zlib""错误? 谢谢你的帮助。