* gc.c: fix build failure on FreeBSD introduced by r43763.

malloc_usable_size() is defined by malloc_np.h on FreeBSD.

* configure.in: check malloc.h and malloc_np.h.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43769 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
naruse 2013-11-22 00:05:34 +00:00
Родитель 62d6fc31c7
Коммит 215a7da2a6
3 изменённых файлов: 14 добавлений и 1 удалений

Просмотреть файл

@ -1,3 +1,10 @@
Fri Nov 22 09:03:16 2013 NARUSE, Yui <naruse@ruby-lang.org>
* gc.c: fix build failure on FreeBSD introduced by r43763.
malloc_usable_size() is defined by malloc_np.h on FreeBSD.
* configure.in: check malloc.h and malloc_np.h.
Fri Nov 22 08:27:13 2013 Eric Hodel <drbrain@segment7.net>
* lib/rubygems: Update to RubyGems master 50a8210. Important changes

Просмотреть файл

@ -1091,6 +1091,8 @@ AC_CHECK_HEADERS( \
process.h \
sys/prctl.h \
atomic.h \
malloc.h \
malloc_np.h \
setjmpex.h
)

4
gc.c
Просмотреть файл

@ -40,7 +40,11 @@
# define malloc_usable_size(a) _msize(a)
# endif
#else
# ifdef HAVE_MALLOC_H
# include <malloc.h>
# elif defined(HAVE_MALLOC_NP_H)
# include <malloc_np.h>
# endif
#endif
#if /* is ASAN enabled? */ \