summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
Diffstat (limited to 'build')
-rw-r--r--build/gecko_templates.mozbuild5
1 files changed, 5 insertions, 0 deletions
diff --git a/build/gecko_templates.mozbuild b/build/gecko_templates.mozbuild
index e2bc999b7..a15fdd77f 100644
--- a/build/gecko_templates.mozbuild
+++ b/build/gecko_templates.mozbuild
@@ -63,6 +63,11 @@ def GeckoBinary(linkage='dependent', msvcrt='dynamic', mozglue=None):
LDFLAGS += ['-rdynamic']
if CONFIG['MOZ_MEMORY']:
USE_LIBS += ['memory']
+ if CONFIG['OS_ARCH'] == 'FreeBSD':
+ # Make sure this function is linked in, so that it is
+ # executed at executable load (it has the 'constructor'
+ # flag).
+ LDFLAGS += ['-u', 'jemalloc_FreeBSD_init']
elif mozglue == 'library':
LIBRARY_DEFINES['MOZ_HAS_MOZGLUE'] = True
if not CONFIG['MOZ_GLUE_IN_PROGRAM']: