Fix build on latest FreeBSD stable (12.2).

This commit is contained in:
Fedor
2021-03-06 18:09:48 +02:00
parent 0851f7aa3a
commit da96a0b5d6
2 changed files with 5 additions and 2 deletions
+2
View File
@@ -24,10 +24,12 @@
* Red Hat Author(s): Behdad Esfahbod
*/
#ifndef __FreeBSD__
/* http://www.oracle.com/technetwork/articles/servers-storage-dev/standardheaderfiles-453865.html */
#ifndef _POSIX_C_SOURCE
#define _POSIX_C_SOURCE 199309L
#endif
#endif
#include "hb-private.hh"
+3 -2
View File
@@ -5267,7 +5267,7 @@ malloc_init_hard(void)
* Another thread initialized the allocator before this one
* acquired init_lock.
*/
#ifndef MOZ_MEMORY_WINDOWS
#if !(defined(MOZ_MEMORY_WINDOWS) || defined(__FreeBSD__))
malloc_mutex_unlock(&init_lock);
#endif
return (false);
@@ -6771,7 +6771,8 @@ jemalloc_darwin_init(void)
#define is_malloc_(a) malloc_is_ ## a
#define is_malloc(a) is_malloc_(a)
#if !defined(MOZ_MEMORY_DARWIN) && (is_malloc(malloc_impl) == 1)
#if !(defined(MOZ_MEMORY_DARWIN) || defined(MOZ_MEMORY_BSD)) && \
(is_malloc(malloc_impl) == 1)
# if defined(__GLIBC__) && !defined(__UCLIBC__)
/*
* glibc provides the RTLD_DEEPBIND flag for dlopen which can make it possible