diff options
author | Cheng Shao <astrohavoc@gmail.com> | 2022-10-24 08:22:05 +0000 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-11-11 00:26:55 -0500 |
commit | 177c56c1841f6ade0677730d7ab4fb1cd3936f52 (patch) | |
tree | 20d410f07df738bb76a09be8522a0e099c8cf1e9 /compiler/GHC/SysTools/Info.hs | |
parent | 5ebeaa45736b62df3b848c30b56cf4154054d1fd (diff) | |
download | haskell-177c56c1841f6ade0677730d7ab4fb1cd3936f52.tar.gz |
driver: avoid -Wl,--no-as-needed for wasm32
The driver used to pass -Wl,--no-as-needed for LLD linking. This is
actually only supported for ELF targets, and must be avoided when
linking for wasm32.
Diffstat (limited to 'compiler/GHC/SysTools/Info.hs')
-rw-r--r-- | compiler/GHC/SysTools/Info.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/GHC/SysTools/Info.hs b/compiler/GHC/SysTools/Info.hs index a953b9da21..ca16146771 100644 --- a/compiler/GHC/SysTools/Info.hs +++ b/compiler/GHC/SysTools/Info.hs @@ -113,7 +113,7 @@ getLinkerInfo' logger dflags = do | any (\line -> "LLD" `isPrefixOf` line || "LLD" `elem` words line) stdo = return (LlvmLLD $ map Option [ --see Note [ELF needed shared libs] - "-Wl,--no-as-needed"]) + "-Wl,--no-as-needed" | osElfTarget os || os == OSMinGW32 ]) -- Unknown linker. | otherwise = fail "invalid --version output, or linker is unsupported" |