4

我需要做什么才能让 GYP 为 Mac OS X 生成典型的类 unix 生成文件堆栈?

我目前使用以下配置文件生成 XCode 构建项目:

{
  "targets": [
    {
      "target_name": "hello",
      'type': 'executable',
      "sources": [ "hello.cc" ]
    }
  ]
}

然后在 CLI 中运行以下命令:

gyp --depth binding.gyp

这会生成一个目录:binding.xcodeproj其中包含 XCode 项目。

我更希望你的标准类 unix 为 OSX 构建。另外,我想将这个项目导入到 Windows,我想使用 MS 编译器。

4

1 回答 1

6

找到了答案。很简单,真的。感谢TooTallNate。我遇到了一个错误,就像我最初做的那样。你明确地这样做:

gyp --depth=./ binding.gyp --format=make

于 2012-11-01T05:40:50.543 回答