OSDN Git Service

2010-12-08 Tobias Burnus <burnus@net-b.de>
[pf3gnuchains/gcc-fork.git] / libquadmath / configure.ac
index 82ee93f..56b1fcb 100644 (file)
@@ -30,7 +30,8 @@ AM_INIT_AUTOMAKE([1.9.0 foreign subdir-objects no-dist -Wall -Werror])
 
 AC_MSG_CHECKING([for --enable-version-specific-runtime-libs])
 AC_ARG_ENABLE(version-specific-runtime-libs,
-[  --enable-version-specific-runtime-libs    Specify that runtime libraries should be installed in a compiler-specific directory ],
+AS_HELP_STRING([--enable-version-specific-runtime-libs],
+ [specify that runtime libraries should be installed in a compiler-specific directory]),
 [case "$enableval" in
  yes) version_specific_libs=yes ;;
  no)  version_specific_libs=no ;;
@@ -41,6 +42,14 @@ AC_MSG_RESULT($version_specific_libs)
 
 GCC_NO_EXECUTABLES
 
+# See if makeinfo has been installed and is modern enough
+# that we can use it.
+ACX_CHECK_PROG_VER([MAKEINFO], [makeinfo], [--version],
+                   [GNU texinfo.* \([0-9][0-9.]*\)],
+                   [4.[4-9]*|4.[1-9][0-9]*|[5-9]*|[1-9][0-9]*])
+AM_CONDITIONAL(BUILD_INFO, test $gcc_cv_prog_makeinfo_modern = "yes")
+
+
 # Configure libtool
 AM_PROG_LIBTOOL
 ACX_LT_HOST_FLAGS
@@ -140,8 +149,8 @@ AM_CONDITIONAL(LIBQUAD_USE_SYMVER, [test "x$quadmath_use_symver" != xno])
 AM_CONDITIONAL(LIBQUAD_USE_SYMVER_GNU, [test "x$quadmath_use_symver" = xgnu])
 AM_CONDITIONAL(LIBQUAD_USE_SYMVER_SUN, [test "x$quadmath_use_symver" = xsun])
 
-AC_MSG_CHECKING([whether __float128 is supported])
-  AC_TRY_LINK([
+AC_CACHE_CHECK([whether __float128 is supported], [libquad_cv_have_float128],
+  [GCC_TRY_COMPILE_OR_LINK([
     typedef _Complex float __attribute__((mode(TC))) __complex128;
 
     __float128 foo (__float128 x)
@@ -164,20 +173,11 @@ AC_MSG_CHECKING([whether __float128 is supported])
     foo (1.2Q);
     bar (1.2Q);
   ],[
-    libquad_have_float128=yes
+    libquad_cv_have_float128=yes
   ],[
-    libquad_have_float128=no
-])
-AC_MSG_RESULT([$libquad_have_float128])
-
-dnl
-dnl Enable the following for a stand-alone library:
-dnl
-dnl if test $libquad_have_float128 = no; then
-dnl   AC_MSG_ERROR([__float128 support is required to build this library.])
-dnl fi
-
-AM_CONDITIONAL(BUILD_LIBQUADMATH, [test "x$libquad_have_float128" = xyes])
+    libquad_cv_have_float128=no
+])])
+AM_CONDITIONAL(BUILD_LIBQUADMATH, [test "x$libquad_cv_have_float128" = xyes])
 
 AC_CACHE_SAVE
 
@@ -187,5 +187,25 @@ else
   multilib_arg=
 fi
 
+
+# We would like our source tree to be readonly. However when releases or
+# pre-releases are generated, the flex/bison generated files as well as the
+# various formats of manuals need to be included along with the rest of the
+# sources.  Therefore we have --enable-generated-files-in-srcdir to do 
+# just that.
+AC_MSG_CHECKING(generated-files-in-srcdir)
+AC_ARG_ENABLE(generated-files-in-srcdir,
+AS_HELP_STRING([--enable-generated-files-in-srcdir],
+ [put copies of generated files in source dir intended for creating source tarballs for users without texinfo bison or flex]),
+[case "$enableval" in
+ yes) enable_generated_files_in_srcdir=yes ;;
+ no)  enable_generated_files_in_srcdir=no ;;
+ *)   AC_MSG_ERROR([Unknown argument to enable/disable version-specific libs]);;
+ esac],
+[enable_generated_files_in_srcdir=no])
+AC_MSG_RESULT($enable_generated_files_in_srcdir)
+AM_CONDITIONAL(GENINSRC, test "$enable_generated_files_in_srcdir" = yes)
+
+
 AC_CONFIG_FILES(Makefile)
 AC_OUTPUT