add mint support #321827 by Alan Hourihane
authorMike Frysinger <vapier@gentoo.org>
Wed, 2 Jun 2010 21:31:12 +0000 (21:31 +0000)
committerMike Frysinger <vapier@gentoo.org>
Wed, 2 Jun 2010 21:31:12 +0000 (21:31 +0000)
eclass/toolchain.eclass

index c7bfdfbcbf7590ee4bb0645264ce65d348030452..a963efdbfdee9ec3c84e31c333072d45ffa0fca7 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2008 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.426 2010/05/25 23:24:18 dirtyepic Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain.eclass,v 1.427 2010/06/02 21:31:12 vapier Exp $
 #
 # Maintainer: Toolchain Ninjas <toolchain@gentoo.org>
 
@@ -1421,10 +1421,20 @@ gcc_do_configure() {
                if [[ ${GCCMAJOR}.${GCCMINOR} > 4.1 ]] ; then
                        confgcc="${confgcc} --disable-bootstrap --disable-libgomp"
                fi
-       elif [[ ${CHOST} == mingw* ]] || [[ ${CHOST} == *-mingw* ]] || [[ ${CHOST} == *-cygwin ]] ; then
-               confgcc="${confgcc} --enable-shared --enable-threads=win32"
        else
-               confgcc="${confgcc} --enable-shared --enable-threads=posix"
+               if tc-is-static-only ; then
+                       confgcc="${confgcc} --disable-shared"
+               else
+                       confgcc="${confgcc} --enable-shared"
+               fi
+               case ${CHOST} in
+                       mingw*|*-mingw*|*-cygwin)
+                               confgcc="${confgcc} --enable-threads=win32" ;;
+                       *-mint*)
+                               confgcc="${confgcc} --disable-threads" ;;
+                       *)
+                               confgcc="${confgcc} --enable-threads=posix" ;;
+               esac
        fi
        [[ ${CTARGET} == *-elf ]] && confgcc="${confgcc} --with-newlib"
        # __cxa_atexit is "essential for fully standards-compliant handling of
@@ -2549,8 +2559,8 @@ is_multilib() {
        case ${CTARGET} in
                mips64*|powerpc64*|s390x*|sparc*|x86_64*)
                        has_multilib_profile || use multilib ;;
-               *-*-solaris*) use multilib ;;
-               *-apple-darwin*) use multilib ;;
+               *-*-solaris*|*-apple-darwin*|*-mint*)
+                       use multilib ;;
                *)      false ;;
        esac
 }