Add i386 ghcup binary

This commit is contained in:
Julian Ospald 2020-04-13 15:22:16 +02:00
parent c40b9dbc0b
commit 28a1077833
No known key found for this signature in database
GPG Key ID: 511B62C09D50CD28
2 changed files with 39 additions and 11 deletions

View File

@ -984,6 +984,13 @@ cabal_3200_64_darwin = DownloadInfo
------------- -------------
ghcup_010_32_linux :: DownloadInfo
ghcup_010_32_linux = DownloadInfo
[uri|https://github.com/hasufell/ghcup-hs/releases/download/v0.1.0/i386-linux-ghcup-0.1.0|]
Nothing
"ce95fd3044ea249c2ea02e122112a787d710cc4be2dcf1e78d8c68b540a70920"
ghcup_010_64_linux :: DownloadInfo ghcup_010_64_linux :: DownloadInfo
ghcup_010_64_linux = DownloadInfo ghcup_010_64_linux = DownloadInfo
[uri|https://github.com/hasufell/ghcup-hs/releases/download/v0.1.0/x86_64-linux-ghcup-0.1.0|] [uri|https://github.com/hasufell/ghcup-hs/releases/download/v0.1.0/x86_64-linux-ghcup-0.1.0|]
@ -1892,6 +1899,10 @@ ghcupDownloads = M.fromList
, (FreeBSD, M.fromList [(Nothing, ghcup_010_64_freebsd)]) , (FreeBSD, M.fromList [(Nothing, ghcup_010_64_freebsd)])
] ]
) )
, ( A_32
, M.fromList
[(Linux UnknownLinux, M.fromList [(Nothing, ghcup_010_32_linux)])]
)
] ]
) )
] ]

View File

@ -27,6 +27,20 @@ download_ghcup() {
_plat="$(uname -s)" _plat="$(uname -s)"
_arch=$(uname -m) _arch=$(uname -m)
case "${_plat}" in
"linux"|"Linux")
case "${_arch}" in
x86_64|amd64)
_url=https://www.haskell.org/ghcup/bin/x86_64-linux-ghcup
;;
i*86)
_url=https://www.haskell.org/ghcup/bin/i386-linux-ghcup
;;
*) die "Unknown architecture: ${_arch}"
;;
esac
;;
"FreeBSD"|"freebsd")
case "${_arch}" in case "${_arch}" in
x86_64|amd64) x86_64|amd64)
;; ;;
@ -36,15 +50,18 @@ download_ghcup() {
*) die "Unknown architecture: ${_arch}" *) die "Unknown architecture: ${_arch}"
;; ;;
esac esac
case "${_plat}" in
"linux"|"Linux")
_url=https://www.haskell.org/ghcup/bin/x86_64-linux-ghcup
;;
"FreeBSD"|"freebsd")
_url=https://www.haskell.org/ghcup/bin/x86_64-portbld-freebsd-ghcup _url=https://www.haskell.org/ghcup/bin/x86_64-portbld-freebsd-ghcup
;; ;;
"Darwin"|"darwin") "Darwin"|"darwin")
case "${_arch}" in
x86_64|amd64)
;;
i*86)
die "i386 currently not supported!"
;;
*) die "Unknown architecture: ${_arch}"
;;
esac
case "$(sw_vers -productVersion || echo "none")" in case "$(sw_vers -productVersion || echo "none")" in
10.15.*) _url=https://www.haskell.org/ghcup/bin/x86_64-apple-darwin-10.14-ghcup ;; 10.15.*) _url=https://www.haskell.org/ghcup/bin/x86_64-apple-darwin-10.14-ghcup ;;
10.14.*) _url=https://www.haskell.org/ghcup/bin/x86_64-apple-darwin-10.14-ghcup ;; 10.14.*) _url=https://www.haskell.org/ghcup/bin/x86_64-apple-darwin-10.14-ghcup ;;