annotate src/libsndfile-1.0.25/M4/gcc_version.m4 @ 88:fe7c3a0b0259

Add some MinGW builds
author Chris Cannam <cannam@all-day-breakfast.com>
date Wed, 20 Mar 2013 13:49:36 +0000
parents 545efbb81310
children
rev   line source
cannam@85 1 dnl @synopsis MN_GCC_VERSION
cannam@85 2 dnl
cannam@85 3 dnl Find the version of gcc.
cannam@85 4 dnl @version 1.0 Nov 05 2007
cannam@85 5 dnl @author Erik de Castro Lopo <erikd AT mega-nerd DOT com>
cannam@85 6 dnl
cannam@85 7 dnl Permission to use, copy, modify, distribute, and sell this file for any
cannam@85 8 dnl purpose is hereby granted without fee, provided that the above copyright
cannam@85 9 dnl and this permission notice appear in all copies. No representations are
cannam@85 10 dnl made about the suitability of this software for any purpose. It is
cannam@85 11 dnl provided "as is" without express or implied warranty.
cannam@85 12 dnl
cannam@85 13
cannam@85 14 AC_DEFUN([MN_GCC_VERSION],
cannam@85 15 [
cannam@85 16 if test "x$ac_cv_c_compiler_gnu" = "xyes" ; then
cannam@85 17
cannam@85 18 AC_MSG_CHECKING([for version of $CC])
cannam@85 19 GCC_VERSION=`$CC -dumpversion`
cannam@85 20 AC_MSG_RESULT($GCC_VERSION)
cannam@85 21
cannam@85 22 changequote(,)dnl
cannam@85 23 GCC_MINOR_VERSION=`echo $GCC_VERSION | sed "s/^[0-9]\+\.//" | sed "s/\..*//"`
cannam@85 24 GCC_MAJOR_VERSION=`echo $GCC_VERSION | sed "s/\..*//"`
cannam@85 25 changequote([,])dnl
cannam@85 26 fi
cannam@85 27
cannam@85 28 AC_SUBST(GCC_VERSION)
cannam@85 29 AC_SUBST(GCC_MAJOR_VERSION)
cannam@85 30 AC_SUBST(GCC_MINOR_VERSION)
cannam@85 31
cannam@85 32 ])# MN_GCC_VERSION
cannam@85 33