From b770a51f2bdfb3c59dd6a3283f8a8e229d4e76ec Mon Sep 17 00:00:00 2001 From: Mark Mentovai Date: Sun, 8 Mar 2015 15:17:22 -0400 Subject: [PATCH] Set the chromium_code GYP variable. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When building in the Chromium tree, chromium_code is necessary to apply Chromium’s build/filename_rules.gypi. Crashpad’s build depends on these rules. chromium_code also enables a high warning level, which is desirable for Crashpad. BUG=crashpad:12 R=rsesek@chromium.org Review URL: https://codereview.chromium.org/986873002 --- build/crashpad.gypi | 23 +++++++++++++++++++++++ client/client.gyp | 3 +++ compat/compat.gyp | 3 +++ handler/handler.gyp | 3 +++ minidump/minidump.gyp | 3 +++ snapshot/snapshot.gyp | 3 +++ tools/tools.gyp | 3 +++ util/util.gyp | 3 +++ 8 files changed, 44 insertions(+) create mode 100644 build/crashpad.gypi diff --git a/build/crashpad.gypi b/build/crashpad.gypi new file mode 100644 index 00000000..0dad63ca --- /dev/null +++ b/build/crashpad.gypi @@ -0,0 +1,23 @@ +# Copyright 2015 The Crashpad Authors. All rights reserved. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +{ + 'variables': { + # When building as a part of Chromium, this variable sets up the build to + # treat Crashpad as Chromium code. This enables warnings at an appropriate + # level and applies Chromium’s build/filename_rules.gypi. In a standalone + # build, this variable has no effect. + 'chromium_code': 1, + }, +} diff --git a/client/client.gyp b/client/client.gyp index c8895563..9036fef6 100644 --- a/client/client.gyp +++ b/client/client.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'targets': [ { 'target_name': 'client', diff --git a/compat/compat.gyp b/compat/compat.gyp index 231dfe00..eb382b37 100644 --- a/compat/compat.gyp +++ b/compat/compat.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'targets': [ { 'target_name': 'compat', diff --git a/handler/handler.gyp b/handler/handler.gyp index f7a4164c..c062075e 100644 --- a/handler/handler.gyp +++ b/handler/handler.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'conditions': [ ['OS=="mac"', { 'targets': [ diff --git a/minidump/minidump.gyp b/minidump/minidump.gyp index 0ccf7137..e92d70a0 100644 --- a/minidump/minidump.gyp +++ b/minidump/minidump.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'targets': [ { 'target_name': 'minidump', diff --git a/snapshot/snapshot.gyp b/snapshot/snapshot.gyp index e0317607..c9d0da70 100644 --- a/snapshot/snapshot.gyp +++ b/snapshot/snapshot.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'targets': [ { 'target_name': 'snapshot', diff --git a/tools/tools.gyp b/tools/tools.gyp index 98010b38..bf239fa6 100644 --- a/tools/tools.gyp +++ b/tools/tools.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'conditions': [ ['OS=="mac"', { 'variables': { diff --git a/util/util.gyp b/util/util.gyp index ba72b15c..31368ee1 100644 --- a/util/util.gyp +++ b/util/util.gyp @@ -13,6 +13,9 @@ # limitations under the License. { + 'includes': [ + '../build/crashpad.gypi', + ], 'targets': [ { 'target_name': 'util',