浏览代码

Merge pull request #13 from tcbrindle/develop

Fix for Clang not working with MacOS
default_compile_flags
vector-of-bool 5 年前
父节点
当前提交
7783e813ef
没有帐户链接到提交者的电子邮件
共有 1 个文件被更改,包括 10 次插入3 次删除
  1. +10
    -3
      src/dds/toolchain/from_dds.cpp

+ 10
- 3
src/dds/toolchain/from_dds.cpp 查看文件

if (!compiler_id) { if (!compiler_id) {
fail(context, "Cannot deduce library file extension without Compiler-ID"); fail(context, "Cannot deduce library file extension without Compiler-ID");
} }
if (is_gnu) {
if (is_gnu_like) {
return ".a"; return ".a";
} else if (is_msvc) { } else if (is_msvc) {
return ".lib"; return ".lib";
if (!compiler_id) { if (!compiler_id) {
fail(context, "Cannot deduce object file extension without Compiler-ID"); fail(context, "Cannot deduce object file extension without Compiler-ID");
} }
if (is_gnu) {
if (is_gnu_like) {
return ".o"; return ".o";
} else if (is_msvc) { } else if (is_msvc) {
return ".obj"; return ".obj";
string_seq ret; string_seq ret;
if (is_msvc) { if (is_msvc) {
ret = {get_compiler(language::cxx), "/nologo", "/EHsc", "<IN>", "/Fe<OUT>"}; ret = {get_compiler(language::cxx), "/nologo", "/EHsc", "<IN>", "/Fe<OUT>"};
} else if (is_gnu_like) {
} else if (is_gnu) {
ret = {get_compiler(language::cxx), ret = {get_compiler(language::cxx),
"-fPIC", "-fPIC",
"-fdiagnostics-color", "-fdiagnostics-color",
"-pthread", "-pthread",
"-lstdc++fs", "-lstdc++fs",
"-o<OUT>"}; "-o<OUT>"};
} else if (is_clang) {
ret = {get_compiler(language::cxx),
"-fPIC",
"-fdiagnostics-color",
"<IN>",
"-pthread",
"-o<OUT>"};
} else { } else {
assert(false && "No link-exe command"); assert(false && "No link-exe command");
std::terminate(); std::terminate();

正在加载...
取消
保存