Skip to content

Commit

Permalink
stack: update to 2.13.1, enable arm64
Browse files Browse the repository at this point in the history
  • Loading branch information
i0ntempest authored and kencu committed Nov 15, 2023
1 parent e006a37 commit a89ddb9
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 12 deletions.
4 changes: 2 additions & 2 deletions _resources/port1.0/group/haskell_stack-1.0.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ post-extract {
xinstall -m 0755 -d "[option haskell_stack.stack_root]"
}

# stack builds x86_64 binaries
supported_archs x86_64
# stack builds arm64 and x86_64 binaries
supported_archs arm64 x86_64

# libHSbase shipped with GHC links against system libiconv, which provides the
# 'iconv' symbol, but not the 'libiconv' symbol. Because the compilation
Expand Down
37 changes: 27 additions & 10 deletions lang/stack/Portfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ PortGroup gpg_verify 1.0
PortGroup haskell_stack 1.0
PortGroup legacysupport 1.1

github.setup commercialhaskell stack 2.9.1 v
github.setup commercialhaskell stack 2.13.1 v
revision 0

name stack
Expand All @@ -28,7 +28,11 @@ homepage https://haskellstack.org
variant prebuilt \
description {Do not bootstrap stack; install the pre-built binary.} {}

distname ${name}-${github.version}-osx-x86_64
if {${build_arch} eq "x86_64"} {
distname ${name}-${github.version}-osx-x86_64
} elseif {${build_arch} eq "arm64"} {
distname ${name}-${github.version}-osx-aarch64
}

worksrcdir ${name}-${github.version}

Expand All @@ -40,16 +44,27 @@ distfiles ${distname}-bin:release \

extract.only ${github.tag_prefix}${github.version}${extract.suffix}

checksums ${distname}-bin \
rmd160 1bef40f79e2ce2981fed55cd360adbb367f66c4d \
sha256 5b338fba3c679d9e4d3b3a8cd1ac6a9e55916755da22165554005f79fc7be3e2 \
size 32626208 \
${github.tag_prefix}${github.version}${extract.suffix} \
rmd160 ca4cd87ce2e03a65840747efc56286b8e662ce17 \
sha256 512d0188c195073d7c452f4b54ca005005ce7b865052a4856dc9975140051d9c \
size 767680 \
checksums ${github.tag_prefix}${github.version}${extract.suffix} \
rmd160 f85b9e6f33bb18bca9969be4a303f39c54eab53a \
sha256 00333782b1bda3bda02ca0c1bbc6becdd86e5a39f6448b0df788b634e1bde692 \
size 905625
if {${build_arch} eq "x86_64"} {
checksums-append \
${distname}-bin \
rmd160 d1129562844cfe67e0aa721af7ffae294ef1e33a \
sha256 99eb8d15420af85aa2df9636851b98edd426dcfcd870908d3dc21fd7a0ddb21e \
size 34298144 \
${distname}-bin.asc \
size 488
} elseif {${build_arch} eq "arm64"} {
checksums-append \
${distname}-bin \
rmd160 39e4a3b868ed9b2883a5e20c00b032795905f001 \
sha256 894b3daf7fb4bfe3d01edc966c2eabe4cfb2503973c1f62e7336f00a7068d13f \
size 103493328 \
${distname}-bin.asc \
size 488
}

gpg_verify.use_gpg_verification \
yes
Expand Down Expand Up @@ -117,5 +132,7 @@ if { [variant_isset "prebuilt"] } {
${workpath}/bin/${name}
}

depends_build-append port:pkgconfig

set haskell_stack.bin ${workpath}/bin/stack
}

0 comments on commit a89ddb9

Please sign in to comment.