1 /* -*- Mode: Groovy; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
2 * This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 // Bug 1353055 - Strip 'vars' debugging information to agree with moz.build.
7 ext.configureVariantDebugLevel = { variant ->
8 // Like 'debug' or 'release'.
9 def buildType = variant.buildType.name
11 // The default is 'lines,source,vars', which includes debugging information
12 // that is quite large: roughly 500kb for Fennec. Therefore we remove
13 // 'vars' unless we're producing a debug build, where it is useful.
14 if (!'debug'.equals(buildType) || mozconfig.substs.MOZILLA_OFFICIAL) {
15 variant.javaCompileProvider.get().options.debugOptions.debugLevel = 'lines,source'