Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
GHC
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Reinier Maas
GHC
Commits
a5d22cab
Commit
a5d22cab
authored
1 year ago
by
John Ericson
Committed by
Marge Bot
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
hadrian: `need` any `configure` script we will call
When the script is changed, we should reconfigure.
parent
fa977034
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
hadrian/src/Hadrian/Haskell/Cabal/Parse.hs
+8
-4
8 additions, 4 deletions
hadrian/src/Hadrian/Haskell/Cabal/Parse.hs
with
8 additions
and
4 deletions
hadrian/src/Hadrian/Haskell/Cabal/Parse.hs
+
8
−
4
View file @
a5d22cab
...
...
@@ -144,17 +144,21 @@ configurePackage context@Context {..} = do
need
deps
-- Figure out what hooks we need.
let
configureFile
=
replaceFileName
(
pkgCabalFile
package
)
"configure"
-- induce dependency on the file
autoconfUserHooks
=
do
need
[
configureFile
]
pure
C
.
autoconfUserHooks
hooks
<-
case
C
.
buildType
(
C
.
flattenPackageDescription
gpd
)
of
C
.
Configure
->
pure
C
.
autoconfUserHooks
C
.
Configure
->
autoconfUserHooks
C
.
Simple
->
pure
C
.
simpleUserHooks
C
.
Make
->
fail
"build-type: Make is not supported"
-- The 'time' package has a 'C.Custom' Setup.hs, but it's actually
-- 'C.Configure' plus a @./Setup test@ hook. However, Cabal is also
-- 'C.Custom', but doesn't have a configure script.
C
.
Custom
->
do
configureExists
<-
doesFileExist
$
replaceFileName
(
pkgCabalFile
package
)
"configure"
pure
$
if
configureExists
then
C
.
autoconfUserHooks
else
C
.
simpleUserHooks
configureExists
<-
doesFileExist
configureFile
if
configureExists
then
autoconfUserHooks
else
pure
C
.
simpleUserHooks
-- Compute the list of flags, and the Cabal configuration arguments
flagList
<-
interpret
(
target
context
(
Cabal
Flags
stage
)
[]
[]
)
getArgs
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment