clang - 如何在.modulemap中递归添加多个头文件?

标签 clang cocoapods module-map

例如,这个 .modulemap 可以工作:

framework module MySDK {
  umbrella header "MySDK-umbrella.h"
  header "inc/header1.h"
  header "inc/header2.h"
  header "inc/header3.h"
  ...

  export *
  module * { export * }
}

但是这个没有:

framework module MySDK {
  umbrella header "MySDK-umbrella.h"
  header "inc/*.h"

  export *
  module * { export * }
}

那么如何在.modulemap中递归添加多个头文件?

最佳答案

对于这样的情况,我建议调查使用umbrella“Headers”而不是umbrella header“MySDK-umbrella.h”

https://clang.llvm.org/docs/Modules.html#umbrella-directory-declaration

关于clang - 如何在.modulemap中递归添加多个头文件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54739829/

相关文章:

c++ - 如何在 clang 3.4 中使用 make_unique?

ios - 如何在 Apple Silicon (M1) 上运行 CocoaPods

ios - Cocoapods 单元测试目标问题

ios - 使用 cocoapods for firebase 的 React-native 共享扩展问题

ios - swift 项目 : "Missing Required Modules" when import a modular framework

swift - #include 来自模块化项目头文件的系统头文件给出 "Include of non-modular header inside framework module..."错误

c - 尝试掌握 C 字节码...GNU/gcc 是否/可以像 Clang/LLVM 一样生成 C 字节码?

gcc - llvm/clang 构建后还需要 MinGW gcc 吗?

c++ - C++ 语言在使用列表初始化时是否强制执行编译器优化?