Skip to content

Commit

Permalink
Remove ghc-api source snapshot (#2156)
Browse files Browse the repository at this point in the history
* Remove ghc-api source snapshot

We can replace the source snapshot with Cabal conditions.
This will unblock Hackage uploads until
#2128 lands

* fix 9.0.1 build

* add allow-newer for ghc-api-compat

* fix version bounds for 9.0.1

* fix hls-eval-plugin

* stack fixes

* added new versions of ghc-api-compat

* remove source snapshot from ghc901 cabal project
  • Loading branch information
pepeiborra authored Sep 7, 2021
1 parent 5afea90 commit a23b66c
Show file tree
Hide file tree
Showing 21 changed files with 156 additions and 54 deletions.
7 changes: 1 addition & 6 deletions cabal-ghc901.project
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,6 @@ source-repository-package
tag: b6245884ae83e00dd2b5261762549b37390179f8
-- https://github.com/lspitzner/czipwith/pull/2

source-repository-package
type: git
location: https://github.com/hsyl20/ghc-api-compat
tag: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15

source-repository-package
type: git
location: https://github.com/anka-213/th-extras
Expand All @@ -66,7 +61,7 @@ source-repository-package

write-ghc-environment-files: never

index-state: 2021-08-30T20:52:40Z
index-state: 2021-09-06T12:12:22Z

constraints:
-- These plugins doesn't work on GHC9 yet
Expand Down
9 changes: 1 addition & 8 deletions cabal.project
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 +31,13 @@ package *
ghc-options: -haddock
test-show-details: direct

-- see https://gitlab.haskell.org/haskell/ghc-api-compat/-/issues/1#note_371055
source-repository-package
type: git
location: https://github.com/hsyl20/ghc-api-compat
tag: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15

write-ghc-environment-files: never

index-state: 2021-08-12T12:00:38Z
index-state: 2021-09-06T12:12:22Z

constraints:
hyphenation +embed


allow-newer:
-- for shake-bench
Chart-diagrams:diagrams-core,
Expand Down
17 changes: 16 additions & 1 deletion ghcide/ghcide.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ library
ghc >= 8.6,
ghc-check >=0.5.0.4,
ghc-paths,
ghc-api-compat,
cryptohash-sha1 >=0.11.100 && <0.12,
hie-bios >= 0.7.1 && < 0.9.0,
implicit-hie-cradle >= 0.3.0.5 && < 0.4,
Expand All @@ -111,6 +110,22 @@ library
build-depends:
unix

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

default-extensions:
ApplicativeDo
BangPatterns
Expand Down
17 changes: 16 additions & 1 deletion haskell-language-server.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,6 @@ executable haskell-language-server
, cryptohash-sha1
, deepseq
, ghc
, ghc-api-compat
, ghc-boot-th
, ghcide
, hashable
Expand All @@ -361,6 +360,22 @@ executable haskell-language-server
, transformers
, unordered-containers

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

default-language: Haskell2010
default-extensions: DataKinds, TypeOperators

Expand Down
17 changes: 16 additions & 1 deletion hls-plugin-api/hls-plugin-api.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ library
, Diff ^>=0.4.0
, dlist
, ghc
, ghc-api-compat
, hashable
, hls-graph ^>=1.4
, hslogger
Expand All @@ -57,6 +56,22 @@ library
, text
, unordered-containers

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

if os(windows)
build-depends: Win32

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ library
, containers
, extra
, ghc
, ghc-api-compat
, ghcide ^>=1.4.1
, hiedb
, hls-plugin-api ^>=1.2
Expand All @@ -40,6 +39,22 @@ library
default-language: Haskell2010
default-extensions: DataKinds

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

test-suite tests
type: exitcode-stdio-1.0
default-language: Haskell2010
Expand Down
17 changes: 16 additions & 1 deletion plugins/hls-class-plugin/hls-class-plugin.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ library
, base >=4.12 && <5
, containers
, ghc
, ghc-api-compat
, ghc-exactprint
, ghcide >=1.2 && <1.5
, hls-plugin-api >=1.1 && <1.3
Expand All @@ -37,6 +36,22 @@ library
, text
, transformers

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

default-language: Haskell2010
default-extensions:
DataKinds
Expand Down
17 changes: 16 additions & 1 deletion plugins/hls-eval-plugin/hls-eval-plugin.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ library
, extra
, filepath
, ghc
, ghc-api-compat
, ghc-boot-th
, ghc-paths
, ghcide >=1.2 && <1.5
Expand All @@ -83,6 +82,22 @@ library
, unliftio
, unordered-containers

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

ghc-options:
-Wall -Wno-name-shadowing -Wno-unticked-promoted-constructors

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,29 @@ library
, containers
, deepseq
, ghc
, ghc-api-compat
, ghcide ^>=1.4
, hls-graph
, hls-plugin-api >=1.1 && <1.3
, lsp
, text
, unordered-containers

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

default-language: Haskell2010
default-extensions:
DataKinds
Expand Down
17 changes: 16 additions & 1 deletion plugins/hls-ormolu-plugin/hls-ormolu-plugin.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ library
, base >=4.12 && <5
, filepath
, ghc
, ghc-api-compat
, ghc-boot-th
, ghcide >=1.2 && <1.5
, hls-plugin-api >=1.1 && <1.3
Expand All @@ -34,6 +33,22 @@ library

default-language: Haskell2010

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

test-suite tests
type: exitcode-stdio-1.0
default-language: Haskell2010
Expand Down
17 changes: 16 additions & 1 deletion plugins/hls-retrie-plugin/hls-retrie-plugin.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ library
, directory
, extra
, ghc
, ghc-api-compat
, ghcide >=1.2 && <1.5
, hashable
, hls-plugin-api >=1.1 && <1.3
Expand All @@ -33,6 +32,22 @@ library
, transformers
, unordered-containers

if impl(ghc < 8.10.5)
build-depends:
ghc-api-compat ==8.6
elif impl(ghc == 8.10.5)
build-depends:
ghc-api-compat ==8.10.5
elif impl(ghc == 8.10.6)
build-depends:
ghc-api-compat ==8.10.6
elif impl(ghc == 8.10.7)
build-depends:
ghc-api-compat ==8.10.7
elif impl(ghc == 9.0.1)
build-depends:
ghc-api-compat ==9.0.1

default-language: Haskell2010
default-extensions:
DataKinds
Expand Down
4 changes: 1 addition & 3 deletions stack-8.10.2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ extra-deps:
- data-tree-print-0.1.0.2@rev:2
- floskell-0.10.4
- fourmolu-0.3.0.0
- # ghc-api-compat-8.6
github: hsyl20/ghc-api-compat
commit: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15
- ghc-api-compat-8.6
- ghc-check-0.5.0.4
- ghc-exactprint-0.6.4
- ghc-lib-8.10.4.20210206
Expand Down
4 changes: 1 addition & 3 deletions stack-8.10.3.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ extra-deps:
- data-tree-print-0.1.0.2@rev:2
- floskell-0.10.4
- fourmolu-0.3.0.0
- # ghc-api-compat-8.6
github: hsyl20/ghc-api-compat
commit: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15
- ghc-api-compat-8.6
- ghc-check-0.5.0.4
- ghc-exactprint-0.6.4
- ghc-lib-8.10.4.20210206
Expand Down
4 changes: 1 addition & 3 deletions stack-8.10.4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,7 @@ extra-deps:
- data-tree-print-0.1.0.2@rev:2
- floskell-0.10.4
- fourmolu-0.3.0.0
- # ghc-api-compat-8.6
github: hsyl20/ghc-api-compat
commit: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15
- ghc-api-compat-8.6
- ghc-check-0.5.0.4
- ghc-exactprint-0.6.4
- ghc-source-gen-0.4.1.0
Expand Down
4 changes: 1 addition & 3 deletions stack-8.10.5.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,7 @@ extra-deps:
- data-tree-print-0.1.0.2@rev:2
- floskell-0.10.5
- fourmolu-0.3.0.0
- # ghc-api-compat-8.6
github: hsyl20/ghc-api-compat
commit: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15
- ghc-api-compat-8.10.5
- ghc-check-0.5.0.4
- ghc-exactprint-0.6.4
- ghc-source-gen-0.4.1.0
Expand Down
5 changes: 1 addition & 4 deletions stack-8.10.7.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ extra-deps:
- bytestring-encoding-0.1.1.0@sha256:1c3b97eb6345fd7153006211c8272215cd78bb0cf440c41185290822f1e3f2c2,1738
- data-tree-print-0.1.0.2@sha256:d845e99f322df70e0c06d6743bf80336f5918d5423498528beb0593a2afc1703,1620
- floskell-0.10.5@sha256:77f0bc1569573d9666b10975a5357fef631d32266c071733739393ccae521dab,3803
- ghc-api-compat-8.10.6@sha256:cde370b1b4c8a090de1ba6a8e27f65def9af43ca88710b412a6545b876568626,3324
- ghc-api-compat-8.10.7
- heapsize-0.3.0.1@sha256:0b69aa97a46d819b700ac7b145f3b5493c3565cf2c5b8298682238d405d0326e,1417
- hiedb-0.4.0.0@sha256:b6dadd5cefc8c1052bc4b29144f616ca9c22e863a96d8e447d66a4d32c96fd4a,2987
- implicit-hie-0.1.2.6@sha256:f50a908979a574a881f753c0f9a5224f023f438b30fdefc5b7fa01803b07a280,2998
Expand All @@ -55,9 +55,6 @@ extra-deps:
# - ghc-lib-parser-ex-9.0.0.4@sha256:8282b11c3797fc8ba225b245e736cc9a0745d9c48d0f9fea7f9bffb5c9997709,3642
# - hlint-3.3@sha256:4218ad6e03050f5d68aeba0e025f5f05e366c8fd49657f2a19df04ee31b2bb23,4154

# for ghc-api-compat-8.10.6
allow-newer: true

configure-options:
ghcide:
- --disable-library-for-ghci
Expand Down
4 changes: 1 addition & 3 deletions stack-8.6.4.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@ extra-deps:
- floskell-0.10.4
- fourmolu-0.3.0.0
- fuzzy-0.1.0.0
- # ghc-api-compat-8.6
github: hsyl20/ghc-api-compat
commit: 8fee87eac97a538dbe81ff1ab18cff10f2f9fa15
- ghc-api-compat-8.6
- ghc-check-0.5.0.4
- ghc-events-0.13.0
- ghc-exactprint-0.6.4
Expand Down
Loading

0 comments on commit a23b66c

Please sign in to comment.