mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-04-29 19:30:36 +02:00
improve autoconfigury for minigmp
* configure.ac: add SCM_I_GSC_ENABLE_MINI_GMP var and rename GUILE_MINI_GMP to ENABLE_MINI_GMP * libguile/bytevectors (GUILE_MINI_GMP): rename to ENABLE_MINI_GMP * libguile/gen-scmconfig.c: renamed GUILE_MINI_GMP to ENABLE_MINI_GMP. rename GUILE_MINI_GMP to SCM_ENABLE_MINI_GMP * libguile/gen-scmconfig.h: add SCM_I_GSC_ENABLE_MINI_GMP * libguile/init.c [GUILE_MINI_GMP]: prefer ENABLE_MINI_GMP * libguile/numbers.c [GUILE_MINI_GMP]: prefer ENABLE_MINI_GMP * libguile/numbers.h: include scmconfig.h rename GUILE_MINI_GMP to SCM_ENABLE_MINI_GMP * libguile/random.c [GUILE_MINI_GMP]: prefer ENABLE_MINI_GMP * libguile/socket.c [GUILE_MINI_GMP]: prefer ENABLE_MINI_GMP * libguile.h [GUILE_MINI_GMP]: prefer SCM_ENABLE_MINI_GMP
This commit is contained in:
parent
eb1bd8050e
commit
54adbd6f0f
10 changed files with 23 additions and 15 deletions
13
configure.ac
13
configure.ac
|
@ -651,19 +651,24 @@ PKG_CHECK_MODULES([GMP],[gmp],
|
|||
[],
|
||||
[$enable_mini_gmp=yes])
|
||||
|
||||
SCM_I_GSC_ENABLE_MINI_GMP=0
|
||||
AC_ARG_ENABLE(mini-gmp,
|
||||
[ --enable-mini-gmp use mini-gmp instead of the full GMP library])
|
||||
if test "$enable_mini_gmp" = yes; then
|
||||
AC_DEFINE([GUILE_MINI_GMP], 1,
|
||||
[AS_HELP_STRING([--enable-mini-gmp],
|
||||
[use mini-gmp instead of the full GMP library])])
|
||||
|
||||
if test "$enable_mini_gmp" = yes || test "$enable_mini_gmp" = y; then
|
||||
SCM_I_GSC_ENABLE_MINI_GMP=1
|
||||
AC_DEFINE([ENABLE_MINI_GMP], 1,
|
||||
[Define this if you want to use mini-gmp.])
|
||||
else
|
||||
LIBS="$GMP_LIBS $LIBS"
|
||||
CFLAGS="$GMP_CFLAGS $CFLAGS"
|
||||
fi
|
||||
AC_SUBST([SCM_I_GSC_ENABLE_MINI_GMP])
|
||||
AM_CONDITIONAL([USE_MINI_GMP], [test "x$enable_mini_gmp" = "xyes"])
|
||||
|
||||
AC_CHECK_DECLS([mpz_inits], [], [],
|
||||
[[#if GUILE_MINI_GMP
|
||||
[[#if ENABLE_MINI_GMP
|
||||
#include "libguile/mini-gmp.h"
|
||||
#else
|
||||
#include <gmp.h>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue