Skip to content
Snippets Groups Projects
Commit 398c8e83 authored by Mike Hommey's avatar Mike Hommey
Browse files

Bug 1417309 - Add the necessary bits to support a --enable-project=memory option. r=nalexander

The option allows to iterate on the allocator code without requiring a
complete setup to build Firefox.
parent a1f665f7
No related branches found
No related tags found
No related merge requests found
......@@ -64,6 +64,8 @@ def replace_malloc(value, jemalloc, milestone, build_project):
die('--enable-replace-malloc requires --enable-jemalloc')
if value.origin != 'default':
return bool(value) or None
if build_project == 'memory':
return True
if milestone.is_nightly and jemalloc and build_project != 'js':
return True
......
# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# 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/.
# Indirectly necessary for chromium's lock.h, included from LogAlloc.cpp
EXPORTS.mozilla += [
'/mozglue/misc/Printf.h',
'/xpcom/base/Logging.h',
]
DIRS += [
'/memory',
]
......@@ -43,7 +43,8 @@ if CONFIG['OS_TARGET'] == 'Android' and CONFIG['CC_TYPE'] == 'clang':
'-Wno-tautological-pointer-compare',
]
FINAL_LIBRARY = 'mozglue'
if CONFIG['MOZ_BUILD_APP'] != 'memory':
FINAL_LIBRARY = 'mozglue'
if CONFIG['_MSC_VER']:
CXXFLAGS += ['-wd4273'] # inconsistent dll linkage (bug 558163)
......
......@@ -9,10 +9,15 @@ with Files("**"):
DIRS += [
'build',
'mozalloc',
'fallible',
]
# For now, don't build mozalloc when building with --enable-project=memory
if CONFIG['MOZ_BUILD_APP'] != 'memory':
DIRS += [
'mozalloc',
]
if CONFIG['MOZ_WIDGET_TOOLKIT']:
DIRS += ['volatile']
......
# -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# 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/.
imply_option('--enable-jemalloc', True)
......@@ -71,7 +71,7 @@ DIRS += [
'third_party/python',
]
if CONFIG['MOZ_WIDGET_TOOLKIT'] or not CONFIG['MOZ_BUILD_APP']:
if not CONFIG['JS_STANDALONE'] or not CONFIG['MOZ_BUILD_APP']:
CONFIGURE_DEFINE_FILES += [
'mozilla-config.h',
]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment