Skip to content

Commit

Permalink
Add MSYS2 triplet
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexpux authored and dscho committed Feb 27, 2024
1 parent a574428 commit 466f9bc
Show file tree
Hide file tree
Showing 16 changed files with 93 additions and 81 deletions.
4 changes: 2 additions & 2 deletions compile
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func_file_conv ()
MINGW*)
file_conv=mingw
;;
CYGWIN*)
CYGWIN*|MSYS*)
file_conv=cygwin
;;
*)
Expand All @@ -67,7 +67,7 @@ func_file_conv ()
mingw/*)
file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
;;
cygwin/*)
cygwin/*|msys/*)
file=`cygpath -m "$file" || echo "$file"`
;;
wine/*)
Expand Down
3 changes: 3 additions & 0 deletions config.guess
Original file line number Diff line number Diff line change
Expand Up @@ -914,6 +914,9 @@ EOF
amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
echo x86_64-pc-cygwin
exit ;;
amd64:MSYS*:*:* | x86_64:MSYS*:*:*)
echo x86_64-unknown-msys
exit ;;
prep*:SunOS:5.*:*)
echo powerpcle-unknown-solaris2"$(echo "$UNAME_RELEASE"|sed -e 's/[^.]*//')"
exit ;;
Expand Down
8 changes: 4 additions & 4 deletions config.rpath
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ hardcode_direct=no
hardcode_minus_L=no

case "$host_os" in
cygwin* | mingw* | pw32*)
cygwin* | msys* | mingw* | pw32*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
Expand Down Expand Up @@ -149,7 +149,7 @@ if test "$with_gnu_ld" = yes; then
ld_shlibs=no
fi
;;
cygwin* | mingw* | pw32*)
cygwin* | msys* | mingw* | pw32*)
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
hardcode_libdir_flag_spec='-L$libdir'
Expand Down Expand Up @@ -268,7 +268,7 @@ else
;;
bsdi4*)
;;
cygwin* | mingw* | pw32*)
cygwin* | msys* | mingw* | pw32*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# hardcode_libdir_flag_spec is actually meaningless, as there is
Expand Down Expand Up @@ -437,7 +437,7 @@ case "$host_os" in
;;
bsdi4*)
;;
cygwin* | mingw* | pw32*)
cygwin* | msys* | mingw* | pw32*)
shrext=.dll
;;
darwin* | rhapsody*)
Expand Down
3 changes: 2 additions & 1 deletion config/dfp.m4
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ Valid choices are 'yes', 'bid', 'dpd', and 'no'.]) ;;
powerpc*-*-linux* | i?86*-*-linux* | x86_64*-*-linux* | s390*-*-linux* | \
i?86*-*-elfiamcu | i?86*-*-gnu* | \
i?86*-*-mingw* | x86_64*-*-mingw* | \
i?86*-*-cygwin* | x86_64*-*-cygwin*)
i?86*-*-cygwin* | x86_64*-*-cygwin* | \
i?86*-*-msys* | x86_64*-*-msys*)
enable_decimal_float=yes
;;
*)
Expand Down
2 changes: 1 addition & 1 deletion config/elf.m4
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ AC_REQUIRE([AC_CANONICAL_TARGET])
target_elf=no
case $target in
*-darwin* | *-aix* | *-cygwin* | *-mingw* | *-aout* | *-*coff* | \
*-darwin* | *-aix* | *-cygwin* | *-msys* | *-mingw* | *-aout* | *-*coff* | \
*-msdosdjgpp* | *-vms* | *-wince* | *-*-pe* | \
alpha*-dec-osf* | hppa[[12]]*-*-hpux* | \
nvptx-*-none)
Expand Down
2 changes: 1 addition & 1 deletion config/lthostflags.m4
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ AC_DEFUN([ACX_LT_HOST_FLAGS], [
AC_REQUIRE([AC_CANONICAL_SYSTEM])
case $host in
*-cygwin* | *-mingw*)
*-cygwin* | *-msys* | *-mingw*)
# 'host' will be top-level target in the case of a target lib,
# we must compare to with_cross_host to decide if this is a native
# or cross-compiler and select where to install dlls appropriately.
Expand Down
4 changes: 2 additions & 2 deletions config/mmap.m4
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ else
# Systems known to be in this category are Windows (all variants),
# VMS, and Darwin.
case "$host_os" in
*vms* | cygwin* | pe | mingw* | darwin* | ultrix* | hpux10* | hpux11.00)
*vms* | cygwin* | msys* | pe | mingw* | darwin* | ultrix* | hpux10* | hpux11.00)
gcc_cv_func_mmap_dev_zero=no ;;
*)
gcc_cv_func_mmap_dev_zero=yes;;
Expand Down Expand Up @@ -74,7 +74,7 @@ else
# above for use of /dev/zero.
# Systems known to be in this category are Windows, VMS, and SCO Unix.
case "$host_os" in
*vms* | cygwin* | pe | mingw* | sco* | udk* )
*vms* | cygwin* | msys* | pe | mingw* | sco* | udk* )
gcc_cv_func_mmap_anon=no ;;
*)
gcc_cv_func_mmap_anon=yes;;
Expand Down
2 changes: 2 additions & 0 deletions config/picflag.m4
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ case "${$2}" in
;;
i[[34567]]86-*-cygwin* | x86_64-*-cygwin*)
;;
i[[34567]]86-*-msys* | x86_64-*-msys*)
;;
i[[34567]]86-*-mingw* | x86_64-*-mingw*)
;;
i[[34567]]86-*-nto-qnx*)
Expand Down
4 changes: 2 additions & 2 deletions config/tcl.m4
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ AC_DEFUN([SC_PATH_TCLCONFIG], [
# First check to see if --with-tcl was specified.
case "${host}" in
*-*-cygwin*) platDir="win" ;;
*-*-cygwin* | *-*-msys*) platDir="win" ;;
*) platDir="unix" ;;
esac
if test x"${with_tclconfig}" != x ; then
Expand Down Expand Up @@ -165,7 +165,7 @@ AC_DEFUN([SC_PATH_TKCONFIG], [
# then check for a private Tk library
case "${host}" in
*-*-cygwin*) platDir="win" ;;
*-*-cygwin* | *-*-msys*) platDir="win" ;;
*) platDir="unix" ;;
esac
if test x"${ac_cv_c_tkconfig}" = x ; then
Expand Down
22 changes: 11 additions & 11 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -3088,7 +3088,7 @@ fi
# Configure extra directories which are host specific

case "${host}" in
*-cygwin*)
*-cygwin* | *-msys*)
configdirs="$configdirs libtermcap" ;;
esac

Expand Down Expand Up @@ -3609,7 +3609,7 @@ esac
# Disable the go frontend on systems where it is known to not work. Please keep
# this in sync with contrib/config-list.mk.
case "${target}" in
*-*-darwin* | *-*-cygwin* | *-*-mingw* | *-*-aix*)
*-*-darwin* | *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-aix*)
unsupported_languages="$unsupported_languages go"
;;
esac
Expand All @@ -3622,7 +3622,7 @@ if test x$enable_libgo = x; then
# PR 46986
noconfigdirs="$noconfigdirs target-libgo"
;;
*-*-cygwin* | *-*-mingw*)
*-*-cygwin* | *-*-msys* | *-*-mingw*)
noconfigdirs="$noconfigdirs target-libgo"
;;
*-*-aix*)
Expand Down Expand Up @@ -3894,7 +3894,7 @@ case "${target}" in
i[3456789]86-*-mingw*)
target_configdirs="$target_configdirs target-winsup"
;;
*-*-cygwin*)
*-*-cygwin* | *-*-msys*)
target_configdirs="$target_configdirs target-libtermcap target-winsup"
noconfigdirs="$noconfigdirs target-libgloss"
# always build newlib if winsup directory is present.
Expand Down Expand Up @@ -4038,7 +4038,7 @@ case "${host}" in
i[3456789]86-*-msdosdjgpp*)
host_makefile_frag="config/mh-djgpp"
;;
*-cygwin*)
*-cygwin* | *-msys*)

{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if cat works as expected" >&5
$as_echo_n "checking to see if cat works as expected... " >&6; }
Expand Down Expand Up @@ -6206,7 +6206,7 @@ fi

target_elf=no
case $target in
*-darwin* | *-aix* | *-cygwin* | *-mingw* | *-aout* | *-*coff* | \
*-darwin* | *-aix* | *-cygwin* | *-msys* | *-mingw* | *-aout* | *-*coff* | \
*-msdosdjgpp* | *-vms* | *-wince* | *-*-pe* | \
alpha*-dec-osf* | hppa[12]*-*-hpux* | \
nvptx-*-none)
Expand All @@ -6224,7 +6224,7 @@ if test $target_elf = yes; then :
else
if test x"$default_enable_lto" = x"yes" ; then
case $target in
*-apple-darwin9* | *-cygwin* | *-mingw* | *djgpp*) ;;
*-apple-darwin9* | *-cygwin* | *-msys* | *-mingw* | *djgpp*) ;;
# On other non-ELF platforms, LTO has yet to be validated.
*) enable_lto=no ;;
esac
Expand All @@ -6235,7 +6235,7 @@ else
# warn during gcc/ subconfigure; unless you're bootstrapping with
# -flto it won't be needed until after installation anyway.
case $target in
*-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
*-cygwin* | *-msys* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
*) if test x"$enable_lto" = x"yes"; then
as_fn_error $? "LTO support is not enabled for this target." "$LINENO" 5
fi
Expand All @@ -6245,7 +6245,7 @@ else
# Among non-ELF, only Windows platforms support the lto-plugin so far.
# Build it unless LTO was explicitly disabled.
case $target in
*-cygwin* | *-mingw*) build_lto_plugin=$enable_lto ;;
*-cygwin* | *-msys* | *-mingw*) build_lto_plugin=$enable_lto ;;
*) ;;
esac

Expand Down Expand Up @@ -7130,7 +7130,7 @@ rm -f conftest*
case "${host}" in
*-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
*-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
*-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
*-*-mingw* | *-*-cygwin | *-msys ) RPATH_ENVVAR=PATH ;;
*) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
esac

Expand Down Expand Up @@ -7648,7 +7648,7 @@ case " $target_configdirs " in
case " $target_configargs " in
*" --with-newlib "*)
case "$target" in
*-cygwin*)
*-cygwin* | *-msys*)
FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -isystem $$s/winsup/cygwin/include'
;;
esac
Expand Down
20 changes: 10 additions & 10 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ AC_ARG_ENABLE(compressed_debug_sections,
# Configure extra directories which are host specific

case "${host}" in
*-cygwin*)
*-cygwin* | *-msys*)
configdirs="$configdirs libtermcap" ;;
esac

Expand Down Expand Up @@ -893,7 +893,7 @@ esac
# Disable the go frontend on systems where it is known to not work. Please keep
# this in sync with contrib/config-list.mk.
case "${target}" in
*-*-darwin* | *-*-cygwin* | *-*-mingw* | *-*-aix*)
*-*-darwin* | *-*-cygwin* | *-*-msys* | *-*-mingw* | *-*-aix*)
unsupported_languages="$unsupported_languages go"
;;
esac
Expand All @@ -906,7 +906,7 @@ if test x$enable_libgo = x; then
# PR 46986
noconfigdirs="$noconfigdirs target-libgo"
;;
*-*-cygwin* | *-*-mingw*)
*-*-cygwin* | *-*-msys* | *-*-mingw*)
noconfigdirs="$noconfigdirs target-libgo"
;;
*-*-aix*)
Expand Down Expand Up @@ -1178,7 +1178,7 @@ case "${target}" in
i[[3456789]]86-*-mingw*)
target_configdirs="$target_configdirs target-winsup"
;;
*-*-cygwin*)
*-*-cygwin* | *-*-msys*)
target_configdirs="$target_configdirs target-libtermcap target-winsup"
noconfigdirs="$noconfigdirs target-libgloss"
# always build newlib if winsup directory is present.
Expand Down Expand Up @@ -1322,7 +1322,7 @@ case "${host}" in
i[[3456789]]86-*-msdosdjgpp*)
host_makefile_frag="config/mh-djgpp"
;;
*-cygwin*)
*-cygwin* | *-msys*)
ACX_CHECK_CYGWIN_CAT_WORKS
host_makefile_frag="config/mh-cygwin"
;;
Expand Down Expand Up @@ -1809,7 +1809,7 @@ ACX_ELF_TARGET_IFELSE([# ELF platforms build the lto-plugin always.
build_lto_plugin=yes
],[if test x"$default_enable_lto" = x"yes" ; then
case $target in
*-apple-darwin9* | *-cygwin* | *-mingw* | *djgpp*) ;;
*-apple-darwin9* | *-cygwin* | *-msys* | *-mingw* | *djgpp*) ;;
# On other non-ELF platforms, LTO has yet to be validated.
*) enable_lto=no ;;
esac
Expand All @@ -1820,7 +1820,7 @@ ACX_ELF_TARGET_IFELSE([# ELF platforms build the lto-plugin always.
# warn during gcc/ subconfigure; unless you're bootstrapping with
# -flto it won't be needed until after installation anyway.
case $target in
*-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
*-cygwin* | *-msys*| *-mingw* | *-apple-darwin* | *djgpp*) ;;
*) if test x"$enable_lto" = x"yes"; then
AC_MSG_ERROR([LTO support is not enabled for this target.])
fi
Expand All @@ -1830,7 +1830,7 @@ ACX_ELF_TARGET_IFELSE([# ELF platforms build the lto-plugin always.
# Among non-ELF, only Windows platforms support the lto-plugin so far.
# Build it unless LTO was explicitly disabled.
case $target in
*-cygwin* | *-mingw*) build_lto_plugin=$enable_lto ;;
*-cygwin* | *-msys* | *-mingw*) build_lto_plugin=$enable_lto ;;
*) ;;
esac
])
Expand Down Expand Up @@ -2652,7 +2652,7 @@ rm -f conftest*
case "${host}" in
*-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
*-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
*-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
*-*-mingw* | *-*-cygwin | *-*-msys ) RPATH_ENVVAR=PATH ;;
*) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
esac

Expand Down Expand Up @@ -3165,7 +3165,7 @@ case " $target_configdirs " in
case " $target_configargs " in
*" --with-newlib "*)
case "$target" in
*-cygwin*)
*-cygwin* | *-msys*)
FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -isystem $$s/winsup/cygwin/include'
;;
esac
Expand Down
Loading

0 comments on commit 466f9bc

Please sign in to comment.