gecko-dev/mozglue/build/replace_malloc.mk
Mike Hommey ed863255b4 Bug 1378592 - Remove MOZ_REPLACE_MALLOC_LINKAGE. r=froydnj
MOZ_REPLACE_MALLOC_LINKAGE was added back when there were problems with
getting weak references working properly for replace-malloc.

Versions of OSX < 10.6 needed flat namespace, but aren't supported
anymore.

Versions of Xcode < 4.5 required flat namespace + a dummy library in
order to produce proper weak references. There is virtually nobody still
building with such an ancient toolchain.

Keeping those around doesn't /really/ hurt, except recent versions of
Xcode don't expose dyldinfo in /usr/bin, used for the configure test.
Consequently, MOZ_REPLACE_MALLOC_LINKAGE ended up being set to use the
dummy library setup, which, by using flat namespace, now causes harm in
bug 1356701, causing bug 1378332.

--HG--
extra : rebase_source : e3edc1f2cf905943c33fafeb631f2f88fc87167e
2017-07-06 10:26:04 +09:00

27 lines
883 B
Makefile

# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
ifeq (Darwin_1,$(OS_TARGET)_$(MOZ_REPLACE_MALLOC))
OS_LDFLAGS += \
-Wl,-U,_replace_init \
-Wl,-U,_replace_get_bridge \
-Wl,-U,_replace_malloc \
-Wl,-U,_replace_posix_memalign \
-Wl,-U,_replace_aligned_alloc \
-Wl,-U,_replace_calloc \
-Wl,-U,_replace_realloc \
-Wl,-U,_replace_free \
-Wl,-U,_replace_memalign \
-Wl,-U,_replace_valloc \
-Wl,-U,_replace_malloc_usable_size \
-Wl,-U,_replace_malloc_good_size \
-Wl,-U,_replace_jemalloc_stats \
-Wl,-U,_replace_jemalloc_purge_freed_pages \
-Wl,-U,_replace_jemalloc_free_dirty_pages \
-Wl,-U,_replace_jemalloc_thread_local_arena \
$(NULL)
EXTRA_DEPS += $(topsrcdir)/mozglue/build/replace_malloc.mk
endif