Commit 545cf1e1 authored by Ben Gamari's avatar Ben Gamari 🐢 Committed by Marge Bot

hadrian: Depend upon libray dependencies when configuring packages

This will hopefully fix #17631.
parent bec76733
Pipeline #15555 passed with stages
in 578 minutes and 16 seconds
module Rules.Library where
import Base
import Context
-- Necessary for inter-dependence between Rules.Register and
-- Rules.Library.
needLibrary :: [Context] -> Action ()
......@@ -13,6 +13,7 @@ import Oracles.Setting
import Packages
import Rules.Gmp
import Rules.Rts
import {-# SOURCE #-} Rules.Library (needLibrary)
import Settings
import Target
import Utilities
......@@ -38,7 +39,9 @@ configurePackageRules = do
root -/- "**/setup-config" %> \out -> do
(stage, path) <- parsePath (parseSetupConfig root) "<setup config path parser>" out
let pkg = unsafeFindPackageByPath path
Cabal.configurePackage (Context stage pkg vanilla)
let ctx = Context stage pkg vanilla
needLibrary =<< contextDependencies ctx
Cabal.configurePackage ctx
root -/- "**/autogen/cabal_macros.h" %> \out -> do
(stage, path) <- parsePath (parseToBuildSubdirectory root) "<cabal macros path parser>" out
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment