pandora_check_compiler_version.m4 972 B

12345678910111213141516171819202122232425262728293031323334353637
  1. dnl Copyright (C) 2009 Sun Microsystems, Inc.
  2. dnl This file is free software; Sun Microsystems, Inc.
  3. dnl gives unlimited permission to copy and/or distribute it,
  4. dnl with or without modifications, as long as this notice is preserved.
  5. AC_DEFUN([PANDORA_CHECK_C_VERSION],[
  6. dnl Print version of C compiler
  7. AC_MSG_CHECKING("C Compiler version--$GCC")
  8. AS_IF([test "$GCC" = "yes"],[
  9. CC_VERSION=`$CC --version | sed 1q`
  10. ],[AS_IF([test "$SUNCC" = "yes"],[
  11. CC_VERSION=`$CC -V 2>&1 | sed 1q`
  12. ],[
  13. CC_VERSION=""
  14. ])
  15. ])
  16. AC_MSG_RESULT("$CC_VERSION")
  17. AC_SUBST(CC_VERSION)
  18. ])
  19. AC_DEFUN([PANDORA_CHECK_CXX_VERSION], [
  20. dnl Print version of CXX compiler
  21. AC_MSG_CHECKING("C++ Compiler version")
  22. AS_IF([test "$GCC" = "yes"],[
  23. CXX_VERSION=`$CXX --version | sed 1q`
  24. ],[AS_IF([test "$SUNCC" = "yes"],[
  25. CXX_VERSION=`$CXX -V 2>&1 | sed 1q`
  26. ],[
  27. CXX_VERSION=""
  28. ])
  29. ])
  30. AC_MSG_RESULT("$CXX_VERSION")
  31. AC_SUBST(CXX_VERSION)
  32. ])