mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2025-06-29 04:39:53 +00:00
scripts: ghc version update (#4010)
This commit is contained in:
parent
76a33a3743
commit
35b7f2cb1c
6 changed files with 18 additions and 18 deletions
8
.github/workflows/build.yml
vendored
8
.github/workflows/build.yml
vendored
|
@ -55,22 +55,22 @@ jobs:
|
||||||
ghc: "8.10.7"
|
ghc: "8.10.7"
|
||||||
cache_path: ~/.cabal/store
|
cache_path: ~/.cabal/store
|
||||||
- os: ubuntu-20.04
|
- os: ubuntu-20.04
|
||||||
ghc: "9.6.3"
|
ghc: "9.6.4"
|
||||||
cache_path: ~/.cabal/store
|
cache_path: ~/.cabal/store
|
||||||
asset_name: simplex-chat-ubuntu-20_04-x86-64
|
asset_name: simplex-chat-ubuntu-20_04-x86-64
|
||||||
desktop_asset_name: simplex-desktop-ubuntu-20_04-x86_64.deb
|
desktop_asset_name: simplex-desktop-ubuntu-20_04-x86_64.deb
|
||||||
- os: ubuntu-22.04
|
- os: ubuntu-22.04
|
||||||
ghc: "9.6.3"
|
ghc: "9.6.4"
|
||||||
cache_path: ~/.cabal/store
|
cache_path: ~/.cabal/store
|
||||||
asset_name: simplex-chat-ubuntu-22_04-x86-64
|
asset_name: simplex-chat-ubuntu-22_04-x86-64
|
||||||
desktop_asset_name: simplex-desktop-ubuntu-22_04-x86_64.deb
|
desktop_asset_name: simplex-desktop-ubuntu-22_04-x86_64.deb
|
||||||
- os: macos-latest
|
- os: macos-latest
|
||||||
ghc: "9.6.3"
|
ghc: "9.6.4"
|
||||||
cache_path: ~/.cabal/store
|
cache_path: ~/.cabal/store
|
||||||
asset_name: simplex-chat-macos-x86-64
|
asset_name: simplex-chat-macos-x86-64
|
||||||
desktop_asset_name: simplex-desktop-macos-x86_64.dmg
|
desktop_asset_name: simplex-desktop-macos-x86_64.dmg
|
||||||
- os: windows-latest
|
- os: windows-latest
|
||||||
ghc: "9.6.3"
|
ghc: "9.6.4"
|
||||||
cache_path: C:/cabal
|
cache_path: C:/cabal
|
||||||
asset_name: simplex-chat-windows-x86-64
|
asset_name: simplex-chat-windows-x86-64
|
||||||
desktop_asset_name: simplex-desktop-windows-x86_64.msi
|
desktop_asset_name: simplex-desktop-windows-x86_64.msi
|
||||||
|
|
|
@ -8,7 +8,7 @@ FROM ubuntu:${TAG} AS build
|
||||||
RUN apt-get update && apt-get install -y curl git build-essential libgmp3-dev zlib1g-dev llvm-12 llvm-12-dev libnuma-dev libssl-dev
|
RUN apt-get update && apt-get install -y curl git build-essential libgmp3-dev zlib1g-dev llvm-12 llvm-12-dev libnuma-dev libssl-dev
|
||||||
|
|
||||||
# Specify bootstrap Haskell versions
|
# Specify bootstrap Haskell versions
|
||||||
ENV BOOTSTRAP_HASKELL_GHC_VERSION=9.6.3
|
ENV BOOTSTRAP_HASKELL_GHC_VERSION=9.6.4
|
||||||
ENV BOOTSTRAP_HASKELL_CABAL_VERSION=3.10.1.0
|
ENV BOOTSTRAP_HASKELL_CABAL_VERSION=3.10.1.0
|
||||||
|
|
||||||
# Install ghcup
|
# Install ghcup
|
||||||
|
|
|
@ -102,7 +102,7 @@ DOCKER_BUILDKIT=1 docker build --output ~/.local/bin .
|
||||||
|
|
||||||
#### In any OS
|
#### In any OS
|
||||||
|
|
||||||
1. Install [Haskell GHCup](https://www.haskell.org/ghcup/), GHC 9.6.3 and cabal 3.10.1.0:
|
1. Install [Haskell GHCup](https://www.haskell.org/ghcup/), GHC 9.6.4 and cabal 3.10.1.0:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh
|
curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh
|
||||||
|
|
|
@ -30,13 +30,13 @@ You will have to add `/opt/homebrew/opt/openssl@1.1/bin` to your PATH in order t
|
||||||
|
|
||||||
**In simplex-chat repo**
|
**In simplex-chat repo**
|
||||||
|
|
||||||
- `stable` - stable release of the apps, can be used for updates to the previous stable release (GHC 9.6.3).
|
- `stable` - stable release of the apps, can be used for updates to the previous stable release (GHC 9.6.4).
|
||||||
|
|
||||||
- `stable-android` - used to build stable Android core library with Nix (GHC 8.10.7) - only for Android armv7a.
|
- `stable-android` - used to build stable Android core library with Nix (GHC 8.10.7) - only for Android armv7a.
|
||||||
|
|
||||||
- `stable-ios` - used to build stable iOS core library with Nix (GHC 8.10.7) – this branch should be the same as `stable-android` except Nix configuration files. Deprecated.
|
- `stable-ios` - used to build stable iOS core library with Nix (GHC 8.10.7) – this branch should be the same as `stable-android` except Nix configuration files. Deprecated.
|
||||||
|
|
||||||
- `master` - branch for beta version releases (GHC 9.6.3).
|
- `master` - branch for beta version releases (GHC 9.6.4).
|
||||||
|
|
||||||
- `master-ghc8107` - branch for beta version releases (GHC 8.10.7). Deprecated.
|
- `master-ghc8107` - branch for beta version releases (GHC 8.10.7). Deprecated.
|
||||||
|
|
||||||
|
@ -50,7 +50,7 @@ You will have to add `/opt/homebrew/opt/openssl@1.1/bin` to your PATH in order t
|
||||||
|
|
||||||
**In simplexmq repo**
|
**In simplexmq repo**
|
||||||
|
|
||||||
- `master` - uses GHC 9.6.3 its commit should be used in `master` branch of simplex-chat repo.
|
- `master` - uses GHC 9.6.4 its commit should be used in `master` branch of simplex-chat repo.
|
||||||
|
|
||||||
- `master-ghc8107` - its commit should be used in `master-android` (and `master-ios`) branch of simplex-chat repo. Deprecated.
|
- `master-ghc8107` - its commit should be used in `master-android` (and `master-ios`) branch of simplex-chat repo. Deprecated.
|
||||||
|
|
||||||
|
@ -77,28 +77,28 @@ You will have to add `/opt/homebrew/opt/openssl@1.1/bin` to your PATH in order t
|
||||||
7. Independently, `master` branch of simplexmq repo should be merged to `stable` branch on stable releases.
|
7. Independently, `master` branch of simplexmq repo should be merged to `stable` branch on stable releases.
|
||||||
|
|
||||||
|
|
||||||
## Differences between GHC 8.10.7 and GHC 9.6.3
|
## Differences between GHC 8.10.7 and GHC 9.6.4
|
||||||
|
|
||||||
1. The main difference is related to `DuplicateRecordFields` extension.
|
1. The main difference is related to `DuplicateRecordFields` extension.
|
||||||
|
|
||||||
It is no longer possible in GHC 9.6.3 to specify type when using selectors, instead OverloadedRecordDot extension and syntax are used that need to be removed in GHC 8.10.7:
|
It is no longer possible in GHC 9.6.4 to specify type when using selectors, instead OverloadedRecordDot extension and syntax are used that need to be removed in GHC 8.10.7:
|
||||||
|
|
||||||
```haskell
|
```haskell
|
||||||
{-# LANGUAGE DuplicateRecordFields #-}
|
{-# LANGUAGE DuplicateRecordFields #-}
|
||||||
-- use this in GHC 9.6.3 when needed
|
-- use this in GHC 9.6.4 when needed
|
||||||
{-# LANGUAGE OverloadedRecordDot #-}
|
{-# LANGUAGE OverloadedRecordDot #-}
|
||||||
|
|
||||||
-- GHC 9.6.3 syntax
|
-- GHC 9.6.4 syntax
|
||||||
let x = record.field
|
let x = record.field
|
||||||
|
|
||||||
-- GHC 8.10.7 syntax removed in GHC 9.6.3
|
-- GHC 8.10.7 syntax absent in GHC 9.6.4
|
||||||
let x = field (record :: Record)
|
let x = field (record :: Record)
|
||||||
```
|
```
|
||||||
|
|
||||||
It is still possible to specify type when using record update syntax, use this pragma to suppress compiler warning:
|
It is still possible to specify type when using record update syntax, use this pragma to suppress compiler warning:
|
||||||
|
|
||||||
```haskell
|
```haskell
|
||||||
-- use this in GHC 9.6.3 when needed
|
-- use this in GHC 9.6.4 when needed
|
||||||
{-# OPTIONS_GHC -fno-warn-ambiguous-fields #-}
|
{-# OPTIONS_GHC -fno-warn-ambiguous-fields #-}
|
||||||
|
|
||||||
let r' = (record :: Record) {field = value}
|
let r' = (record :: Record) {field = value}
|
||||||
|
@ -107,7 +107,7 @@ let r' = (record :: Record) {field = value}
|
||||||
2. Most monad functions now have to be imported from `Control.Monad`, and not from specific monad modules (e.g. `Control.Monad.Except`).
|
2. Most monad functions now have to be imported from `Control.Monad`, and not from specific monad modules (e.g. `Control.Monad.Except`).
|
||||||
|
|
||||||
```haskell
|
```haskell
|
||||||
-- use this in GHC 9.6.3 when needed
|
-- use this in GHC 9.6.4 when needed
|
||||||
import Control.Monad
|
import Control.Monad
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ function readlink() {
|
||||||
|
|
||||||
OS=linux
|
OS=linux
|
||||||
ARCH=${1:-`uname -a | rev | cut -d' ' -f2 | rev`}
|
ARCH=${1:-`uname -a | rev | cut -d' ' -f2 | rev`}
|
||||||
GHC_VERSION=9.6.3
|
GHC_VERSION=9.6.4
|
||||||
|
|
||||||
if [ "$ARCH" == "aarch64" ]; then
|
if [ "$ARCH" == "aarch64" ]; then
|
||||||
COMPOSE_ARCH=arm64
|
COMPOSE_ARCH=arm64
|
||||||
|
|
|
@ -5,7 +5,7 @@ set -e
|
||||||
OS=mac
|
OS=mac
|
||||||
ARCH="${1:-`uname -a | rev | cut -d' ' -f1 | rev`}"
|
ARCH="${1:-`uname -a | rev | cut -d' ' -f1 | rev`}"
|
||||||
COMPOSE_ARCH=$ARCH
|
COMPOSE_ARCH=$ARCH
|
||||||
GHC_VERSION=9.6.3
|
GHC_VERSION=9.6.4
|
||||||
|
|
||||||
if [ "$ARCH" == "arm64" ]; then
|
if [ "$ARCH" == "arm64" ]; then
|
||||||
ARCH=aarch64
|
ARCH=aarch64
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue