projects
/
silc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
0ca188e
)
fix --with-gmp to correctly handle situation when $withval=yes
author
Lubomir Sedlacik
<salo@silcnet.org>
Sat, 9 Nov 2002 17:00:27 +0000
(17:00 +0000)
committer
Lubomir Sedlacik
<salo@silcnet.org>
Sat, 9 Nov 2002 17:00:27 +0000
(17:00 +0000)
configure.in.pre
patch
|
blob
|
history
diff --git
a/configure.in.pre
b/configure.in.pre
index 2766a7ce4c8821acfba9b38969045fa41070f30f..1dee7247a07cdb6c43e4dbf86cc37acdb6ed8746 100644
(file)
--- a/
configure.in.pre
+++ b/
configure.in.pre
@@
-554,6
+554,8
@@
fi
# source tree.
#
mp_gmp=false
# source tree.
#
mp_gmp=false
+SAVELIBS="$LIBS"
+SAVECFLAGS="$CFLAGS"
AC_MSG_CHECKING(whether to search for GMP)
AC_ARG_WITH(gmp,
[[ --with-gmp[=DIR] use GMP instead of MPI [search in DIR/lib and DIR/include]]],
AC_MSG_CHECKING(whether to search for GMP)
AC_ARG_WITH(gmp,
[[ --with-gmp[=DIR] use GMP instead of MPI [search in DIR/lib and DIR/include]]],
@@
-562,6
+564,10
@@
AC_ARG_WITH(gmp,
no)
AC_MSG_RESULT(no)
;;
no)
AC_MSG_RESULT(no)
;;
+ yes)
+ AC_MSG_RESULT(yes)
+ LIBS="-lgmp $LIBS"
+ ;;
*)
AC_MSG_RESULT(yes)
*)
AC_MSG_RESULT(yes)
@@
-577,14
+583,19
@@
AC_ARG_WITH(gmp,
fi
LIBS="$withval $LIBS"
fi
LIBS="$withval $LIBS"
- AC_CHECK_LIB(gmp, __gmpz_init,
- [
- mp_gmp=true
- AC_DEFINE(SILC_MP_GMP)
- AC_MSG_RESULT(Using GMP as a MP library.)
- ])
;;
esac
;;
esac
+
+ AC_CHECK_LIB(gmp, __gmpz_init,
+ [
+ mp_gmp=true
+ AC_DEFINE(SILC_MP_GMP)
+ AC_MSG_RESULT(Using GMP as a MP library.)
+ ],
+ [
+ LIBS="$SAVELIBS"
+ CFLAGS="$SAVECFLAGS"
+ ])
],
AC_MSG_RESULT(no)
)
],
AC_MSG_RESULT(no)
)