diff options
-rw-r--r-- | lld/wasm/Driver.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lld/wasm/Driver.cpp b/lld/wasm/Driver.cpp index 983d8e9f55d..3fb6321c87f 100644 --- a/lld/wasm/Driver.cpp +++ b/lld/wasm/Driver.cpp @@ -239,10 +239,10 @@ void LinkerDriver::link(ArrayRef<const char *> ArgsArr) { Config->CheckSignatures = Args.hasFlag(OPT_check_signatures, OPT_no_check_signatures, false); Config->EmitRelocs = Args.hasArg(OPT_emit_relocs); - Config->Relocatable = Args.hasArg(OPT_relocatable); - Config->Entry = getEntry(Args, Config->Relocatable ? "" : "_start"); + Config->Entry = getEntry(Args, Args.hasArg(OPT_relocatable) ? "" : "_start"); Config->ImportMemory = Args.hasArg(OPT_import_memory); Config->OutputFile = Args.getLastArgValue(OPT_o); + Config->Relocatable = Args.hasArg(OPT_relocatable); Config->SearchPaths = args::getStrings(Args, OPT_L); Config->StripAll = Args.hasArg(OPT_strip_all); Config->StripDebug = Args.hasArg(OPT_strip_debug); |