Enable more compilation checks in clang
These checks were disabled in Chromium due to historical reason. Also fix compilation errors as a result of the above mentioned change. Change-Id: I5d240f2f11aa5920598f954d696a15bdcbf78fd8
This commit is contained in:
parent
cb12a2bad2
commit
301f8c134d
|
@ -0,0 +1,33 @@
|
||||||
|
# Copyright 2014 Google Inc. All rights reserved.
|
||||||
|
#
|
||||||
|
# Use of this source code is governed by a BSD-style
|
||||||
|
# license that can be found in the LICENSE file or at
|
||||||
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
#
|
||||||
|
# This file contains common settings for building packager components.
|
||||||
|
|
||||||
|
{
|
||||||
|
'variables': {
|
||||||
|
# Compile as Chromium code to enable warnings and warnings-as-errors.
|
||||||
|
'chromium_code': 1,
|
||||||
|
},
|
||||||
|
'target_defaults': {
|
||||||
|
'include_dirs': [
|
||||||
|
'.',
|
||||||
|
],
|
||||||
|
'conditions': [
|
||||||
|
['clang==1', {
|
||||||
|
# Revert the relevant settings in Chromium's common.gypi.
|
||||||
|
'cflags!': [
|
||||||
|
'-Wno-char-subscripts',
|
||||||
|
'-Wno-unneeded-internal-declaration',
|
||||||
|
'-Wno-covered-switch-default',
|
||||||
|
|
||||||
|
# C++11-related flags:
|
||||||
|
'-Wno-c++11-narrowing',
|
||||||
|
'-Wno-reserved-user-defined-literal',
|
||||||
|
],
|
||||||
|
}],
|
||||||
|
],
|
||||||
|
},
|
||||||
|
}
|
|
@ -13,9 +13,11 @@
|
||||||
|
|
||||||
namespace media {
|
namespace media {
|
||||||
|
|
||||||
#define TAG(a, b, c, d) \
|
#define TAG(a, b, c, d) \
|
||||||
((static_cast<uint8>(a) << 24) | (static_cast<uint8>(b) << 16) | \
|
((static_cast<uint32>(static_cast<uint8>(a)) << 24) | \
|
||||||
(static_cast<uint8>(c) << 8) | (static_cast<uint8>(d)))
|
(static_cast<uint8>(b) << 16) | \
|
||||||
|
(static_cast<uint8>(c) << 8) | \
|
||||||
|
(static_cast<uint8>(d)))
|
||||||
|
|
||||||
#define RCHECK(x) \
|
#define RCHECK(x) \
|
||||||
do { \
|
do { \
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'base',
|
'target_name': 'base',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'media_event',
|
'target_name': 'media_event',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'file',
|
'target_name': 'file',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'filters',
|
'target_name': 'filters',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'mp2t',
|
'target_name': 'mp2t',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'mp4',
|
'target_name': 'mp4',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'mpeg',
|
'target_name': 'mpeg',
|
||||||
|
|
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'../..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'run_all_unittests',
|
'target_name': 'run_all_unittests',
|
||||||
|
|
12
mpd/mpd.gyp
12
mpd/mpd.gyp
|
@ -7,15 +7,9 @@
|
||||||
# GYP file for any MPD generation targets.
|
# GYP file for any MPD generation targets.
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'../common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'..',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'media_info_proto',
|
'target_name': 'media_info_proto',
|
||||||
|
|
12
packager.gyp
12
packager.gyp
|
@ -5,15 +5,9 @@
|
||||||
# https://developers.google.com/open-source/licenses/bsd
|
# https://developers.google.com/open-source/licenses/bsd
|
||||||
|
|
||||||
{
|
{
|
||||||
'variables': {
|
'includes': [
|
||||||
# Compile as chromium code to enable warnings and warnings-as-errors.
|
'common.gypi',
|
||||||
'chromium_code': 1,
|
],
|
||||||
},
|
|
||||||
'target_defaults': {
|
|
||||||
'include_dirs': [
|
|
||||||
'.',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
'targets': [
|
'targets': [
|
||||||
{
|
{
|
||||||
'target_name': 'packager',
|
'target_name': 'packager',
|
||||||
|
|
Loading…
Reference in New Issue