Skip to content
This repository was archived by the owner on Oct 7, 2020. It is now read-only.

Commit cf44df9

Browse files
authored
Merge pull request #966 from alanz/stack-install-cabal
Install Cabal library using stack GHC
2 parents b8d2e16 + f703d3f commit cf44df9

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

Makefile

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,13 @@ build: hie-8.2.1 hie-8.2.2 \
1414
build-all: build build-docs
1515
.PHONY: build-all
1616

17+
GHC := $(shell stack path --compiler-exe)
18+
19+
ghc:
20+
$(GHC) --version
21+
@echo GHC
22+
.PHONY: ghc
23+
1724
# ------------------------------------------------------
1825

1926
## Builds hie for GHC version 8.2.1 only
@@ -91,8 +98,9 @@ submodules:
9198
## NOTE 2: this is temporary, will go away once the new cabal-helper lands.
9299
## NOTE 3: This is needed for stack only projects too
93100
cabal:
94-
cabal update
95-
cabal install Cabal-2.4.1.0
101+
stack install cabal-install
102+
cabal v1-update
103+
cabal v1-install Cabal-2.4.1.0 --with-compiler=$(GHC)
96104
.PHONY: cabal
97105

98106
# ------------------------------------------------------

0 commit comments

Comments
 (0)