diff --git a/.github/workflows/bootstrap.yaml b/.github/workflows/bootstrap.yaml index c8144dfe..216d740f 100644 --- a/.github/workflows/bootstrap.yaml +++ b/.github/workflows/bootstrap.yaml @@ -25,7 +25,7 @@ jobs: include: - os: ubuntu-latest DISTRO: Ubuntu - - os: macOS-12 + - os: macOS-13 DISTRO: na - os: windows-latest DISTRO: na diff --git a/.github/workflows/cabal.project.yaml b/.github/workflows/cabal.project.yaml index 79871d92..6bd27c2a 100644 --- a/.github/workflows/cabal.project.yaml +++ b/.github/workflows/cabal.project.yaml @@ -19,7 +19,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macOS-12, windows-latest, ubuntu-latest] + os: [macOS-13, windows-latest, ubuntu-latest] ghc: ["8.10.7", "9.0.2", "9.2.8", "9.4.8", "9.6.6"] include: - os: macOS-latest diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 8940cc13..edc1e187 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -169,7 +169,7 @@ jobs: ARTIFACT: "aarch64-apple-darwin-ghcup" GHC_VER: 9.6.6 ARCH: ARM64 - - os: macOS-12 + - os: macOS-13 ARTIFACT: "x86_64-apple-darwin-ghcup" GHC_VER: 9.6.6 ARCH: 64 @@ -431,7 +431,7 @@ jobs: GHC_VER: 9.6.6 ARCH: ARM64 DISTRO: na - - os: macOS-12 + - os: macOS-13 ARTIFACT: "x86_64-apple-darwin-ghcup" GHC_VER: 9.6.6 ARCH: 64 diff --git a/.github/workflows/stack.yaml b/.github/workflows/stack.yaml index a43644fa..2e231d60 100644 --- a/.github/workflows/stack.yaml +++ b/.github/workflows/stack.yaml @@ -19,7 +19,7 @@ jobs: strategy: fail-fast: false matrix: - os: [macOS-latest, macOS-12, windows-latest, ubuntu-latest] + os: [macOS-latest, macOS-13, windows-latest, ubuntu-latest] steps: - name: Checkout code uses: actions/checkout@v4 diff --git a/cabal.ghc8107.Unix.project.freeze b/cabal.ghc8107.Unix.project.freeze index a00c319c..b1ca2e78 100644 --- a/cabal.ghc8107.Unix.project.freeze +++ b/cabal.ghc8107.Unix.project.freeze @@ -228,4 +228,4 @@ constraints: any.Cabal ==3.10.3.0, any.zlib ==0.6.3.0, zlib -bundled-c-zlib -non-blocking-ffi -pkg-config, any.zlib-bindings ==0.1.1.5 -index-state: hackage.haskell.org 2024-08-25T14:11:43Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc8107.Win32.project.freeze b/cabal.ghc8107.Win32.project.freeze index 7359f7b5..f2256c91 100644 --- a/cabal.ghc8107.Win32.project.freeze +++ b/cabal.ghc8107.Win32.project.freeze @@ -213,4 +213,4 @@ constraints: any.Cabal ==3.10.3.0, yaml +no-examples +no-exe, any.zlib ==0.6.3.0, zlib +bundled-c-zlib -non-blocking-ffi -pkg-config -index-state: hackage.haskell.org 2024-08-27T01:59:55Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc902.Unix.project.freeze b/cabal.ghc902.Unix.project.freeze index ad4cdd30..261570ee 100644 --- a/cabal.ghc902.Unix.project.freeze +++ b/cabal.ghc902.Unix.project.freeze @@ -233,4 +233,4 @@ constraints: any.Cabal ==3.10.3.0, any.zlib-bindings ==0.1.1.5, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-25T14:11:43Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc902.Win32.project.freeze b/cabal.ghc902.Win32.project.freeze index 61a75d27..dd95b2fd 100644 --- a/cabal.ghc902.Win32.project.freeze +++ b/cabal.ghc902.Win32.project.freeze @@ -219,4 +219,4 @@ constraints: any.Cabal ==3.10.3.0, zlib +bundled-c-zlib -non-blocking-ffi -pkg-config, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-27T01:59:55Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc928.Unix.project.freeze b/cabal.ghc928.Unix.project.freeze index b388c1d4..c6f53f31 100644 --- a/cabal.ghc928.Unix.project.freeze +++ b/cabal.ghc928.Unix.project.freeze @@ -233,4 +233,4 @@ constraints: any.Cabal ==3.10.3.0, any.zlib-bindings ==0.1.1.5, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-25T14:11:43Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc928.Win32.project.freeze b/cabal.ghc928.Win32.project.freeze index d70ffbbe..09b8a363 100644 --- a/cabal.ghc928.Win32.project.freeze +++ b/cabal.ghc928.Win32.project.freeze @@ -219,4 +219,4 @@ constraints: any.Cabal ==3.10.3.0, zlib +bundled-c-zlib -non-blocking-ffi -pkg-config, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-27T01:59:55Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc948.Unix.project.freeze b/cabal.ghc948.Unix.project.freeze index 942f7efc..c68ee2cd 100644 --- a/cabal.ghc948.Unix.project.freeze +++ b/cabal.ghc948.Unix.project.freeze @@ -231,4 +231,4 @@ constraints: any.Cabal ==3.10.3.0, any.zlib-bindings ==0.1.1.5, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-25T14:11:43Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc948.Win32.project.freeze b/cabal.ghc948.Win32.project.freeze index 0de4392c..1c85cf74 100644 --- a/cabal.ghc948.Win32.project.freeze +++ b/cabal.ghc948.Win32.project.freeze @@ -217,4 +217,4 @@ constraints: any.Cabal ==3.10.3.0, zlib +bundled-c-zlib -non-blocking-ffi -pkg-config, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-27T01:59:55Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc966.Unix.project.freeze b/cabal.ghc966.Unix.project.freeze index 03065839..bf459de7 100644 --- a/cabal.ghc966.Unix.project.freeze +++ b/cabal.ghc966.Unix.project.freeze @@ -228,4 +228,4 @@ constraints: any.Cabal ==3.10.3.0, any.zlib-bindings ==0.1.1.5, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-25T14:11:43Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.ghc966.Win32.project.freeze b/cabal.ghc966.Win32.project.freeze index 4089446d..dbd8f70e 100644 --- a/cabal.ghc966.Win32.project.freeze +++ b/cabal.ghc966.Win32.project.freeze @@ -214,4 +214,4 @@ constraints: any.Cabal ==3.10.3.0, zlib +bundled-c-zlib -non-blocking-ffi -pkg-config, any.zstd ==0.1.3.0, zstd +standalone -index-state: hackage.haskell.org 2024-08-27T01:59:55Z +index-state: hackage.haskell.org 2024-11-15T05:14:10Z diff --git a/cabal.project b/cabal.project index d65a3fc0..6eff5907 100644 --- a/cabal.project +++ b/cabal.project @@ -1,4 +1,4 @@ -packages: ./ghcup.cabal +import: cabal.project.common optional-packages: ./vendored/*/*.cabal @@ -9,44 +9,5 @@ else package ghcup flags: +tui +tar -constraints: http-io-streams -brotli, - any.aeson >= 2.0.1.0, - any.hsc2hs >=0.68.10, - bzlib-conduit >= 0.3.0.3, - bz2 >= 1.0.1.1, - bzlib >= 0.5.2.0, - directory >= 1.3.8.3, - filepath == 1.4.101.0 || == 1.4.300.1 || >= 1.5.2.0, - tar >= 0.6.2.0 - -constraints: text -simdutf - -if os(mingw32) - constraints: zlib +bundled-c-zlib, - lzma +static, - text -simdutf, - vty-windows >=0.2.0.2 - - if impl(ghc >= 9.4) - constraints: language-c >= 0.9.3 - - -source-repository-package - type: git - location: https://github.com/hasufell/uri-bytestring.git - tag: 4fb5ed14b500c192e6e7a97f6b2b1eb478806001 - -package libarchive - flags: -system-libarchive - -package aeson-pretty - flags: +lib-only - -package aeson - flags: +ordered-keymap - -package hashable - flags: -arch-native - package * test-show-details: direct diff --git a/cabal.project.common b/cabal.project.common new file mode 100644 index 00000000..f815df25 --- /dev/null +++ b/cabal.project.common @@ -0,0 +1,39 @@ +packages: ./ghcup.cabal + +constraints: http-io-streams -brotli, + any.aeson >= 2.0.1.0, + any.hsc2hs >=0.68.10, + bzlib-conduit >= 0.3.0.3, + bz2 >= 1.0.1.1, + bzlib >= 0.5.2.0, + directory >= 1.3.8.3, + filepath == 1.4.101.0 || == 1.4.300.1 || >= 1.5.2.0, + tar >= 0.6.2.0 + +constraints: text -simdutf + +if os(mingw32) + constraints: zlib +bundled-c-zlib, + text -simdutf, + vty-windows >=0.2.0.2 + + if impl(ghc >= 9.4) + constraints: language-c >= 0.9.3 + + +source-repository-package + type: git + location: https://github.com/hasufell/uri-bytestring.git + tag: 4fb5ed14b500c192e6e7a97f6b2b1eb478806001 + +package libarchive + flags: -system-libarchive + +package aeson-pretty + flags: +lib-only + +package aeson + flags: +ordered-keymap + +package hashable + flags: -arch-native diff --git a/cabal.project.release b/cabal.project.release index 5adf9cae..0acb162e 100644 --- a/cabal.project.release +++ b/cabal.project.release @@ -1,4 +1,4 @@ -import: cabal.project +import: cabal.project.common optimization: 2 @@ -6,17 +6,29 @@ optimization: 2 -- The tar flag is only there to circumvent complicated errors during -- development, which sometimes happens due to libarchive. package ghcup - flags: +tui -tar + flags: +tui if os(linux) + constraints: xz -system-xz if arch(x86_64) || arch(i386) + flags: -tar package * ghc-options: -split-sections -optl-static + elif arch(arm) + flags: +tar + else + flags: -tar elif os(darwin) + flags: -tar constraints: zlib +bundled-c-zlib, - lzma +static + xz -system-xz +elif os(mingw32) + flags: -tar + constraints: xz -system-xz elif os(freebsd) + flags: -tar constraints: zlib +bundled-c-zlib, - zip +disable-zstd + zip +disable-zstd, + xz -system-xz package * ghc-options: -split-sections diff --git a/docker/alpine32/Dockerfile b/docker/alpine32/Dockerfile index 6c2a412d..4e424457 100644 --- a/docker/alpine32/Dockerfile +++ b/docker/alpine32/Dockerfile @@ -49,7 +49,7 @@ RUN gpg --batch --keyserver keys.openpgp.org --recv-keys $GPG_KEY && \ sha256sum -c --ignore-missing SHA256SUMS && \ mv i386-linux-ghcup-$GHCUP_VERSION /usr/bin/ghcup && \ chmod +x /usr/bin/ghcup && \ - rm -rf SHA256SUMS SHA256SUMS.sig + rm -rf SHA256SUMS SHA256SUMS.sig ~/.gnupg/public-keys.d/pubring.db.lock ARG GHC=9.4.8 ARG CABAL_INSTALL=3.10.2.0 diff --git a/docker/alpine64/Dockerfile b/docker/alpine64/Dockerfile index fd55f501..16d22099 100644 --- a/docker/alpine64/Dockerfile +++ b/docker/alpine64/Dockerfile @@ -50,7 +50,7 @@ RUN gpg --batch --keyserver keys.openpgp.org --recv-keys $GPG_KEY && \ sha256sum -c --ignore-missing SHA256SUMS && \ mv x86_64-linux-ghcup-$GHCUP_VERSION /usr/bin/ghcup && \ chmod +x /usr/bin/ghcup && \ - rm -rf SHA256SUMS SHA256SUMS.sig + rm -rf SHA256SUMS SHA256SUMS.sig ~/.gnupg/public-keys.d/pubring.db.lock ARG GHC=9.4.8 ARG CABAL_INSTALL=3.10.2.0 diff --git a/ghcup.cabal b/ghcup.cabal index b0708ab8..6e97f168 100644 --- a/ghcup.cabal +++ b/ghcup.cabal @@ -204,7 +204,7 @@ library , filepath >=1.4.101.0 , file-uri ^>=0.1.0.0 , variant ^>=1.0 - , lzma-static ^>=5.2.5.3 + , xz ^>=5.6.3 , megaparsec >=8.0.0 && <9.3 , mtl ^>=2.2 || ^>=2.3 , optics ^>=0.4 diff --git a/stack.yaml b/stack.yaml index 968dbcda..313ca0e1 100644 --- a/stack.yaml +++ b/stack.yaml @@ -37,6 +37,8 @@ extra-deps: - vty-crossplatform-0.4.0.0@sha256:50593f91ad16777d921138475a8d2784d538fd206addd30664c620278d6c8544,3172 - vty-unix-0.2.0.0@sha256:2af3d0bdae3c4b7b7e567ee374efe32c7439fabdf9096465ce011a6c6736e9ae,2932 - vty-windows-0.2.0.2 + - xz-5.6.3 + - xz-clib-5.6.3 - github: hasufell/uri-bytestring commit: 4fb5ed14b500c192e6e7a97f6b2b1eb478806001 @@ -55,6 +57,9 @@ flags: libarchive: system-libarchive: false + xz: + system-xz: false + regex-posix: _regex-posix-clib: true