Skip to content

Commit

Permalink
contrib/release/build.sh: add recipe for mingw-w64-gcc-13.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jayrm committed Jan 1, 2024
1 parent 957b06f commit f2ca746
Showing 1 changed file with 48 additions and 17 deletions.
65 changes: 48 additions & 17 deletions contrib/release/build.sh
Expand Up @@ -67,6 +67,7 @@
# * -gcc-8.1.0 (mingw-w64 project)
# * -gcc-11.2.0 (mingw-w64 project)
# -gcc-12.2.0 (mingw-w64 project)
# -gcc-13.2.0 (mingw-w64 project)
# * -winlibs-gcc-9.3.0 (winlibs mingwrt 7.0.0r3 - sjlj)
# -winlibs-gcc-11.2.0 (winlibs mingwrt 10.0.0r1 - msvcrt)
# -winlibs-gcc-11.3.0 (winlibs mingwrt 10.0.0r3 - msvcrt)
Expand Down Expand Up @@ -114,7 +115,7 @@ usage() {
echo " --remote name specify the name to use for the alternate remote"
echo " --recipe name specify a build recipe to use"
echo " --use-libffi-cache"
echo " don't build libffi, just use the chaced files"
echo " don't build libffi, just use the cached files"
exit 1
}

Expand Down Expand Up @@ -502,6 +503,17 @@ get_nixman_toolchain() {
default_rt=rt

case "$named_recipe" in
-mingw-w64-gcc-13.2.0|-gcc-13.2.0)
gccversion=13.2.0
mingwbuildsrev=rev1
mingwruntime=v11
if [ "$bits" = "32" ]; then
default_eh=dwarf
else
default_eh=seh
fi
default_rt=msvcrt-rt
;;
-mingw-w64-gcc-12.2.0|-gcc-12.2.0)
gccversion=12.2.0
mingwbuildsrev=rev2
Expand Down Expand Up @@ -548,7 +560,7 @@ get_windows_toolchain() {
-equation-*)
get_equation_toolchain $bits $arch
;;
-mingw-w64-gcc-11.2.0|-gcc-11.2.0|-mingw-w64-gcc-12.2.0|-gcc-12.2.0)
-mingw-w64-gcc-11.2.0|-gcc-11.2.0|-mingw-w64-gcc-12.2.0|-gcc-12.2.0|-mingw-w64-gcc-13.2.0|-gcc-13.2.0)
get_nixman_toolchain $bits $arch
;;
-mingw-w64-gcc-*|-gcc-*)
Expand Down Expand Up @@ -725,30 +737,49 @@ linux*)
;;
esac

# libffi-3.2.1
# mingw-w64-gcc-5.2
# mingw-w64-gcc-8.1

# libffi-3.3
# winlibs-gcc-9.3.0

# libffi-3.4.4
# mingw-w64-gcc-11.2.0
# mingw-w64-gcc-12.2.0
# mingw-w64-gcc-13.2.0

case "$named_recipe" in
# older mingw-w64 packages are distributed with headers for libffi-3.2.1
# but libffi-3.3 below should work for them also
#-mingw-w64-gcc-5.2.0|-gcc-5.2.0|-mingw-w64-gcc-8.1.0|-gcc-8.1.0)
# # libffi sources https://github.com/libffi/libffi/releases/download/v3.3/libffi-3.2.1.tar.gz.
# libffi_version="3.2.1"
# libffi_dir="https://github.com/libffi/libffi/releases/download/v${libffi_version}"
# ;;
-winlibs-gcc-9.3.0)
# - https://github.com/libffi/libffi/releases/download/v3.3/libffi-3.3.tar.gz.
libffi_version="3.3"
libffi_dir="https://github.com/libffi/libffi/releases/download/v${libffi_version}"
;;
*)
# - https://github.com/libffi/libffi/releases/download/v3.4.4/libffi-3.4.4.tar.gz
libffi_version="3.4.4"
libffi_dir="https://github.com/libffi/libffi/releases/download/v${libffi_version}"
;;
esac

case $fbtarget in
win32)
# libffi sources https://github.com/libffi/libffi/releases/download/v3.3/libffi-3.3.tar.gz.
libffi_title=libffi-3.3
libffi_title=libffi-${libffi_version}
libffi_package="${libffi_title}.tar.gz"
download "$libffi_package" "ftp://sourceware.org/pub/libffi/$libffi_package"
download "$libffi_package" "${libffi_dir}/$libffi_package"
echo "extracting $libffi_package"
tar xf "../input/$libffi_package"
;;

win64)
# libffi sources:
# - ftp://sourceware.org/pub/libffi/libffi-3.4.3.tar.gz
# - https://github.com/libffi/libffi/releases/download/v3.4.4/libffi-3.4.4.tar.gz
libffi_version=3.4.4
libffi_title=libffi-${libffi_version}
libffi_package="${libffi_title}.tar.gz"

# sourware:
# libffi_dir="ftp://sourceware.org/pub/libffi/"

# github:
libffi_dir="https://github.com/libffi/libffi/releases/download/v${libffi_version}/"

download "$libffi_package" "${libffi_dir}${libffi_package}"
echo "extracting ${libffi_package}"
tar xf "../input/${libffi_package}"
Expand Down

0 comments on commit f2ca746

Please sign in to comment.