Add -Xlinker -lrt to fix issues with linking libSystem.Native.a, change --ilc-args to --ilcargs

This commit is contained in:
Bryan Thornbury 2015-11-19 12:05:54 -08:00
parent b3b2ee737f
commit f3f0d389d8
2 changed files with 2 additions and 2 deletions

View file

@ -17,7 +17,7 @@ namespace Microsoft.DotNet.Tools.Compiler.Native
// TODO: debug/release support
private readonly string cLibsFlags = "-lm -ldl";
private readonly string cflags = "-g -lstdc++ -lrt -Wno-invalid-offsetof -pthread";
private readonly string cflags = "-g -lstdc++ -lrt -Xlinker -lrt -Wno-invalid-offsetof -pthread";
private readonly string[] libs = new string[]
{

View file

@ -39,7 +39,7 @@ namespace Microsoft.DotNet.Tools.Compiler
// Native Args
var native = app.Option("-n|--native", "Compiles source to native machine code.", CommandOptionType.NoValue);
var arch = app.Option("-a|--arch <ARCH>", "The architecture for which to compile. x64 only currently supported.", CommandOptionType.SingleValue);
var ilcArgs = app.Option("--ilc-args <ARGS>", "String to pass directory to ilc in native compilation.", CommandOptionType.SingleValue);
var ilcArgs = app.Option("--ilcargs <ARGS>", "String to pass directory to ilc in native compilation.", CommandOptionType.SingleValue);
var cppMode = app.Option("--cpp", "Flag to do native compilation with C++ code generator.", CommandOptionType.NoValue);
app.OnExecute(() =>