Add -Xlinker -lrt to fix issues with linking libSystem.Native.a, change --ilc-args to --ilcargs
This commit is contained in:
parent
b3b2ee737f
commit
f3f0d389d8
2 changed files with 2 additions and 2 deletions
|
@ -17,7 +17,7 @@ namespace Microsoft.DotNet.Tools.Compiler.Native
|
||||||
|
|
||||||
// TODO: debug/release support
|
// TODO: debug/release support
|
||||||
private readonly string cLibsFlags = "-lm -ldl";
|
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[]
|
private readonly string[] libs = new string[]
|
||||||
{
|
{
|
||||||
|
|
|
@ -39,7 +39,7 @@ namespace Microsoft.DotNet.Tools.Compiler
|
||||||
// Native Args
|
// Native Args
|
||||||
var native = app.Option("-n|--native", "Compiles source to native machine code.", CommandOptionType.NoValue);
|
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 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);
|
var cppMode = app.Option("--cpp", "Flag to do native compilation with C++ code generator.", CommandOptionType.NoValue);
|
||||||
|
|
||||||
app.OnExecute(() =>
|
app.OnExecute(() =>
|
||||||
|
|
Loading…
Add table
Reference in a new issue