Skip to content

Commit

Permalink
handle winpthreads
Browse files Browse the repository at this point in the history
  • Loading branch information
kit-ty-kate committed Oct 29, 2024
1 parent 0a48bf9 commit 1f92b27
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/scripts/main/ocaml-cache.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,12 @@ case "$HOST" in
esac

FLEXDLL_VERSION=0.43
MINGW_W64_VERSION=12.0.0

curl -sLO "https://github.com/ocaml/ocaml/archive/${OCAML_VERSION}.tar.gz"
if [[ $PLATFORM = 'Windows' ]] ; then
curl -sLO "https://github.com/ocaml/flexdll/archive/refs/tags/$FLEXDLL_VERSION.tar.gz"
curl -sLO "https://github.com/mingw-w64/mingw-w64/archive/refs/tags/v${MINGW_W64_VERSION}.tar.gz"
fi

tar -xzf "$OCAML_VERSION.tar.gz"
Expand All @@ -72,6 +74,11 @@ if [[ $PLATFORM = 'Windows' ]] ; then
tar -xzf ../$FLEXDLL_VERSION.tar.gz
rm -rf flexdll
mv "flexdll-$FLEXDLL_VERSION" flexdll

tar -xzf "../v${MINGW_W64_VERSION}.tar.gz"
rm -rf winpthreads
mv "mingw-w64-${MINGW_W64_VERSION}/mingw-w64-libraries/winpthreads" winpthreads
rm -rf "mingw-w64-${MINGW_W64_VERSION}"
fi

if [[ $PLATFORM = 'macOS' ]]; then
Expand Down

0 comments on commit 1f92b27

Please sign in to comment.