[kaffe] CVS kaffe (robilad): enabled pur java java.math per default

Kaffe CVS cvs-commits at kaffe.org
Thu Jan 17 12:34:47 PST 2008


PatchSet 7682 
Date: 2008/01/17 20:29:25
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
enabled pur java java.math per default

2008-01-17  Dalibor Topic  <robilad at kaffe.org>

        * configure.ac: Rewritten checking for pure java math to make the
        native GNU MP implementation disabled by default.

Members: 
	ChangeLog:1.5184->1.5185 
	configure:1.628->1.629 
	configure.ac:1.297->1.298 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.5184 kaffe/ChangeLog:1.5185
--- kaffe/ChangeLog:1.5184	Thu Jan 17 01:59:08 2008
+++ kaffe/ChangeLog	Thu Jan 17 20:29:25 2008
@@ -1,3 +1,8 @@
+2008-01-17  Dalibor Topic  <robilad at kaffe.org>
+
+	* configure.ac: Rewritten checking for pure java math to make the 
+	native GNU MP implementation disabled by default.
+
 2008-01-17  Doug Young  <doug at morphlix.com>
 
 	* kaffe/kaffevm/systems/unix-pthreads/signal.c (stackOverflowDetector),
Index: kaffe/configure
diff -u kaffe/configure:1.628 kaffe/configure:1.629
--- kaffe/configure:1.628	Wed Jan 16 23:10:06 2008
+++ kaffe/configure	Thu Jan 17 20:29:26 2008
@@ -1671,8 +1671,8 @@
                           (enabled by default)
   --disable-zlib-zip      Disable java.util.zip implementation using zlib
                           [default=enabled]
-  --enable-pure-java-math Enable pure java java.math.* package
-                          [default=native]
+  --disable-pure-java-math
+                          Disable pure java java.math.* package
   --disable-direct-threading
                           Use switched interpreter instead of direct-threading
 
@@ -41558,34 +41558,13 @@
 
 # Check whether --enable-pure_java_math was given.
 if test "${enable_pure_java_math+set}" = set; then
-  enableval=$enable_pure_java_math; case "$enableval" in
-yes)
-	pure_java_math=true
-	;;
-no)
-	pure_java_math=false
-	;;
-*)
-	{ { echo "$as_me:$LINENO: error: bad value ${enableval} for --enable-pure-java-math" >&5
-echo "$as_me: error: bad value ${enableval} for --enable-pure-java-math" >&2;}
-   { (exit 1); exit 1; }; }
-	;;
-esac
+  enableval=$enable_pure_java_math;
 else
-
-        if test x"$ac_cv_lib_gmp_mpz_get_d" = x"no"; then
-                if test x"$ac_cv_lib_gmp___gmpz_get_d" = x"no"; then
-			{ { echo "$as_me:$LINENO: error: Could not find GNU MP library.  Install the gmp development package, or pass --enable-pure-java-math to configure." >&5
-echo "$as_me: error: Could not find GNU MP library.  Install the gmp development package, or pass --enable-pure-java-math to configure." >&2;}
-   { (exit 1); exit 1; }; }
-		fi
-	fi
-
-
+  enable_pure_java_math=yes
 fi
 
 
- if test "$enable_pure_java_math" = yes; then
+ if test x"$enable_pure_java_math" = x"yes"; then
   COND_PURE_JAVA_MATH_TRUE=
   COND_PURE_JAVA_MATH_FALSE='#'
 else
@@ -41594,16 +41573,27 @@
 fi
 
 
-if test x"$pure_java_math" = x"true" ; then
-	{ echo "$as_me:$LINENO: result: Information: Using pure Java math library" >&5
-echo "${ECHO_T}Information: Using pure Java math library" >&6; }
-	MATH_LIB=""
-else
-	{ echo "$as_me:$LINENO: result: Information: Using native math library" >&5
-echo "${ECHO_T}Information: Using native math library" >&6; }
-	MATH_LIB="\$(top_builddir)/libraries/clib/math/libmath.la"
+if test x"$enable_pure_java_math" = x"yes"; then
+  { echo "$as_me:$LINENO: Using GNU Classpath's java.math library" >&5
+echo "$as_me: Using GNU Classpath's java.math library" >&6;}
+else
+  { echo "$as_me:$LINENO: Using Kaffe's java.math library" >&5
+echo "$as_me: Using Kaffe's java.math library" >&6;}
+       MATH_LIB="\$(top_builddir)/libraries/clib/math/libmath.la"
+
+
+       if test x"$ac_cv_lib_gmp_mpz_get_d" = x"no"; then
+  if test x"$ac_cv_lib_gmp___gmpz_get_d" = x"no"; then
+  { { echo "$as_me:$LINENO: error: Could not find GNU MP library.  Install the gmp development package
+elif or pass --enable-pure-java-math to configure." >&5
+echo "$as_me: error: Could not find GNU MP library.  Install the gmp development package; then
+  or pass --enable-pure-java-math to configure." >&2;}
+   { (exit 1); exit 1; }; }
+fi
+
 fi
 
+fi
 
 
 
Index: kaffe/configure.ac
diff -u kaffe/configure.ac:1.297 kaffe/configure.ac:1.298
--- kaffe/configure.ac:1.297	Wed Jan 16 23:10:07 2008
+++ kaffe/configure.ac	Thu Jan 17 20:29:27 2008
@@ -1585,41 +1585,20 @@
 dnl -----------------------------------------------------------------------
 
 AC_ARG_ENABLE([pure_java_math],
-              AS_HELP_STRING([--enable-pure-java-math],
-                             [Enable pure java java.math.* package @<:@default=native@:>@]),
-[case "$enableval" in
-yes)
-	pure_java_math=true
-	;;
-no)
-dnl  Use native implementation
-	pure_java_math=false
-	;;
-*)
-	AC_MSG_ERROR(bad value ${enableval} for --enable-pure-java-math)
-	;;
-esac],
-[
-dnl  If nothing is set, use native implementation if GNU MP can be found.
-        if test x"$ac_cv_lib_gmp_mpz_get_d" = x"no"; then
-                if test x"$ac_cv_lib_gmp___gmpz_get_d" = x"no"; then
-			AC_MSG_ERROR([Could not find GNU MP library.  Install the gmp development package, or pass --enable-pure-java-math to configure.])
-		fi
-	fi
-]
-)
+  AS_HELP_STRING([--disable-pure-java-math], [Disable pure java java.math.* package]),
+  [],
+  [enable_pure_java_math=yes])
 
-AM_CONDITIONAL([COND_PURE_JAVA_MATH], [test "$enable_pure_java_math" = yes])
+AM_CONDITIONAL([COND_PURE_JAVA_MATH], [test x"$enable_pure_java_math" = x"yes"])
 
-if test x"$pure_java_math" = x"true" ; then
-	AC_MSG_RESULT(Information: Using pure Java math library)
-	MATH_LIB=""
-else
-	AC_MSG_RESULT(Information: Using native math library)
-	MATH_LIB="\$(top_builddir)/libraries/clib/math/libmath.la"
-fi
+AS_IF([test x"$enable_pure_java_math" = x"yes"],
+      [AC_MSG_NOTICE([Using GNU Classpath's java.math library])],
+      [AC_MSG_NOTICE([Using Kaffe's java.math library])
+       AC_SUBST([MATH_LIB], ["\$(top_builddir)/libraries/clib/math/libmath.la"])
 
-AC_SUBST(MATH_LIB)
+       AS_IF([test x"$ac_cv_lib_gmp_mpz_get_d" = x"no"],
+             AS_IF([test x"$ac_cv_lib_gmp___gmpz_get_d" = x"no"],
+                   [AC_MSG_ERROR([Could not find GNU MP library.  Install the gmp development package, or pass --enable-pure-java-math to configure.])]))])
 
 dnl -----------------------------------------------------------------------
 dnl                    Memory debugging support




More information about the kaffe mailing list