Matthew Pickering pushed to branch wip/mp/14996 at Glasgow Haskell Compiler / GHC
Commits:
-
01262c01
by Matthew Pickering at 2025-11-07T16:48:55+00:00
1 changed file:
Changes:
| ... | ... | @@ -352,6 +352,9 @@ instance H.Builder Builder where |
| 352 | 352 | |
| 353 | 353 | Haddock BuildPackage -> runHaddock path buildArgs buildInputs
|
| 354 | 354 | |
| 355 | + Ghc FindHsDependencies _ -> do
|
|
| 356 | + runGhcWithResponse path buildArgs buildInputs
|
|
| 357 | + |
|
| 355 | 358 | HsCpp -> captureStdout
|
| 356 | 359 | |
| 357 | 360 | Make dir -> cmd' buildOptions path ["-C", dir] buildArgs
|
| ... | ... | @@ -394,6 +397,13 @@ runHaddock haddockPath flagArgs fileInputs = withTempFile $ \tmp -> do |
| 394 | 397 | writeFile' tmp $ escapeArgs fileInputs
|
| 395 | 398 | cmd [haddockPath] flagArgs ('@' : tmp)
|
| 396 | 399 | |
| 400 | +runGhcWithResponse :: FilePath -> [String] -> [FilePath] -> Action ()
|
|
| 401 | +runGhcWithResponse ghcPath flagArgs fileInputs = withTempFile $ \tmp -> do
|
|
| 402 | + writeFile' tmp $ escapeArgs (fileInputs)
|
|
| 403 | + |
|
| 404 | + cmd [ghcPath] flagArgs ('@' : tmp)
|
|
| 405 | + |
|
| 406 | + |
|
| 397 | 407 | -- TODO: Some builders are required only on certain platforms. For example,
|
| 398 | 408 | -- 'Objdump' is only required on OpenBSD and AIX. Add support for platform
|
| 399 | 409 | -- specific optional builders as soon as we can reliably test this feature.
|