Skip to content
Snippets Groups Projects
Commit 99623358 authored by Matthew Pickering's avatar Matthew Pickering Committed by Marge Bot
Browse files

hadrian: Correct generation of hsc2hs wrapper

If you inspect the inside of a wrapper script for hsc2hs you will see
that the cflag and lflag values are concatenated incorrectly.

```
HSC2HS_EXTRA="--cflag=-U__i686--lflag=-fuse-ld=gold"
```

It should instead be

```
HSC2HS_EXTRA="--cflag=-U__i686 --lflag=-fuse-ld=gold"
```

Fixes #21221
parent 1756d547
No related branches found
No related tags found
No related merge requests found
......@@ -417,7 +417,7 @@ hsc2hsWrapper = do
ldFlags <- map ("--lflag=" <>) <$> settingList (ConfGccLinkerArgs Stage1)
wrapper <- drop 4 . lines <$> liftIO (readFile "utils/hsc2hs/hsc2hs.wrapper")
return $ unlines
( "HSC2HS_EXTRA=\"" <> unwords ccArgs <> unwords ldFlags <> "\""
( "HSC2HS_EXTRA=\"" <> unwords (ccArgs ++ ldFlags) <> "\""
: "tflag=\"--template=$libdir/template-hsc.h\""
: "Iflag=\"-I$includedir/\""
: wrapper )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment