Skip to content

Commit 3839eaa

Browse files
committed
Import patch for gmp and jemalloc issue
https://bugs.ruby-lang.org/issues/13899
1 parent 5bd8612 commit 3839eaa

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

configure.in

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1403,13 +1403,15 @@ AC_ARG_WITH([gmp],
14031403
AS_IF([test "x$with_gmp" != xno],
14041404
[AC_CHECK_HEADERS(gmp.h)
14051405
AS_IF([test "x$ac_cv_header_gmp_h" != xno],
1406-
AC_SEARCH_LIBS([__gmpz_init], [gmp]))])
1406+
AC_SEARCH_LIBS([__gmpz_init], [gmp],
1407+
[AC_DEFINE(HAVE_LIBGMP, 1)]))])
14071408

14081409
AC_ARG_WITH([jemalloc],
14091410
[AS_HELP_STRING([--with-jemalloc],[use jemalloc allocator])],
14101411
[with_jemalloc=$withval], [with_jemalloc=no])
14111412
AS_IF([test "x$with_jemalloc" = xyes],[
1412-
AC_SEARCH_LIBS([malloc_conf], [jemalloc], [], [with_jemalloc=no])
1413+
AC_SEARCH_LIBS([malloc_conf], [jemalloc],
1414+
[AC_DEFINE(HAVE_LIBJEMALLOC, 1)], [with_jemalloc=no])
14131415
AC_CHECK_HEADER(jemalloc/jemalloc.h, [
14141416
AC_DEFINE(RUBY_ALTERNATIVE_MALLOC_HEADER, [<jemalloc/jemalloc.h>])
14151417
])

0 commit comments

Comments
 (0)