From 7e09aaf6ade993e6130753facddd17e665b00d1b Mon Sep 17 00:00:00 2001 From: Ehsan Akhgari Date: Fri, 3 Jul 2015 13:59:00 -0400 Subject: [PATCH] Bug 1180275 - Part 1: Add a release_build mozinfo variable; r=ted --- build/docs/mozinfo.rst | 7 +++++++ python/mozbuild/mozbuild/mozinfo.py | 1 + 2 files changed, 8 insertions(+) diff --git a/build/docs/mozinfo.rst b/build/docs/mozinfo.rst index de745bcb8e9..1d09fd55b23 100644 --- a/build/docs/mozinfo.rst +++ b/build/docs/mozinfo.rst @@ -122,6 +122,13 @@ processor Always defined. +release_build + Whether this is a release build. + + Values are ``true`` and ``false``. + + Always defined. + tests_enabled Whether tests are enabled for this build. diff --git a/python/mozbuild/mozbuild/mozinfo.py b/python/mozbuild/mozbuild/mozinfo.py index c4f785dc47f..28d838372bd 100755 --- a/python/mozbuild/mozbuild/mozinfo.py +++ b/python/mozbuild/mozbuild/mozinfo.py @@ -80,6 +80,7 @@ def build_dict(config, env=os.environ): # other CPUs will wind up with unknown bits d['debug'] = substs.get('MOZ_DEBUG') == '1' + d['release_build'] = substs.get('RELEASE_BUILD') == '1' d['pgo'] = substs.get('MOZ_PGO') == '1' d['crashreporter'] = bool(substs.get('MOZ_CRASHREPORTER')) d['datareporting'] = bool(substs.get('MOZ_DATA_REPORTING'))