From 526abaf6fbcd5948295776c54fc6aa777e5e19cb Mon Sep 17 00:00:00 2001 From: Chinmay Garde Date: Wed, 7 Jun 2017 12:16:58 -0700 Subject: [PATCH] Remove all (unused) gypi files from build/ (#70) --- build/android/apkbuilder_action.gypi | 79 - .../android/create_standalone_apk_action.gypi | 41 - .../android/developer_recommended_flags.gypi | 61 - build/android/dex_action.gypi | 60 - build/android/disable_lto.gypi | 20 - build/android/finalize_apk_action.gypi | 49 - build/android/finalize_splits_action.gypi | 76 - build/android/findbugs_action.gypi | 22 - build/android/increase_size_for_speed.gypi | 42 - build/android/insert_chromium_version.gypi | 53 - build/android/instr_action.gypi | 53 - build/android/java_cpp_enum.gypi | 64 - build/android/java_cpp_template.gypi | 81 - build/android/jinja_template.gypi | 85 - build/android/lint_action.gypi | 43 - build/android/locale_pak_resources.gypi | 52 - build/android/native_app_dependencies.gypi | 67 - build/android/pack_relocations.gypi | 77 - build/android/package_resources_action.gypi | 97 - build/android/push_libraries.gypi | 49 - build/android/strip_native_libraries.gypi | 54 - build/android/test_runner.gypi | 81 - build/android/write_ordered_libraries.gypi | 43 - build/apk_browsertest.gypi | 43 - build/apk_fake_jar.gypi | 15 - build/apk_test.gypi | 45 - build/chrome_settings.gypi | 30 - build/common.gypi | 6216 ----------------- build/common_untrusted.gypi | 40 - build/copy_test_data_ios.gypi | 53 - build/filename_rules.gypi | 106 - build/gn_migration.gypi | 723 -- build/grit_action.gypi | 71 - build/grit_target.gypi | 31 - build/host_jar.gypi | 146 - build/host_prebuilt_jar.gypi | 50 - build/internal/release_defaults.gypi | 18 - build/internal/release_impl.gypi | 17 - build/internal/release_impl_official.gypi | 41 - build/ios/coverage.gypi | 32 - build/ios/mac_build.gypi | 83 - build/isolate.gypi | 125 - build/jar_file_jni_generator.gypi | 67 - build/java.gypi | 368 - build/java_aidl.gypi | 79 - build/java_apk.gypi | 1063 --- build/java_prebuilt.gypi | 102 - build/java_strings_grd.gypi | 62 - build/jni_generator.gypi | 87 - build/json_schema_bundle_compile.gypi | 83 - ...on_schema_bundle_registration_compile.gypi | 78 - build/json_schema_compile.gypi | 123 - build/json_to_struct.gypi | 53 - build/nocompile.gypi | 96 - build/protoc.gypi | 123 - build/protoc_java.gypi | 83 - build/release.gypi | 29 - build/repack_action.gypi | 31 - build/set_clang_warning_flags.gypi | 58 - build/shim_headers.gypi | 60 - build/uiautomator_test.gypi | 37 - build/util/version.gypi | 20 - build/win/importlibs/create_import_lib.gypi | 53 - build/win_precompile.gypi | 20 - 64 files changed, 12009 deletions(-) delete mode 100644 build/android/apkbuilder_action.gypi delete mode 100644 build/android/create_standalone_apk_action.gypi delete mode 100644 build/android/developer_recommended_flags.gypi delete mode 100644 build/android/dex_action.gypi delete mode 100644 build/android/disable_lto.gypi delete mode 100644 build/android/finalize_apk_action.gypi delete mode 100644 build/android/finalize_splits_action.gypi delete mode 100644 build/android/findbugs_action.gypi delete mode 100644 build/android/increase_size_for_speed.gypi delete mode 100644 build/android/insert_chromium_version.gypi delete mode 100644 build/android/instr_action.gypi delete mode 100644 build/android/java_cpp_enum.gypi delete mode 100644 build/android/java_cpp_template.gypi delete mode 100644 build/android/jinja_template.gypi delete mode 100644 build/android/lint_action.gypi delete mode 100644 build/android/locale_pak_resources.gypi delete mode 100644 build/android/native_app_dependencies.gypi delete mode 100644 build/android/pack_relocations.gypi delete mode 100644 build/android/package_resources_action.gypi delete mode 100644 build/android/push_libraries.gypi delete mode 100644 build/android/strip_native_libraries.gypi delete mode 100644 build/android/test_runner.gypi delete mode 100644 build/android/write_ordered_libraries.gypi delete mode 100644 build/apk_browsertest.gypi delete mode 100644 build/apk_fake_jar.gypi delete mode 100644 build/apk_test.gypi delete mode 100644 build/chrome_settings.gypi delete mode 100644 build/common.gypi delete mode 100644 build/common_untrusted.gypi delete mode 100644 build/copy_test_data_ios.gypi delete mode 100644 build/filename_rules.gypi delete mode 100644 build/gn_migration.gypi delete mode 100644 build/grit_action.gypi delete mode 100644 build/grit_target.gypi delete mode 100644 build/host_jar.gypi delete mode 100644 build/host_prebuilt_jar.gypi delete mode 100644 build/internal/release_defaults.gypi delete mode 100644 build/internal/release_impl.gypi delete mode 100644 build/internal/release_impl_official.gypi delete mode 100644 build/ios/coverage.gypi delete mode 100644 build/ios/mac_build.gypi delete mode 100644 build/isolate.gypi delete mode 100644 build/jar_file_jni_generator.gypi delete mode 100644 build/java.gypi delete mode 100644 build/java_aidl.gypi delete mode 100644 build/java_apk.gypi delete mode 100644 build/java_prebuilt.gypi delete mode 100644 build/java_strings_grd.gypi delete mode 100644 build/jni_generator.gypi delete mode 100644 build/json_schema_bundle_compile.gypi delete mode 100644 build/json_schema_bundle_registration_compile.gypi delete mode 100644 build/json_schema_compile.gypi delete mode 100644 build/json_to_struct.gypi delete mode 100644 build/nocompile.gypi delete mode 100644 build/protoc.gypi delete mode 100644 build/protoc_java.gypi delete mode 100644 build/release.gypi delete mode 100644 build/repack_action.gypi delete mode 100644 build/set_clang_warning_flags.gypi delete mode 100644 build/shim_headers.gypi delete mode 100644 build/uiautomator_test.gypi delete mode 100644 build/util/version.gypi delete mode 100644 build/win/importlibs/create_import_lib.gypi delete mode 100644 build/win_precompile.gypi diff --git a/build/android/apkbuilder_action.gypi b/build/android/apkbuilder_action.gypi deleted file mode 100644 index 27807d861fbff..0000000000000 --- a/build/android/apkbuilder_action.gypi +++ /dev/null @@ -1,79 +0,0 @@ -# Copyright 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is a helper to java_apk.gypi. It should be used to create an -# action that runs ApkBuilder via ANT. -# -# Required variables: -# apk_name - File name (minus path & extension) of the output apk. -# apk_path - Path to output apk. -# package_input_paths - Late-evaluated list of resource zips. -# native_libs_dir - Path to lib/ directory to use. Set to an empty directory -# if no native libs are needed. -# Optional variables: -# has_code - Whether to include classes.dex in the apk. -# dex_path - Path to classes.dex. Used only when has_code=1. -# extra_inputs - List of extra action inputs. -{ - 'variables': { - 'variables': { - 'has_code%': 1, - }, - 'conditions': [ - ['has_code == 0', { - 'has_code_str': 'false', - }, { - 'has_code_str': 'true', - }], - ], - 'has_code%': '<(has_code)', - 'extra_inputs%': [], - # Write the inputs list to a file, so that its mtime is updated when - # the list of inputs changes. - 'inputs_list_file': '>|(apk_package.<(_target_name).<(apk_name).gypcmd >@(package_input_paths))', - 'resource_packaged_apk_name': '<(apk_name)-resources.ap_', - 'resource_packaged_apk_path': '<(intermediate_dir)/<(resource_packaged_apk_name)', - }, - 'action_name': 'apkbuilder_<(apk_name)', - 'message': 'Packaging <(apk_name)', - 'inputs': [ - '<(DEPTH)/build/android/ant/apk-package.xml', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/ant.py', - '<(resource_packaged_apk_path)', - '<@(extra_inputs)', - '>@(package_input_paths)', - '>(inputs_list_file)', - ], - 'outputs': [ - '<(apk_path)', - ], - 'conditions': [ - ['has_code == 1', { - 'inputs': ['<(dex_path)'], - 'action': [ - '-DDEX_FILE_PATH=<(dex_path)', - ] - }], - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/ant.py', - '--', - '-quiet', - '-DHAS_CODE=<(has_code_str)', - '-DANDROID_SDK_ROOT=<(android_sdk_root)', - '-DANDROID_SDK_TOOLS=<(android_sdk_tools)', - '-DRESOURCE_PACKAGED_APK_NAME=<(resource_packaged_apk_name)', - '-DNATIVE_LIBS_DIR=<(native_libs_dir)', - '-DAPK_NAME=<(apk_name)', - '-DCONFIGURATION_NAME=<(CONFIGURATION_NAME)', - '-DOUT_DIR=<(intermediate_dir)', - '-DUNSIGNED_APK_PATH=<(apk_path)', - '-DEMMA_INSTRUMENT=<(emma_instrument)', - '-DEMMA_DEVICE_JAR=<(emma_device_jar)', - '-Dbasedir=.', - '-buildfile', - '<(DEPTH)/build/android/ant/apk-package.xml', - ] -} diff --git a/build/android/create_standalone_apk_action.gypi b/build/android/create_standalone_apk_action.gypi deleted file mode 100644 index d17af7c8e5d9f..0000000000000 --- a/build/android/create_standalone_apk_action.gypi +++ /dev/null @@ -1,41 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide an action that -# combines a directory of shared libraries and an incomplete APK into a -# standalone APK. -# -# To use this, create a gyp action with the following form: -# { -# 'action_name': 'some descriptive action name', -# 'variables': { -# 'inputs': [ 'input_path1', 'input_path2' ], -# 'input_apk_path': '<(unsigned_apk_path)', -# 'output_apk_path': '<(unsigned_standalone_apk_path)', -# 'libraries_top_dir': '<(libraries_top_dir)', -# }, -# 'includes': [ 'relative/path/to/create_standalone_apk_action.gypi' ], -# }, - -{ - 'message': 'Creating standalone APK: <(output_apk_path)', - 'variables': { - 'inputs': [], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/create_standalone_apk.py', - '<(input_apk_path)', - '>@(inputs)', - ], - 'outputs': [ - '<(output_apk_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/create_standalone_apk.py', - '--libraries-top-dir=<(libraries_top_dir)', - '--input-apk-path=<(input_apk_path)', - '--output-apk-path=<(output_apk_path)', - ], -} diff --git a/build/android/developer_recommended_flags.gypi b/build/android/developer_recommended_flags.gypi deleted file mode 100644 index 79c201deccb3b..0000000000000 --- a/build/android/developer_recommended_flags.gypi +++ /dev/null @@ -1,61 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This is the set of recommended gyp variable settings for Chrome for Android development. -# -# These can be used by copying this file to $CHROME_SRC/chrome/supplement.gypi. -# -# Even better, create chrome/supplement.gypi containing the following: -# { -# 'includes': [ '../build/android/developer_recommended_flags.gypi' ] -# } -# and you'll get new settings automatically. -# When using this method, you can override individual settings by setting them unconditionally (with -# no %) in chrome/supplement.gypi. -# I.e. to disable gyp_managed_install but use everything else: -# { -# 'variables': { -# 'gyp_managed_install': 0, -# }, -# 'includes': [ '../build/android/developer_recommended_flags.gypi' ] -# } - -{ - 'variables': { - 'variables': { - # Set component to 'shared_library' to enable the component build. This builds native code as - # many small shared libraries instead of one monolithic library. This slightly reduces the time - # required for incremental builds. - 'component%': 'shared_library', - }, - 'component%': '<(component)', - - # When gyp_managed_install is set to 1, building an APK will install that APK on the connected - # device(/emulator). To install on multiple devices (or onto a new device), build the APK once - # with each device attached. This greatly reduces the time required for incremental builds. - # - # This comes with some caveats: - # Only works with a single device connected (it will print a warning if - # zero or multiple devices are attached). - # Device must be flashed with a user-debug unsigned Android build. - # Some actions are always run (i.e. ninja will never say "no work to do"). - 'gyp_managed_install%': 1, - - # With gyp_managed_install, we do not necessarily need a standalone APK. - # When create_standalone_apk is set to 1, we will build a standalone APK - # anyway. For even faster builds, you can set create_standalone_apk to 0. - 'create_standalone_apk%': 1, - - # Set clang to 1 to use the clang compiler. Clang has much (much, much) better warning/error - # messages than gcc. - # TODO(cjhopman): Enable this when http://crbug.com/156420 is addressed. Until then, users can - # set clang to 1, but Android stack traces will sometimes be incomplete. - #'clang%': 1, - - # Set fastbuild to 1 to build with less debugging information. This can greatly decrease linking - # time. The downside is that stack traces will be missing useful information (like line - # numbers). - #'fastbuild%': 1, - }, -} diff --git a/build/android/dex_action.gypi b/build/android/dex_action.gypi deleted file mode 100644 index 56d386ffad1e7..0000000000000 --- a/build/android/dex_action.gypi +++ /dev/null @@ -1,60 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that dexes -# compiled java files. If proguard_enabled == "true" and CONFIGURATION_NAME == -# "Release", then it will dex the proguard_enabled_input_path instead of the -# normal dex_input_paths/dex_generated_input_paths. -# -# To use this, create a gyp target with the following form: -# { -# 'action_name': 'some name for the action' -# 'actions': [ -# 'variables': { -# 'dex_input_paths': [ 'files to dex (when proguard is not used) and add to input paths' ], -# 'dex_generated_input_dirs': [ 'dirs that contain generated files to dex' ], -# -# # For targets that use proguard: -# 'proguard_enabled': 'true', -# 'proguard_enabled_input_path': 'path to dex when using proguard', -# }, -# 'includes': [ 'relative/path/to/dex_action.gypi' ], -# ], -# }, -# - -{ - 'message': 'Creating dex file: <(output_path)', - 'variables': { - 'dex_input_paths': [], - 'dex_generated_input_dirs': [], - 'proguard_enabled%': 'false', - 'proguard_enabled_input_path%': '', - 'dex_no_locals%': 0, - 'dex_additional_options': [], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/util/md5_check.py', - '<(DEPTH)/build/android/gyp/dex.py', - '>@(dex_input_paths)', - ], - 'outputs': [ - '<(output_path)', - '<(output_path).inputs', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/dex.py', - '--dex-path=<(output_path)', - '--android-sdk-tools=<(android_sdk_tools)', - '--output-directory=<(PRODUCT_DIR)', - '--configuration-name=<(CONFIGURATION_NAME)', - '--proguard-enabled=>(proguard_enabled)', - '--proguard-enabled-input-path=<(proguard_enabled_input_path)', - '--no-locals=>(dex_no_locals)', - '>@(dex_additional_options)', - '>@(dex_input_paths)', - '>@(dex_generated_input_dirs)', - ] -} diff --git a/build/android/disable_lto.gypi b/build/android/disable_lto.gypi deleted file mode 100644 index e379cfd3199ae..0000000000000 --- a/build/android/disable_lto.gypi +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright (c) 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included to disable LTO on a target. - -{ - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - ['OS=="android" and (use_lto==1 or use_lto_o2==1)', { - 'cflags!': [ - '-flto', - '-ffat-lto-objects', - ], - }], - ], - }], - ], -} diff --git a/build/android/finalize_apk_action.gypi b/build/android/finalize_apk_action.gypi deleted file mode 100644 index 644f9e8ecc5b2..0000000000000 --- a/build/android/finalize_apk_action.gypi +++ /dev/null @@ -1,49 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide an action that -# signs and zipaligns an APK. -# -# To use this, create a gyp action with the following form: -# { -# 'action_name': 'some descriptive action name', -# 'variables': { -# 'input_apk_path': 'relative/path/to/input.apk', -# 'output_apk_path': 'relative/path/to/output.apk', -# }, -# 'includes': [ '../../build/android/finalize_apk_action.gypi' ], -# }, -# - -{ - 'message': 'Signing/aligning <(_target_name) APK: <(input_apk_path)', - 'variables': { - 'keystore_path%': '<(DEPTH)/build/android/ant/chromium-debug.keystore', - 'keystore_name%': 'chromiumdebugkey', - 'keystore_password%': 'chromium', - 'zipalign_path%': '<(android_sdk_tools)/zipalign', - 'rezip_apk_jar_path%': '<(PRODUCT_DIR)/lib.java/rezip_apk.jar', - 'load_library_from_zip%': 0, - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/finalize_apk.py', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(keystore_path)', - '<(input_apk_path)', - ], - 'outputs': [ - '<(output_apk_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/finalize_apk.py', - '--zipalign-path=<(zipalign_path)', - '--unsigned-apk-path=<(input_apk_path)', - '--final-apk-path=<(output_apk_path)', - '--key-path=<(keystore_path)', - '--key-name=<(keystore_name)', - '--key-passwd=<(keystore_password)', - '--load-library-from-zip=<(load_library_from_zip)', - '--rezip-apk-jar-path=<(rezip_apk_jar_path)', - ], -} diff --git a/build/android/finalize_splits_action.gypi b/build/android/finalize_splits_action.gypi deleted file mode 100644 index daa7f834ebb08..0000000000000 --- a/build/android/finalize_splits_action.gypi +++ /dev/null @@ -1,76 +0,0 @@ -# Copyright 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide an action that -# signs and zipaligns split APKs. -# -# Required variables: -# apk_name - Base name of the apk. -# Optional variables: -# density_splits - Whether to process density splits -# language_splits - Whether to language splits - -{ - 'variables': { - 'keystore_path%': '<(DEPTH)/build/android/ant/chromium-debug.keystore', - 'keystore_name%': 'chromiumdebugkey', - 'keystore_password%': 'chromium', - 'zipalign_path%': '<(android_sdk_tools)/zipalign', - 'density_splits%': 0, - 'language_splits%': [], - 'resource_packaged_apk_name': '<(apk_name)-resources.ap_', - 'resource_packaged_apk_path': '<(intermediate_dir)/<(resource_packaged_apk_name)', - 'base_output_path': '<(PRODUCT_DIR)/apks/<(apk_name)', - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/finalize_splits.py', - '<(DEPTH)/build/android/gyp/finalize_apk.py', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(keystore_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/finalize_splits.py', - '--resource-packaged-apk-path=<(resource_packaged_apk_path)', - '--base-output-path=<(base_output_path)', - '--zipalign-path=<(zipalign_path)', - '--key-path=<(keystore_path)', - '--key-name=<(keystore_name)', - '--key-passwd=<(keystore_password)', - ], - 'conditions': [ - ['density_splits == 1', { - 'message': 'Signing/aligning <(_target_name) density splits', - 'inputs': [ - '<(resource_packaged_apk_path)_hdpi', - '<(resource_packaged_apk_path)_xhdpi', - '<(resource_packaged_apk_path)_xxhdpi', - '<(resource_packaged_apk_path)_xxxhdpi', - '<(resource_packaged_apk_path)_tvdpi', - ], - 'outputs': [ - '<(base_output_path)-density-hdpi.apk', - '<(base_output_path)-density-xhdpi.apk', - '<(base_output_path)-density-xxhdpi.apk', - '<(base_output_path)-density-xxxhdpi.apk', - '<(base_output_path)-density-tvdpi.apk', - ], - 'action': [ - '--densities=hdpi,xhdpi,xxhdpi,xxxhdpi,tvdpi', - ], - }], - ['language_splits != []', { - 'message': 'Signing/aligning <(_target_name) language splits', - 'inputs': [ - "(auxclasspath)', - '--stamp', '<(stamp_path)', - '<(findbugs_target_jar_path)', - ], -} diff --git a/build/android/increase_size_for_speed.gypi b/build/android/increase_size_for_speed.gypi deleted file mode 100644 index 48d17f5f19c14..0000000000000 --- a/build/android/increase_size_for_speed.gypi +++ /dev/null @@ -1,42 +0,0 @@ -# Copyright (c) 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included to optimize a target for speed -# rather than for size on Android. -# This is used in some carefully tailored targets and is not meant -# to be included everywhere. Before adding the template to another target, -# please ask in chromium-dev@. See crbug.com/411909 - -{ - 'configurations': { - 'Release': { - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - ['OS=="android"', { - 'cflags!': ['-Os'], - 'cflags': ['-O2'], - }], - # Do not merge -Os and -O2 in LTO. - # LTO merges all optimization options at link-time. -O2 takes - # precedence over -Os. Avoid using LTO simultaneously - # on -Os and -O2 parts for that reason. - ['OS=="android" and use_lto==1', { - 'cflags!': [ - '-flto', - '-ffat-lto-objects', - ], - }], - ['OS=="android" and use_lto_o2==1', { - 'cflags': [ - '-flto', - '-ffat-lto-objects', - ], - }], - ], - }], - ], - }, - }, -} diff --git a/build/android/insert_chromium_version.gypi b/build/android/insert_chromium_version.gypi deleted file mode 100644 index a6ff9081086c7..0000000000000 --- a/build/android/insert_chromium_version.gypi +++ /dev/null @@ -1,53 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that -# inserts a chromium version string into native libraries. -# -# To use this, create a gyp target with the following form: -# { -# 'action_name': 'insert_chromium_version', -# 'actions': [ -# 'variables': { -# 'ordered_libraries_file': 'file generated by write_ordered_libraries' -# 'stripped_libraries_dir': 'the directory contains native libraries' -# 'input_paths': 'files to be added to the list of inputs' -# 'stamp': 'file to touch when the action is complete' -# 'version_string': 'chromium version string to be inserted' -# 'includes': [ '../../build/android/insert_chromium_version.gypi' ], -# ], -# }, -# - -{ - 'message': 'Inserting chromium version string into native libraries', - 'variables': { - 'input_paths': [], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/insert_chromium_version.py', - '<(ordered_libraries_file)', - '>@(input_paths)', - ], - 'outputs': [ - '<(stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/insert_chromium_version.py', - '--android-objcopy=<(android_objcopy)', - '--stripped-libraries-dir=<(stripped_libraries_dir)', - '--libraries=@FileArg(<(ordered_libraries_file):libraries)', - '--version-string=<(version_string)', - '--stamp=<(stamp)', - ], - 'conditions': [ - ['component == "shared_library"', { - # Add a fake output to force the build to always re-run this step. This - # is required because the real inputs are not known at gyp-time and - # changing base.so may not trigger changes to dependent libraries. - 'outputs': [ '<(stamp).fake' ] - }], - ], -} diff --git a/build/android/instr_action.gypi b/build/android/instr_action.gypi deleted file mode 100644 index fa6d06235ea16..0000000000000 --- a/build/android/instr_action.gypi +++ /dev/null @@ -1,53 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that -# instruments either java class files, or jars. - -{ - 'variables': { - 'instr_type%': 'jar', - 'input_path%': '', - 'output_path%': '', - 'stamp_path%': '', - 'extra_instr_args': [ - '--coverage-file=<(_target_name).em', - '--sources-file=<(_target_name)_sources.txt', - ], - 'emma_jar': '<(android_sdk_root)/tools/lib/emma.jar', - 'conditions': [ - ['emma_instrument != 0', { - 'extra_instr_args': [ - '--sources=<(java_in_dir)/src >(additional_src_dirs) >(generated_src_dirs)', - '--src-root=<(DEPTH)', - '--emma-jar=<(emma_jar)', - '--filter-string=<(emma_filter)', - ], - 'conditions': [ - ['instr_type == "jar"', { - 'instr_action': 'instrument_jar', - }, { - 'instr_action': 'instrument_classes', - }] - ], - }, { - 'instr_action': 'copy', - 'extra_instr_args': [], - }] - ] - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/emma_instr.py', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/pylib/utils/command_option_parser.py', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/emma_instr.py', - '<(instr_action)', - '--input-path=<(input_path)', - '--output-path=<(output_path)', - '--stamp=<(stamp_path)', - '<@(extra_instr_args)', - ] -} diff --git a/build/android/java_cpp_enum.gypi b/build/android/java_cpp_enum.gypi deleted file mode 100644 index d4abafa812f95..0000000000000 --- a/build/android/java_cpp_enum.gypi +++ /dev/null @@ -1,64 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide an action -# to generate Java source files from a C++ header file containing annotated -# enum definitions using a Python script. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'bitmap_format_java', -# 'type': 'none', -# 'variables': { -# 'source_file': 'ui/android/bitmap_format.h', -# }, -# 'includes': [ '../build/android/java_cpp_enum.gypi' ], -# }, -# -# Then have the gyp target which compiles the java code depend on the newly -# created target. - -{ - 'variables': { - # Location where all generated Java sources will be placed. - 'output_dir': '<(SHARED_INTERMEDIATE_DIR)/enums/<(_target_name)', - 'generator_path': '<(DEPTH)/build/android/gyp/java_cpp_enum.py', - 'generator_args': '<(output_dir) <(source_file)', - }, - 'direct_dependent_settings': { - 'variables': { - # Ensure that the output directory is used in the class path - # when building targets that depend on this one. - 'generated_src_dirs': [ - '<(output_dir)/', - ], - # Ensure that the targets depending on this one are rebuilt if the sources - # of this one are modified. - 'additional_input_paths': [ - '<(source_file)', - ], - }, - }, - 'actions': [ - { - 'action_name': 'generate_java_constants', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(generator_path)', - '<(source_file)', - ], - 'outputs': [ - # This is the main reason this is an action and not a rule. Gyp doesn't - # properly expand RULE_INPUT_PATH here and so it's impossible to - # calculate the list of outputs. - '//ClassName.java. The files which -# template dependents on and typically included by the template should be listed -# in template_deps variables. Any change to them will force a rebuild of -# the template, and hence of any source that depends on it. -# - -{ - # Location where all generated Java sources will be placed. - 'variables': { - 'include_path%': '<(DEPTH)', - 'output_dir': '<(SHARED_INTERMEDIATE_DIR)/templates/<(_target_name)/<(package_name)', - }, - 'direct_dependent_settings': { - 'variables': { - # Ensure that the output directory is used in the class path - # when building targets that depend on this one. - 'generated_src_dirs': [ - '<(output_dir)/', - ], - # Ensure dependents are rebuilt when sources for this rule change. - 'additional_input_paths': [ - '<@(_sources)', - '<@(template_deps)', - ], - }, - }, - # Define a single rule that will be apply to each .template file - # listed in 'sources'. - 'rules': [ - { - 'rule_name': 'generate_java_constants', - 'extension': 'template', - # Set template_deps as additional dependencies. - 'variables': { - 'output_path': '<(output_dir)/<(RULE_INPUT_ROOT).java', - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/gcc_preprocess.py', - '<@(template_deps)' - ], - 'outputs': [ - '<(output_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/gcc_preprocess.py', - '--include-path=<(include_path)', - '--output=<(output_path)', - '--template=<(RULE_INPUT_PATH)', - ], - 'message': 'Generating Java from cpp template <(RULE_INPUT_PATH)', - } - ], -} diff --git a/build/android/jinja_template.gypi b/build/android/jinja_template.gypi deleted file mode 100644 index 9c49360dc6ef0..0000000000000 --- a/build/android/jinja_template.gypi +++ /dev/null @@ -1,85 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to process one or more -# Jinja templates. -# -# To process a single template file, create a gyp target with the following -# form: -# { -# 'target_name': 'chrome_shell_manifest', -# 'type': 'none', -# 'variables': { -# 'jinja_inputs': ['android/shell/java/AndroidManifest.xml'], -# 'jinja_output': '<(SHARED_INTERMEDIATE_DIR)/chrome_shell_manifest/AndroidManifest.xml', -# 'jinja_variables': ['app_name=ChromeShell'], -# }, -# 'includes': [ '../build/android/jinja_template.gypi' ], -# }, -# -# To process multiple template files and package the results into a zip file, -# create a gyp target with the following form: -# { -# 'target_name': 'chrome_template_resources', -# 'type': 'none', -# 'variables': { -# 'jinja_inputs_base_dir': 'android/shell/java/res_template', -# 'jinja_inputs': [ -# '<(jinja_inputs_base_dir)/xml/searchable.xml', -# '<(jinja_inputs_base_dir)/xml/syncadapter.xml', -# ], -# 'jinja_outputs_zip': '<(PRODUCT_DIR)/res.java/<(_target_name).zip', -# 'jinja_variables': ['app_name=ChromeShell'], -# }, -# 'includes': [ '../build/android/jinja_template.gypi' ], -# }, -# - -{ - 'actions': [ - { - 'action_name': '<(_target_name)_jinja_template', - 'message': 'processing jinja template', - 'variables': { - 'jinja_output%': '', - 'jinja_outputs_zip%': '', - 'jinja_inputs_base_dir%': '', - 'jinja_includes%': [], - 'jinja_variables%': [], - 'jinja_args': [], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/jinja_template.py', - '<@(jinja_inputs)', - '<@(jinja_includes)', - ], - 'conditions': [ - ['jinja_output != ""', { - 'outputs': [ '<(jinja_output)' ], - 'variables': { - 'jinja_args': ['--output', '<(jinja_output)'], - }, - }], - ['jinja_outputs_zip != ""', { - 'outputs': [ '<(jinja_outputs_zip)' ], - 'variables': { - 'jinja_args': ['--outputs-zip', '<(jinja_outputs_zip)'], - }, - }], - ['jinja_inputs_base_dir != ""', { - 'variables': { - 'jinja_args': ['--inputs-base-dir', '<(jinja_inputs_base_dir)'], - }, - }], - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/jinja_template.py', - '--inputs', '<(jinja_inputs)', - '--variables', '<(jinja_variables)', - '<@(jinja_args)', - ], - }, - ], -} diff --git a/build/android/lint_action.gypi b/build/android/lint_action.gypi deleted file mode 100644 index e1adf1f842c30..0000000000000 --- a/build/android/lint_action.gypi +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule to -# run lint on java/class files. - -{ - 'action_name': 'lint_<(_target_name)', - 'message': 'Linting <(_target_name)', - 'variables': { - 'conditions': [ - ['chromium_code != 0 and android_lint != 0 and never_lint == 0', { - 'is_enabled': '--enable', - }, { - 'is_enabled': '', - }] - ], - 'android_manifest_path%': '<(DEPTH)/build/android/AndroidManifest.xml', - 'resource_dir%': '<(DEPTH)/build/android/ant/empty/res', - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/lint.py', - '<(DEPTH)/build/android/lint/suppressions.xml', - '<(lint_jar_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/lint.py', - '--lint-path=<(android_sdk_root)/tools/lint', - '--config-path=<(DEPTH)/build/android/lint/suppressions.xml', - '--processed-config-path=<(config_path)', - '--manifest-path=<(android_manifest_path)', - '--result-path=<(result_path)', - '--resource-dir=<(resource_dir)', - '--product-dir=<(PRODUCT_DIR)', - '--src-dirs=>(src_dirs)', - '--jar-path=<(lint_jar_path)', - '--can-fail-build', - '--stamp=<(stamp_path)', - '<(is_enabled)', - ], -} diff --git a/build/android/locale_pak_resources.gypi b/build/android/locale_pak_resources.gypi deleted file mode 100644 index 6f8e56f8f15c2..0000000000000 --- a/build/android/locale_pak_resources.gypi +++ /dev/null @@ -1,52 +0,0 @@ -# Copyright 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# Creates a resources.zip with locale.pak files placed into appropriate -# resource configs (e.g. en-GB.pak -> res/raw-en/en_gb.pak). Also generates -# a locale_paks TypedArray so that resource files can be enumerated at runtime. -# -# If this target is included in the deps of an android resources/library/apk, -# the resources will be included with that target. -# -# Variables: -# locale_pak_files - List of .pak files to process. -# Names must be of the form "en.pak" or "en-US.pak". -# -# Example -# { -# 'target_name': 'my_locale_resources', -# 'type': 'none', -# 'variables': { -# 'locale_paks_files': ['path1/fr.pak'], -# }, -# 'includes': [ '../build/android/locale_pak_resources.gypi' ], -# }, -# -{ - 'variables': { - 'resources_zip_path': '<(PRODUCT_DIR)/res.java/<(_target_name).zip', - }, - 'all_dependent_settings': { - 'variables': { - 'additional_input_paths': ['<(resources_zip_path)'], - 'dependencies_res_zip_paths': ['<(resources_zip_path)'], - }, - }, - 'actions': [{ - 'action_name': '<(_target_name)_locale_pak_resources', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/locale_pak_resources.py', - '<@(locale_pak_files)', - ], - 'outputs': [ - '<(resources_zip_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/locale_pak_resources.py', - '--locale-paks', '<(locale_pak_files)', - '--resources-zip', '<(resources_zip_path)', - ], - }], -} diff --git a/build/android/native_app_dependencies.gypi b/build/android/native_app_dependencies.gypi deleted file mode 100644 index 6032274dbbabf..0000000000000 --- a/build/android/native_app_dependencies.gypi +++ /dev/null @@ -1,67 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to strip and place dependent shared libraries required by a native binary in a -# single folder that can later be pushed to the device. -# -# NOTE: consider packaging your binary as an apk instead of running a native -# library. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'target_that_depends_on_my_binary', -# 'type': 'none', -# 'dependencies': [ -# 'my_binary', -# ], -# 'variables': { -# 'native_binary': '<(PRODUCT_DIR)/my_binary', -# 'output_dir': 'location to place binary and dependent libraries' -# }, -# 'includes': [ '../../build/android/native_app_dependencies.gypi' ], -# }, -# - -{ - 'variables': { - 'include_main_binary%': 1, - }, - 'conditions': [ - ['component == "shared_library"', { - 'dependencies': [ - '<(DEPTH)/build/android/setup.gyp:copy_system_libraries', - ], - 'variables': { - 'intermediate_dir': '<(PRODUCT_DIR)/<(_target_name)', - 'ordered_libraries_file': '<(intermediate_dir)/native_libraries.json', - }, - 'actions': [ - { - 'variables': { - 'input_libraries': ['<(native_binary)'], - }, - 'includes': ['../../build/android/write_ordered_libraries.gypi'], - }, - { - 'action_name': 'stripping native libraries', - 'variables': { - 'stripped_libraries_dir%': '<(output_dir)', - 'input_paths': ['<(native_binary)'], - 'stamp': '<(intermediate_dir)/strip.stamp', - }, - 'includes': ['../../build/android/strip_native_libraries.gypi'], - }, - ], - }], - ['include_main_binary==1', { - 'copies': [ - { - 'destination': '<(output_dir)', - 'files': [ '<(native_binary)' ], - } - ], - }], - ], -} diff --git a/build/android/pack_relocations.gypi b/build/android/pack_relocations.gypi deleted file mode 100644 index 8567fa6e45f18..0000000000000 --- a/build/android/pack_relocations.gypi +++ /dev/null @@ -1,77 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that -# packs relocations in Release builds of native libraries. -# -# To use this, create a gyp target with the following form: -# { -# 'action_name': 'pack_relocations', -# 'actions': [ -# 'variables': { -# 'enable_packing': 'pack relocations if 1, plain file copy if 0' -# 'exclude_packing_list': 'names of libraries explicitly not packed', -# 'ordered_libraries_file': 'file generated by write_ordered_libraries' -# 'input_paths': 'files to be added to the list of inputs' -# 'stamp': 'file to touch when the action is complete' -# 'stripped_libraries_dir': 'directory holding stripped libraries', -# 'packed_libraries_dir': 'directory holding packed libraries', -# 'includes': [ '../../build/android/pack_relocations.gypi' ], -# ], -# }, -# - -{ - 'variables': { - 'input_paths': [], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/pack_relocations.py', - '<(ordered_libraries_file)', - '>@(input_paths)', - ], - 'outputs': [ - '<(stamp)', - ], - 'conditions': [ - ['enable_packing == 1', { - 'message': 'Packing relocations for <(_target_name)', - 'dependencies': [ - '<(DEPTH)/third_party/android_platform/relocation_packer.gyp:android_relocation_packer#host', - ], - 'inputs': [ - '<(PRODUCT_DIR)/android_relocation_packer', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/pack_relocations.py', - '--configuration-name=<(CONFIGURATION_NAME)', - '--enable-packing=1', - '--exclude-packing-list=<@(exclude_packing_list)', - '--android-pack-relocations=<(PRODUCT_DIR)/android_relocation_packer', - '--stripped-libraries-dir=<(stripped_libraries_dir)', - '--packed-libraries-dir=<(packed_libraries_dir)', - '--libraries=@FileArg(<(ordered_libraries_file):libraries)', - '--stamp=<(stamp)', - ], - }, { - 'message': 'Copying libraries (no relocation packing) for <(_target_name)', - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/pack_relocations.py', - '--configuration-name=<(CONFIGURATION_NAME)', - '--enable-packing=0', - '--stripped-libraries-dir=<(stripped_libraries_dir)', - '--packed-libraries-dir=<(packed_libraries_dir)', - '--libraries=@FileArg(<(ordered_libraries_file):libraries)', - '--stamp=<(stamp)', - ], - }], - ['component == "shared_library"', { - # Add a fake output to force the build to always re-run this step. This - # is required because the real inputs are not known at gyp-time and - # changing base.so may not trigger changes to dependent libraries. - 'outputs': [ '<(stamp).fake' ] - }], - ], -} diff --git a/build/android/package_resources_action.gypi b/build/android/package_resources_action.gypi deleted file mode 100644 index eb608718951b2..0000000000000 --- a/build/android/package_resources_action.gypi +++ /dev/null @@ -1,97 +0,0 @@ -# Copyright 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is a helper to java_apk.gypi. It should be used to create an -# action that runs ApkBuilder via ANT. -# -# Required variables: -# apk_name - File name (minus path & extension) of the output apk. -# android_manifest_path - Path to AndroidManifest.xml. -# app_manifest_version_name - set the apps 'human readable' version number. -# app_manifest_version_code - set the apps version number. -# Optional variables: -# asset_location - The directory where assets are located (if any). -# create_density_splits - Whether to create density-based apk splits. Splits -# are supported only for minSdkVersion >= 21. -# language_splits - List of languages to create apk splits for. -# resource_zips - List of paths to resource zip files. -# shared_resources - Make a resource package that can be loaded by a different -# application at runtime to access the package's resources. -# extensions_to_not_compress - E.g.: 'pak,dat,bin' -# extra_inputs - List of extra action inputs. -{ - 'variables': { - 'asset_location%': '', - 'create_density_splits%': 0, - 'resource_zips%': [], - 'shared_resources%': 0, - 'extensions_to_not_compress%': '', - 'extra_inputs%': [], - 'resource_packaged_apk_name': '<(apk_name)-resources.ap_', - 'resource_packaged_apk_path': '<(intermediate_dir)/<(resource_packaged_apk_name)', - }, - 'action_name': 'package_resources_<(apk_name)', - 'message': 'packaging resources for <(apk_name)', - 'inputs': [ - # TODO: This isn't always rerun correctly, http://crbug.com/351928 - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/package_resources.py', - '<(android_manifest_path)', - '<@(extra_inputs)', - ], - 'outputs': [ - '<(resource_packaged_apk_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/package_resources.py', - '--android-sdk', '<(android_sdk)', - '--aapt-path', '<(android_aapt_path)', - '--configuration-name', '<(CONFIGURATION_NAME)', - '--android-manifest', '<(android_manifest_path)', - '--version-code', '<(app_manifest_version_code)', - '--version-name', '<(app_manifest_version_name)', - '--no-compress', '<(extensions_to_not_compress)', - '--apk-path', '<(resource_packaged_apk_path)', - ], - 'conditions': [ - ['shared_resources == 1', { - 'action': [ - '--shared-resources', - ], - }], - ['asset_location != ""', { - 'action': [ - '--asset-dir', '<(asset_location)', - ], - }], - ['create_density_splits == 1', { - 'action': [ - '--create-density-splits', - ], - 'outputs': [ - '<(resource_packaged_apk_path)_hdpi', - '<(resource_packaged_apk_path)_xhdpi', - '<(resource_packaged_apk_path)_xxhdpi', - '<(resource_packaged_apk_path)_xxxhdpi', - '<(resource_packaged_apk_path)_tvdpi', - ], - }], - ['language_splits != []', { - 'action': [ - '--language-splits=<(language_splits)', - ], - 'outputs': [ - "(resource_zips)', - ], - 'inputs': [ - '>@(resource_zips)', - ], - }], - ], -} diff --git a/build/android/push_libraries.gypi b/build/android/push_libraries.gypi deleted file mode 100644 index 773c44f8ab1cc..0000000000000 --- a/build/android/push_libraries.gypi +++ /dev/null @@ -1,49 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that -# pushes stripped shared libraries to the attached Android device. This should -# only be used with the gyp_managed_install flag set. -# -# To use this, create a gyp target with the following form: -# { -# 'actions': [ -# 'variables': { -# 'ordered_libraries_file': 'file generated by write_ordered_libraries' -# 'strip_stamp': 'stamp from strip action to block on' -# 'libraries_source_dir': 'location where stripped libraries are stored' -# 'device_library_dir': 'location on the device where to put pushed libraries', -# 'push_stamp': 'file to touch when the action is complete' -# 'configuration_name': 'The build CONFIGURATION_NAME' -# }, -# 'includes': [ '../../build/android/push_libraries.gypi' ], -# ], -# }, -# - -{ - 'action_name': 'push_libraries_<(_target_name)', - 'message': 'Pushing libraries to device for <(_target_name)', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/util/md5_check.py', - '<(DEPTH)/build/android/gyp/push_libraries.py', - '<(strip_stamp)', - '<(strip_additional_stamp)', - '<(build_device_config_path)', - '<(pack_relocations_stamp)', - ], - 'outputs': [ - '<(push_stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/push_libraries.py', - '--build-device-configuration=<(build_device_config_path)', - '--libraries-dir=<(libraries_source_dir)', - '--device-dir=<(device_library_dir)', - '--libraries=@FileArg(<(ordered_libraries_file):libraries)', - '--stamp=<(push_stamp)', - '--configuration-name=<(configuration_name)', - ], -} diff --git a/build/android/strip_native_libraries.gypi b/build/android/strip_native_libraries.gypi deleted file mode 100644 index bdffcfd04941a..0000000000000 --- a/build/android/strip_native_libraries.gypi +++ /dev/null @@ -1,54 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that strips -# native libraries. -# -# To use this, create a gyp target with the following form: -# { -# 'action_name': 'strip_native_libraries', -# 'actions': [ -# 'variables': { -# 'ordered_libraries_file': 'file generated by write_ordered_libraries' -# 'input_paths': 'files to be added to the list of inputs' -# 'stamp': 'file to touch when the action is complete' -# 'stripped_libraries_dir': 'directory to store stripped libraries', -# }, -# 'includes': [ '../../build/android/strip_native_libraries.gypi' ], -# ], -# }, -# - -{ - 'message': 'Stripping libraries for <(_target_name)', - 'variables': { - 'input_paths': [], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/strip_library_for_device.py', - '<(ordered_libraries_file)', - '>@(input_paths)', - ], - 'outputs': [ - '<(stamp)', - ], - 'conditions': [ - ['component == "shared_library"', { - # Add a fake output to force the build to always re-run this step. This - # is required because the real inputs are not known at gyp-time and - # changing base.so may not trigger changes to dependent libraries. - 'outputs': [ '<(stamp).fake' ] - }], - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/strip_library_for_device.py', - '--android-strip=<(android_strip)', - '--android-strip-arg=--strip-unneeded', - '--stripped-libraries-dir=<(stripped_libraries_dir)', - '--libraries-dir=<(SHARED_LIB_DIR),<(PRODUCT_DIR)', - '--libraries=@FileArg(<(ordered_libraries_file):libraries)', - '--stamp=<(stamp)', - ], -} diff --git a/build/android/test_runner.gypi b/build/android/test_runner.gypi deleted file mode 100644 index f92b7cedc0e2c..0000000000000 --- a/build/android/test_runner.gypi +++ /dev/null @@ -1,81 +0,0 @@ -# Copyright 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# Generates a script in the output bin directory which runs the test -# target using the test runner script in build/android/pylib/test_runner.py. -# -# To use this, include this file in a gtest or instrumentation test target. -# { -# 'target_name': 'gtest', -# 'type': 'none', -# 'variables': { -# 'test_type': 'gtest', # string -# 'test_suite_name': 'gtest_suite' # string -# 'isolate_file': 'path/to/gtest.isolate' # string -# }, -# 'includes': ['path/to/this/gypi/file'], -# } -# -# { -# 'target_name': 'instrumentation_apk', -# 'type': 'none', -# 'variables': { -# 'test_type': 'instrumentation', # string -# 'apk_name': 'TestApk' # string -# 'isolate_file': 'path/to/instrumentation_test.isolate' # string -# }, -# 'includes': ['path/to/this/gypi/file'], -# } -# - -{ - 'variables': { - 'variables': { - 'isolate_file%': '', - 'support_apk_path%': '', - }, - 'test_runner_args': ['--output-directory', '<(PRODUCT_DIR)'], - 'conditions': [ - ['test_type == "gtest"', { - 'test_runner_args': ['--suite', '<(test_suite_name)'], - 'script_name': 'run_<(test_suite_name)', - }], - ['test_type == "instrumentation"', { - 'test_runner_args': ['--test-apk', '<(apk_name)'], - 'script_name': 'run_<(_target_name)', - 'conditions': [ - ['support_apk_path != ""', { - 'test_runner_args': [ - '--support-apk', - '<(support_apk_path)' - ], - }], - ], - }], - ['isolate_file != ""', { - 'test_runner_args': ['--isolate-file-path', '<(isolate_file)'] - }], - ], - }, - 'actions': [ - { - 'action_name': 'create_test_runner_script_<(script_name)', - 'message': 'Creating test runner script <(script_name)', - 'variables': { - 'script_output_path': '<(PRODUCT_DIR)/bin/<(script_name)', - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/create_test_runner_script.py', - ], - 'outputs': [ - '<(script_output_path)' - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/create_test_runner_script.py', - '--script-output-path=<(script_output_path)', - '<(test_type)', '<@(test_runner_args)', - ], - }, - ], -} \ No newline at end of file diff --git a/build/android/write_ordered_libraries.gypi b/build/android/write_ordered_libraries.gypi deleted file mode 100644 index 1b52e71e4231c..0000000000000 --- a/build/android/write_ordered_libraries.gypi +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to provide a rule that -# generates a json file with the list of dependent libraries needed for a given -# shared library or executable. -# -# To use this, create a gyp target with the following form: -# { -# 'actions': [ -# 'variables': { -# 'input_libraries': 'shared library or executable to process', -# 'ordered_libraries_file': 'file to generate' -# }, -# 'includes': [ '../../build/android/write_ordered_libraries.gypi' ], -# ], -# }, -# - -{ - 'action_name': 'ordered_libraries_<(_target_name)<(subtarget)', - 'message': 'Writing dependency ordered libraries for <(_target_name)', - 'variables': { - 'input_libraries%': [], - 'subtarget%': '', - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/write_ordered_libraries.py', - '<@(input_libraries)', - ], - 'outputs': [ - '<(ordered_libraries_file)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/write_ordered_libraries.py', - '--input-libraries=<(input_libraries)', - '--libraries-dir=<(SHARED_LIB_DIR),<(PRODUCT_DIR)', - '--readelf=<(android_readelf)', - '--output=<(ordered_libraries_file)', - ], -} diff --git a/build/apk_browsertest.gypi b/build/apk_browsertest.gypi deleted file mode 100644 index 316f52fb85332..0000000000000 --- a/build/apk_browsertest.gypi +++ /dev/null @@ -1,43 +0,0 @@ -# Copyright 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to build APK-based browser test suites. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'test_suite_name_apk', -# 'type': 'none', -# 'variables': { -# 'test_suite_name': 'test_suite_name', # string -# 'java_in_dir': 'path/to/java/dir', -# }, -# 'includes': ['path/to/this/gypi/file'], -# } -# - -{ - 'dependencies': [ - '<(DEPTH)/base/base.gyp:base_java', - '<(DEPTH)/build/android/pylib/device/commands/commands.gyp:chromium_commands', - '<(DEPTH)/build/android/pylib/remote/device/dummy/dummy.gyp:remote_device_dummy_apk', - '<(DEPTH)/testing/android/appurify_support.gyp:appurify_support_java', - '<(DEPTH)/testing/android/native_test.gyp:native_test_java', - '<(DEPTH)/tools/android/android_tools.gyp:android_tools', - ], - 'conditions': [ - ['OS == "android"', { - 'variables': { - # These are used to configure java_apk.gypi included below. - 'apk_name': '<(test_suite_name)', - 'intermediate_dir': '<(PRODUCT_DIR)/<(test_suite_name)_apk', - 'final_apk_path': '<(intermediate_dir)/<(test_suite_name)-debug.apk', - 'native_lib_target': 'lib<(test_suite_name)', - # TODO(yfriedman, cjhopman): Support managed installs for gtests. - 'gyp_managed_install': 0, - }, - 'includes': [ 'java_apk.gypi' ], - }], # 'OS == "android" - ], # conditions -} diff --git a/build/apk_fake_jar.gypi b/build/apk_fake_jar.gypi deleted file mode 100644 index 128b84cc2fa2b..0000000000000 --- a/build/apk_fake_jar.gypi +++ /dev/null @@ -1,15 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to build Java in a consistent manner. - -{ - 'all_dependent_settings': { - 'variables': { - 'input_jars_paths': ['>(apk_output_jar_path)'], - 'library_dexed_jars_paths': ['>(apk_output_jar_path)'], - }, - }, -} diff --git a/build/apk_test.gypi b/build/apk_test.gypi deleted file mode 100644 index e0d323f74a36b..0000000000000 --- a/build/apk_test.gypi +++ /dev/null @@ -1,45 +0,0 @@ -# Copyright (c) 2012 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to build APK based test suites. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'test_suite_name_apk', -# 'type': 'none', -# 'variables': { -# 'test_suite_name': 'test_suite_name', # string -# 'input_jars_paths': ['/path/to/test_suite.jar', ... ], # list -# }, -# 'includes': ['path/to/this/gypi/file'], -# } -# - -{ - 'dependencies': [ - '<(DEPTH)/base/base.gyp:base_java', - '<(DEPTH)/build/android/pylib/device/commands/commands.gyp:chromium_commands', - '<(DEPTH)/build/android/pylib/remote/device/dummy/dummy.gyp:remote_device_dummy_apk', - '<(DEPTH)/testing/android/appurify_support.gyp:appurify_support_java', - '<(DEPTH)/testing/android/on_device_instrumentation.gyp:reporter_java', - '<(DEPTH)/tools/android/android_tools.gyp:android_tools', - ], - 'conditions': [ - ['OS == "android"', { - 'variables': { - # These are used to configure java_apk.gypi included below. - 'test_type': 'gtest', - 'apk_name': '<(test_suite_name)', - 'intermediate_dir': '<(PRODUCT_DIR)/<(test_suite_name)_apk', - 'final_apk_path': '<(intermediate_dir)/<(test_suite_name)-debug.apk', - 'java_in_dir': '<(DEPTH)/testing/android/native_test/java', - 'native_lib_target': 'lib<(test_suite_name)', - # TODO(yfriedman, cjhopman): Support managed installs for gtests. - 'gyp_managed_install': 0, - }, - 'includes': [ 'java_apk.gypi', 'android/test_runner.gypi' ], - }], # 'OS == "android" - ], # conditions -} diff --git a/build/chrome_settings.gypi b/build/chrome_settings.gypi deleted file mode 100644 index e9c753554de3b..0000000000000 --- a/build/chrome_settings.gypi +++ /dev/null @@ -1,30 +0,0 @@ -# Copyright 2013 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file contains settings for ../chrome/chrome.gyp that other gyp files -# also use. -{ - 'variables': { - # TODO: remove this helper when we have loops in GYP - 'apply_locales_cmd': ['python', '<(DEPTH)/build/apply_locales.py'], - - 'conditions': [ - ['OS=="mac"', { - 'conditions': [ - ['branding=="Chrome"', { - 'mac_bundle_id': 'com.google.Chrome', - 'mac_creator': 'rimZ', - # The policy .grd file also needs the bundle id. - 'grit_defines': ['-D', 'mac_bundle_id=com.google.Chrome'], - }, { # else: branding!="Chrome" - 'mac_bundle_id': 'org.chromium.Chromium', - 'mac_creator': 'Cr24', - # The policy .grd file also needs the bundle id. - 'grit_defines': ['-D', 'mac_bundle_id=org.chromium.Chromium'], - }], # branding - ], # conditions - }], # OS=="mac" - ], # conditions - }, # variables -} diff --git a/build/common.gypi b/build/common.gypi deleted file mode 100644 index 3a2df58447cdd..0000000000000 --- a/build/common.gypi +++ /dev/null @@ -1,6216 +0,0 @@ -# Copyright (c) 2012 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# IMPORTANT: -# Please don't directly include this file if you are building via gyp_chromium, -# since gyp_chromium is automatically forcing its inclusion. -{ - # Variables expected to be overriden on the GYP command line (-D) or by - # ~/.gyp/include.gypi. - 'variables': { - # Putting a variables dict inside another variables dict looks kind of - # weird. This is done so that 'host_arch', 'chromeos', etc are defined as - # variables within the outer variables dict here. This is necessary - # to get these variables defined for the conditions within this variables - # dict that operate on these variables. - 'variables': { - 'variables': { - 'variables': { - 'variables': { - # Whether we're building a ChromeOS build. - 'chromeos%': 0, - - # Whether we're building the cast (chromecast) shell - 'chromecast%': 0, - - # Whether or not we are using the Aura windowing framework. - 'use_aura%': 0, - - # Whether or not we are building the Ash shell. - 'use_ash%': 0, - - # Whether or not we are using CRAS, the ChromeOS Audio Server. - 'use_cras%': 0, - - # Use a raw surface abstraction. - 'use_ozone%': 0, - - # Configure the build for small devices. See crbug.com/318413 - 'embedded%': 0, - - 'conditions': [ - # Compute the architecture that we're building on. - ['OS=="win" or OS=="ios"', { - 'host_arch%': 'ia32', - }, { - 'host_arch%': '= 4.8 or clang. - # http://gcc.gnu.org/wiki/DebugFission - ['OS=="linux" and target_arch=="x64"', { - 'linux_use_debug_fission%': 1, - }, { - 'linux_use_debug_fission%': 0, - }], - - ['OS=="android" or OS=="ios"', { - 'enable_captive_portal_detection%': 0, - 'enable_media_router%': 0, - }, { - 'enable_captive_portal_detection%': 1, - 'enable_media_router%': 1, - }], - - # Enable Skia UI text drawing incrementally on different platforms. - # http://crbug.com/105550 - # - # On Aura, this allows per-tile painting to be used in the browser - # compositor. - ['OS!="android" and OS!="ios"', { - 'use_canvas_skia%': 1, - }], - - ['chromeos==1', { - 'enable_basic_printing%': 0, - 'enable_print_preview%': 1, - }], - - # Do not enable the Settings App on ChromeOS. - ['enable_app_list==1 and chromeos==0', { - 'enable_settings_app%': 1, - }, { - 'enable_settings_app%': 0, - }], - - # Whether tests targets should be run, archived or just have the - # dependencies verified. All the tests targets have the '_run' suffix, - # e.g. base_unittests_run runs the target base_unittests. The test - # target always calls tools/swarming_client/isolate.py. See the script's - # --help for more information. Meant to be overriden with GYP_DEFINES. - # TODO(maruel): Remove the conditions as more configurations are - # supported. - ['OS!="ios" and OS!="android" and chromeos==0', { - 'test_isolation_mode%': 'check', - }, { - 'test_isolation_mode%': 'noop', - }], - # Whether Android build uses OpenMAX DL FFT. - ['OS=="android" and ((target_arch=="arm" and arm_version >= 7) or target_arch=="ia32" or target_arch=="x64" or target_arch=="arm64" or target_arch=="mipsel")', { - # Currently only supported on Android ARMv7+, ARM64, ia32, x64 and mipsel. - # When enabled, this will also enable WebAudio support on - # Android for these architectures. Default is enabled. Whether - # WebAudio is actually available depends on runtime settings - # and flags. - 'use_openmax_dl_fft%': 1, - }, { - 'use_openmax_dl_fft%': 0, - }], - ['OS=="win" or OS=="linux"', { - 'enable_mdns%' : 1, - }], - - # Disable various features by default on embedded. - ['embedded==1', { - 'remoting%': 0, - 'enable_basic_printing%': 0, - 'enable_print_preview%': 0, - }], - - ['OS=="win" or OS=="mac"', { - 'enable_wifi_bootstrapping%' : 1, - }], - - # Path to sas.dll, which provides the SendSAS function. - # http://msdn.microsoft.com/en-us/library/windows/desktop/dd979761(v=vs.85).aspx - ['target_arch=="x64"', { - 'sas_dll_path%': '<(DEPTH)/third_party/platformsdk_win7/files/redist/amd64', - }, { - 'sas_dll_path%': '<(DEPTH)/third_party/platformsdk_win7/files/redist/x86', - }], - - ['sysroot!=""', { - 'pkg-config': '<(chroot_cmd) <(DEPTH)/build/linux/pkg-config-wrapper "<(sysroot)" "<(target_arch)" "<(system_libdir)"', - }, { - 'pkg-config': 'pkg-config' - }], - ], - - # WebVR support disabled until platform implementations have been added - 'enable_webvr%': 0, - - # Setting this to '0' will cause V8's startup snapshot to be - # embedded in the binary instead of being a external files. - 'v8_use_external_startup_data%': 1, - - # Set this to 1 to enable use of concatenated impulse responses - # for the HRTF panner in WebAudio. - 'use_concatenated_impulse_responses': 1, - - # You can set the variable 'use_official_google_api_keys' to 1 - # to use the Google-internal file containing official API keys - # for Google Chrome even in a developer build. Setting this - # variable explicitly to 1 will cause your build to fail if the - # internal file is missing. - # - # The variable is documented here, but not handled in this file; - # see //google_apis/determine_use_official_keys.gypi for the - # implementation. - # - # Set the variable to 0 to not use the internal file, even when - # it exists in your checkout. - # - # Leave it unset in your include.gypi to have the variable - # implicitly set to 1 if you have - # src/google_apis/internal/google_chrome_api_keys.h in your - # checkout, and implicitly set to 0 if not. - # - # Note that official builds always behave as if the variable - # was explicitly set to 1, i.e. they always use official keys, - # and will fail to build if the internal file is missing. - # - # NOTE: You MUST NOT explicitly set the variable to 2 in your - # include.gypi or by other means. Due to subtleties of GYP, this - # is not the same as leaving the variable unset, even though its - # default value in - # //google_apis/determine_use_official_keys.gypi is 2. - - # Set these to bake the specified API keys and OAuth client - # IDs/secrets into your build. - # - # If you create a build without values baked in, you can instead - # set environment variables to provide the keys at runtime (see - # src/google_apis/google_api_keys.h for details). Features that - # require server-side APIs may fail to work if no keys are - # provided. - # - # Note that if you are building an official build or if - # use_official_google_api_keys has been set to 1 (explicitly or - # implicitly), these values will be ignored and the official - # keys will be used instead. - 'google_api_key%': '', - 'google_default_client_id%': '', - 'google_default_client_secret%': '', - # Native Client is enabled by default. - 'disable_nacl%': '0', - - # Sets the default version name and code for Android app, by default we - # do a developer build. - 'android_app_version_name%': 'Developer Build', - 'android_app_version_code%': 1, - }, - - # Copy conditionally-set variables out one scope. - 'branding%': '<(branding)', - 'branding_path_component%': '<(branding_path_component)', - 'buildtype%': '<(buildtype)', - 'target_arch%': '<(target_arch)', - 'target_subarch%': '<(target_subarch)', - 'mips_arch_variant%': '<(mips_arch_variant)', - 'mips_dsp_rev%': '<(mips_dsp_rev)', - 'host_arch%': '<(host_arch)', - 'toolkit_views%': '<(toolkit_views)', - 'ui_compositor_image_transport%': '<(ui_compositor_image_transport)', - 'use_aura%': '<(use_aura)', - 'use_ash%': '<(use_ash)', - 'use_cras%': '<(use_cras)', - 'use_libpci%': '<(use_libpci)', - 'use_openssl%': '<(use_openssl)', - 'use_openssl_certs%': '<(use_openssl_certs)', - 'use_nss_certs%': '<(use_nss_certs)', - 'use_udev%': '<(use_udev)', - 'os_bsd%': '<(os_bsd)', - 'os_posix%': '<(os_posix)', - 'use_dbus%': '<(use_dbus)', - 'use_glib%': '<(use_glib)', - 'use_pango%': '<(use_pango)', - 'use_cairo%': '<(use_cairo)', - 'use_ozone%': '<(use_ozone)', - 'use_ozone_evdev%': '<(use_ozone_evdev)', - 'use_xkbcommon%': '<(use_xkbcommon)', - 'use_clipboard_aurax11%': '<(use_clipboard_aurax11)', - 'desktop_linux%': '<(desktop_linux)', - 'use_x11%': '<(use_x11)', - 'use_gnome_keyring%': '<(use_gnome_keyring)', - 'linux_fpic%': '<(linux_fpic)', - 'chromeos%': '<(chromeos)', - 'chromecast%': '<(chromecast)', - 'enable_viewport%': '<(enable_viewport)', - 'enable_hidpi%': '<(enable_hidpi)', - 'enable_topchrome_md%': '<(enable_topchrome_md)', - 'image_loader_extension%': '<(image_loader_extension)', - 'fastbuild%': '<(fastbuild)', - 'dont_embed_build_metadata%': '<(dont_embed_build_metadata)', - 'win_z7%': '<(win_z7)', - 'dcheck_always_on%': '<(dcheck_always_on)', - 'tracing_like_official_build%': '<(tracing_like_official_build)', - 'arm_version%': '<(arm_version)', - 'arm_neon%': '<(arm_neon)', - 'arm_neon_optional%': '<(arm_neon_optional)', - 'sysroot%': '<(sysroot)', - 'pkg-config%': '<(pkg-config)', - 'chroot_cmd%': '<(chroot_cmd)', - 'system_libdir%': '<(system_libdir)', - 'component%': '<(component)', - 'win_analyze%': '<(win_analyze)', - 'enable_resource_whitelist_generation%': '<(enable_resource_whitelist_generation)', - 'use_titlecase_in_grd%': '<(use_titlecase_in_grd)', - 'use_third_party_translations%': '<(use_third_party_translations)', - 'remoting%': '<(remoting)', - 'enable_one_click_signin%': '<(enable_one_click_signin)', - 'enable_pre_sync_backup%': '<(enable_pre_sync_backup)', - 'enable_media_router%': '<(enable_media_router)', - 'enable_webrtc%': '<(enable_webrtc)', - 'chromium_win_pch%': '<(chromium_win_pch)', - 'configuration_policy%': '<(configuration_policy)', - 'safe_browsing%': '<(safe_browsing)', - 'enable_web_speech%': '<(enable_web_speech)', - 'enable_hotwording%': '<(enable_hotwording)', - 'notifications%': '<(notifications)', - 'clang_use_chrome_plugins%': '<(clang_use_chrome_plugins)', - 'mac_want_real_dsym%': '<(mac_want_real_dsym)', - 'asan%': '<(asan)', - 'asan_blacklist%': '<(asan_blacklist)', - 'asan_coverage%': '<(asan_coverage)', - 'sanitizer_coverage%': '<(sanitizer_coverage)', - 'asan_field_padding%': '<(asan_field_padding)', - 'use_sanitizer_options%': '<(use_sanitizer_options)', - 'syzyasan%': '<(syzyasan)', - 'kasko%': '<(kasko)', - 'syzygy_optimize%': '<(syzygy_optimize)', - 'lsan%': '<(lsan)', - 'msan%': '<(msan)', - 'msan_blacklist%': '<(msan_blacklist)', - 'msan_track_origins%': '<(msan_track_origins)', - 'tsan%': '<(tsan)', - 'tsan_blacklist%': '<(tsan_blacklist)', - 'ubsan%': '<(ubsan)', - 'ubsan_blacklist%': '<(ubsan_blacklist)', - 'ubsan_vptr_blacklist%': '<(ubsan_vptr_blacklist)', - 'ubsan_vptr%': '<(ubsan_vptr)', - 'use_instrumented_libraries%': '<(use_instrumented_libraries)', - 'use_prebuilt_instrumented_libraries%': '<(use_prebuilt_instrumented_libraries)', - 'use_custom_libcxx%': '<(use_custom_libcxx)', - 'use_system_libcxx%': '<(use_system_libcxx)', - 'clang_type_profiler%': '<(clang_type_profiler)', - 'order_profiling%': '<(order_profiling)', - 'order_text_section%': '<(order_text_section)', - 'enable_extensions%': '<(enable_extensions)', - 'enable_plugin_installation%': '<(enable_plugin_installation)', - 'enable_plugins%': '<(enable_plugins)', - 'enable_session_service%': '<(enable_session_service)', - 'enable_themes%': '<(enable_themes)', - 'enable_autofill_dialog%': '<(enable_autofill_dialog)', - 'enable_prod_wallet_service%': '<(enable_prod_wallet_service)', - 'enable_background%': '<(enable_background)', - 'linux_use_bundled_gold%': '<(linux_use_bundled_gold)', - 'linux_use_bundled_binutils%': '<(linux_use_bundled_binutils)', - 'linux_use_gold_flags%': '<(linux_use_gold_flags)', - 'linux_use_debug_fission%': '<(linux_use_debug_fission)', - 'use_canvas_skia%': '<(use_canvas_skia)', - 'test_isolation_mode%': '<(test_isolation_mode)', - 'enable_basic_printing%': '<(enable_basic_printing)', - 'enable_print_preview%': '<(enable_print_preview)', - 'enable_spellcheck%': '<(enable_spellcheck)', - 'use_platform_spellchecker%': '<(use_platform_spellchecker)', - 'enable_google_now%': '<(enable_google_now)', - 'cld_version%': '<(cld_version)', - 'cld2_table_size%': '<(cld2_table_size)', - 'enable_captive_portal_detection%': '<(enable_captive_portal_detection)', - 'disable_file_support%': '<(disable_file_support)', - 'disable_ftp_support%': '<(disable_ftp_support)', - 'use_icu_alternatives_on_android%': '<(use_icu_alternatives_on_android)', - 'enable_task_manager%': '<(enable_task_manager)', - 'sas_dll_path%': '<(sas_dll_path)', - 'wix_path%': '<(wix_path)', - 'use_libjpeg_turbo%': '<(use_libjpeg_turbo)', - 'use_system_libjpeg%': '<(use_system_libjpeg)', - 'android_channel%': '<(android_channel)', - 'icu_use_data_file_flag%': '<(icu_use_data_file_flag)', - 'gyp_managed_install%': 0, - 'create_standalone_apk%': 1, - 'enable_app_list%': '<(enable_app_list)', - 'use_default_render_theme%': '<(use_default_render_theme)', - 'enable_settings_app%': '<(enable_settings_app)', - 'google_api_key%': '<(google_api_key)', - 'google_default_client_id%': '<(google_default_client_id)', - 'google_default_client_secret%': '<(google_default_client_secret)', - 'enable_supervised_users%': '<(enable_supervised_users)', - 'native_memory_pressure_signals%': '<(native_memory_pressure_signals)', - 'enable_mdns%' : '<(enable_mdns)', - 'enable_service_discovery%' : '<(enable_service_discovery)', - 'enable_wifi_bootstrapping%': '<(enable_wifi_bootstrapping)', - 'enable_hangout_services_extension%' : '<(enable_hangout_services_extension)', - 'proprietary_codecs%': '<(proprietary_codecs)', - 'use_goma%': '<(use_goma)', - 'gomadir%': '<(gomadir)', - 'use_lto%': '<(use_lto)', - 'use_lto_o2%': '<(use_lto_o2)', - 'gold_icf_level%': '<(gold_icf_level)', - 'video_hole%': '<(video_hole)', - 'v8_use_external_startup_data%': '<(v8_use_external_startup_data)', - 'cfi_vptr%': '<(cfi_vptr)', - 'cfi_blacklist%': '<(cfi_blacklist)', - 'mac_views_browser%': '<(mac_views_browser)', - 'android_app_version_name%': '<(android_app_version_name)', - 'android_app_version_code%': '<(android_app_version_code)', - 'enable_webvr%': '<(enable_webvr)', - - # Turns on compiler optimizations in V8 in Debug build. - 'v8_optimized_debug%': 1, - - # Use system protobuf instead of bundled one. - 'use_system_protobuf%': 0, - - # Use system yasm instead of bundled one. - 'use_system_yasm%': 0, - - # Use system ICU instead of bundled one. - 'use_system_icu%' : 0, - - # Default to enabled PIE; this is important for ASLR but we may need to be - # able to turn it off for various reasons. - 'linux_disable_pie%': 0, - - # The release channel that this build targets. This is used to restrict - # channel-specific build options, like which installer packages to create. - # The default is 'all', which does no channel-specific filtering. - 'channel%': 'all', - - # Override chromium_mac_pch and set it to 0 to suppress the use of - # precompiled headers on the Mac. Prefix header injection may still be - # used, but prefix headers will not be precompiled. This is useful when - # using distcc to distribute a build to compile slaves that don't - # share the same compiler executable as the system driving the compilation, - # because precompiled headers rely on pointers into a specific compiler - # executable's image. Setting this to 0 is needed to use an experimental - # Linux-Mac cross compiler distcc farm. - 'chromium_mac_pch%': 1, - - # The default value for mac_strip in target_defaults. This cannot be - # set there, per the comment about variable% in a target_defaults. - 'mac_strip_release%': 0, - - # Set to 1 to enable java code coverage. Instruments classes during build - # to produce .ec files during runtime. - 'emma_coverage%': 0, - - # EMMA filter string consisting of a list of inclusion/exclusion patterns - # separated with whitespace and/or comma. Only has effect if - # 'emma_coverage=1'. - 'emma_filter%': '', - - # Set to 1 to enable running Android lint on java/class files. - 'android_lint%': 1, - - # Although base/allocator lets you select a heap library via an - # environment variable, the libcmt shim it uses sometimes gets in - # the way. To disable it entirely, and switch to normal msvcrt, do e.g. - # 'win_use_allocator_shim': 0, - # 'win_release_RuntimeLibrary': 2 - # to ~/.gyp/include.gypi, gclient runhooks --force, and do a release build. - 'win_use_allocator_shim%': 1, # 1 = shim allocator via libcmt; 0 = msvcrt - - # TODO(bradnelson): eliminate this when possible. - # To allow local gyp files to prevent release.vsprops from being included. - # Yes(1) means include release.vsprops. - # Once all vsprops settings are migrated into gyp, this can go away. - 'msvs_use_common_release%': 1, - - # TODO(bradnelson): eliminate this when possible. - # To allow local gyp files to override additional linker options for msvs. - # Yes(1) means set use the common linker options. - 'msvs_use_common_linker_extras%': 1, - - # TODO(sgk): eliminate this if possible. - # It would be nicer to support this via a setting in 'target_defaults' - # in chrome/app/locales/locales.gypi overriding the setting in the - # 'Debug' configuration in the 'target_defaults' dict below, - # but that doesn't work as we'd like. - 'msvs_debug_link_incremental%': '2', - - # Needed for some of the largest modules. - 'msvs_debug_link_nonincremental%': '1', - - # Turns on Use Library Dependency Inputs for linking chrome.dll on Windows - # to get incremental linking to be faster in debug builds. - 'incremental_chrome_dll%': '0', - - # Experimental setting to break chrome.dll into multiple pieces based on - # process type. - 'chrome_multiple_dll%': '0', - - # Experimental setting to optimize Chrome's DLLs with PGO. - 'chrome_pgo_phase%': '0', - - # Whether the VS xtree header has been patched to disable warning 4702. If - # it has, then we don't need to disable 4702 (unreachable code warning). - # The patch is preapplied to the internal toolchain and hence all bots. - 'msvs_xtree_patched%': '. Additional - # documentation on these macros is available at - # http://developer.apple.com/mac/library/technotes/tn2002/tn2064.html#SECTION3 - # Chrome normally builds with the Mac OS X 10.6 SDK and sets the - # deployment target to 10.6. Other projects, such as O3D, may - # override these defaults. - - # Normally, mac_sdk_min is used to find an SDK that Xcode knows - # about that is at least the specified version. In official builds, - # the SDK must match mac_sdk_min exactly. If the SDK is installed - # someplace that Xcode doesn't know about, set mac_sdk_path to the - # path to the SDK; when set to a non-empty string, SDK detection - # based on mac_sdk_min will be bypassed entirely. - 'conditions': [ - ['OS=="ios"', { - 'mac_sdk_min%': '10.8', - }, { # else OS!="ios" - 'mac_sdk_min%': '10.6', - }], - ], - 'mac_sdk_path%': '', - - 'mac_deployment_target%': '10.6', - }, - - 'mac_sdk_min': '<(mac_sdk_min)', - 'mac_sdk_path': '<(mac_sdk_path)', - 'mac_deployment_target': '<(mac_deployment_target)', - - # Compile in Breakpad support by default so that it can be - # tested, even if it is not enabled by default at runtime. - 'mac_breakpad_compiled_in%': 1, - 'conditions': [ - # mac_product_name is set to the name of the .app bundle as it should - # appear on disk. This duplicates data from - # chrome/app/theme/chromium/BRANDING and - # chrome/app/theme/google_chrome/BRANDING, but is necessary to get - # these names into the build system. - ['branding=="Chrome"', { - 'mac_product_name%': 'Google Chrome', - }, { # else: branding!="Chrome" - 'mac_product_name%': 'Chromium', - }], - # Official mac builds require a specific OS X SDK, but iOS and - # non-official mac builds do not. - ['branding=="Chrome" and buildtype=="Official" and OS=="mac"', { - 'mac_sdk%': '= 7.0)}\')==1', { - 'clang_xcode%': 1, - }], - ], - }], - ['enable_extensions==1', { - 'grit_defines': ['-D', 'enable_extensions'], - }], - ['enable_plugins!=0', { - 'grit_defines': ['-D', 'enable_plugins'], - }], - ['enable_basic_printing==1 or enable_print_preview==1', { - 'grit_defines': ['-D', 'enable_printing'], - }], - ['enable_print_preview==1', { - 'grit_defines': ['-D', 'enable_print_preview'], - }], - ['enable_themes==1', { - 'grit_defines': ['-D', 'enable_themes'], - }], - ['enable_app_list==1', { - 'grit_defines': ['-D', 'enable_app_list'], - }], - ['enable_settings_app==1', { - 'grit_defines': ['-D', 'enable_settings_app'], - }], - ['enable_google_now==1', { - 'grit_defines': ['-D', 'enable_google_now'], - }], - ['use_concatenated_impulse_responses==1', { - 'grit_defines': ['-D', 'use_concatenated_impulse_responses'], - }], - ['enable_media_router==1', { - 'grit_defines': ['-D', 'enable_media_router'], - }], - ['enable_webrtc==1', { - 'grit_defines': ['-D', 'enable_webrtc'], - }], - ['enable_hangout_services_extension==1', { - 'grit_defines': ['-D', 'enable_hangout_services_extension'], - }], - ['enable_task_manager==1', { - 'grit_defines': ['-D', 'enable_task_manager'], - }], - ['notifications==1', { - 'grit_defines': ['-D', 'enable_notifications'], - }], - ['enable_wifi_bootstrapping==1', { - 'grit_defines': ['-D', 'enable_wifi_bootstrapping'], - }], - ['mac_views_browser==1', { - 'grit_defines': ['-D', 'mac_views_browser'], - }], - ['enable_resource_whitelist_generation==1 and OS!="win"', { - 'grit_rc_header_format': ['-h', '#define {textual_id} _Pragma("whitelisted_resource_{numeric_id}") {numeric_id}'], - }], - ['enable_resource_whitelist_generation==1 and OS=="win"', { - 'grit_rc_header_format': ['-h', '#define {textual_id} __pragma(message("whitelisted_resource_{numeric_id}")) {numeric_id}'], - }], - ['enable_mdns==1 or OS=="mac"', { - 'grit_defines': ['-D', 'enable_service_discovery'], - 'enable_service_discovery%': 1 - }], - ['clang_use_chrome_plugins==1', { - 'variables': { - 'conditions': [ - ['OS!="win"', { - 'variables': { - 'conditions': [ - ['OS=="mac" or OS=="ios"', { - 'clang_lib_path%': '(nacl_untrusted_build)==1', { - 'defines': [ - 'USE_OPENSSL=1', - 'USE_OPENSSL_CERTS=1', - ], - }], - ['<(use_glib)==1 and >(nacl_untrusted_build)==0', { - 'defines': ['USE_GLIB=1'], - }], - ['<(use_nss_certs)==1 and >(nacl_untrusted_build)==0', { - 'defines': ['USE_NSS_CERTS=1'], - }], - ['<(chromeos)==1 and >(nacl_untrusted_build)==0', { - 'defines': ['OS_CHROMEOS=1'], - }], - ['enable_wexit_time_destructors==1 and OS!="win"', { - # TODO: Enable on Windows too, http://crbug.com/404525 - 'variables': { 'clang_warning_flags': ['-Wexit-time-destructors']}, - }], - ['chromium_code==0', { - 'variables': { - 'clang_warning_flags': [ - # TODO(mgiuca): Move this suppression into individual third-party - # libraries as required. http://crbug.com/505301. - '-Wno-overloaded-virtual', - # Lots of third-party libraries have unused variables. Instead of - # suppressing them individually, we just blanket suppress them here. - '-Wno-unused-variable', - ], - }, - 'conditions': [ - [ 'os_posix==1 and OS!="mac" and OS!="ios"', { - # We don't want to get warnings from third-party code, - # so remove any existing warning-enabling flags like -Wall. - 'cflags!': [ - '-Wall', - '-Wextra', - ], - 'cflags_cc': [ - # Don't warn about hash_map in third-party code. - '-Wno-deprecated', - ], - 'cflags': [ - # Don't warn about printf format problems. - # This is off by default in gcc but on in Ubuntu's gcc(!). - '-Wno-format', - ], - 'cflags_cc!': [ - # Necessary because llvm.org/PR10448 is WONTFIX (crbug.com/90453). - '-Wsign-compare', - ] - }], - # TODO: Fix all warnings on chromeos too. - [ 'os_posix==1 and OS!="mac" and OS!="ios" and (clang!=1 or chromeos==1)', { - 'cflags!': [ - '-Werror', - ], - }], - [ 'os_posix==1 and os_bsd!=1 and OS!="mac" and OS!="android"', { - 'cflags': [ - # Don't warn about ignoring the return value from e.g. close(). - # This is off by default in some gccs but on by default in others. - # BSD systems do not support this option, since they are usually - # using gcc 4.2.1, which does not have this flag yet. - '-Wno-unused-result', - ], - }], - [ 'OS=="win"', { - 'defines': [ - '_CRT_SECURE_NO_DEPRECATE', - '_CRT_NONSTDC_NO_WARNINGS', - '_CRT_NONSTDC_NO_DEPRECATE', - '_SCL_SECURE_NO_DEPRECATE', - ], - 'msvs_disabled_warnings': [ - 4800, - ], - 'msvs_settings': { - 'VCCLCompilerTool': { - 'WarningLevel': '3', - 'WarnAsError': 'true', - 'Detect64BitPortabilityProblems': 'false', - }, - }, - 'conditions': [ - ['buildtype=="Official"', { - 'msvs_settings': { - 'VCCLCompilerTool': { 'WarnAsError': 'false' }, - } - }], - [ 'component=="shared_library"', { - # TODO(darin): Unfortunately, some third_party code depends on base. - 'msvs_disabled_warnings': [ - 4251, # class 'std::xx' needs to have dll-interface. - ], - }], - ], - }], - - [ 'OS=="mac" or OS=="ios"', { - 'xcode_settings': { - 'WARNING_CFLAGS!': ['-Wall', '-Wextra'], - }, - 'conditions': [ - ['buildtype=="Official"', { - 'xcode_settings': { - 'GCC_TREAT_WARNINGS_AS_ERRORS': 'NO', # -Werror - }, - }], - ], - }], - [ 'OS=="ios"', { - 'xcode_settings': { - # TODO(ios): Fix remaining warnings in third-party code, then - # remove this; the Mac cleanup didn't get everything that's - # flagged in an iOS build. - 'GCC_TREAT_WARNINGS_AS_ERRORS': 'NO', - 'RUN_CLANG_STATIC_ANALYZER': 'NO', - # Several internal ios directories generate numerous warnings for - # -Wobjc-missing-property-synthesis. - 'CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS': 'NO', - }, - }], - ], - }, { - 'includes': [ - # Rules for excluding e.g. foo_win.cc from the build on non-Windows. - 'filename_rules.gypi', - ], - # In Chromium code, we define __STDC_foo_MACROS in order to get the - # C99 macros on Mac and Linux. - 'defines': [ - '__STDC_CONSTANT_MACROS', - '__STDC_FORMAT_MACROS', - ], - 'conditions': [ - ['OS=="win"', { - # turn on warnings for signed/unsigned mismatch on chromium code. - 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions': ['/we4389'], - }, - }, - }], - ['OS=="win" and component=="shared_library"', { - 'msvs_disabled_warnings': [ - 4251, # class 'std::xx' needs to have dll-interface. - ], - }], - ], - }], - ], # target_conditions for 'target_defaults' - 'default_configuration': 'Debug', - 'configurations': { - # VCLinkerTool LinkIncremental values below: - # 0 == default - # 1 == /INCREMENTAL:NO - # 2 == /INCREMENTAL - # Debug links incremental, Release does not. - # - # Abstract base configurations to cover common attributes. - # - 'Common_Base': { - 'abstract': 1, - 'msvs_configuration_attributes': { - 'OutputDirectory': '<(DEPTH)\\build\\<(build_dir_prefix)$(ConfigurationName)', - 'IntermediateDirectory': '$(OutDir)\\obj\\$(ProjectName)', - 'CharacterSet': '1', - }, - 'msvs_settings':{ - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - '/bigobj', - ], - }, - 'VCLinkerTool': { - # Add the default import libs. - 'AdditionalDependencies': [ - 'kernel32.lib', - 'gdi32.lib', - 'winspool.lib', - 'comdlg32.lib', - 'advapi32.lib', - 'shell32.lib', - 'ole32.lib', - 'oleaut32.lib', - 'user32.lib', - 'uuid.lib', - 'odbc32.lib', - 'odbccp32.lib', - 'delayimp.lib', - 'credui.lib', - 'netapi32.lib', - ], - 'AdditionalOptions': [ - # Suggested by Microsoft Devrel to avoid - # LINK : fatal error LNK1248: image size (80000000) exceeds maximum allowable size (80000000) - # which started happening more regularly after VS2013 Update 4. - # Needs to be a bit lower for VS2015, or else errors out. - '/maxilksize:0x7ff00000', - ], - }, - }, - }, - 'x86_Base': { - 'abstract': 1, - 'msvs_settings': { - 'VCLinkerTool': { - 'MinimumRequiredVersion': '5.01', # XP. - 'TargetMachine': '1', - }, - 'VCLibrarianTool': { - 'TargetMachine': '1', - }, - }, - 'msvs_configuration_platform': 'Win32', - }, - 'x64_Base': { - 'abstract': 1, - 'msvs_configuration_platform': 'x64', - 'msvs_settings': { - 'VCLinkerTool': { - # Make sure to understand http://crbug.com/361720 if you want to - # increase this. - 'MinimumRequiredVersion': '5.02', # Server 2003. - 'TargetMachine': '17', # x86 - 64 - 'AdditionalLibraryDirectories!': - ['<(windows_sdk_path)/Lib/win8/um/x86'], - 'AdditionalLibraryDirectories': - ['<(windows_sdk_path)/Lib/win8/um/x64'], - # Doesn't exist x64 SDK. Should use oleaut32 in any case. - 'IgnoreDefaultLibraryNames': [ 'olepro32.lib' ], - }, - 'VCLibrarianTool': { - 'AdditionalLibraryDirectories!': - ['<(windows_sdk_path)/Lib/win8/um/x86'], - 'AdditionalLibraryDirectories': - ['<(windows_sdk_path)/Lib/win8/um/x64'], - 'TargetMachine': '17', # x64 - }, - }, - }, - 'Debug_Base': { - 'abstract': 1, - 'defines': [ - 'DYNAMIC_ANNOTATIONS_ENABLED=1', - 'WTF_USE_DYNAMIC_ANNOTATIONS=1', - ], - 'xcode_settings': { - 'GCC_OPTIMIZATION_LEVEL': '<(mac_debug_optimization)', - 'OTHER_CFLAGS': [ - '<@(debug_extra_cflags)', - ], - }, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'Optimization': '<(win_debug_Optimization)', - 'PreprocessorDefinitions': ['_DEBUG'], - 'BasicRuntimeChecks': '<(win_debug_RuntimeChecks)', - 'RuntimeLibrary': '<(win_debug_RuntimeLibrary)', - 'conditions': [ - # According to MSVS, InlineFunctionExpansion=0 means - # "default inlining", not "/Ob0". - # Thus, we have to handle InlineFunctionExpansion==0 separately. - ['win_debug_InlineFunctionExpansion==0', { - 'AdditionalOptions': ['/Ob0'], - }], - ['win_debug_InlineFunctionExpansion!=""', { - 'InlineFunctionExpansion': - '<(win_debug_InlineFunctionExpansion)', - }], - ['win_debug_disable_iterator_debugging==1', { - 'PreprocessorDefinitions': ['_HAS_ITERATOR_DEBUGGING=0'], - }], - - # if win_debug_OmitFramePointers is blank, leave as default - ['win_debug_OmitFramePointers==1', { - 'OmitFramePointers': 'true', - }], - ['win_debug_OmitFramePointers==0', { - 'OmitFramePointers': 'false', - # The above is not sufficient (http://crbug.com/106711): it - # simply eliminates an explicit "/Oy", but both /O2 and /Ox - # perform FPO regardless, so we must explicitly disable. - # We still want the false setting above to avoid having - # "/Oy /Oy-" and warnings about overriding. - 'AdditionalOptions': ['/Oy-'], - }], - ], - 'AdditionalOptions': [ '<@(win_debug_extra_cflags)', ], - }, - 'VCLinkerTool': { - 'LinkIncremental': '<(msvs_debug_link_incremental)', - # ASLR makes debugging with windbg difficult because Chrome.exe and - # Chrome.dll share the same base name. As result, windbg will - # name the Chrome.dll module like chrome_, where - # typically changes with each launch. This in turn - # means that breakpoints in Chrome.dll don't stick from one launch - # to the next. For this reason, we turn ASLR off in debug builds. - # Note that this is a three-way bool, where 0 means to pick up - # the default setting, 1 is off and 2 is on. - 'RandomizedBaseAddress': 1, - }, - 'VCResourceCompilerTool': { - 'PreprocessorDefinitions': ['_DEBUG'], - }, - }, - 'conditions': [ - ['OS=="linux" or OS=="android"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'cflags': [ - '<@(debug_extra_cflags)', - ], - }], - ], - }], - ['OS=="linux" and target_arch!="ia32" and disable_glibcxx_debug==0', { - # Enable libstdc++ debugging facilities to help catch problems - # early, see http://crbug.com/65151 . - # TODO(phajdan.jr): Should we enable this for all of POSIX? - 'defines': ['_GLIBCXX_DEBUG=1',], - }], - ['release_valgrind_build==0', { - 'xcode_settings': { - 'OTHER_CFLAGS': [ - '-fstack-protector-all', # Implies -fstack-protector - ], - }, - }], - ['clang==1', { - 'cflags': [ - # Allow comparing the address of references and 'this' against 0 - # in debug builds. Technically, these can never be null in - # well-defined C/C++ and Clang can optimize such checks away in - # release builds, but they may be used in asserts in debug builds. - '-Wno-undefined-bool-conversion', - '-Wno-tautological-undefined-compare', - ], - 'xcode_settings': { - 'OTHER_CFLAGS': [ - '-Wno-undefined-bool-conversion', - '-Wno-tautological-undefined-compare', - ], - }, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - '-Wno-undefined-bool-conversion', - '-Wno-tautological-undefined-compare', - ], - }, - }, - }], - ], - }, - 'Release_Base': { - 'abstract': 1, - 'defines': [ - 'NDEBUG', - ], - 'xcode_settings': { - 'DEAD_CODE_STRIPPING': 'YES', # -Wl,-dead_strip - 'GCC_OPTIMIZATION_LEVEL': '<(mac_release_optimization)', - 'OTHER_CFLAGS': [ '<@(release_extra_cflags)', ], - }, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'RuntimeLibrary': '<(win_release_RuntimeLibrary)', - 'conditions': [ - # In official builds, each target will self-select - # an optimization level. - ['buildtype!="Official"', { - 'Optimization': '<(win_release_Optimization)', - }, - ], - # According to MSVS, InlineFunctionExpansion=0 means - # "default inlining", not "/Ob0". - # Thus, we have to handle InlineFunctionExpansion==0 separately. - ['win_release_InlineFunctionExpansion==0', { - 'AdditionalOptions': ['/Ob0'], - }], - ['win_release_InlineFunctionExpansion!=""', { - 'InlineFunctionExpansion': - '<(win_release_InlineFunctionExpansion)', - }], - - # if win_release_OmitFramePointers is blank, leave as default - ['win_release_OmitFramePointers==1', { - 'OmitFramePointers': 'true', - }], - ['win_release_OmitFramePointers==0', { - 'OmitFramePointers': 'false', - # The above is not sufficient (http://crbug.com/106711): it - # simply eliminates an explicit "/Oy", but both /O2 and /Ox - # perform FPO regardless, so we must explicitly disable. - # We still want the false setting above to avoid having - # "/Oy /Oy-" and warnings about overriding. - 'AdditionalOptions': ['/Oy-'], - }], - ['asan==0', { - # Put data in separate COMDATs. This allows the linker - # to put bit-identical constants at the same address even if - # they're unrelated constants, which saves binary size. - # This optimization can't be used when ASan is enabled because - # it is not compatible with the ASan ODR checker. - 'AdditionalOptions': ['/Gw'], - }], - ], - 'AdditionalOptions': [ - '/d2Zi+', # Improve debugging of Release builds. - '/Zc:inline', # Remove unreferenced COMDAT (faster links). - '<@(win_release_extra_cflags)', - ], - }, - 'VCLinkerTool': { - # LinkIncremental is a tri-state boolean, where 0 means default - # (i.e., inherit from parent solution), 1 means false, and - # 2 means true. - 'LinkIncremental': '1', - # This corresponds to the /PROFILE flag which ensures the PDB - # file contains FIXUP information (growing the PDB file by about - # 5%) but does not otherwise alter the output binary. This - # information is used by the Syzygy optimization tool when - # decomposing the release image. - 'Profile': 'true', - }, - }, - 'conditions': [ - ['msvs_use_common_release', { - 'includes': ['release.gypi'], - }], - ['release_valgrind_build==0 and tsan==0', { - 'defines': [ - 'NVALGRIND', - 'DYNAMIC_ANNOTATIONS_ENABLED=0', - ], - }, { - 'defines': [ - 'MEMORY_TOOL_REPLACES_ALLOCATOR', - 'MEMORY_SANITIZER_INITIAL_SIZE', - 'DYNAMIC_ANNOTATIONS_ENABLED=1', - 'WTF_USE_DYNAMIC_ANNOTATIONS=1', - ], - }], - ['OS=="win"', { - 'defines': ['NO_TCMALLOC'], - }], - # _FORTIFY_SOURCE isn't really supported by Clang now, see - # http://llvm.org/bugs/show_bug.cgi?id=16821. - # It seems to work fine with Ubuntu 12 headers though, so use it - # in official builds. - ['os_posix==1 and (asan!=1 and msan!=1 and tsan!=1 and lsan!=1 and ubsan!=1) and (OS!="linux" or clang!=1 or buildtype=="Official")', { - 'target_conditions': [ - ['chromium_code==1', { - # Non-chromium code is not guaranteed to compile cleanly - # with _FORTIFY_SOURCE. Also, fortified build may fail - # when optimizations are disabled, so only do that for Release - # build. - 'defines': [ - '_FORTIFY_SOURCE=2', - ], - }], - ], - }], - ['OS=="linux" or OS=="android"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'cflags': [ - '<@(release_extra_cflags)', - ], - 'conditions': [ - ['enable_resource_whitelist_generation==1', { - 'cflags': [ - '-Wunknown-pragmas -Wno-error=unknown-pragmas', - ], - }], - ], - }], - ], - }], - ['OS=="ios"', { - 'defines': [ - 'NS_BLOCK_ASSERTIONS=1', - ], - }], - ], - }, - # - # Concrete configurations - # - 'Debug': { - 'inherit_from': ['Common_Base', 'x86_Base', 'Debug_Base'], - }, - 'Release': { - 'inherit_from': ['Common_Base', 'x86_Base', 'Release_Base'], - }, - 'conditions': [ - [ 'OS=="ios"', { - 'Profile': { - 'inherit_from': ['Common_Base', 'x86_Base', 'Release_Base'], - 'target_conditions': [ - [ '_type=="executable"', { - # To get a real .dSYM bundle produced by dsymutil, set the - # debug information format to dwarf-with-dsym. Since - # strip_from_xcode will not be used, set Xcode to do the - # stripping as well. - 'xcode_settings': { - 'DEBUG_INFORMATION_FORMAT': 'dwarf-with-dsym', - 'DEPLOYMENT_POSTPROCESSING': 'YES', - 'STRIP_INSTALLED_PRODUCT': 'YES', - }, - }], - ], - }, - }], - [ 'OS=="win"', { - # TODO(bradnelson): add a gyp mechanism to make this more graceful. - 'Debug_x64': { - 'inherit_from': ['Common_Base', 'x64_Base', 'Debug_Base'], - }, - 'Release_x64': { - 'inherit_from': ['Common_Base', 'x64_Base', 'Release_Base'], - }, - }], - ], - }, - }, - 'conditions': [ - ['os_posix==1', { - 'target_defaults': { - 'ldflags': [ - '-Wl,-z,now', - '-Wl,-z,relro', - ], - # TODO(glider): enable the default options on other systems. - 'conditions': [ - ['use_sanitizer_options==1 and ((OS=="linux" and (chromeos==0 or target_arch!="ia32")) or OS=="mac")', { - 'dependencies': [ - '<(DEPTH)/build/sanitizers/sanitizers.gyp:sanitizer_options', - ], - }], - ], - }, - }], - # TODO(jochen): Enable this on chromeos on arm. http://crbug.com/356580 - ['os_posix==1 and disable_fatal_linker_warnings==0 and use_evdev_gestures==0 and (chromeos==0 or target_arch!="arm")', { - 'target_defaults': { - 'ldflags': [ - '-Wl,--fatal-warnings', - ], - }, - }], - # -Wl,-z,-defs doesn't work with the sanitiziers, http://crbug.com/452065 - ['(OS=="linux" or OS=="android") and asan==0 and msan==0 and tsan==0 and ubsan==0 and ubsan_vptr==0', { - 'target_defaults': { - 'ldflags': [ - '-Wl,-z,defs', - ], - }, - }], - ['os_posix==1 and chromeos==0', { - # Chrome OS enables -fstack-protector-strong via its build wrapper, - # and we want to avoid overriding this, so stack-protector is only - # enabled when not building on Chrome OS. - # TODO(phajdan.jr): Use -fstack-protector-strong when our gcc - # supports it. - 'target_defaults': { - 'cflags': [ - '-fstack-protector', - '--param=ssp-buffer-size=4', - ], - }, - }], - ['os_posix==1 and OS=="linux"', { - 'defines': [ - '_LARGEFILE_SOURCE', - '_LARGEFILE64_SOURCE', - '_FILE_OFFSET_BITS=64', - ], - }], - ['os_posix==1 and OS!="mac" and OS!="ios"', { - 'target_defaults': { - # Enable -Werror by default, but put it in a variable so it can - # be disabled in ~/.gyp/include.gypi on the valgrind builders. - 'variables': { - 'werror%': '-Werror', - 'libraries_for_target%': '', - }, - 'defines': [ - '_FILE_OFFSET_BITS=64', - ], - 'cflags': [ - '<(werror)', # See note above about the werror variable. - '-pthread', - '-fno-strict-aliasing', # See http://crbug.com/32204 - '-Wall', - # Don't warn about unused function params. We use those everywhere. - '-Wno-unused-parameter', - # Don't warn about the "struct foo f = {0};" initialization pattern. - '-Wno-missing-field-initializers', - # Don't export any symbols (for example, to plugins we dlopen()). - # Note: this is *required* to make some plugins work. - '-fvisibility=hidden', - '-pipe', - ], - 'cflags_cc': [ - '-fno-exceptions', - '-fno-rtti', - '-fno-threadsafe-statics', - # Make inline functions have hidden visiblity by default. - # Surprisingly, not covered by -fvisibility=hidden. - '-fvisibility-inlines-hidden', - # GCC turns on -Wsign-compare for C++ under -Wall, but clang doesn't, - # so we specify it explicitly. (llvm.org/PR10448, crbug.com/90453) - '-Wsign-compare', - ], - 'ldflags': [ - '-pthread', '-Wl,-z,noexecstack', - ], - 'libraries' : [ - '<(libraries_for_target)', - ], - 'configurations': { - 'Debug_Base': { - 'variables': { - 'debug_optimize%': '0', - }, - 'defines': [ - '_DEBUG', - ], - 'cflags': [ - '-O>(debug_optimize)', - '-g', - ], - 'conditions' : [ - ['OS=="android" and target_arch!="mipsel" and target_arch!="mips64el"', { - # TODO(jdduke) Re-enable on mips after resolving linking - # issues with libc++ (crbug.com/456380). - 'ldflags': [ - # Warn in case of text relocations. - '-Wl,--warn-shared-textrel', - ], - }], - ['OS=="android" and android_full_debug==0', { - # Some configurations are copied from Release_Base to reduce - # the binary size. - 'variables': { - 'debug_optimize%': 's', - }, - 'cflags': [ - '-fdata-sections', - '-ffunction-sections', - ], - 'ldflags': [ - '-Wl,-O1', - '-Wl,--as-needed', - ], - }], - ['OS=="android" and android_full_debug==0 and target_arch!="arm64"', { - # We don't omit frame pointers on arm64 since they are required - # to correctly unwind stackframes which contain system library - # function frames (crbug.com/391706). - 'cflags': [ - '-fomit-frame-pointer', - ], - }], - ['OS=="linux" and target_arch=="ia32"', { - 'ldflags': [ - '-Wl,--no-as-needed', - ], - }], - ['debug_unwind_tables==1', { - 'cflags': ['-funwind-tables'], - }, { - 'cflags': ['-fno-unwind-tables', '-fno-asynchronous-unwind-tables'], - 'defines': ['NO_UNWIND_TABLES'], - }], - # TODO(mostynb): shuffle clang/gcc_version/binutils_version - # definitions in to the right scope to use them when setting - # linux_use_debug_fission, so it can be used here alone. - ['linux_use_debug_fission==1 and linux_use_gold_flags==1 and (clang==1 or gcc_version>=48) and binutils_version>=223', { - 'cflags': ['-gsplit-dwarf'], - }], - ], - }, - 'Release_Base': { - 'variables': { - 'release_optimize%': '2', - # Binaries become big and gold is unable to perform GC - # and remove unused sections for some of test targets - # on 32 bit platform. - # (This is currently observed only in chromeos valgrind bots) - # The following flag is to disable --gc-sections linker - # option for these bots. - 'no_gc_sections%': 0, - - # TODO(bradnelson): reexamine how this is done if we change the - # expansion of configurations - 'release_valgrind_build%': 0, - }, - 'cflags': [ - '-O<(release_optimize)', - # Don't emit the GCC version ident directives, they just end up - # in the .comment section taking up binary size. - '-fno-ident', - # Put data and code in their own sections, so that unused symbols - # can be removed at link time with --gc-sections. - '-fdata-sections', - '-ffunction-sections', - ], - 'ldflags': [ - # Specifically tell the linker to perform optimizations. - # See http://lwn.net/Articles/192624/ . - '-Wl,-O1', - '-Wl,--as-needed', - ], - 'conditions' : [ - ['no_gc_sections==0', { - 'ldflags': [ - '-Wl,--gc-sections', - ], - }], - ['OS=="android" and target_arch!="arm64"', { - # We don't omit frame pointers on arm64 since they are required - # to correctly unwind stackframes which contain system library - # function frames (crbug.com/391706). - 'cflags': [ - '-fomit-frame-pointer', - ] - }], - ['OS=="android" and target_arch!="mipsel" and target_arch!="mips64el"', { - # TODO(jdduke) Re-enable on mips after resolving linking - # issues with libc++ (crbug.com/456380). - 'ldflags': [ - # Warn in case of text relocations. - '-Wl,--warn-shared-textrel', - ], - }], - ['OS=="android"', { - 'variables': { - 'release_optimize%': 's', - }, - }], - ['profiling==1', { - 'cflags': [ - '-fno-omit-frame-pointer', - '-g', - ], - 'conditions' : [ - ['profiling_full_stack_frames==1', { - 'cflags': [ - '-fno-inline', - '-fno-optimize-sibling-calls', - ], - }], - ], - }], - ['release_unwind_tables==1', { - 'cflags': ['-funwind-tables'], - }, { - 'cflags': ['-fno-unwind-tables', '-fno-asynchronous-unwind-tables'], - 'defines': ['NO_UNWIND_TABLES'], - }], - ], - }, - }, - 'conditions': [ - ['target_arch=="ia32"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'asflags': [ - # Needed so that libs with .s files (e.g. libicudata.a) - # are compatible with the general 32-bit-ness. - '-32', - ], - # All floating-point computations on x87 happens in 80-bit - # precision. Because the C and C++ language standards allow - # the compiler to keep the floating-point values in higher - # precision than what's specified in the source and doing so - # is more efficient than constantly rounding up to 64-bit or - # 32-bit precision as specified in the source, the compiler, - # especially in the optimized mode, tries very hard to keep - # values in x87 floating-point stack (in 80-bit precision) - # as long as possible. This has important side effects, that - # the real value used in computation may change depending on - # how the compiler did the optimization - that is, the value - # kept in 80-bit is different than the value rounded down to - # 64-bit or 32-bit. There are possible compiler options to - # make this behavior consistent (e.g. -ffloat-store would keep - # all floating-values in the memory, thus force them to be - # rounded to its original precision) but they have significant - # runtime performance penalty. - # - # -mfpmath=sse -msse2 makes the compiler use SSE instructions - # which keep floating-point values in SSE registers in its - # native precision (32-bit for single precision, and 64-bit - # for double precision values). This means the floating-point - # value used during computation does not change depending on - # how the compiler optimized the code, since the value is - # always kept in its specified precision. - # - # Refer to http://crbug.com/348761 for rationale behind SSE2 - # being a minimum requirement for 32-bit Linux builds and - # http://crbug.com/313032 for an example where this has "bit" - # us in the past. - 'cflags': [ - '-msse2', - '-mfpmath=sse', - '-mmmx', # Allows mmintrin.h for MMX intrinsics. - '-m32', - ], - 'ldflags': [ - '-m32', - ], - 'conditions': [ - # Use gold linker for Android ia32 target. - ['OS=="android"', { - 'ldflags': [ - '-fuse-ld=gold', - ], - }], - ], - }], - ], - }], - ['target_arch=="x64"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - # Use gold linker for Android x64 target. - ['OS=="android"', { - 'ldflags': [ - '-fuse-ld=gold', - ], - }], - ], - 'cflags': [ - '-m64', - '-march=x86-64', - ], - 'ldflags': [ - '-m64', - ], - }], - ], - }], - ['target_arch=="arm"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - ['clang==0', { - 'cflags_cc': [ - # The codesourcery arm-2009q3 toolchain warns at that the ABI - # has changed whenever it encounters a varargs function. This - # silences those warnings, as they are not helpful and - # clutter legitimate warnings. - '-Wno-abi', - ], - }], - ['clang==1 and arm_arch!="" and OS!="android"', { - 'cflags': [ - '-target arm-linux-gnueabihf', - ], - 'ldflags': [ - '-target arm-linux-gnueabihf', - ], - }], - ['arm_arch!=""', { - 'cflags': [ - '-march=<(arm_arch)', - ], - 'conditions': [ - ['use_lto==1 or use_lto_o2==1', { - 'ldflags': [ - '-march=<(arm_arch)', - ], - }], - ], - }], - ['clang==1 and OS!="android"', { - 'cflags': [ - # We need to disable clang's builtin assembler as it can't - # handle several asm files, crbug.com/124610 - '-no-integrated-as', - ], - }], - ['arm_tune!=""', { - 'cflags': [ - '-mtune=<(arm_tune)', - ], - 'conditions': [ - ['use_lto==1 or use_lto_o2==1', { - 'ldflags': [ - '-mtune=<(arm_tune)', - ], - }], - ], - }], - ['arm_fpu!=""', { - 'cflags': [ - '-mfpu=<(arm_fpu)', - ], - 'conditions': [ - ['use_lto==1 or use_lto_o2==1', { - 'ldflags': [ - '-mfpu=<(arm_fpu)', - ], - }], - ], - }], - ['arm_float_abi!=""', { - 'cflags': [ - '-mfloat-abi=<(arm_float_abi)', - ], - 'conditions': [ - ['use_lto==1 or use_lto_o2==1', { - 'ldflags': [ - '-mfloat-abi=<(arm_float_abi)', - ], - }], - ], - }], - ['arm_thumb==1', { - 'cflags': [ - '-mthumb', - ], - 'conditions': [ - ['use_lto==1 or use_lto_o2==1', { - 'ldflags': [ - '-mthumb', - ], - }], - ], - }], - ['OS=="android"', { - # Most of the following flags are derived from what Android - # uses by default when building for arm, reference for which - # can be found in the following file in the Android NDK: - # toolchains/arm-linux-androideabi-4.9/setup.mk - 'cflags': [ - # The tree-sra optimization (scalar replacement for - # aggregates enabling subsequent optimizations) leads to - # invalid code generation when using the Android NDK's - # compiler (r5-r7). This can be verified using - # webkit_unit_tests' WTF.Checked_int8_t test. - '-fno-tree-sra', - # The following option is disabled to improve binary - # size and performance in gcc 4.9. - '-fno-caller-saves', - '-Wno-psabi', - ], - # Android now supports .relro sections properly. - # NOTE: While these flags enable the generation of .relro - # sections, the generated libraries can still be loaded on - # older Android platform versions. - 'ldflags': [ - '-Wl,-z,relro', - '-Wl,-z,now', - '-fuse-ld=gold', - ], - 'conditions': [ - ['gcc_version==48 and clang==0', { - 'cflags': [ - # The following 5 options are disabled to save on - # binary size in GCC 4.8. - '-fno-partial-inlining', - '-fno-early-inlining', - '-fno-tree-copy-prop', - '-fno-tree-loop-optimize', - '-fno-move-loop-invariants', - ], - }], - ['arm_thumb==1', { - 'cflags': [ '-mthumb-interwork' ], - }], - ['profiling==1', { - 'cflags': [ - # Thumb code with frame pointer makes chrome crash - # early. - '-marm', - '-mapcs-frame', # Required by -fno-omit-frame-pointer. - # The perf report sometimes incorrectly attributes - # code from tail calls. - '-fno-optimize-sibling-calls', - ], - 'cflags!': [ - '-fomit-frame-pointer', - ], - }], - ['clang==1', { - 'cflags!': [ - # Clang does not support the following options. - '-mapcs-frame', - '-mthumb-interwork', - '-finline-limit=64', - '-fno-tree-sra', - '-fno-caller-saves', - '-Wno-psabi', - ], - 'cflags': [ - # TODO(hans) Enable integrated-as (crbug.com/124610). - '-no-integrated-as', - '-B<(android_toolchain)', # Else /usr/bin/as gets picked up. - ], - }], - ['clang==1 and linux_use_bundled_gold==0', { - 'ldflags': [ - # Let clang find the ld.gold in the NDK. - '--gcc-toolchain=<(android_toolchain)/..', - ], - }], - ['asan==1', { - 'cflags': [ - '-marm', # Required for frame pointer based stack traces. - ], - }], - ], - }], - ['chromecast==1', { - 'cflags': [ - # We set arm_arch to "" so that -march compiler option - # is not set. Otherwise a gcc bug that would complain - # about it conflicting with '-mcpu=cortex-a9'. The flag - # '-march=armv7-a' is actually redundant anyway because - # it is enabled by default when we built the toolchain. - # And using '-mcpu=cortex-a9' should be sufficient. - '-mcpu=cortex-a9', - '-funwind-tables', - # Breakpad requires symbols with debugging information - '-g', - ], - 'ldflags': [ - # We want to statically link libstdc++/libgcc_s. - '-static-libstdc++', - '-static-libgcc', - ], - 'cflags!': [ - # Some components in Chromium (e.g. v8, skia, ffmpeg) - # define their own cflags for arm builds that could - # conflict with the flags we set here (e.g. - # '-mcpu=cortex-a9'). Remove these flags explicitly. - '-march=armv7-a', - '-mtune=cortex-a8', - ], - }], - ], - }], - ], - }], - ['target_arch=="arm64"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - ['OS=="android"', { - 'cflags!': [ - '-fstack-protector', # stack protector is always enabled on arm64. - ], - }], - ], - }], - ], - }], - ['target_arch=="mipsel"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - ['mips_arch_variant=="r6"', { - 'conditions': [ - ['clang==1', { - 'cflags': [ '-target mipsel-linux-gnu', '-march=mips32r6', ], - 'ldflags': [ '-target mipsel-linux-gnu', ], - }, { # clang==0 - 'cflags': ['-mips32r6', '-Wa,-mips32r6', ], - }], - ['clang==0 and OS=="android"', { - 'ldflags': ['-mips32r6', '-Wl,-melf32ltsmip',], - }], - ], - }], - ['mips_arch_variant=="r2"', { - 'conditions': [ - ['mips_float_abi=="hard" and mips_fpu_mode!=""', { - 'cflags': ['-m<(mips_fpu_mode)'], - }], - ['clang==1', { - 'conditions': [ - ['OS=="android"', { - 'cflags': [ '-target mipsel-linux-android', '-march=mipsel', '-mcpu=mips32r2'], - 'ldflags': [ '-target mipsel-linux-android', ], - }, { - 'cflags': [ '-target mipsel-linux-gnu', '-march=mipsel', '-mcpu=mips32r2'], - 'ldflags': [ '-target mipsel-linux-gnu', ], - }], - ], - }, { # clang==0 - 'cflags': ['-mips32r2', '-Wa,-mips32r2', ], - }], - ], - }], - ['mips_arch_variant=="r1"', { - 'conditions': [ - ['clang==1', { - 'conditions': [ - ['OS=="android"', { - 'cflags': [ '-target mipsel-linux-android', '-march=mipsel', '-mcpu=mips32'], - 'ldflags': [ '-target mipsel-linux-android', ], - }, { - 'cflags': [ '-target mipsel-linux-gnu', '-march=mipsel', '-mcpu=mips32'], - 'ldflags': [ '-target mipsel-linux-gnu', ], - }], - ], - }, { # clang==0 - 'cflags': ['-mips32', '-Wa,-mips32', ], - }], - ], - }], - ['clang==1', { - 'cflags!': [ - # Clang does not support the following options. - '-finline-limit=64', - ], - 'cflags': [ - # TODO(gordanac) Enable integrated-as. - '-no-integrated-as', - ], - }], - ['clang==1 and OS=="android"', { - 'cflags': [ - '-B<(android_toolchain)', # Else /usr/bin/as gets picked up. - ], - 'ldflags': [ - # Let clang find the ld in the NDK. - '--gcc-toolchain=<(android_toolchain)/..', - ], - }], - ['mips_dsp_rev==1', { - 'cflags': ['-mdsp'], - }], - ['mips_dsp_rev==2', { - 'cflags': ['-mdspr2'], - }], - ], - 'cflags': [ - '-m<(mips_float_abi)-float' - ], - 'ldflags': [ - '-Wl,--no-keep-memory' - ], - 'cflags_cc': [ - '-Wno-uninitialized', - ], - }], - ], - }], - ['target_arch=="mips64el"', { - 'target_conditions': [ - ['_toolset=="target"', { - 'conditions': [ - ['mips_arch_variant=="r6"', { - 'cflags': ['-mips64r6', '-Wa,-mips64r6'], - 'ldflags': ['-mips64r6'], - }], - ['mips_arch_variant=="r2"', { - 'cflags': ['-mips64r2', '-Wa,-mips64r2'], - 'ldflags': ['-mips64r2'], - }], - ], - 'cflags_cc': [ - '-Wno-uninitialized', - ], - }], - ], - }], - ['linux_fpic==1', { - 'cflags': [ - '-fPIC', - ], - 'ldflags': [ - '-fPIC', - ], - }], - ['sysroot!=""', { - 'target_conditions': [ - ['_toolset=="target"', { - 'cflags': [ - '--sysroot=<(sysroot)', - ], - 'ldflags': [ - '--sysroot=<(sysroot)', - '=223', { - # Newer binutils don't set DT_RPATH unless you disable "new" dtags - # and the new DT_RUNPATH doesn't work without --no-as-needed flag. - # FIXME(mithro): Figure out the --as-needed/--no-as-needed flags - # inside this file to allow usage of --no-as-needed and removal of - # this flag. - 'ldflags': [ - '-Wl,--disable-new-dtags', - ], - }], - ['gcc_version>=47 and clang==0', { - 'target_conditions': [ - ['_toolset=="target"', { - 'cflags_cc': [ - '-std=gnu++11', - # See comment for -Wno-c++11-narrowing. - '-Wno-narrowing', - # TODO(thakis): Remove, http://crbug.com/263960 - '-Wno-literal-suffix', - ], - }], - ], - }], - ['host_gcc_version>=47 and clang==0 and host_clang==0', { - 'target_conditions': [ - ['_toolset=="host"', { - 'cflags_cc': [ - '-std=gnu++11', - # See comment for -Wno-c++11-narrowing. - '-Wno-narrowing', - # TODO(thakis): Remove, http://crbug.com/263960 - '-Wno-literal-suffix', - ], - }], - ], - }], - ], - }, - }], - # FreeBSD-specific options; note that most FreeBSD options are set above, - # with Linux. - ['OS=="freebsd"', { - 'target_defaults': { - 'ldflags': [ - '-Wl,--no-keep-memory', - ], - }, - }], - # Android-specific options; note that most are set above with Linux. - ['OS=="android"', { - 'variables': { - # This is a unique identifier for a given build. It's used for - # identifying various build artifacts corresponding to a particular - # build of chrome (e.g. where to find archived symbols). - 'chrome_build_id%': '', - 'conditions': [ - # Figure this out early since it needs symbols from libgcc.a, so it - # has to be before that in the set of libraries. - ['component=="shared_library"', { - 'android_libcpp_library': 'c++_shared', - }, { - 'android_libcpp_library': 'c++_static', - }], - ], - - # Placing this variable here prevents from forking libvpx, used - # by remoting. Remoting is off, so it needn't built, - # so forking it's deps seems like overkill. - # But this variable need defined to properly run gyp. - # A proper solution is to have an OS==android conditional - # in third_party/libvpx/libvpx.gyp to define it. - 'libvpx_path': 'lib/linux/arm', - }, - 'target_defaults': { - 'variables': { - 'release_extra_cflags%': '', - 'conditions': [ - # If we're using the components build, append "cr" to all shared - # libraries to avoid naming collisions with android system library - # versions with the same name (e.g. skia, icu). - ['component=="shared_library"', { - 'android_product_extension': 'cr.so', - }, { - 'android_product_extension': 'so', - } ], - ], - }, - 'target_conditions': [ - ['_type=="shared_library"', { - 'product_extension': '<(android_product_extension)', - }], - - # Settings for building device targets using Android's toolchain. - # These are based on the setup.mk file from the Android NDK. - # - # The NDK Android executable link step looks as follows: - # $LDFLAGS - # $(TARGET_CRTBEGIN_DYNAMIC_O) <-- crtbegin.o - # $(PRIVATE_OBJECTS) <-- The .o that we built - # $(PRIVATE_STATIC_LIBRARIES) <-- The .a that we built - # $(TARGET_LIBGCC) <-- libgcc.a - # $(PRIVATE_SHARED_LIBRARIES) <-- The .so that we built - # $(PRIVATE_LDLIBS) <-- System .so - # $(TARGET_CRTEND_O) <-- crtend.o - # - # For now the above are approximated for executables by adding - # crtbegin.o to the end of the ldflags and 'crtend.o' to the end - # of 'libraries'. - # - # The NDK Android shared library link step looks as follows: - # $LDFLAGS - # $(PRIVATE_OBJECTS) <-- The .o that we built - # -l,--whole-archive - # $(PRIVATE_WHOLE_STATIC_LIBRARIES) - # -l,--no-whole-archive - # $(PRIVATE_STATIC_LIBRARIES) <-- The .a that we built - # $(TARGET_LIBGCC) <-- libgcc.a - # $(PRIVATE_SHARED_LIBRARIES) <-- The .so that we built - # $(PRIVATE_LDLIBS) <-- System .so - # - # For now, assume that whole static libraries are not needed. - # - # For both executables and shared libraries, add the proper - # libgcc.a to the start of libraries which puts it in the - # proper spot after .o and .a files get linked in. - # - # TODO: The proper thing to do longer-tem would be proper gyp - # support for a custom link command line. - ['_toolset=="target"', { - 'cflags!': [ - '-pthread', # Not supported by Android toolchain. - ], - 'cflags': [ - '-ffunction-sections', - '-funwind-tables', - '-g', - '-fstack-protector', - '-fno-short-enums', - '-finline-limit=64', - '<@(release_extra_cflags)', - '--sysroot=<(android_ndk_sysroot)', - # NOTE: The libc++ header include paths below are specified in - # cflags rather than include_dirs because they need to come - # after include_dirs. - # The include ordering here is important; change with caution. - '-isystem<(android_libcpp_include)', - '-isystem<(android_ndk_root)/sources/cxx-stl/llvm-libc++abi/libcxxabi/include', - '-isystem<(android_ndk_root)/sources/android/support/include', - ], - 'defines': [ - 'ANDROID', - '__GNU_SOURCE=1', # Necessary for clone() - 'CHROME_BUILD_ID="<(chrome_build_id)"', - # The NDK has these things, but doesn't define the constants - # to say that it does. Define them here instead. - 'HAVE_SYS_UIO_H', - ], - 'ldflags!': [ - '-pthread', # Not supported by Android toolchain. - ], - 'ldflags': [ - '-Wl,--build-id=sha1', - '-Wl,--no-undefined', - '--sysroot=<(android_ndk_sysroot)', - '-nostdlib', - '-L<(android_libcpp_libs_dir)', - # Don't allow visible symbols from libgcc or libc++ to be - # re-exported. - '-Wl,--exclude-libs=libgcc.a', - '-Wl,--exclude-libs=libc++_static.a', - # Don't allow visible symbols from libraries that contain - # assembly code with symbols that aren't hidden properly. - # http://crbug.com/448386 - '-Wl,--exclude-libs=libcommon_audio.a', - '-Wl,--exclude-libs=libcommon_audio_neon.a', - '-Wl,--exclude-libs=libcommon_audio_sse2.a', - '-Wl,--exclude-libs=libiSACFix.a', - '-Wl,--exclude-libs=libisac_neon.a', - '-Wl,--exclude-libs=libopus.a', - '-Wl,--exclude-libs=libvpx.a', - ], - 'libraries': [ - '-l<(android_libcpp_library)', - '-latomic', - # Manually link the libgcc.a that the cross compiler uses. - '(_target_name).map', - ], - }, - }], - ], - }], - ['_mac_bundle', { - 'xcode_settings': {'OTHER_LDFLAGS': ['-Wl,-ObjC']}, - 'target_conditions': [ - ['_type=="executable"', { - 'conditions': [ - ['asan==1', { - 'postbuilds': [ - { - 'variables': { - # Define copy_asan_dylib_path in a variable ending in - # _path so that gyp understands it's a path and - # performs proper relativization during dict merging. - 'copy_asan_dylib_path': - 'mac/copy_asan_runtime_dylib.sh', - }, - 'postbuild_name': 'Copy ASan runtime dylib', - 'action': [ - '<(copy_asan_dylib_path)', - ], - }, - ], - }], - ], - }], - ], - }], - ], # target_conditions - }, # target_defaults - }], # OS=="mac" or OS=="ios" - ['OS=="mac"', { - 'target_defaults': { - 'defines': [ - # Prevent Mac OS X AssertMacros.h from defining macros that collide - # with common names, like 'check', 'require', and 'verify'. - # (Included by system header. Also exists on iOS but not included.) - # http://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/AssertMacros.h - '__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORE=0', - ], - 'variables': { - # These should end with %, but there seems to be a bug with % in - # variables that are intended to be set to different values in - # different targets, like these. - 'mac_pie': 1, # Most executables can be position-independent. - # Strip debugging symbols from the target. - 'mac_strip': '<(mac_strip_release)', - 'conditions': [ - ['asan==1', { - 'conditions': [ - ['mac_want_real_dsym=="default"', { - 'mac_real_dsym': 1, - }, { - 'mac_real_dsym': '<(mac_want_real_dsym)' - }], - ], - }, { - 'conditions': [ - ['mac_want_real_dsym=="default"', { - 'mac_real_dsym': 0, # Fake .dSYMs are fine in most cases. - }, { - 'mac_real_dsym': '<(mac_want_real_dsym)' - }], - ], - }], - ], - }, - 'configurations': { - 'Release_Base': { - 'conditions': [ - ['branding=="Chrome" and buildtype=="Official"', { - 'xcode_settings': { - 'OTHER_CFLAGS': [ - # The Google Chrome Framework dSYM generated by dsymutil has - # grown larger than 4GB, which dsymutil can't handle. Reduce - # the amount of debug symbols. - '-fno-standalone-debug', # See http://crbug.com/479841 - ] - }, - }], - ], - }, # configuration "Release" - }, # configurations - 'xcode_settings': { - 'GCC_DYNAMIC_NO_PIC': 'NO', # No -mdynamic-no-pic - # (Equivalent to -fPIC) - # MACOSX_DEPLOYMENT_TARGET maps to -mmacosx-version-min - 'MACOSX_DEPLOYMENT_TARGET': '<(mac_deployment_target)', - # Keep pch files below xcodebuild/. - 'SHARED_PRECOMPS_DIR': '$(CONFIGURATION_BUILD_DIR)/SharedPrecompiledHeaders', - 'OTHER_CFLAGS': [ - # Someday this can be replaced by an 'GCC_STRICT_ALIASING': 'NO' - # xcode_setting, but not until all downstream projects' mac bots are - # using xcode >= 4.6, because that's when the default value of the - # flag in the compiler switched. Pre-4.6, the value 'NO' for that - # setting is a no-op as far as xcode is concerned, but the compiler - # behaves differently based on whether -fno-strict-aliasing is - # specified or not. - '-fno-strict-aliasing', # See http://crbug.com/32204. - ], - }, - 'target_conditions': [ - ['_type=="executable"', { - 'postbuilds': [ - { - # Arranges for data (heap) pages to be protected against - # code execution when running on Mac OS X 10.7 ("Lion"), and - # ensures that the position-independent executable (PIE) bit - # is set for ASLR when running on Mac OS X 10.5 ("Leopard"). - 'variables': { - # Define change_mach_o_flags in a variable ending in _path - # so that GYP understands it's a path and performs proper - # relativization during dict merging. - 'change_mach_o_flags_path': - 'mac/change_mach_o_flags_from_xcode.sh', - 'change_mach_o_flags_options%': [ - ], - 'target_conditions': [ - ['mac_pie==0 or release_valgrind_build==1', { - # Don't enable PIE if it's unwanted. It's unwanted if - # the target specifies mac_pie=0 or if building for - # Valgrind, because Valgrind doesn't understand slide. - # See the similar mac_pie/release_valgrind_build check - # below. - 'change_mach_o_flags_options': [ - '--no-pie', - ], - }], - ], - }, - 'postbuild_name': 'Change Mach-O Flags', - 'action': [ - '<(change_mach_o_flags_path)', - '>@(change_mach_o_flags_options)', - ], - }, - ], - 'target_conditions': [ - ['mac_pie==1 and release_valgrind_build==0', { - # Turn on position-independence (ASLR) for executables. When - # PIE is on for the Chrome executables, the framework will - # also be subject to ASLR. - # Don't do this when building for Valgrind, because Valgrind - # doesn't understand slide. TODO: Make Valgrind on Mac OS X - # understand slide, and get rid of the Valgrind check. - 'xcode_settings': { - 'OTHER_LDFLAGS': [ - '-Wl,-pie', # Position-independent executable (MH_PIE) - ], - }, - }], - ], - }], - ['(_type=="executable" or _type=="shared_library" or \ - _type=="loadable_module") and mac_strip!=0', { - 'target_conditions': [ - ['mac_real_dsym == 1', { - # To get a real .dSYM bundle produced by dsymutil, set the - # debug information format to dwarf-with-dsym. Since - # strip_from_xcode will not be used, set Xcode to do the - # stripping as well. - 'configurations': { - 'Release_Base': { - 'xcode_settings': { - 'DEBUG_INFORMATION_FORMAT': 'dwarf-with-dsym', - 'DEPLOYMENT_POSTPROCESSING': 'YES', - 'STRIP_INSTALLED_PRODUCT': 'YES', - 'conditions': [ - # Only strip non-ASan builds. - ['asan==0', { - 'target_conditions': [ - ['_type=="shared_library" or _type=="loadable_module"', { - # The Xcode default is to strip debugging symbols - # only (-S). Local symbols should be stripped as - # well, which will be handled by -x. Xcode will - # continue to insert -S when stripping even when - # additional flags are added with STRIPFLAGS. - 'STRIPFLAGS': '-x', - }], # _type=="shared_library" or _type=="loadable_module" - ], # target_conditions - }, { # asan != 0 - 'STRIPFLAGS': '-S', - }], - ], - }, # xcode_settings - }, # configuration "Release" - }, # configurations - }, { # mac_real_dsym != 1 - # To get a fast fake .dSYM bundle, use a post-build step to - # produce the .dSYM and strip the executable. strip_from_xcode - # only operates in the Release configuration. - 'postbuilds': [ - { - 'variables': { - # Define strip_from_xcode in a variable ending in _path - # so that gyp understands it's a path and performs proper - # relativization during dict merging. - 'strip_from_xcode_path': 'mac/strip_from_xcode', - }, - 'postbuild_name': 'Strip If Needed', - 'action': ['<(strip_from_xcode_path)'], - }, - ], # postbuilds - }], # mac_real_dsym - ], # target_conditions - }], # (_type=="executable" or _type=="shared_library" or - # _type=="loadable_module") and mac_strip!=0 - ], # target_conditions - }, # target_defaults - }], # OS=="mac" - ['OS=="ios"', { - 'includes': [ - 'ios/coverage.gypi', - ], - 'target_defaults': { - 'xcode_settings' : { - 'CLANG_CXX_LANGUAGE_STANDARD': 'c++11', - - 'conditions': [ - # Older Xcodes do not support -Wno-deprecated-register, so pass an - # additional flag to suppress the "unknown compiler option" error. - # Restrict this flag to builds that are either compiling with Xcode - # or compiling with Xcode's Clang. This will allow Ninja builds to - # continue failing on unknown compiler options. - # TODO(rohitrao): This flag is temporary and should be removed as - # soon as the iOS bots are updated to use Xcode 5.1. - ['clang_xcode==1', { - 'WARNING_CFLAGS': [ - '-Wno-unknown-warning-option', - # It's not possible to achieve nullability completeness before - # all builders are running Xcode 7. crbug.com/499809 - '-Wno-nullability-completeness', - ], - }], - - # Limit the valid architectures depending on "target_subarch". - # This need to include the "arm" architectures but also the "x86" - # ones (they are used when building for the simulator). - ['target_subarch=="arm32"', { - 'VALID_ARCHS': ['armv7', 'i386'], - }], - ['target_subarch=="arm64"', { - 'VALID_ARCHS': ['arm64', 'x86_64'], - }], - ['target_subarch=="both"', { - 'VALID_ARCHS': ['arm64', 'armv7', 'x86_64', 'i386'], - }], - ['use_system_libcxx==1', { - 'target_conditions': [ - # Only use libc++ when building target for iOS not when building - # tools for the host (OS X) as Mac targets OS X SDK 10.6 which - # does not support libc++. - ['_toolset=="target"', { - 'CLANG_CXX_LIBRARY': 'libc++', # -stdlib=libc++ - }] - ], - }, { - # The default for deployment target of 7.0+ is libc++, so force - # the old behavior unless libc++ is enabled. - 'CLANG_CXX_LIBRARY': 'libstdc++', # -stdlib=libstdc++ - }], - ], - }, - 'target_conditions': [ - ['_toolset=="host"', { - 'xcode_settings': { - 'SDKROOT': 'macosx<(mac_sdk)', # -isysroot - 'MACOSX_DEPLOYMENT_TARGET': '<(mac_deployment_target)', - 'VALID_ARCHS': [ - 'x86_64', - ], - 'ARCHS': [ - 'x86_64', - ], - }, - }], - ['_toolset=="target"', { - 'xcode_settings': { - # This section should be for overriding host settings. But, - # since we can't negate the iphone deployment target above, we - # instead set it here for target only. - 'IPHONEOS_DEPLOYMENT_TARGET': '<(ios_deployment_target)', - 'ARCHS': ['$(ARCHS_STANDARD_INCLUDING_64_BIT)'], - }, - }], - ['_type=="executable"', { - 'configurations': { - 'Release_Base': { - 'xcode_settings': { - 'DEPLOYMENT_POSTPROCESSING': 'YES', - 'STRIP_INSTALLED_PRODUCT': 'YES', - }, - }, - 'Debug_Base': { - 'xcode_settings': { - # Remove dSYM to reduce build time. - 'DEBUG_INFORMATION_FORMAT': 'dwarf', - }, - }, - }, - 'xcode_settings': { - 'conditions': [ - ['chromium_ios_signing', { - # iOS SDK wants everything for device signed. - 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': 'iPhone Developer', - }, { - 'CODE_SIGNING_REQUIRED': 'NO', - 'CODE_SIGN_IDENTITY[sdk=iphoneos*]': '', - }], - ], - }, - }], - ], # target_conditions - }, # target_defaults - }], # OS=="ios" - ['OS=="win"', { - 'target_defaults': { - 'defines': [ - '_WIN32_WINNT=0x0603', - 'WINVER=0x0603', - 'WIN32', - '_WINDOWS', - 'NOMINMAX', - 'PSAPI_VERSION=1', - '_CRT_RAND_S', - 'CERT_CHAIN_PARA_HAS_EXTRA_FIELDS', - 'WIN32_LEAN_AND_MEAN', - '_ATL_NO_OPENGL', - '_SECURE_ATL', - # _HAS_EXCEPTIONS must match ExceptionHandling in msvs_settings. - '_HAS_EXCEPTIONS=0', - # Silence some warnings; we can't switch the the 'recommended' - # versions as they're not available on old OSs. - '_WINSOCK_DEPRECATED_NO_WARNINGS', - ], - 'conditions': [ - ['buildtype=="Official"', { - # In official builds, targets can self-select an optimization - # level by defining a variable named 'optimize', and setting it - # to one of - # - "size", optimizes for minimal code size - the default. - # - "speed", optimizes for speed over code size. - # - "max", whole program optimization and link-time code - # generation. This is very expensive and should be used - # sparingly. - 'variables': { - 'optimize%': 'size', - }, - 'msvs_settings': { - 'VCLinkerTool': { - # Set /LTCG for the official builds. - 'LinkTimeCodeGeneration': '1', - 'AdditionalOptions': [ - # Set the number of LTCG code-gen threads to eight. - # The default is four. This gives a 5-10% link speedup. - '/cgthreads:8', - ], - }, - }, - 'target_conditions': [ - ['optimize=="size"', { - 'msvs_settings': { - 'VCCLCompilerTool': { - # 1, optimizeMinSpace, Minimize Size (/O1) - 'Optimization': '1', - # 2, favorSize - Favor small code (/Os) - 'FavorSizeOrSpeed': '2', - }, - }, - }, - ], - # This config is used to avoid a problem in ffmpeg, see - # http://crbug.com/264459. - ['optimize=="size_no_ltcg"', { - 'msvs_settings': { - 'VCCLCompilerTool': { - # 1, optimizeMinSpace, Minimize Size (/O1) - 'Optimization': '1', - # 2, favorSize - Favor small code (/Os) - 'FavorSizeOrSpeed': '2', - }, - }, - }, - ], - ['optimize=="speed"', { - 'msvs_settings': { - 'VCCLCompilerTool': { - # 2, optimizeMaxSpeed, Maximize Speed (/O2) - 'Optimization': '2', - # 1, favorSpeed - Favor fast code (/Ot) - 'FavorSizeOrSpeed': '1', - }, - }, - }, - ], - ['optimize=="max"', { - # Disable Warning 4702 ("Unreachable code") for the WPO/PGO - # builds. Probably anything that this would catch that - # wouldn't be caught in a normal build isn't going to - # actually be a bug, so the incremental value of C4702 for - # PGO builds is likely very small. - 'msvs_disabled_warnings': [ - 4702 - ], - 'msvs_settings': { - 'VCCLCompilerTool': { - # 2, optimizeMaxSpeed, Maximize Speed (/O2) - 'Optimization': '2', - # 1, favorSpeed - Favor fast code (/Ot) - 'FavorSizeOrSpeed': '1', - # This implies link time code generation. - 'WholeProgramOptimization': 'true', - }, - }, - }, - ], - ], - }, - ], - ['msvs_xtree_patched!=1', { - # If xtree hasn't been patched, then we disable C4702. Otherwise, - # it's enabled. This will generally only be true for system-level - # installed Express users. - 'msvs_disabled_warnings': [ - 4702, - ], - }], - ], - 'msvs_system_include_dirs': [ - '<(windows_sdk_path)/Include/shared', - '<(windows_sdk_path)/Include/um', - '<(windows_sdk_path)/Include/winrt', - '$(VSInstallDir)/VC/atlmfc/include', - ], - 'msvs_cygwin_shell': 0, - 'msvs_disabled_warnings': [ - # C4091: 'typedef ': ignored on left of 'X' when no variable is - # declared. - # This happens in a number of Windows headers. Dumb. - 4091, - - # C4127: conditional expression is constant - # This warning can in theory catch dead code and other problems, but - # triggers in far too many desirable cases where the conditional - # expression is either set by macros or corresponds some legitimate - # compile-time constant expression (due to constant template args, - # conditionals comparing the sizes of different types, etc.). Some of - # these can be worked around, but it's not worth it. - 4127, - - # C4351: new behavior: elements of array 'array' will be default - # initialized - # This is a silly "warning" that basically just alerts you that the - # compiler is going to actually follow the language spec like it's - # supposed to, instead of not following it like old buggy versions - # did. There's absolutely no reason to turn this on. - 4351, - - # C4355: 'this': used in base member initializer list - # It's commonly useful to pass |this| to objects in a class' - # initializer list. While this warning can catch real bugs, most of - # the time the constructors in question don't attempt to call methods - # on the passed-in pointer (until later), and annotating every legit - # usage of this is simply more hassle than the warning is worth. - 4355, - - # C4503: 'identifier': decorated name length exceeded, name was - # truncated - # This only means that some long error messages might have truncated - # identifiers in the presence of lots of templates. It has no effect - # on program correctness and there's no real reason to waste time - # trying to prevent it. - 4503, - - # Warning C4589 says: "Constructor of abstract class ignores - # initializer for virtual base class." Disable this warning because it - # is flaky in VS 2015 RTM. It triggers on compiler generated - # copy-constructors in some cases. - 4589, - - # C4611: interaction between 'function' and C++ object destruction is - # non-portable - # This warning is unavoidable when using e.g. setjmp/longjmp. MSDN - # suggests using exceptions instead of setjmp/longjmp for C++, but - # Chromium code compiles without exception support. We therefore have - # to use setjmp/longjmp for e.g. JPEG decode error handling, which - # means we have to turn off this warning (and be careful about how - # object destruction happens in such cases). - 4611, - - # TODO(maruel): These warnings are level 4. They will be slowly - # removed as code is fixed. - 4100, # Unreferenced formal parameter - 4121, # Alignment of a member was sensitive to packing - 4244, # Conversion from 'type1' to 'type2', possible loss of data - 4481, # Nonstandard extension used: override specifier 'keyword' - 4505, # Unreferenced local function has been removed - 4510, # Default constructor could not be generated - 4512, # Assignment operator could not be generated - 4610, # Object can never be instantiated - 4838, # Narrowing conversion. Doesn't seem to be very useful. - 4996, # 'X': was declared deprecated (for GetVersionEx). - - # These are variable shadowing warnings that are new in VS2015. We - # should work through these at some point -- they may be removed from - # the RTM release in the /W4 set. - 4456, 4457, 4458, 4459, - ], - 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions': ['/MP'], - 'MinimalRebuild': 'false', - 'BufferSecurityCheck': 'true', - 'EnableFunctionLevelLinking': 'true', - 'RuntimeTypeInfo': 'false', - 'WarningLevel': '4', - 'WarnAsError': 'true', - 'DebugInformationFormat': '3', - # ExceptionHandling must match _HAS_EXCEPTIONS above. - 'ExceptionHandling': '0', - }, - 'VCLibrarianTool': { - 'AdditionalOptions': ['/ignore:4221'], - 'AdditionalLibraryDirectories': [ - '<(windows_sdk_path)/Lib/win8/um/x86', - ], - }, - 'VCLinkerTool': { - 'AdditionalDependencies': [ - 'wininet.lib', - 'dnsapi.lib', - 'version.lib', - 'msimg32.lib', - 'ws2_32.lib', - 'usp10.lib', - 'psapi.lib', - 'dbghelp.lib', - 'winmm.lib', - 'shlwapi.lib', - ], - 'AdditionalLibraryDirectories': [ - '<(windows_sdk_path)/Lib/win8/um/x86', - ], - 'GenerateDebugInformation': 'true', - 'MapFileName': '$(OutDir)\\$(TargetName).map', - 'ImportLibrary': '$(OutDir)\\lib\\$(TargetName).lib', - 'FixedBaseAddress': '1', - # SubSystem values: - # 0 == not set - # 1 == /SUBSYSTEM:CONSOLE - # 2 == /SUBSYSTEM:WINDOWS - # Most of the executables we'll ever create are tests - # and utilities with console output. - 'SubSystem': '1', - }, - 'VCMIDLTool': { - 'GenerateStublessProxies': 'true', - 'TypeLibraryName': '$(InputName).tlb', - 'OutputDirectory': '$(IntDir)', - 'HeaderFileName': '$(InputName).h', - 'DLLDataFileName': '$(InputName).dlldata.c', - 'InterfaceIdentifierFileName': '$(InputName)_i.c', - 'ProxyFileName': '$(InputName)_p.c', - }, - 'VCResourceCompilerTool': { - 'Culture' : '1033', - 'AdditionalIncludeDirectories': [ - '<(DEPTH)', - '<(SHARED_INTERMEDIATE_DIR)', - ], - }, - 'target_conditions': [ - ['_type=="executable"', { - 'VCManifestTool': { - 'EmbedManifest': 'true', - }, - }], - ['_type=="executable" and ">(win_exe_compatibility_manifest)"!=""', { - 'VCManifestTool': { - 'AdditionalManifestFiles': [ - '>(win_exe_compatibility_manifest)', - ], - }, - }], - ], - 'conditions': [ - # Building with Clang on Windows is a work in progress and very - # experimental. See crbug.com/82385. - # Keep this in sync with the similar blocks in build/config/compiler/BUILD.gn - ['clang==1', { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - # Many files use intrinsics without including this header. - # TODO(hans): Fix those files, or move this to sub-GYPs. - '/FIIntrin.h', - - # TODO(hans): Make this list shorter eventually, http://crbug.com/504657 - '-Qunused-arguments', # http://crbug.com/504658 - '-Wno-microsoft', # http://crbug.com/505296 - '-Wno-switch', # http://crbug.com/505308 - '-Wno-unknown-pragmas', # http://crbug.com/505314 - '-Wno-unused-function', # http://crbug.com/505316 - '-Wno-unused-value', # http://crbug.com/505318 - '-Wno-unused-local-typedef', # http://crbug.com/411648 - ], - }, - }], - ['clang==1 and target_arch=="ia32"', { - 'VCCLCompilerTool': { - 'WarnAsError': 'false', - 'AdditionalOptions': [ - '/fallback', - ], - }, - }], - ['clang==1 and clang_use_chrome_plugins==1', { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - '<@(clang_chrome_plugins_flags)', - ], - }, - }], - ['clang==1 and MSVS_VERSION == "2013"', { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - '-fmsc-version=1800', - ], - }, - }], - ['clang==1 and MSVS_VERSION == "2015"', { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ - '-fmsc-version=1900', - ], - }, - }], - ['clang==1 and "=48 and clang==0', { - 'target_defaults': { - 'cflags': [ - '-Wno-unused-local-typedefs', - ], - }, - }], - ['gcc_version>=48 and clang==0 and host_clang==1', { - 'target_defaults': { - 'target_conditions': [ - ['_toolset=="host"', { 'cflags!': [ '-Wno-unused-local-typedefs' ]}], - ], - }, - }], - ['clang==1 and ((OS!="mac" and OS!="ios") or clang_xcode==0) ' - 'and OS!="win"', { - 'make_global_settings': [ - ['CC', '<(make_clang_dir)/bin/clang'], - ['CXX', '<(make_clang_dir)/bin/clang++'], - ['CC.host', '$(CC)'], - ['CXX.host', '$(CXX)'], - ], - }], - ['clang==1 and OS=="win"', { - 'make_global_settings': [ - # On Windows, gyp's ninja generator only looks at CC. - ['CC', '<(make_clang_dir)/bin/clang-cl'], - ], - }], - ['use_lld==1 and OS=="win"', { - 'make_global_settings': [ - # Limited to Windows because -flavor link2 is the driver that is - # compatible with link.exe. - ['LD', '<(make_clang_dir)/bin/lld -flavor link2'], - ], - }], - ['OS=="android" and clang==0', { - # Hardcode the compiler names in the Makefile so that - # it won't depend on the environment at make time. - 'make_global_settings': [ - ['CC', '(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_win(_browsertest|_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)win/'], - ['exclude', '(^|/)win_[^/]*\\.(h|cc)$'] ], - }], - ['OS!="mac" or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_(cocoa|mac)(_unittest)?\\.(h|cc|mm?)$'], - ['exclude', '(^|/)(cocoa|mac)/'] ], - }], - ['OS!="ios" or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_ios(_unittest)?\\.(h|cc|mm?)$'], - ['exclude', '(^|/)ios/'] ], - }], - ['(OS!="mac" and OS!="ios") or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '\\.mm?$' ] ], - }], - # Do not exclude the linux files on *BSD since most of them can be - # shared at this point. - # In case a file is not needed, it is going to be excluded later on. - # TODO(evan): the above is not correct; we shouldn't build _linux - # files on non-linux. - ['OS!="linux" and OS!="openbsd" and OS!="freebsd" or >(nacl_untrusted_build)==1', { - 'sources/': [ - ['exclude', '_linux(_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)linux/'], - ], - }], - ['OS!="android" or _toolset=="host" or >(nacl_untrusted_build)==1', { - 'sources/': [ - ['exclude', '_android(_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)android/'], - ], - }], - ['OS=="win" and >(nacl_untrusted_build)==0', { - 'sources/': [ - ['exclude', '_posix(_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)posix/'], - ], - }], - ['<(chromeos)!=1 or >(nacl_untrusted_build)==1', { - 'sources/': [ - ['exclude', '_chromeos(_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)chromeos/'], - ], - }], - ['>(nacl_untrusted_build)==0', { - 'sources/': [ - ['exclude', '_nacl(_unittest)?\\.(h|cc)$'], - ], - }], - ['OS!="linux" and OS!="openbsd" and OS!="freebsd" or >(nacl_untrusted_build)==1', { - 'sources/': [ - ['exclude', '_xdg(_unittest)?\\.(h|cc)$'], - ], - }], - ['<(use_x11)!=1 or >(nacl_untrusted_build)==1', { - 'sources/': [ - ['exclude', '_(x|x11)(_interactive_uitest|_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)x11_[^/]*\\.(h|cc)$'], - ['exclude', '(^|/)x11/'], - ['exclude', '(^|/)x/'], - ], - }], - ['<(toolkit_views)==0 or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_views(_browsertest|_unittest)?\\.(h|cc)$'] ] - }], - ['<(use_aura)==0 or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_aura(_browsertest|_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)aura/'], - ] - }], - ['<(use_aura)==0 or <(use_x11)==0 or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_aurax11(_browsertest|_unittest)?\\.(h|cc)$'] ] - }], - ['<(use_aura)==0 or OS!="win" or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_aurawin\\.(h|cc)$'] ] - }], - ['<(use_aura)==0 or OS!="linux" or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_auralinux\\.(h|cc)$'] ] - }], - ['<(use_ash)==0 or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_ash(_browsertest|_unittest)?\\.(h|cc)$'], - ['exclude', '(^|/)ash/'], - ] - }], - ['<(use_ash)==0 or OS!="win" or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_ashwin\\.(h|cc)$'] ] - }], - ['<(use_ozone)==0 or >(nacl_untrusted_build)==1', { - 'sources/': [ ['exclude', '_ozone(_browsertest|_unittest)?\\.(h|cc)$'] ] - }], - ['<(use_pango)==0', { - 'sources/': [ ['exclude', '(^|_)pango(_util|_browsertest|_unittest)?\\.(h|cc)$'], ], - }], - ] -} diff --git a/build/gn_migration.gypi b/build/gn_migration.gypi deleted file mode 100644 index 94fcb0d5997a7..0000000000000 --- a/build/gn_migration.gypi +++ /dev/null @@ -1,723 +0,0 @@ -# Copyright (c) 2015 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file defines five targets that we are using to track the progress of the -# GYP->GN migration: -# -# 'both_gn_and_gyp' lists what GN is currently capable of building and should -# match the 'both_gn_and_gyp' target in //BUILD.gn. -# -# 'gyp_all' Should include everything built when building "all"; i.e., if you -# type 'ninja gyp_all' and then 'ninja all', the second build should do -# nothing. 'gyp_all' should just depend on the other four targets. -# -# 'gyp_only' lists any targets that are not meant to be ported over to the GN -# build. -# -# 'gyp_remaining' lists all of the targets that still need to be converted, -# i.e., all of the other (non-empty) targets that a GYP build will build. -# -# TODO(GYP): crbug.com/481694. Add a build step to the bot that enforces the -# above contracts. - -{ - 'targets': [ - { - 'target_name': 'gyp_all', - 'type': 'none', - 'dependencies': [ - 'both_gn_and_gyp', - 'gyp_only', - 'gyp_remaining', - ] - }, - { - # This target should mirror the structure of //:both_gn_and_gyp - # in src/BUILD.gn as closely as possible, for ease of comparison. - 'target_name': 'both_gn_and_gyp', - 'type': 'none', - 'dependencies': [ - '../base/base.gyp:base_i18n_perftests', - '../base/base.gyp:base_perftests', - '../base/base.gyp:base_unittests', - '../base/base.gyp:build_utf8_validator_tables#host', - '../base/base.gyp:check_example', - '../cc/cc_tests.gyp:cc_perftests', - '../cc/cc_tests.gyp:cc_unittests', - '../cc/blink/cc_blink_tests.gyp:cc_blink_unittests', - '../chrome/chrome.gyp:chrome', - '../chrome/chrome.gyp:browser_tests', - '../chrome/chrome.gyp:chrome_app_unittests', - '../chrome/chrome.gyp:chromedriver', - '../chrome/chrome.gyp:chromedriver_tests', - '../chrome/chrome.gyp:chromedriver_unittests', - '../chrome/chrome.gyp:interactive_ui_tests', - '../chrome/chrome.gyp:load_library_perf_tests', - '../chrome/chrome.gyp:performance_browser_tests', - '../chrome/chrome.gyp:sync_integration_tests', - '../chrome/chrome.gyp:sync_performance_tests', - '../chrome/chrome.gyp:unit_tests', - '../chrome/tools/profile_reset/jtl_compiler.gyp:jtl_compiler', - '../cloud_print/cloud_print.gyp:cloud_print_unittests', - '../components/components.gyp:network_hints_browser', - '../components/components.gyp:policy_templates', - '../components/components_tests.gyp:components_browsertests', - '../components/components_tests.gyp:components_perftests', - '../components/components_tests.gyp:components_unittests', - '../content/content.gyp:content_app_browser', - '../content/content.gyp:content_app_child', - '../content/content_shell_and_tests.gyp:content_browsertests', - '../content/content_shell_and_tests.gyp:content_gl_benchmark', - '../content/content_shell_and_tests.gyp:content_gl_tests', - '../content/content_shell_and_tests.gyp:content_perftests', - '../content/content_shell_and_tests.gyp:content_shell', - '../content/content_shell_and_tests.gyp:content_unittests', - '../courgette/courgette.gyp:courgette', - '../courgette/courgette.gyp:courgette_fuzz', - '../courgette/courgette.gyp:courgette_minimal_tool', - '../courgette/courgette.gyp:courgette_unittests', - '../crypto/crypto.gyp:crypto_unittests', - '../extensions/extensions_tests.gyp:extensions_browsertests', - '../extensions/extensions_tests.gyp:extensions_unittests', - '../device/device_tests.gyp:device_unittests', - '../gin/gin.gyp:gin_v8_snapshot_fingerprint', - '../gin/gin.gyp:gin_shell', - '../gin/gin.gyp:gin_unittests', - '../google_apis/gcm/gcm.gyp:gcm_unit_tests', - '../google_apis/gcm/gcm.gyp:mcs_probe', - '../google_apis/google_apis.gyp:google_apis_unittests', - '../gpu/gpu.gyp:angle_unittests', - '../gpu/gpu.gyp:gl_tests', - '../gpu/gpu.gyp:gpu_perftests', - '../gpu/gpu.gyp:gpu_unittests', - '../gpu/gles2_conform_support/gles2_conform_support.gyp:gles2_conform_support', # TODO(GYP) crbug.com/471920 - '../gpu/gles2_conform_support/gles2_conform_test.gyp:gles2_conform_test', # TODO(GYP) crbug.com/471920 - '../gpu/khronos_glcts_support/khronos_glcts_test.gyp:khronos_glcts_test', # TODO(GYP) crbug.com/471903 to make this complete. - '../ipc/ipc.gyp:ipc_perftests', - '../ipc/ipc.gyp:ipc_tests', - '../ipc/mojo/ipc_mojo.gyp:ipc_mojo_unittests', - '../jingle/jingle.gyp:jingle_unittests', - '../media/media.gyp:ffmpeg_regression_tests', # TODO(GYP) this should be conditional on media_use_ffmpeg - '../media/media.gyp:media_perftests', - '../media/media.gyp:media_unittests', - '../media/midi/midi.gyp:midi_unittests', - '../media/cast/cast.gyp:cast_benchmarks', - '../media/cast/cast.gyp:cast_unittests', - '../media/cast/cast.gyp:generate_barcode_video', - '../media/cast/cast.gyp:generate_timecode_audio', - '../mojo/mojo.gyp:mojo', - '../mojo/mojo_base.gyp:mojo_application_base', - '../mojo/mojo_base.gyp:mojo_common_unittests', - '../net/net.gyp:crash_cache', - '../net/net.gyp:crl_set_dump', - '../net/net.gyp:dns_fuzz_stub', - '../net/net.gyp:dump_cache', - '../net/net.gyp:gdig', - '../net/net.gyp:get_server_time', - '../net/net.gyp:hpack_example_generator', - '../net/net.gyp:hpack_fuzz_mutator', - '../net/net.gyp:hpack_fuzz_wrapper', - '../net/net.gyp:net_perftests', - '../net/net.gyp:net_unittests', - '../net/net.gyp:net_watcher', # TODO(GYP): This should be conditional on use_v8_in_net - '../net/net.gyp:run_testserver', - '../net/net.gyp:stress_cache', - '../net/net.gyp:tld_cleanup', - '../ppapi/ppapi_internal.gyp:ppapi_example_audio', - '../ppapi/ppapi_internal.gyp:ppapi_example_audio_input', - '../ppapi/ppapi_internal.gyp:ppapi_example_c_stub', - '../ppapi/ppapi_internal.gyp:ppapi_example_cc_stub', - '../ppapi/ppapi_internal.gyp:ppapi_example_compositor', - '../ppapi/ppapi_internal.gyp:ppapi_example_crxfs', - '../ppapi/ppapi_internal.gyp:ppapi_example_enumerate_devices', - '../ppapi/ppapi_internal.gyp:ppapi_example_file_chooser', - '../ppapi/ppapi_internal.gyp:ppapi_example_flash_topmost', - '../ppapi/ppapi_internal.gyp:ppapi_example_gamepad', - '../ppapi/ppapi_internal.gyp:ppapi_example_gles2', - '../ppapi/ppapi_internal.gyp:ppapi_example_gles2_spinning_cube', - '../ppapi/ppapi_internal.gyp:ppapi_example_graphics_2d', - '../ppapi/ppapi_internal.gyp:ppapi_example_ime', - '../ppapi/ppapi_internal.gyp:ppapi_example_input', - '../ppapi/ppapi_internal.gyp:ppapi_example_media_stream_audio', - '../ppapi/ppapi_internal.gyp:ppapi_example_media_stream_video', - '../ppapi/ppapi_internal.gyp:ppapi_example_mouse_cursor', - '../ppapi/ppapi_internal.gyp:ppapi_example_mouse_lock', - '../ppapi/ppapi_internal.gyp:ppapi_example_paint_manager', - '../ppapi/ppapi_internal.gyp:ppapi_example_post_message', - '../ppapi/ppapi_internal.gyp:ppapi_example_printing', - '../ppapi/ppapi_internal.gyp:ppapi_example_scaling', - '../ppapi/ppapi_internal.gyp:ppapi_example_scroll', - '../ppapi/ppapi_internal.gyp:ppapi_example_simple_font', - '../ppapi/ppapi_internal.gyp:ppapi_example_threading', - '../ppapi/ppapi_internal.gyp:ppapi_example_url_loader', - '../ppapi/ppapi_internal.gyp:ppapi_example_url_loader_file', - '../ppapi/ppapi_internal.gyp:ppapi_example_vc', - '../ppapi/ppapi_internal.gyp:ppapi_example_video_decode', - '../ppapi/ppapi_internal.gyp:ppapi_example_video_decode_dev', - '../ppapi/ppapi_internal.gyp:ppapi_example_video_effects', - '../ppapi/ppapi_internal.gyp:ppapi_example_video_encode', - '../ppapi/ppapi_internal.gyp:ppapi_tests', - '../ppapi/ppapi_internal.gyp:ppapi_perftests', - '../ppapi/ppapi_internal.gyp:ppapi_unittests', - '../ppapi/tools/ppapi_tools.gyp:pepper_hash_for_uma', - '../printing/printing.gyp:printing_unittests', - '../skia/skia_tests.gyp:skia_unittests', - '../skia/skia.gyp:filter_fuzz_stub', - '../skia/skia.gyp:image_operations_bench', - '../sql/sql.gyp:sql_unittests', - '../sync/sync.gyp:run_sync_testserver', - '../sync/sync.gyp:sync_unit_tests', - '../sync/tools/sync_tools.gyp:sync_client', - '../sync/tools/sync_tools.gyp:sync_listen_notifications', - '../testing/gmock.gyp:gmock_main', - '../third_party/WebKit/Source/platform/blink_platform_tests.gyp:blink_heap_unittests', - '../third_party/WebKit/Source/platform/blink_platform_tests.gyp:blink_platform_unittests', - '../third_party/WebKit/Source/web/web_tests.gyp:webkit_unit_tests', - '../third_party/WebKit/Source/wtf/wtf_tests.gyp:wtf_unittests', - '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation_unittests', - '../third_party/codesighs/codesighs.gyp:codesighs', - '../third_party/codesighs/codesighs.gyp:maptsvdifftool', - '../third_party/leveldatabase/leveldatabase.gyp:env_chromium_unittests', - '../third_party/libphonenumber/libphonenumber.gyp:libphonenumber_unittests', - '../third_party/libaddressinput/libaddressinput.gyp:libaddressinput_unittests', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_system_unittests', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_public_bindings_unittests', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_public_environment_unittests', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_public_system_perftests', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_public_system_unittests', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_public_utility_unittests', - '../third_party/pdfium/samples/samples.gyp:pdfium_diff', - '../third_party/pdfium/samples/samples.gyp:pdfium_test', - '../tools/gn/gn.gyp:gn', - '../tools/gn/gn.gyp:generate_test_gn_data', - '../tools/gn/gn.gyp:gn_unittests', - '../tools/imagediff/image_diff.gyp:image_diff', - '../tools/perf/clear_system_cache/clear_system_cache.gyp:clear_system_cache', - '../tools/telemetry/telemetry.gyp:bitmaptools#host', - '../ui/accessibility/accessibility.gyp:accessibility_unittests', - '../ui/app_list/app_list.gyp:app_list_unittests', - '../ui/base/ui_base_tests.gyp:ui_base_unittests', - '../ui/compositor/compositor.gyp:compositor_unittests', - '../ui/display/display.gyp:display_unittests', - '../ui/events/events.gyp:events_unittests', - '../ui/gfx/gfx_tests.gyp:gfx_unittests', - '../ui/gl/gl_tests.gyp:gl_unittests', - '../ui/message_center/message_center.gyp:message_center_unittests', - '../ui/snapshot/snapshot.gyp:snapshot_unittests', - '../ui/touch_selection/ui_touch_selection.gyp:ui_touch_selection_unittests', - '../ui/views/examples/examples.gyp:views_examples_with_content_exe', - '../url/url.gyp:url_unittests', - '../v8/tools/gyp/v8.gyp:v8_snapshot', - '../v8/tools/gyp/v8.gyp:postmortem-metadata', - ], - 'conditions': [ - ['clang==1', { - 'dependencies': [ - '../build/sanitizers/sanitizers.gyp:llvm-symbolizer', - ], - }], - ['disable_nacl==0 and disable_nacl_untrusted==0', { - 'dependencies': [ - '../components/nacl.gyp:nacl_loader_unittests', - ] - }], - ['enable_extensions==1 and OS!="mac"', { - 'dependencies': [ - '../extensions/shell/app_shell.gyp:app_shell', - '../extensions/shell/app_shell.gyp:app_shell_unittests', - ], - }], - ['enable_mdns==1', { - 'dependencies': [ - '../chrome/chrome.gyp:service_discovery_sniffer', - ] - }], - ['remoting==1', { - 'dependencies': [ - '../remoting/remoting_all.gyp:remoting_all', - ], - }], - ['remoting==1 and chromeos==0 and use_x11==1', { - 'dependencies': [ - '../remoting/remoting.gyp:remoting_me2me_host', - '../remoting/remoting.gyp:remoting_me2me_native_messaging_host', - ], - }], - ['toolkit_views==1', { - 'dependencies': [ - '../ui/app_list/app_list.gyp:app_list_demo', - '../ui/views/views.gyp:views_unittests', - ], - }], - ['use_ash==1', { - 'dependencies': [ - '../ash/ash.gyp:ash_shell', - '../ash/ash.gyp:ash_shell_unittests', - '../ash/ash.gyp:ash_unittests', - ], - }], - ['use_ash==1 or chromeos== 1', { - 'dependencies': [ - '../components/components.gyp:session_manager_component', - ] - }], - ['use_aura==1', { - 'dependencies': [ - '../ui/aura/aura.gyp:aura_bench', - '../ui/aura/aura.gyp:aura_demo', - '../ui/aura/aura.gyp:aura_unittests', - '../ui/keyboard/keyboard.gyp:keyboard_unittests', - '../ui/wm/wm.gyp:wm_unittests', - ], - }], - ['use_ozone==1', { - 'dependencies': [ - '../ui/ozone/ozone.gyp:ozone', - ], - }], - ['use_x11==1', { - 'dependencies': [ - '../tools/xdisplaycheck/xdisplaycheck.gyp:xdisplaycheck', - ], - 'conditions': [ - ['target_arch!="arm"', { - 'dependencies': [ - '../gpu/tools/tools.gyp:compositor_model_bench', - ], - }], - ], - }], - ['OS=="android"', { - 'dependencies': [ - '../base/base.gyp:chromium_android_linker', - '../breakpad/breakpad.gyp:dump_syms', - '../build/android/rezip.gyp:rezip_apk_jar', - '../chrome/chrome.gyp:chrome_public_apk', - '../chrome/chrome.gyp:chrome_public_test_apk', - '../chrome/chrome.gyp:chrome_shell_apk', - '../chrome/chrome.gyp:chromedriver_webview_shell_apk', - #"//clank" TODO(GYP) - conditional somehow? - '../tools/imagediff/image_diff.gyp:image_diff#host', - '../tools/telemetry/telemetry.gyp:bitmaptools#host', - - # TODO(GYP): Remove these when the components_unittests work. - #"//components/history/core/test:test", - #"//components/policy:policy_component_test_support", - #"//components/policy:test_support", - #"//components/rappor:test_support", - #"//components/signin/core/browser:test_support", - #"//components/sync_driver:test_support", - #"//components/user_manager", - #"//components/wallpaper", - - '../content/content_shell_and_tests.gyp:content_shell_apk', - - '../third_party/WebKit/Source/platform/blink_platform_tests.gyp:blink_heap_unittests_apk', - '../third_party/WebKit/Source/platform/blink_platform_tests.gyp:blink_platform_unittests_apk', - '../third_party/WebKit/Source/web/web_tests.gyp:webkit_unit_tests_apk', - '../third_party/WebKit/Source/wtf/wtf_tests.gyp:wtf_unittests_apk', - # TODO(GYP): Are these needed, or will they be pulled in automatically? - #"//third_party/android_tools:android_gcm_java", - #"//third_party/android_tools:uiautomator_java", - #"//third_party/android_tools:android_support_v13_java", - #"//third_party/android_tools:android_support_v7_appcompat_java", - #"//third_party/android_tools:android_support_v7_mediarouter_java", - #"//third_party/mesa", - #"//third_party/mockito:mockito_java", - #"//third_party/openmax_dl/dl", - #"//third_party/speex", - #"//ui/android:ui_java", - - # TODO(GYP): Are these needed? - #"//chrome/test:test_support_unit", - #"//ui/message_center:test_support", - ], - 'dependencies!': [ - '../breakpad/breakpad.gyp:symupload', - '../chrome/chrome.gyp:browser_tests', - '../chrome/chrome.gyp:chromedriver', - '../chrome/chrome.gyp:chromedriver_unitests', - '../chrome/chrome.gyp:interactive_ui_tests', - '../chrome/chrome.gyp:performance_browser_tests', - '../chrome/chrome.gyp:sync_integration_tests', - '../chrome/chrome.gyp:unit_tests', - '../extensions/extensions_tests.gyp:extensions_browsertests', - '../extensions/extensions_tests.gyp:extensions_unittests', - '../google_apis/gcm/gcm.gyp:gcm_unit_tests', - '../ipc/ipc.gyp:ipc_tests', - '../jingle/jingle.gyp:jingle_unittests', - '../net/net.gyp:net_unittests', - #"//ppapi/examples", - '../third_party/pdfium/samples/samples.gyp:pdfium_test', - '../tools/gn/gn.gyp:gn', - '../tools/gn/gn.gyp:gn_unittests', - '../tools/imagediff/image_diff.gyp:image_diff', - '../tools/gn/gn.gyp:gn', - '../tools/gn/gn.gyp:gn_unittests', - '../ui/app_list/app_list.gyp:app_list_unittests', - '../url/url.gyp:url_unittests', - ], - }], - ['OS=="android" or OS=="linux"', { - 'dependencies': [ - '../net/net.gyp:disk_cache_memory_test', - ], - }], - ['chromeos==1', { - 'dependencies': [ - '../chromeos/chromeos.gyp:chromeos_unittests', - '../ui/chromeos/ui_chromeos.gyp:ui_chromeos_unittests', - ] - }], - ['chromeos==1 or OS=="win" or OS=="mac"', { - 'dependencies': [ - '../rlz/rlz.gyp:rlz_id', - '../rlz/rlz.gyp:rlz_lib', - '../rlz/rlz.gyp:rlz_unittests', - ], - }], - ['OS=="android" or OS=="linux" or os_bsd==1', { - 'dependencies': [ - '../breakpad/breakpad.gyp:core-2-minidump', - '../breakpad/breakpad.gyp:microdump_stackwalk', - '../breakpad/breakpad.gyp:minidump_dump', - '../breakpad/breakpad.gyp:minidump_stackwalk', - '../breakpad/breakpad.gyp:symupload', - '../third_party/codesighs/codesighs.gyp:nm2tsv', - ], - }], - ['OS=="linux"', { - 'dependencies': [ - '../breakpad/breakpad.gyp:breakpad_unittests', - '../breakpad/breakpad.gyp:dump_syms#host', - '../breakpad/breakpad.gyp:generate_test_dump', - '../breakpad/breakpad.gyp:minidump-2-core', - '../dbus/dbus.gyp:dbus_test_server', - '../dbus/dbus.gyp:dbus_unittests', - '../media/cast/cast.gyp:tap_proxy', - '../net/net.gyp:disk_cache_memory_test', - '../net/net.gyp:flip_in_mem_edsm_server', - '../net/net.gyp:flip_in_mem_edsm_server_unittests', - '../net/net.gyp:epoll_quic_client', - '../net/net.gyp:epoll_quic_server', - '../net/net.gyp:hpack_example_generator', - '../net/net.gyp:hpack_fuzz_mutator', - '../net/net.gyp:hpack_fuzz_wrapper', - '../net/net.gyp:net_perftests', - '../net/net.gyp:quic_client', - '../net/net.gyp:quic_server', - '../sandbox/sandbox.gyp:chrome_sandbox', - '../sandbox/sandbox.gyp:sandbox_linux_unittests', - '../sandbox/sandbox.gyp:sandbox_linux_jni_unittests', - '../third_party/sqlite/sqlite.gyp:sqlite_shell', - ], - }], - ['OS=="mac"', { - 'dependencies': [ - '../breakpad/breakpad.gyp:crash_inspector', - '../breakpad/breakpad.gyp:dump_syms', - '../breakpad/breakpad.gyp:symupload', - '../third_party/apple_sample_code/apple_sample_code.gyp:apple_sample_code', - '../third_party/molokocacao/molokocacao.gyp:molokocacao', - - # TODO(GYP): remove these when the corresponding root targets work. - #"//cc/blink", - #"//components/ui/zoom:ui_zoom", - #"//content", - #"//content/test:test_support", - #"//device/battery", - #"//device/bluetooth", - #"//device/nfc", - #"//device/usb", - #"//device/vibration", - #"//media/blink", - #"//pdf", - #"//storage/browser", - #"//third_party/brotli", - #"//third_party/flac", - #"//third_party/hunspell", - #//third_party/iccjpeg", - #"//third_party/libphonenumber", - #"//third_party/ots", - #"//third_party/qcms", - #"//third_party/speex", - #"//third_party/webrtc/system_wrappers", - #"//ui/native_theme", - #"//ui/snapshot", - #"//ui/surface", - ], - 'dependencies!': [ - #"//chrome", # TODO(GYP) - #"//chrome/test:browser_tests", # TODO(GYP) - #"//chrome/test:interactive_ui_tests", # TODO(GYP) - #"//chrome/test:sync_integration_tests", # TODO(GYP) - #"//chrome/test:unit_tests", # TODO(GYP) - #"//components:components_unittests", # TODO(GYP) - #"//content/test:content_browsertests", # TODO(GYP) - #"//content/test:content_perftests", # TODO(GYP) - #"//content/test:content_unittests", # TODO(GYP) - #"//extensions:extensions_browsertests", # TODO(GYP) - #"//extensions:extensions_unittests", # TODO(GYP) - #"//net:net_unittests", # TODO(GYP) - #"//third_party/usrsctp", # TODO(GYP) - #"//ui/app_list:app_list_unittests", # TODO(GYP) - #"//ui/gfx:gfx_unittests", # TODO(GYP) - ], - }], - ['OS=="win"', { - 'dependencies': [ - '../base/base.gyp:pe_image_test', - '../chrome/chrome.gyp:crash_service', - '../chrome/chrome.gyp:setup_unittests', - '../chrome_elf/chrome_elf.gyp:chrome_elf_unittests', - '../chrome_elf/chrome_elf.gyp:dll_hash_main', - '../components/components.gyp:wifi_test', - '../net/net.gyp:quic_client', - '../net/net.gyp:quic_server', - '../sandbox/sandbox.gyp:pocdll', - '../sandbox/sandbox.gyp:sandbox_poc', - '../sandbox/sandbox.gyp:sbox_integration_tests', - '../sandbox/sandbox.gyp:sbox_unittests', - '../sandbox/sandbox.gyp:sbox_validation_tests', - '../testing/gtest.gyp:gtest_main', - '../third_party/codesighs/codesighs.gyp:msdump2symdb', - '../third_party/codesighs/codesighs.gyp:msmap2tsv', - '../third_party/pdfium/samples/samples.gyp:pdfium_diff', - '../win8/win8.gyp:metro_viewer', - ], - }], - ], - }, - { - 'target_name': 'gyp_only', - 'type': 'none', - 'conditions': [ - ['OS=="linux" or OS=="win"', { - 'conditions': [ - ['disable_nacl==0 and disable_nacl_untrusted==0', { - 'dependencies': [ - '../mojo/mojo_nacl.gyp:monacl_shell', # This should not be built in chromium. - ] - }], - ] - }], - ], - }, - { - 'target_name': 'gyp_remaining', - 'type': 'none', - 'conditions': [ - ['remoting==1', { - 'dependencies': [ - '../remoting/app_remoting_webapp.gyp:ar_sample_app', # crbug.com/471916 - ], - }], - ['test_isolation_mode!="noop"', { - 'dependencies': [ - '../base/base.gyp:base_unittests_run', - '../cc/cc_tests.gyp:cc_unittests_run', - '../chrome/chrome.gyp:browser_tests_run', - '../chrome/chrome.gyp:chrome_run', - '../chrome/chrome.gyp:interactive_ui_tests_run', - '../chrome/chrome.gyp:sync_integration_tests_run', - '../chrome/chrome.gyp:unit_tests_run', - '../components/components_tests.gyp:components_browsertests_run', - '../components/components_tests.gyp:components_unittests_run', - '../content/content_shell_and_tests.gyp:content_browsertests_run', - '../content/content_shell_and_tests.gyp:content_unittests_run', - '../courgette/courgette.gyp:courgette_unittests_run', - '../crypto/crypto.gyp:crypto_unittests_run', - '../google_apis/gcm/gcm.gyp:gcm_unit_tests_run', - '../gpu/gpu.gyp:gpu_unittests_run', - '../ipc/ipc.gyp:ipc_tests_run', - '../media/cast/cast.gyp:cast_unittests_run', - '../media/media.gyp:media_unittests_run', - '../media/midi/midi.gyp:midi_unittests_run', - '../net/net.gyp:net_unittests_run', - '../printing/printing.gyp:printing_unittests_run', - '../remoting/remoting.gyp:remoting_unittests_run', - '../skia/skia_tests.gyp:skia_unittests_run', - '../sql/sql.gyp:sql_unittests_run', - '../sync/sync.gyp:sync_unit_tests_run', - '../third_party/cacheinvalidation/cacheinvalidation.gyp:cacheinvalidation_unittests_run', - '../third_party/mojo/mojo_edk_tests.gyp:mojo_public_bindings_unittests_run', - '../tools/gn/gn.gyp:gn_unittests_run', - '../ui/accessibility/accessibility.gyp:accessibility_unittests_run', - '../ui/app_list/app_list.gyp:app_list_unittests_run', - '../ui/compositor/compositor.gyp:compositor_unittests_run', - '../ui/events/events.gyp:events_unittests_run', - '../ui/gl/gl_tests.gyp:gl_unittests_run', - '../ui/message_center/message_center.gyp:message_center_unittests_run', - '../ui/touch_selection/ui_touch_selection.gyp:ui_touch_selection_unittests_run', - '../url/url.gyp:url_unittests_run', - ], - 'conditions': [ - ['OS=="linux"', { - 'dependencies': [ - '../sandbox/sandbox.gyp:sandbox_linux_unittests_run', - '../ui/display/display.gyp:display_unittests_run', - ], - }], - ['OS=="mac"', { - 'dependencies': [ - '../sandbox/sandbox.gyp:sandbox_mac_unittests_run', - ], - }], - ['OS=="win"', { - 'dependencies': [ - '../chrome/chrome.gyp:installer_util_unittests_run', - '../chrome/chrome.gyp:setup_unittests_run', - '../sandbox/sandbox.gyp:sbox_integration_tests', - '../sandbox/sandbox.gyp:sbox_unittests', - '../sandbox/sandbox.gyp:sbox_validation_tests', - ], - }], - ['use_ash==1', { - 'dependencies': [ - '../ash/ash.gyp:ash_unittests_run', - ], - }], - ['use_aura==1', { - 'dependencies': [ - '../ui/aura/aura.gyp:aura_unittests_run', - '../ui/wm/wm.gyp:wm_unittests_run', - ], - }], - ['enable_webrtc==1 or OS!="android"', { - 'dependencies': [ - '../jingle/jingle.gyp:jingle_unittests_run', - ], - }], - ['disable_nacl==0 and disable_nacl_untrusted==0', { - 'dependencies': [ - '../components/nacl.gyp:nacl_loader_unittests_run', - ] - }], - ], - }], - ['use_openssl==1', { - 'dependencies': [ - # TODO(GYP): All of these targets still need to be converted. - '../third_party/boringssl/boringssl_tests.gyp:boringssl_ecdsa_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_bn_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_pqueue_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_digest_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_cipher_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_hkdf_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_constant_time_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_thread_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_base64_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_gcm_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_bytestring_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_evp_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_dsa_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_rsa_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_hmac_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_aead_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_ssl_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_err_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_lhash_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_pbkdf_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_dh_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_pkcs12_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_example_mul', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_ec_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_bio_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_pkcs7_test', - '../third_party/boringssl/boringssl_tests.gyp:boringssl_unittests', - ], - }], - ['chromeos==1', { - 'dependencies': [ - '../content/content_shell_and_tests.gyp:jpeg_decode_accelerator_unittest', - '../content/content_shell_and_tests.gyp:video_encode_accelerator_unittest', - ], - }], - ['chromeos==1 and target_arch != "arm"', { - 'dependencies': [ - '../content/content_shell_and_tests.gyp:vaapi_jpeg_decoder_unittest', - ], - }], - ['chromeos==1 or OS=="win" or OS=="android"', { - 'dependencies': [ - '../content/content_shell_and_tests.gyp:video_decode_accelerator_unittest', - ], - }], - ['OS=="linux" or OS=="win"', { - 'dependencies': [ - # TODO(GYP): Figure out which of these run on android/mac/win/ios/etc. - '../net/net.gyp:net_docs', - '../remoting/remoting.gyp:ar_sample_test_driver', - - # TODO(GYP): in progress - see tfarina. - '../third_party/webrtc/tools/tools.gyp:frame_analyzer', - '../third_party/webrtc/tools/tools.gyp:rgba_to_i420_converter', - ], - }], - ['OS=="win"', { - 'dependencies': [ - # TODO(GYP): All of these targets still need to be converted. - '../base/base.gyp:debug_message', - '../chrome/chrome.gyp:app_shim', - '../chrome/chrome.gyp:gcapi_dll', - '../chrome/chrome.gyp:gcapi_test', - '../chrome/chrome.gyp:installer_util_unittests', - '../chrome/chrome.gyp:pack_policy_templates', - '../chrome/chrome.gyp:sb_sigutil', - '../chrome/chrome.gyp:setup', - '../chrome/installer/mini_installer.gyp:mini_installer', - '../chrome/tools/crash_service/caps/caps.gyp:caps', - '../cloud_print/gcp20/prototype/gcp20_device.gyp:gcp20_device', - '../cloud_print/gcp20/prototype/gcp20_device.gyp:gcp20_device_unittests', - '../cloud_print/service/win/service.gyp:cloud_print_service', - '../cloud_print/service/win/service.gyp:cloud_print_service_config', - '../cloud_print/service/win/service.gyp:cloud_print_service_setup', - '../cloud_print/virtual_driver/win/install/virtual_driver_install.gyp:virtual_driver_setup', - '../cloud_print/virtual_driver/win/virtual_driver.gyp:gcp_portmon', - '../components/test_runner/test_runner.gyp:layout_test_helper', - '../content/content_shell_and_tests.gyp:content_shell_crash_service', - '../gpu/gpu.gyp:angle_end2end_tests', - '../gpu/gpu.gyp:angle_perftests', - '../net/net.gyp:net_docs', - '../ppapi/ppapi_internal.gyp:ppapi_perftests', - '../remoting/remoting.gyp:ar_sample_test_driver', - '../remoting/remoting.gyp:remoting_breakpad_tester', - '../remoting/remoting.gyp:remoting_console', - '../remoting/remoting.gyp:remoting_desktop', - '../rlz/rlz.gyp:rlz', - '../tools/win/static_initializers/static_initializers.gyp:static_initializers', - ], - }], - ['OS=="win" and win_use_allocator_shim==1', { - 'dependencies': [ - '../base/allocator/allocator.gyp:allocator_unittests', - ] - }], - ['OS=="win" and target_arch=="ia32"', { - 'dependencies': [ - # TODO(GYP): All of these targets need to be ported over. - '../base/base.gyp:base_win64', - '../base/base.gyp:base_i18n_nacl_win64', - '../chrome/chrome.gyp:crash_service_win64', - '../chrome/chrome.gyp:launcher_support64', - '../components/components.gyp:breakpad_win64', - '../courgette/courgette.gyp:courgette64', - '../crypto/crypto.gyp:crypto_nacl_win64', - '../ipc/ipc.gyp:ipc_win64', - '../sandbox/sandbox.gyp:sandbox_win64', - '../cloud_print/virtual_driver/win/virtual_driver64.gyp:gcp_portmon64', - '../cloud_print/virtual_driver/win/virtual_driver64.gyp:virtual_driver_lib64', - ], - }], - ['OS=="win" and target_arch=="ia32" and configuration_policy==1', { - 'dependencies': [ - # TODO(GYP): All of these targets need to be ported over. - '../components/components.gyp:policy_win64', - ] - }], - ], - }, - ] -} - diff --git a/build/grit_action.gypi b/build/grit_action.gypi deleted file mode 100644 index b24f0f8d715cd..0000000000000 --- a/build/grit_action.gypi +++ /dev/null @@ -1,71 +0,0 @@ -# Copyright (c) 2011 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to invoke grit in a -# consistent manner. To use this the following variables need to be -# defined: -# grit_grd_file: string: grd file path -# grit_out_dir: string: the output directory path - -# It would be really nice to do this with a rule instead of actions, but it -# would need to determine inputs and outputs via grit_info on a per-file -# basis. GYP rules don't currently support that. They could be extended to -# do this, but then every generator would need to be updated to handle this. - -{ - 'variables': { - 'grit_cmd': ['python', '<(DEPTH)/tools/grit/grit.py'], - 'grit_resource_ids%': '<(DEPTH)/tools/gritsettings/resource_ids', - # This makes it possible to add more defines in specific targets, - # instead of build/common.gypi . - 'grit_additional_defines%': [], - 'grit_rc_header_format%': [], - 'grit_whitelist%': '', - - 'conditions': [ - # These scripts can skip writing generated files if they are identical - # to the already existing files, which avoids further build steps, like - # recompilation. However, a dependency (earlier build step) having a - # newer timestamp than an output (later build step) confuses some build - # systems, so only use this on ninja, which explicitly supports this use - # case (gyp turns all actions into ninja restat rules). - ['"<(GENERATOR)"=="ninja"', { - 'write_only_new': '1', - }, { - 'write_only_new': '0', - }], - ], - }, - 'conditions': [ - ['"<(grit_whitelist)"==""', { - 'variables': { - 'grit_whitelist_flag': [], - } - }, { - 'variables': { - 'grit_whitelist_flag': ['-w', '<(grit_whitelist)'], - } - }] - ], - 'inputs': [ - '(main_class)'] - }], - ['enable_errorprone == 1', { - 'extra_inputs': [ - '<(errorprone_exe_path)', - ], - 'extra_args': [ '--use-errorprone-path=<(errorprone_exe_path)' ], - }], - ], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/javac.py', - '^@(java_sources)', - '>@(input_jars_paths)', - '<@(extra_inputs)', - ], - 'outputs': [ - '<(jar_path)', - '<(stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/javac.py', - '--classpath=>(input_jars_paths)', - '--src-gendirs=>(generated_src_dirs)', - '--chromium-code=<(chromium_code)', - '--stamp=<(stamp)', - '--jar-path=<(jar_path)', - '<@(extra_args)', - '^@(java_sources)', - ], - }, - ], - 'conditions': [ - ['main_class != ""', { - 'actions': [ - { - 'action_name': 'create_java_binary_script_<(_target_name)', - 'message': 'Creating java binary script <(_target_name)', - 'variables': { - 'output': '<(PRODUCT_DIR)/bin/<(_target_name)', - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/create_java_binary_script.py', - '<(jar_path)', - ], - 'outputs': [ - '<(output)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/create_java_binary_script.py', - '--classpath=>(input_jars_paths)', - '--jar-path=<(jar_path)', - '--output=<(output)', - '--main-class=>(main_class)', - ] - } - ] - }], - ['enable_errorprone == 1', { - 'dependencies': [ - '<(DEPTH)/third_party/errorprone/errorprone.gyp:chromium_errorprone', - ], - }], - ] -} - diff --git a/build/host_prebuilt_jar.gypi b/build/host_prebuilt_jar.gypi deleted file mode 100644 index feed5caebb594..0000000000000 --- a/build/host_prebuilt_jar.gypi +++ /dev/null @@ -1,50 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule to -# copy a prebuilt JAR for use on a host to the output directory. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'my_prebuilt_jar', -# 'type': 'none', -# 'variables': { -# 'jar_path': 'path/to/prebuilt.jar', -# }, -# 'includes': [ 'path/to/this/gypi/file' ], -# } -# -# Required variables: -# jar_path - The path to the prebuilt jar. - -{ - 'dependencies': [ - ], - 'variables': { - 'dest_path': '<(PRODUCT_DIR)/lib.java/<(_target_name).jar', - 'src_path': '<(jar_path)', - }, - 'all_dependent_settings': { - 'variables': { - 'input_jars_paths': [ - '<(dest_path)', - ] - }, - }, - 'actions': [ - { - 'action_name': 'copy_prebuilt_jar', - 'message': 'Copy <(src_path) to <(dest_path)', - 'inputs': [ - '<(src_path)', - ], - 'outputs': [ - '<(dest_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/cp.py', '<(src_path)', '<(dest_path)', - ], - } - ] -} diff --git a/build/internal/release_defaults.gypi b/build/internal/release_defaults.gypi deleted file mode 100644 index 1bf674ac12165..0000000000000 --- a/build/internal/release_defaults.gypi +++ /dev/null @@ -1,18 +0,0 @@ -# Copyright (c) 2011 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. -{ - 'msvs_settings': { - 'VCCLCompilerTool': { - 'StringPooling': 'true', - }, - 'VCLinkerTool': { - # No incremental linking. - 'LinkIncremental': '1', - # Eliminate Unreferenced Data (/OPT:REF). - 'OptimizeReferences': '2', - # Folding on (/OPT:ICF). - 'EnableCOMDATFolding': '2', - }, - }, -} diff --git a/build/internal/release_impl.gypi b/build/internal/release_impl.gypi deleted file mode 100644 index 5ac0e09d1ec4c..0000000000000 --- a/build/internal/release_impl.gypi +++ /dev/null @@ -1,17 +0,0 @@ -# Copyright (c) 2011 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. -{ - 'includes': ['release_defaults.gypi'], - 'msvs_settings': { - 'VCCLCompilerTool': { - 'OmitFramePointers': 'false', - # The above is not sufficient (http://crbug.com/106711): it - # simply eliminates an explicit "/Oy", but both /O2 and /Ox - # perform FPO regardless, so we must explicitly disable. - # We still want the false setting above to avoid having - # "/Oy /Oy-" and warnings about overriding. - 'AdditionalOptions': ['/Oy-'], - }, - }, -} diff --git a/build/internal/release_impl_official.gypi b/build/internal/release_impl_official.gypi deleted file mode 100644 index 36d5d787e9b35..0000000000000 --- a/build/internal/release_impl_official.gypi +++ /dev/null @@ -1,41 +0,0 @@ -# Copyright (c) 2011 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. -{ - 'includes': ['release_defaults.gypi'], - 'defines': ['OFFICIAL_BUILD'], - 'msvs_settings': { - 'VCCLCompilerTool': { - 'InlineFunctionExpansion': '2', - 'EnableIntrinsicFunctions': 'true', - 'OmitFramePointers': 'false', - # The above is not sufficient (http://crbug.com/106711): it - # simply eliminates an explicit "/Oy", but both /O2 and /Ox - # perform FPO regardless, so we must explicitly disable. - # We still want the false setting above to avoid having - # "/Oy /Oy-" and warnings about overriding. - 'AdditionalOptions': ['/Oy-'], - }, - 'VCLibrarianTool': { - 'AdditionalOptions': [ - '/ltcg', - '/expectedoutputsize:120000000' - ], - }, - 'VCLinkerTool': { - 'AdditionalOptions': [ - '/time', - # This may reduce memory fragmentation during linking. - # The expected size is 40*1024*1024, which gives us about 10M of - # headroom as of Dec 16, 2011. - '/expectedoutputsize:41943040', - ], - # The /PROFILE flag causes the linker to add a "FIXUP" debug stream to - # the generated PDB. According to MSDN documentation, this flag is only - # available (or perhaps supported) in the Enterprise (team development) - # version of Visual Studio. If this blocks your official build, simply - # comment out this line, then re-run "gclient runhooks". - 'Profile': 'true', - }, - }, -} diff --git a/build/ios/coverage.gypi b/build/ios/coverage.gypi deleted file mode 100644 index e82208902cc42..0000000000000 --- a/build/ios/coverage.gypi +++ /dev/null @@ -1,32 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -{ - 'variables': { - 'enable_coverage%': 0, - }, - 'conditions': [ - ['enable_coverage', { - 'target_defaults': { - 'defines': [ - 'ENABLE_TEST_CODE_COVERAGE=1' - ], - 'link_settings': { - 'xcode_settings': { - 'OTHER_LDFLAGS': [ - '-fprofile-arcs', - ], - }, - }, - 'xcode_settings': { - 'OTHER_CFLAGS': [ - '-fprofile-arcs', - '-ftest-coverage', - ], - }, - }, - }], - ], -} - diff --git a/build/ios/mac_build.gypi b/build/ios/mac_build.gypi deleted file mode 100644 index 4da21eb25353c..0000000000000 --- a/build/ios/mac_build.gypi +++ /dev/null @@ -1,83 +0,0 @@ -# Copyright (c) 2012 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# Xcode throws an error if an iOS target depends on a Mac OS X target. So -# any place a utility program needs to be build and run, an action is -# used to run ninja as script to work around this. -# Example: -# { -# 'target_name': 'foo', -# 'type': 'none', -# 'variables': { -# # The name of a directory used for ninja. This cannot be shared with -# # another mac build. -# 'ninja_output_dir': 'ninja-foo', -# # The full path to the location in which the ninja executable should be -# # placed. This cannot be shared with another mac build. -# 'ninja_product_dir': -# '<(DEPTH)/xcodebuild/<(ninja_output_dir)/<(CONFIGURATION_NAME)', -# # The list of all the gyp files that contain the targets to run. -# 're_run_targets': [ -# 'foo.gyp', -# ], -# }, -# 'includes': ['path_to/mac_build.gypi'], -# 'actions': [ -# { -# 'action_name': 'compile foo', -# 'inputs': [], -# 'outputs': [], -# 'action': [ -# '<@(ninja_cmd)', -# # All the targets to build. -# 'foo1', -# 'foo2', -# ], -# }, -# ], -# } -{ - 'variables': { - 'variables': { - 'parent_generator%': '<(GENERATOR)', - }, - 'parent_generator%': '<(parent_generator)', - # Common ninja command line flags. - 'ninja_cmd': [ - # Bounce through clean_env to clean up the environment so things - # set by the iOS build don't pollute the Mac build. - '<(DEPTH)/build/ios/clean_env.py', - # ninja must be found in the PATH. - 'ADD_TO_PATH=/src. -# Optional/automatic variables: -# add_to_dependents_classpaths - Set to 0 if the resulting jar file should not -# be added to its dependents' classpaths. -# additional_input_paths - These paths will be included in the 'inputs' list to -# ensure that this target is rebuilt when one of these paths changes. -# additional_src_dirs - Additional directories with .java files to be compiled -# and included in the output of this target. -# generated_src_dirs - Same as additional_src_dirs except used for .java files -# that are generated at build time. This should be set automatically by a -# target's dependencies. The .java files in these directories are not -# included in the 'inputs' list (unlike additional_src_dirs). -# input_jars_paths - The path to jars to be included in the classpath. This -# should be filled automatically by depending on the appropriate targets. -# javac_includes - A list of specific files to include. This is by default -# empty, which leads to inclusion of all files specified. May include -# wildcard, and supports '**/' for recursive path wildcards, ie.: -# '**/MyFileRegardlessOfDirectory.java', '**/IncludedPrefix*.java'. -# has_java_resources - Set to 1 if the java target contains an -# Android-compatible resources folder named res. If 1, R_package and -# R_package_relpath must also be set. -# R_package - The java package in which the R class (which maps resources to -# integer IDs) should be generated, e.g. org.chromium.content. -# R_package_relpath - Same as R_package, but replace each '.' with '/'. -# res_extra_dirs - A list of extra directories containing Android resources. -# These directories may be generated at build time. -# res_extra_files - A list of the files in res_extra_dirs. -# never_lint - Set to 1 to not run lint on this target. - -{ - 'dependencies': [ - '<(DEPTH)/build/android/setup.gyp:build_output_dirs' - ], - 'variables': { - 'add_to_dependents_classpaths%': 1, - 'android_jar': '<(android_sdk)/android.jar', - 'input_jars_paths': [ '<(android_jar)' ], - 'additional_src_dirs': [], - 'javac_includes': [], - 'jar_name': '<(_target_name).jar', - 'jar_dir': '<(PRODUCT_DIR)/lib.java', - 'jar_path': '<(intermediate_dir)/<(jar_name)', - 'jar_final_path': '<(jar_dir)/<(jar_name)', - 'jar_excluded_classes': [ '*/R.class', '*/R##*.class' ], - 'instr_stamp': '<(intermediate_dir)/instr.stamp', - 'additional_input_paths': [], - 'dex_path': '<(PRODUCT_DIR)/lib.java/<(_target_name).dex.jar', - 'generated_src_dirs': ['>@(generated_R_dirs)'], - 'generated_R_dirs': [], - 'has_java_resources%': 0, - 'res_extra_dirs': [], - 'res_extra_files': [], - 'res_v14_skip%': 0, - 'resource_input_paths': ['>@(res_extra_files)'], - 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)', - 'compile_stamp': '<(intermediate_dir)/compile.stamp', - 'lint_stamp': '<(intermediate_dir)/lint.stamp', - 'lint_result': '<(intermediate_dir)/lint_result.xml', - 'lint_config': '<(intermediate_dir)/lint_config.xml', - 'never_lint%': 0, - 'findbugs_stamp': '<(intermediate_dir)/findbugs.stamp', - 'run_findbugs%': 0, - 'java_in_dir_suffix%': '/src', - 'proguard_config%': '', - 'proguard_preprocess%': '0', - 'enable_errorprone%': '0', - 'errorprone_exe_path': '<(PRODUCT_DIR)/bin.java/chromium_errorprone', - 'variables': { - 'variables': { - 'proguard_preprocess%': 0, - 'emma_never_instrument%': 0, - }, - 'conditions': [ - ['proguard_preprocess == 1', { - 'javac_jar_path': '<(intermediate_dir)/<(_target_name).pre.jar' - }, { - 'javac_jar_path': '<(jar_path)' - }], - ['chromium_code != 0 and emma_coverage != 0 and emma_never_instrument == 0', { - 'emma_instrument': 1, - }, { - 'emma_instrument': 0, - }], - ], - }, - 'emma_instrument': '<(emma_instrument)', - 'javac_jar_path': '<(javac_jar_path)', - }, - 'conditions': [ - ['add_to_dependents_classpaths == 1', { - # This all_dependent_settings is used for java targets only. This will add the - # jar path to the classpath of dependent java targets. - 'all_dependent_settings': { - 'variables': { - 'input_jars_paths': ['<(jar_final_path)'], - 'library_dexed_jars_paths': ['<(dex_path)'], - }, - }, - }], - ['has_java_resources == 1', { - 'variables': { - 'resource_dir': '<(java_in_dir)/res', - 'res_input_dirs': ['<(resource_dir)', '<@(res_extra_dirs)'], - 'resource_input_paths': ['|(java_resources.<(_target_name).gypcmd >@(resource_input_paths))', - 'process_resources_options': [], - 'conditions': [ - ['res_v14_skip == 1', { - 'process_resources_options': ['--v14-skip'] - }], - ], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/process_resources.py', - '<(DEPTH)/build/android/gyp/generate_v14_compatible_resources.py', - '>@(resource_input_paths)', - '>@(dependencies_res_zip_paths)', - '>(inputs_list_file)', - ], - 'outputs': [ - '<(resource_zip_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/process_resources.py', - '--android-sdk', '<(android_sdk)', - '--aapt-path', '<(android_aapt_path)', - '--non-constant-id', - - '--android-manifest', '<(android_manifest)', - '--custom-package', '<(R_package)', - - '--dependencies-res-zips', '>(dependencies_res_zip_paths)', - '--resource-dirs', '<(res_input_dirs)', - - '--R-dir', '<(R_dir)', - '--resource-zip-out', '<(resource_zip_path)', - - '<@(process_resources_options)', - ], - }, - ], - }], - ['proguard_preprocess == 1', { - 'actions': [ - { - 'action_name': 'proguard_<(_target_name)', - 'message': 'Proguard preprocessing <(_target_name) jar', - 'inputs': [ - '<(android_sdk_root)/tools/proguard/lib/proguard.jar', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/proguard.py', - '<(javac_jar_path)', - '<(proguard_config)', - ], - 'outputs': [ - '<(jar_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/proguard.py', - '--proguard-path=<(android_sdk_root)/tools/proguard/lib/proguard.jar', - '--input-path=<(javac_jar_path)', - '--output-path=<(jar_path)', - '--proguard-config=<(proguard_config)', - '--classpath=<(android_sdk_jar) >(input_jars_paths)', - ] - }, - ], - }], - ['run_findbugs == 1', { - 'actions': [ - { - 'action_name': 'findbugs_<(_target_name)', - 'message': 'Running findbugs on <(_target_name)', - 'inputs': [ - '<(DEPTH)/build/android/findbugs_diff.py', - '<(DEPTH)/build/android/findbugs_filter/findbugs_exclude.xml', - '<(DEPTH)/build/android/pylib/utils/findbugs.py', - '>@(input_jars_paths)', - '<(jar_final_path)', - '<(compile_stamp)', - ], - 'outputs': [ - '<(findbugs_stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/findbugs_diff.py', - '--auxclasspath-gyp', '>(input_jars_paths)', - '--stamp', '<(findbugs_stamp)', - '<(jar_final_path)', - ], - }, - ], - }], - ['enable_errorprone == 1', { - 'dependencies': [ - '<(DEPTH)/third_party/errorprone/errorprone.gyp:chromium_errorprone', - ], - }], - ], - 'actions': [ - { - 'action_name': 'javac_<(_target_name)', - 'message': 'Compiling <(_target_name) java sources', - 'variables': { - 'extra_args': [], - 'extra_inputs': [], - 'java_sources': ['>!@(find >(java_in_dir)>(java_in_dir_suffix) >(additional_src_dirs) -name "*.java")'], - 'conditions': [ - ['enable_errorprone == 1', { - 'extra_inputs': [ - '<(errorprone_exe_path)', - ], - 'extra_args': [ '--use-errorprone-path=<(errorprone_exe_path)' ], - }], - ], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/javac.py', - '>@(java_sources)', - '>@(input_jars_paths)', - '>@(additional_input_paths)', - '<@(extra_inputs)', - ], - 'outputs': [ - '<(compile_stamp)', - '<(javac_jar_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/javac.py', - '--bootclasspath=<(android_sdk_jar)', - '--classpath=>(input_jars_paths)', - '--src-gendirs=>(generated_src_dirs)', - '--javac-includes=<(javac_includes)', - '--chromium-code=<(chromium_code)', - '--jar-path=<(javac_jar_path)', - '--jar-excluded-classes=<(jar_excluded_classes)', - '--stamp=<(compile_stamp)', - '>@(java_sources)', - '<@(extra_args)', - ] - }, - { - 'action_name': 'instr_jar_<(_target_name)', - 'message': 'Instrumenting <(_target_name) jar', - 'variables': { - 'input_path': '<(jar_path)', - 'output_path': '<(jar_final_path)', - 'stamp_path': '<(instr_stamp)', - 'instr_type': 'jar', - }, - 'outputs': [ - '<(jar_final_path)', - ], - 'inputs': [ - '<(jar_path)', - ], - 'includes': [ 'android/instr_action.gypi' ], - }, - { - 'variables': { - 'src_dirs': [ - '<(java_in_dir)<(java_in_dir_suffix)', - '>@(additional_src_dirs)', - ], - 'stamp_path': '<(lint_stamp)', - 'result_path': '<(lint_result)', - 'config_path': '<(lint_config)', - 'lint_jar_path': '<(jar_final_path)', - }, - 'inputs': [ - '<(jar_final_path)', - '<(compile_stamp)', - ], - 'outputs': [ - '<(lint_stamp)', - ], - 'includes': [ 'android/lint_action.gypi' ], - }, - { - 'action_name': 'jar_toc_<(_target_name)', - 'message': 'Creating <(_target_name) jar.TOC', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/util/md5_check.py', - '<(DEPTH)/build/android/gyp/jar_toc.py', - '<(jar_final_path)', - ], - 'outputs': [ - '<(jar_final_path).TOC', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/jar_toc.py', - '--jar-path=<(jar_final_path)', - '--toc-path=<(jar_final_path).TOC', - ] - }, - { - 'action_name': 'dex_<(_target_name)', - 'variables': { - 'conditions': [ - ['emma_instrument != 0', { - 'dex_no_locals': 1, - }], - ], - 'dex_input_paths': [ '<(jar_final_path)' ], - 'output_path': '<(dex_path)', - }, - 'includes': [ 'android/dex_action.gypi' ], - }, - ], -} diff --git a/build/java_aidl.gypi b/build/java_aidl.gypi deleted file mode 100644 index dda28942e2b6f..0000000000000 --- a/build/java_aidl.gypi +++ /dev/null @@ -1,79 +0,0 @@ -# Copyright (c) 2012 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to build Java aidl files in a consistent manner. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'aidl_aidl-file-name', -# 'type': 'none', -# 'variables': { -# 'aidl_interface_file': '/.aidl', -# 'aidl_import_include': '<(DEPTH)/', -# }, -# 'sources': { -# '/.aidl', -# '/.aidl', -# ... -# }, -# 'includes': ['/java_aidl.gypi'], -# } -# -# -# The generated java files will be: -# <(PRODUCT_DIR)/lib.java/.java -# <(PRODUCT_DIR)/lib.java/.java -# ... -# -# Optional variables: -# aidl_import_include - This should be an absolute path to your java src folder -# that contains the classes that are imported by your aidl files. -# -# TODO(cjhopman): dependents need to rebuild when this target's inputs have changed. - -{ - 'variables': { - 'aidl_path%': '<(android_sdk_tools)/aidl', - 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)/aidl', - 'aidl_import_include%': '', - 'additional_aidl_arguments': [], - 'additional_aidl_input_paths': [], - }, - 'direct_dependent_settings': { - 'variables': { - 'generated_src_dirs': ['<(intermediate_dir)/'], - }, - }, - 'conditions': [ - ['aidl_import_include != ""', { - 'variables': { - 'additional_aidl_arguments': [ '-I<(aidl_import_include)' ], - 'additional_aidl_input_paths': [ '.apk -# java_in_dir - The top-level java directory. The src should be in -# <(java_in_dir)/src. -# Optional/automatic variables: -# additional_input_paths - These paths will be included in the 'inputs' list to -# ensure that this target is rebuilt when one of these paths changes. -# additional_res_packages - Package names of R.java files generated in addition -# to the default package name defined in AndroidManifest.xml. -# additional_src_dirs - Additional directories with .java files to be compiled -# and included in the output of this target. -# additional_bundled_libs - Additional libraries what will be stripped and -# bundled in the apk. -# asset_location - The directory where assets are located. -# create_abi_split - Whether to create abi-based spilts. Splits -# are supported only for minSdkVersion >= 21. -# create_density_splits - Whether to create density-based apk splits. -# language_splits - List of languages to create apk splits for. -# generated_src_dirs - Same as additional_src_dirs except used for .java files -# that are generated at build time. This should be set automatically by a -# target's dependencies. The .java files in these directories are not -# included in the 'inputs' list (unlike additional_src_dirs). -# input_jars_paths - The path to jars to be included in the classpath. This -# should be filled automatically by depending on the appropriate targets. -# is_test_apk - Set to 1 if building a test apk. This prevents resources from -# dependencies from being re-included. -# native_lib_target - The target_name of the target which generates the final -# shared library to be included in this apk. A stripped copy of the -# library will be included in the apk. -# resource_dir - The directory for resources. -# shared_resources - Make a resource package that can be loaded by a different -# application at runtime to access the package's resources. -# R_package - A custom Java package to generate the resource file R.java in. -# By default, the package given in AndroidManifest.xml will be used. -# include_all_resources - Set to 1 to include all resource IDs in all generated -# R.java files. -# use_chromium_linker - Enable the content dynamic linker that allows sharing the -# RELRO section of the native libraries between the different processes. -# load_library_from_zip - When using the dynamic linker, load the library -# directly out of the zip file. -# use_relocation_packer - Enable relocation packing. Relies on the chromium -# linker, so use_chromium_linker must also be enabled. -# enable_chromium_linker_tests - Enable the content dynamic linker test support -# code. This allows a test APK to inject a Linker.TestRunner instance at -# runtime. Should only be used by the chromium_linker_test_apk target!! -# never_lint - Set to 1 to not run lint on this target. -# java_in_dir_suffix - To override the /src suffix on java_in_dir. -# app_manifest_version_name - set the apps 'human readable' version number. -# app_manifest_version_code - set the apps version number. -{ - 'variables': { - 'tested_apk_obfuscated_jar_path%': '/', - 'tested_apk_dex_path%': '/', - 'additional_input_paths': [], - 'create_density_splits%': 0, - 'language_splits': [], - 'input_jars_paths': [], - 'library_dexed_jars_paths': [], - 'additional_src_dirs': [], - 'generated_src_dirs': [], - 'app_manifest_version_name%': '<(android_app_version_name)', - 'app_manifest_version_code%': '<(android_app_version_code)', - # aapt generates this proguard.txt. - 'generated_proguard_file': '<(intermediate_dir)/proguard.txt', - 'proguard_enabled%': 'false', - 'proguard_flags_paths': ['<(generated_proguard_file)'], - 'jar_name': 'chromium_apk_<(_target_name).jar', - 'resource_dir%':'<(DEPTH)/build/android/ant/empty/res', - 'R_package%':'', - 'include_all_resources%': 0, - 'additional_R_text_files': [], - 'dependencies_res_zip_paths': [], - 'additional_res_packages': [], - 'additional_bundled_libs%': [], - 'is_test_apk%': 0, - # Allow icu data, v8 snapshots, and pak files to be loaded directly from the .apk. - # Note: These are actually suffix matches, not necessarily extensions. - 'extensions_to_not_compress%': '.dat,.bin,.pak', - 'resource_input_paths': [], - 'intermediate_dir': '<(PRODUCT_DIR)/<(_target_name)', - 'asset_location%': '<(intermediate_dir)/assets', - 'codegen_stamp': '<(intermediate_dir)/codegen.stamp', - 'package_input_paths': [], - 'ordered_libraries_file': '<(intermediate_dir)/native_libraries.json', - 'additional_ordered_libraries_file': '<(intermediate_dir)/additional_native_libraries.json', - 'native_libraries_template': '<(DEPTH)/base/android/java/templates/NativeLibraries.template', - 'native_libraries_java_dir': '<(intermediate_dir)/native_libraries_java/', - 'native_libraries_java_file': '<(native_libraries_java_dir)/NativeLibraries.java', - 'native_libraries_java_stamp': '<(intermediate_dir)/native_libraries_java.stamp', - 'native_libraries_template_data_dir': '<(intermediate_dir)/native_libraries/', - 'native_libraries_template_data_file': '<(native_libraries_template_data_dir)/native_libraries_array.h', - 'native_libraries_template_version_file': '<(native_libraries_template_data_dir)/native_libraries_version.h', - 'compile_stamp': '<(intermediate_dir)/compile.stamp', - 'lint_stamp': '<(intermediate_dir)/lint.stamp', - 'lint_result': '<(intermediate_dir)/lint_result.xml', - 'lint_config': '<(intermediate_dir)/lint_config.xml', - 'never_lint%': 0, - 'findbugs_stamp': '<(intermediate_dir)/findbugs.stamp', - 'run_findbugs%': 0, - 'java_in_dir_suffix%': '/src', - 'instr_stamp': '<(intermediate_dir)/instr.stamp', - 'jar_stamp': '<(intermediate_dir)/jar.stamp', - 'obfuscate_stamp': '<(intermediate_dir)/obfuscate.stamp', - 'pack_relocations_stamp': '<(intermediate_dir)/pack_relocations.stamp', - 'strip_stamp': '<(intermediate_dir)/strip.stamp', - 'stripped_libraries_dir': '<(intermediate_dir)/stripped_libraries', - 'strip_additional_stamp': '<(intermediate_dir)/strip_additional.stamp', - 'version_stamp': '<(intermediate_dir)/version.stamp', - 'javac_includes': [], - 'jar_excluded_classes': [], - 'javac_jar_path': '<(intermediate_dir)/<(_target_name).javac.jar', - 'jar_path': '<(PRODUCT_DIR)/lib.java/<(jar_name)', - 'obfuscated_jar_path': '<(intermediate_dir)/obfuscated.jar', - 'test_jar_path': '<(PRODUCT_DIR)/test.lib.java/<(apk_name).jar', - 'dex_path': '<(intermediate_dir)/classes.dex', - 'emma_device_jar': '<(android_sdk_root)/tools/lib/emma_device.jar', - 'android_manifest_path%': '<(java_in_dir)/AndroidManifest.xml', - 'split_android_manifest_path': '<(intermediate_dir)/split-manifests/<(android_app_abi)/AndroidManifest.xml', - 'push_stamp': '<(intermediate_dir)/push.stamp', - 'link_stamp': '<(intermediate_dir)/link.stamp', - 'resource_zip_path': '<(intermediate_dir)/<(_target_name).resources.zip', - 'shared_resources%': 0, - 'final_apk_path%': '<(PRODUCT_DIR)/apks/<(apk_name).apk', - 'final_apk_path_no_extension%': '<(PRODUCT_DIR)/apks/<(apk_name)', - 'final_abi_split_apk_path%': '<(PRODUCT_DIR)/apks/<(apk_name)-abi-<(android_app_abi).apk', - 'incomplete_apk_path': '<(intermediate_dir)/<(apk_name)-incomplete.apk', - 'apk_install_record': '<(intermediate_dir)/apk_install.record.stamp', - 'device_intermediate_dir': '/data/data/org.chromium.gyp_managed_install/<(_target_name)/<(CONFIGURATION_NAME)', - 'symlink_script_host_path': '<(intermediate_dir)/create_symlinks.sh', - 'symlink_script_device_path': '<(device_intermediate_dir)/create_symlinks.sh', - 'create_standalone_apk%': 1, - 'res_v14_skip%': 0, - 'variables': { - 'variables': { - 'native_lib_target%': '', - 'native_lib_version_name%': '', - 'use_chromium_linker%' : 0, - 'use_relocation_packer%' : 0, - 'enable_chromium_linker_tests%': 0, - 'is_test_apk%': 0, - 'unsigned_apk_path': '<(intermediate_dir)/<(apk_name)-unsigned.apk', - 'unsigned_abi_split_apk_path': '<(intermediate_dir)/<(apk_name)-abi-<(android_app_abi)-unsigned.apk', - 'create_abi_split%': 0, - }, - 'unsigned_apk_path': '<(unsigned_apk_path)', - 'unsigned_abi_split_apk_path': '<(unsigned_abi_split_apk_path)', - 'create_abi_split%': '<(create_abi_split)', - 'conditions': [ - ['gyp_managed_install == 1 and native_lib_target != ""', { - 'conditions': [ - ['create_abi_split == 0', { - 'unsigned_standalone_apk_path': '<(intermediate_dir)/<(apk_name)-standalone-unsigned.apk', - }, { - 'unsigned_standalone_apk_path': '<(intermediate_dir)/<(apk_name)-abi-<(android_app_abi)-standalone-unsigned.apk', - }], - ], - }, { - 'unsigned_standalone_apk_path': '<(unsigned_apk_path)', - }], - ['gyp_managed_install == 1', { - 'apk_package_native_libs_dir': '<(intermediate_dir)/libs.managed', - }, { - 'apk_package_native_libs_dir': '<(intermediate_dir)/libs', - }], - ['is_test_apk == 0 and emma_coverage != 0', { - 'emma_instrument%': 1, - },{ - 'emma_instrument%': 0, - }], - # When using abi splits, the abi split is modified by - # gyp_managed_install rather than the main .apk - ['create_abi_split == 1', { - 'managed_input_apk_path': '<(unsigned_abi_split_apk_path)', - }, { - 'managed_input_apk_path': '<(unsigned_apk_path)', - }], - ], - }, - 'native_lib_target%': '', - 'native_lib_version_name%': '', - 'use_chromium_linker%' : 0, - 'load_library_from_zip%' : 0, - 'use_relocation_packer%' : 0, - 'enable_chromium_linker_tests%': 0, - 'emma_instrument%': '<(emma_instrument)', - 'apk_package_native_libs_dir': '<(apk_package_native_libs_dir)', - 'unsigned_standalone_apk_path': '<(unsigned_standalone_apk_path)', - 'unsigned_apk_path': '<(unsigned_apk_path)', - 'unsigned_abi_split_apk_path': '<(unsigned_abi_split_apk_path)', - 'create_abi_split%': '<(create_abi_split)', - 'managed_input_apk_path': '<(managed_input_apk_path)', - 'libchromium_android_linker': 'libchromium_android_linker.>(android_product_extension)', - 'extra_native_libs': [], - 'native_lib_placeholder_stamp': '<(apk_package_native_libs_dir)/<(android_app_abi)/native_lib_placeholder.stamp', - 'native_lib_placeholders': [], - 'main_apk_name': '<(apk_name)', - 'enable_errorprone%': '0', - 'errorprone_exe_path': '<(PRODUCT_DIR)/bin.java/chromium_errorprone', - }, - # Pass the jar path to the apk's "fake" jar target. This would be better as - # direct_dependent_settings, but a variable set by a direct_dependent_settings - # cannot be lifted in a dependent to all_dependent_settings. - 'all_dependent_settings': { - 'conditions': [ - ['proguard_enabled == "true"', { - 'variables': { - 'proguard_enabled': 'true', - } - }], - ], - 'variables': { - 'apk_output_jar_path': '<(jar_path)', - 'tested_apk_obfuscated_jar_path': '<(obfuscated_jar_path)', - 'tested_apk_dex_path': '<(dex_path)', - }, - }, - 'conditions': [ - ['resource_dir!=""', { - 'variables': { - 'resource_input_paths': [ '(android_product_extension)', - '<@(chromium_linker_path)' - ], - 'package_input_paths': [ - '<(apk_package_native_libs_dir)/<(android_app_abi)/gdbserver', - ], - }, - 'copies': [ - { - # gdbserver is always copied into the APK's native libs dir. The ant - # build scripts (apkbuilder task) will only include it in a debug - # build. - 'destination': '<(apk_package_native_libs_dir)/<(android_app_abi)', - 'files': [ - '<(android_gdbserver)', - ], - }, - ], - 'actions': [ - { - 'variables': { - 'input_libraries': [ - '<@(native_libs_paths)', - '<@(extra_native_libs)', - ], - }, - 'includes': ['../build/android/write_ordered_libraries.gypi'], - }, - { - 'action_name': 'native_libraries_<(_target_name)', - 'variables': { - 'conditions': [ - ['use_chromium_linker == 1', { - 'variables': { - 'linker_gcc_preprocess_defines': [ - '--defines', 'ENABLE_CHROMIUM_LINKER', - ], - } - }, { - 'variables': { - 'linker_gcc_preprocess_defines': [], - }, - }], - ['load_library_from_zip == 1', { - 'variables': { - 'linker_load_from_zip_file_preprocess_defines': [ - '--defines', 'ENABLE_CHROMIUM_LINKER_LIBRARY_IN_ZIP_FILE', - ], - } - }, { - 'variables': { - 'linker_load_from_zip_file_preprocess_defines': [], - }, - }], - ['enable_chromium_linker_tests == 1', { - 'variables': { - 'linker_tests_gcc_preprocess_defines': [ - '--defines', 'ENABLE_CHROMIUM_LINKER_TESTS', - ], - } - }, { - 'variables': { - 'linker_tests_gcc_preprocess_defines': [], - }, - }], - ], - 'gcc_preprocess_defines': [ - '<@(linker_load_from_zip_file_preprocess_defines)', - '<@(linker_gcc_preprocess_defines)', - '<@(linker_tests_gcc_preprocess_defines)', - ], - }, - 'message': 'Creating NativeLibraries.java for <(_target_name)', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/gcc_preprocess.py', - '<(ordered_libraries_file)', - '<(native_libraries_template)', - ], - 'outputs': [ - '<(native_libraries_java_stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/gcc_preprocess.py', - '--include-path=', - '--output=<(native_libraries_java_file)', - '--template=<(native_libraries_template)', - '--stamp=<(native_libraries_java_stamp)', - '--defines', 'NATIVE_LIBRARIES_LIST=@FileArg(<(ordered_libraries_file):java_libraries_list)', - '--defines', 'NATIVE_LIBRARIES_VERSION_NUMBER="<(native_lib_version_name)"', - '<@(gcc_preprocess_defines)', - ], - }, - { - 'action_name': 'strip_native_libraries', - 'variables': { - 'ordered_libraries_file%': '<(ordered_libraries_file)', - 'stripped_libraries_dir%': '<(stripped_libraries_dir)', - 'input_paths': [ - '<@(native_libs_paths)', - '<@(extra_native_libs)', - ], - 'stamp': '<(strip_stamp)' - }, - 'includes': ['../build/android/strip_native_libraries.gypi'], - }, - { - 'action_name': 'insert_chromium_version', - 'variables': { - 'ordered_libraries_file%': '<(ordered_libraries_file)', - 'stripped_libraries_dir%': '<(stripped_libraries_dir)', - 'version_string': '<(native_lib_version_name)', - 'input_paths': [ - '<(strip_stamp)', - ], - 'stamp': '<(version_stamp)' - }, - 'includes': ['../build/android/insert_chromium_version.gypi'], - }, - { - 'action_name': 'pack_relocations', - 'variables': { - 'conditions': [ - ['use_chromium_linker == 1 and use_relocation_packer == 1 and profiling != 1', { - 'enable_packing': 1, - }, { - 'enable_packing': 0, - }], - ], - 'exclude_packing_list': [ - '<(libchromium_android_linker)', - ], - 'ordered_libraries_file%': '<(ordered_libraries_file)', - 'stripped_libraries_dir%': '<(stripped_libraries_dir)', - 'packed_libraries_dir': '<(libraries_source_dir)', - 'input_paths': [ - '<(version_stamp)' - ], - 'stamp': '<(pack_relocations_stamp)', - }, - 'includes': ['../build/android/pack_relocations.gypi'], - }, - { - 'variables': { - 'input_libraries': [ - '<@(additional_bundled_libs)', - ], - 'ordered_libraries_file': '<(additional_ordered_libraries_file)', - 'subtarget': '_additional_libraries', - }, - 'includes': ['../build/android/write_ordered_libraries.gypi'], - }, - { - 'action_name': 'strip_additional_libraries', - 'variables': { - 'ordered_libraries_file': '<(additional_ordered_libraries_file)', - 'stripped_libraries_dir': '<(libraries_source_dir)', - 'input_paths': [ - '<@(additional_bundled_libs)', - '<(strip_stamp)', - ], - 'stamp': '<(strip_additional_stamp)' - }, - 'includes': ['../build/android/strip_native_libraries.gypi'], - }, - { - 'action_name': 'Create native lib placeholder files for previous releases', - 'variables': { - 'placeholders': ['<@(native_lib_placeholders)'], - 'conditions': [ - ['gyp_managed_install == 1', { - # This "library" just needs to be put in the .apk. It is not loaded - # at runtime. - 'placeholders': ['libfix.crbug.384638.so'], - }] - ], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/create_placeholder_files.py', - ], - 'outputs': [ - '<(native_lib_placeholder_stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/create_placeholder_files.py', - '--dest-lib-dir=<(apk_package_native_libs_dir)/<(android_app_abi)/', - '--stamp=<(native_lib_placeholder_stamp)', - '<@(placeholders)', - ], - }, - ], - 'conditions': [ - ['gyp_managed_install == 1', { - 'variables': { - 'libraries_top_dir': '<(intermediate_dir)/lib.stripped', - 'libraries_source_dir': '<(libraries_top_dir)/lib/<(android_app_abi)', - 'device_library_dir': '<(device_intermediate_dir)/lib.stripped', - 'configuration_name': '<(CONFIGURATION_NAME)', - }, - 'dependencies': [ - '<(DEPTH)/build/android/setup.gyp:get_build_device_configurations', - '<(DEPTH)/build/android/pylib/device/commands/commands.gyp:chromium_commands', - ], - 'actions': [ - { - 'includes': ['../build/android/push_libraries.gypi'], - }, - { - 'action_name': 'create device library symlinks', - 'message': 'Creating links on device for <(_target_name)', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/create_device_library_links.py', - '<(apk_install_record)', - '<(build_device_config_path)', - '<(ordered_libraries_file)', - ], - 'outputs': [ - '<(link_stamp)' - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/create_device_library_links.py', - '--build-device-configuration=<(build_device_config_path)', - '--libraries=@FileArg(<(ordered_libraries_file):libraries)', - '--script-host-path=<(symlink_script_host_path)', - '--script-device-path=<(symlink_script_device_path)', - '--target-dir=<(device_library_dir)', - '--apk=<(incomplete_apk_path)', - '--stamp=<(link_stamp)', - '--configuration-name=<(CONFIGURATION_NAME)', - ], - }, - ], - 'conditions': [ - ['create_standalone_apk == 1', { - 'actions': [ - { - 'action_name': 'create standalone APK', - 'variables': { - 'inputs': [ - '<(ordered_libraries_file)', - '<(strip_additional_stamp)', - '<(pack_relocations_stamp)', - ], - 'output_apk_path': '<(unsigned_standalone_apk_path)', - 'libraries_top_dir%': '<(libraries_top_dir)', - 'input_apk_path': '<(managed_input_apk_path)', - }, - 'includes': [ 'android/create_standalone_apk_action.gypi' ], - }, - ], - }], - ], - }, { - # gyp_managed_install != 1 - 'variables': { - 'libraries_source_dir': '<(apk_package_native_libs_dir)/<(android_app_abi)', - 'package_input_paths': [ - '<(strip_additional_stamp)', - '<(pack_relocations_stamp)', - ], - }, - }], - ], - }], # native_lib_target != '' - ['gyp_managed_install == 0 or create_standalone_apk == 1 or create_abi_split == 1', { - 'dependencies': [ - '<(DEPTH)/build/android/rezip.gyp:rezip_apk_jar', - ], - }], - ['create_abi_split == 1 or gyp_managed_install == 0 or create_standalone_apk == 1', { - 'actions': [ - { - 'action_name': 'finalize_base', - 'variables': { - 'output_apk_path': '<(final_apk_path)', - 'conditions': [ - ['create_abi_split == 0', { - 'input_apk_path': '<(unsigned_standalone_apk_path)', - }, { - 'input_apk_path': '<(unsigned_apk_path)', - 'load_library_from_zip': 0, - }] - ], - }, - 'includes': [ 'android/finalize_apk_action.gypi'] - }, - ], - }], - ['create_abi_split == 1', { - 'actions': [ - { - 'action_name': 'generate_split_manifest_<(_target_name)', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/generate_split_manifest.py', - '<(android_manifest_path)', - ], - 'outputs': [ - '<(split_android_manifest_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/generate_split_manifest.py', - '--main-manifest', '<(android_manifest_path)', - '--out-manifest', '<(split_android_manifest_path)', - '--split', 'abi_<(android_app_abi)', - ], - }, - { - 'variables': { - 'apk_name': '<(main_apk_name)-abi-<(android_app_abi)', - 'asset_location': '', - 'android_manifest_path': '<(split_android_manifest_path)', - 'create_density_splits': 0, - 'language_splits=': [], - }, - 'includes': [ 'android/package_resources_action.gypi' ], - }, - { - 'variables': { - 'apk_name': '<(main_apk_name)-abi-<(android_app_abi)', - 'apk_path': '<(unsigned_abi_split_apk_path)', - 'has_code': 0, - 'native_libs_dir': '<(apk_package_native_libs_dir)', - 'extra_inputs': ['<(native_lib_placeholder_stamp)'], - }, - 'includes': ['android/apkbuilder_action.gypi'], - }, - ], - }], - ['create_abi_split == 1 and (gyp_managed_install == 0 or create_standalone_apk == 1)', { - 'actions': [ - { - 'action_name': 'finalize_split', - 'variables': { - 'output_apk_path': '<(final_abi_split_apk_path)', - 'conditions': [ - ['gyp_managed_install == 1', { - 'input_apk_path': '<(unsigned_standalone_apk_path)', - }, { - 'input_apk_path': '<(unsigned_abi_split_apk_path)', - }], - ], - }, - 'includes': [ 'android/finalize_apk_action.gypi'] - }, - ], - }], - ['gyp_managed_install == 1', { - 'actions': [ - { - 'action_name': 'finalize incomplete apk', - 'variables': { - 'load_library_from_zip': 0, - 'input_apk_path': '<(managed_input_apk_path)', - 'output_apk_path': '<(incomplete_apk_path)', - }, - 'includes': [ 'android/finalize_apk_action.gypi'] - }, - { - 'action_name': 'apk_install_<(_target_name)', - 'message': 'Installing <(apk_name).apk', - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/apk_install.py', - '<(build_device_config_path)', - '<(incomplete_apk_path)', - ], - 'outputs': [ - '<(apk_install_record)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/apk_install.py', - '--build-device-configuration=<(build_device_config_path)', - '--install-record=<(apk_install_record)', - '--configuration-name=<(CONFIGURATION_NAME)', - '--android-sdk-tools', '<(android_sdk_tools)', - ], - 'conditions': [ - ['create_abi_split == 1', { - 'inputs': [ - '<(final_apk_path)', - ], - 'action': [ - '--apk-path=<(final_apk_path)', - '--split-apk-path=<(incomplete_apk_path)', - ], - }, { - 'action': [ - '--apk-path=<(incomplete_apk_path)', - ], - }], - ['create_density_splits == 1', { - 'inputs': [ - '<(final_apk_path_no_extension)-density-hdpi.apk', - '<(final_apk_path_no_extension)-density-xhdpi.apk', - '<(final_apk_path_no_extension)-density-xxhdpi.apk', - '<(final_apk_path_no_extension)-density-xxxhdpi.apk', - '<(final_apk_path_no_extension)-density-tvdpi.apk', - ], - 'action': [ - '--split-apk-path=<(final_apk_path_no_extension)-density-hdpi.apk', - '--split-apk-path=<(final_apk_path_no_extension)-density-xhdpi.apk', - '--split-apk-path=<(final_apk_path_no_extension)-density-xxhdpi.apk', - '--split-apk-path=<(final_apk_path_no_extension)-density-xxxhdpi.apk', - '--split-apk-path=<(final_apk_path_no_extension)-density-tvdpi.apk', - ], - }], - ['language_splits != []', { - 'inputs': [ - "@(input_jars_paths)', - '<(jar_path)', - '<(compile_stamp)', - ], - 'outputs': [ - '<(findbugs_stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/findbugs_diff.py', - '--auxclasspath-gyp', '>(input_jars_paths)', - '--stamp', '<(findbugs_stamp)', - '<(jar_path)', - ], - }, - ], - }, - ] - ], - 'dependencies': [ - '<(DEPTH)/tools/android/md5sum/md5sum.gyp:md5sum', - ], - 'actions': [ - { - 'action_name': 'process_resources', - 'message': 'processing resources for <(_target_name)', - 'variables': { - # Write the inputs list to a file, so that its mtime is updated when - # the list of inputs changes. - 'inputs_list_file': '>|(apk_codegen.<(_target_name).gypcmd >@(additional_input_paths) >@(resource_input_paths))', - 'process_resources_options': [], - 'conditions': [ - ['is_test_apk == 1', { - 'dependencies_res_zip_paths=': [], - 'additional_res_packages=': [], - }], - ['res_v14_skip == 1', { - 'process_resources_options+': ['--v14-skip'] - }], - ['shared_resources == 1', { - 'process_resources_options+': ['--shared-resources'] - }], - ['R_package != ""', { - 'process_resources_options+': ['--custom-package', '<(R_package)'] - }], - ['include_all_resources == 1', { - 'process_resources_options+': ['--include-all-resources'] - }] - ], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/process_resources.py', - '<(android_manifest_path)', - '>@(additional_input_paths)', - '>@(resource_input_paths)', - '>@(dependencies_res_zip_paths)', - '>(inputs_list_file)', - ], - 'outputs': [ - '<(resource_zip_path)', - '<(generated_proguard_file)', - '<(codegen_stamp)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/process_resources.py', - '--android-sdk', '<(android_sdk)', - '--aapt-path', '<(android_aapt_path)', - - '--android-manifest', '<(android_manifest_path)', - '--dependencies-res-zips', '>(dependencies_res_zip_paths)', - - '--extra-res-packages', '>(additional_res_packages)', - '--extra-r-text-files', '>(additional_R_text_files)', - - '--proguard-file', '<(generated_proguard_file)', - - '--resource-dirs', '<(resource_dir)', - '--resource-zip-out', '<(resource_zip_path)', - - '--R-dir', '<(intermediate_dir)/gen', - - '--stamp', '<(codegen_stamp)', - - '<@(process_resources_options)', - ], - }, - { - 'action_name': 'javac_<(_target_name)', - 'message': 'Compiling java for <(_target_name)', - 'variables': { - 'extra_args': [], - 'extra_inputs': [], - 'gen_src_dirs': [ - '<(intermediate_dir)/gen', - '>@(generated_src_dirs)', - ], - # If there is a separate find for additional_src_dirs, it will find the - # wrong .java files when additional_src_dirs is empty. - # TODO(thakis): Gyp caches >! evaluation by command. Both java.gypi and - # java_apk.gypi evaluate the same command, and at the moment two targets - # set java_in_dir to "java". Add a dummy comment here to make sure - # that the two targets (one uses java.gypi, the other java_apk.gypi) - # get distinct source lists. Medium-term, make targets list all their - # Java files instead of using find. (As is, this will be broken if two - # targets use the same java_in_dir and both use java_apk.gypi or - # both use java.gypi.) - 'java_sources': ['>!@(find >(java_in_dir)>(java_in_dir_suffix) >(additional_src_dirs) -name "*.java" # apk)'], - 'conditions': [ - ['enable_errorprone == 1', { - 'extra_inputs': [ - '<(errorprone_exe_path)', - ], - 'extra_args': [ '--use-errorprone-path=<(errorprone_exe_path)' ], - }], - ], - }, - 'inputs': [ - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/javac.py', - '>@(java_sources)', - '>@(input_jars_paths)', - '<(codegen_stamp)', - '<@(extra_inputs)', - ], - 'conditions': [ - ['native_lib_target != ""', { - 'inputs': [ '<(native_libraries_java_stamp)' ], - }], - ], - 'outputs': [ - '<(compile_stamp)', - '<(javac_jar_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/javac.py', - '--bootclasspath=<(android_sdk_jar)', - '--classpath=>(input_jars_paths) <(android_sdk_jar)', - '--src-gendirs=>(gen_src_dirs)', - '--javac-includes=<(javac_includes)', - '--chromium-code=<(chromium_code)', - '--jar-path=<(javac_jar_path)', - '--jar-excluded-classes=<(jar_excluded_classes)', - '--stamp=<(compile_stamp)', - '<@(extra_args)', - '>@(java_sources)', - ], - }, - { - 'action_name': 'instr_jar_<(_target_name)', - 'message': 'Instrumenting <(_target_name) jar', - 'variables': { - 'input_path': '<(javac_jar_path)', - 'output_path': '<(jar_path)', - 'stamp_path': '<(instr_stamp)', - 'instr_type': 'jar', - }, - 'outputs': [ - '<(instr_stamp)', - '<(jar_path)', - ], - 'inputs': [ - '<(javac_jar_path)', - ], - 'includes': [ 'android/instr_action.gypi' ], - }, - { - 'variables': { - 'src_dirs': [ - '<(java_in_dir)<(java_in_dir_suffix)', - '>@(additional_src_dirs)', - ], - 'lint_jar_path': '<(jar_path)', - 'stamp_path': '<(lint_stamp)', - 'result_path': '<(lint_result)', - 'config_path': '<(lint_config)', - }, - 'outputs': [ - '<(lint_stamp)', - ], - 'includes': [ 'android/lint_action.gypi' ], - }, - { - 'action_name': 'obfuscate_<(_target_name)', - 'message': 'Obfuscating <(_target_name)', - 'variables': { - 'additional_obfuscate_options': [], - 'additional_obfuscate_input_paths': [], - 'proguard_out_dir': '<(intermediate_dir)/proguard', - 'proguard_input_jar_paths': [ - '>@(input_jars_paths)', - '<(jar_path)', - ], - 'target_conditions': [ - ['is_test_apk == 1', { - 'additional_obfuscate_options': [ - '--testapp', - ], - }], - ['is_test_apk == 1 and tested_apk_obfuscated_jar_path != "/"', { - 'additional_obfuscate_options': [ - '--tested-apk-obfuscated-jar-path', '>(tested_apk_obfuscated_jar_path)', - ], - 'additional_obfuscate_input_paths': [ - '>(tested_apk_obfuscated_jar_path).info', - ], - }], - ['proguard_enabled == "true"', { - 'additional_obfuscate_options': [ - '--proguard-enabled', - ], - }], - ], - 'obfuscate_input_jars_paths': [ - '>@(input_jars_paths)', - '<(jar_path)', - ], - }, - 'conditions': [ - ['is_test_apk == 1', { - 'outputs': [ - '<(test_jar_path)', - ], - }], - ], - 'inputs': [ - '<(DEPTH)/build/android/gyp/apk_obfuscate.py', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '>@(proguard_flags_paths)', - '>@(obfuscate_input_jars_paths)', - '>@(additional_obfuscate_input_paths)', - '<(instr_stamp)', - ], - 'outputs': [ - '<(obfuscate_stamp)', - - # In non-Release builds, these paths will all be empty files. - '<(obfuscated_jar_path)', - '<(obfuscated_jar_path).info', - '<(obfuscated_jar_path).dump', - '<(obfuscated_jar_path).seeds', - '<(obfuscated_jar_path).mapping', - '<(obfuscated_jar_path).usage', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/apk_obfuscate.py', - - '--configuration-name', '<(CONFIGURATION_NAME)', - - '--android-sdk', '<(android_sdk)', - '--android-sdk-tools', '<(android_sdk_tools)', - '--android-sdk-jar', '<(android_sdk_jar)', - - '--input-jars-paths=>(proguard_input_jar_paths)', - '--proguard-configs=>(proguard_flags_paths)', - - '--test-jar-path', '<(test_jar_path)', - '--obfuscated-jar-path', '<(obfuscated_jar_path)', - - '--proguard-jar-path', '<(android_sdk_root)/tools/proguard/lib/proguard.jar', - - '--stamp', '<(obfuscate_stamp)', - - '>@(additional_obfuscate_options)', - ], - }, - { - 'action_name': 'dex_<(_target_name)', - 'variables': { - 'dex_input_paths': [ - '>@(library_dexed_jars_paths)', - '<(jar_path)', - ], - 'output_path': '<(dex_path)', - 'proguard_enabled_input_path': '<(obfuscated_jar_path)', - }, - 'target_conditions': [ - ['emma_instrument != 0', { - 'variables': { - 'dex_no_locals': 1, - 'dex_input_paths': [ - '<(emma_device_jar)' - ], - }, - }], - ['is_test_apk == 1 and tested_apk_dex_path != "/"', { - 'variables': { - 'dex_additional_options': [ - '--excluded-paths', '@FileArg(>(tested_apk_dex_path).inputs)' - ], - }, - 'inputs': [ - '>(tested_apk_dex_path).inputs', - ], - }], - ['proguard_enabled == "true"', { - 'inputs': [ '<(obfuscate_stamp)' ] - }, { - 'inputs': [ '<(instr_stamp)' ] - }], - ], - 'includes': [ 'android/dex_action.gypi' ], - }, - { - 'variables': { - 'extra_inputs': ['<(codegen_stamp)'], - 'resource_zips': [ - '<(resource_zip_path)', - ], - 'conditions': [ - ['is_test_apk == 0', { - 'resource_zips': [ - '>@(dependencies_res_zip_paths)', - ], - }], - ], - }, - 'includes': [ 'android/package_resources_action.gypi' ], - }, - { - 'variables': { - 'apk_path': '<(unsigned_apk_path)', - 'conditions': [ - ['native_lib_target != ""', { - 'extra_inputs': ['<(native_lib_placeholder_stamp)'], - }], - ['create_abi_split == 0', { - 'native_libs_dir': '<(apk_package_native_libs_dir)', - }, { - 'native_libs_dir': '<(DEPTH)/build/android/ant/empty/res', - }], - ], - }, - 'includes': ['android/apkbuilder_action.gypi'], - }, - ], -} diff --git a/build/java_prebuilt.gypi b/build/java_prebuilt.gypi deleted file mode 100644 index 8efc4ef7f4d17..0000000000000 --- a/build/java_prebuilt.gypi +++ /dev/null @@ -1,102 +0,0 @@ -# Copyright (c) 2012 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to package prebuilt Java JARs in a consistent manner. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'my-package_java', -# 'type': 'none', -# 'variables': { -# 'jar_path': 'path/to/your.jar', -# }, -# 'includes': ['path/to/this/gypi/file'], -# } -# -# Required variables: -# jar_path - The path to the prebuilt Java JAR file. - -{ - 'dependencies': [ - '<(DEPTH)/build/android/setup.gyp:build_output_dirs' - ], - 'variables': { - 'dex_path': '<(PRODUCT_DIR)/lib.java/<(_target_name).dex.jar', - 'intermediate_dir': '<(SHARED_INTERMEDIATE_DIR)/<(_target_name)', - 'android_jar': '<(android_sdk)/android.jar', - 'input_jars_paths': [ '<(android_jar)' ], - 'neverlink%': 0, - 'proguard_config%': '', - 'proguard_preprocess%': '0', - 'variables': { - 'variables': { - 'proguard_preprocess%': 0, - }, - 'conditions': [ - ['proguard_preprocess == 1', { - 'dex_input_jar_path': '<(intermediate_dir)/<(_target_name).pre.jar' - }, { - 'dex_input_jar_path': '<(jar_path)' - }], - ], - }, - 'dex_input_jar_path': '<(dex_input_jar_path)', - }, - 'all_dependent_settings': { - 'variables': { - 'input_jars_paths': ['<(dex_input_jar_path)'], - 'conditions': [ - ['neverlink == 1', { - 'library_dexed_jars_paths': [], - }, { - 'library_dexed_jars_paths': ['<(dex_path)'], - }], - ], - }, - }, - 'conditions' : [ - ['proguard_preprocess == 1', { - 'actions': [ - { - 'action_name': 'proguard_<(_target_name)', - 'message': 'Proguard preprocessing <(_target_name) jar', - 'inputs': [ - '<(android_sdk_root)/tools/proguard/lib/proguard.jar', - '<(DEPTH)/build/android/gyp/util/build_utils.py', - '<(DEPTH)/build/android/gyp/proguard.py', - '<(jar_path)', - '<(proguard_config)', - ], - 'outputs': [ - '<(dex_input_jar_path)', - ], - 'action': [ - 'python', '<(DEPTH)/build/android/gyp/proguard.py', - '--proguard-path=<(android_sdk_root)/tools/proguard/lib/proguard.jar', - '--input-path=<(jar_path)', - '--output-path=<(dex_input_jar_path)', - '--proguard-config=<(proguard_config)', - '--classpath=>(input_jars_paths)', - ] - }, - ], - }], - ['neverlink == 0', { - 'actions': [ - { - 'action_name': 'dex_<(_target_name)', - 'message': 'Dexing <(_target_name) jar', - 'variables': { - 'dex_input_paths': [ - '<(dex_input_jar_path)', - ], - 'output_path': '<(dex_path)', - }, - 'includes': [ 'android/dex_action.gypi' ], - }, - ], - }], - ], -} diff --git a/build/java_strings_grd.gypi b/build/java_strings_grd.gypi deleted file mode 100644 index 7534be5beeaf2..0000000000000 --- a/build/java_strings_grd.gypi +++ /dev/null @@ -1,62 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to provide a rule -# to generate localized strings.xml from a grd file. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'my-package_strings_grd', -# 'type': 'none', -# 'variables': { -# 'grd_file': 'path/to/grd/file', -# }, -# 'includes': ['path/to/this/gypi/file'], -# } -# -# Required variables: -# grd_file - The path to the grd file to use. -{ - 'variables': { - 'res_grit_dir': '<(INTERMEDIATE_DIR)/<(_target_name)/res_grit', - 'grit_grd_file': '<(grd_file)', - 'resource_zip_path': '<(PRODUCT_DIR)/res.java/<(_target_name).zip', - 'grit_additional_defines': ['-E', 'ANDROID_JAVA_TAGGED_ONLY=false'], - 'grit_out_dir': '<(res_grit_dir)', - # resource_ids is unneeded since we don't generate .h headers. - 'grit_resource_ids': '', - 'grit_outputs': [ - '(java_out_dir), since that -# is the root directory of all the output. -# -# Implementation notes: -# A target_name of foo and proto-specified 'package' java.package.path produces: -# <(PRODUCT_DIR)/java_proto/foo/{java/package/path/}{Foo,Bar}.java -# where Foo and Bar are taken from 'java_outer_classname' of the protos. -# -# How the .jar-file is created is different than how protoc is used for other -# targets, and as such, this lives in its own file. - -{ - 'variables': { - 'protoc': '<(PRODUCT_DIR)/<(EXECUTABLE_PREFIX)android_protoc<(EXECUTABLE_SUFFIX)', - 'java_out_dir': '<(PRODUCT_DIR)/java_proto/<(_target_name)/src', - 'proto_in_dir%': '.', - 'stamp_file': '<(java_out_dir).stamp', - 'script': '<(DEPTH)/build/protoc_java.py', - - # The rest of the variables here are for the java.gypi include. - 'java_in_dir': '<(DEPTH)/build/android/empty', - 'generated_src_dirs': ['<(java_out_dir)'], - # Adding the |stamp_file| to |additional_input_paths| makes the actions in - # the include of java.gypi depend on the genproto_java action. - 'additional_input_paths': ['<(stamp_file)'], - 'run_findbugs': 0, - }, - 'actions': [ - { - 'action_name': 'genproto_java', - 'inputs': [ - '<(script)', - '<(protoc)', - '<@(_sources)', - ], - # We do not know the names of the generated files, so we use a stamp. - 'outputs': [ - '<(stamp_file)', - ], - 'action': [ - '<(script)', - '--protoc=<(protoc)', - '--proto-path=<(proto_in_dir)', - '--java-out-dir=<(java_out_dir)', - '--stamp=<(stamp_file)', - '<@(_sources)', - ], - 'message': 'Generating Java code from protobuf files in <(proto_in_dir)', - }, - ], - 'dependencies': [ - '<(DEPTH)/third_party/android_protobuf/android_protobuf.gyp:android_protoc#host', - '<(DEPTH)/third_party/android_protobuf/android_protobuf.gyp:protobuf_nano_javalib', - ], - 'includes': [ 'java.gypi' ], -} diff --git a/build/release.gypi b/build/release.gypi deleted file mode 100644 index 9b8b11d20f3a4..0000000000000 --- a/build/release.gypi +++ /dev/null @@ -1,29 +0,0 @@ -{ - 'conditions': [ - # Handle build types. - ['buildtype=="Dev"', { - 'includes': ['internal/release_impl.gypi'], - }], - ['buildtype=="Dev" and incremental_chrome_dll==1', { - 'msvs_settings': { - 'VCLinkerTool': { - # Enable incremental linking and disable conflicting link options: - # http://msdn.microsoft.com/en-us/library/4khtbfyf.aspx - 'LinkIncremental': '2', - 'OptimizeReferences': '1', - 'EnableCOMDATFolding': '1', - 'Profile': 'false', - }, - }, - }], - ['buildtype=="Official"', { - 'includes': ['internal/release_impl_official.gypi'], - }], - # TODO(bradnelson): may also need: - # checksenabled - # coverage - # dom_stats - # pgo_instrument - # pgo_optimize - ], -} diff --git a/build/repack_action.gypi b/build/repack_action.gypi deleted file mode 100644 index 04b982a38bdf2..0000000000000 --- a/build/repack_action.gypi +++ /dev/null @@ -1,31 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into an action to invoke grit repack in a -# consistent manner. To use this the following variables need to be -# defined: -# pak_inputs: list: paths of pak files that need to be combined. -# pak_output: string: the output pak file path. - -{ - # GYP version: //tools/grit/repack.gni - 'variables': { - 'repack_path': '<(DEPTH)/tools/grit/grit/format/repack.py', - 'repack_options%': [], - }, - 'inputs': [ - '<(repack_path)', - '<@(pak_inputs)', - ], - 'outputs': [ - '<(pak_output)' - ], - 'action': [ - 'python', - '<(repack_path)', - '<@(repack_options)', - '<(pak_output)', - '<@(pak_inputs)', - ], -} diff --git a/build/set_clang_warning_flags.gypi b/build/set_clang_warning_flags.gypi deleted file mode 100644 index f6d7aea700d8d..0000000000000 --- a/build/set_clang_warning_flags.gypi +++ /dev/null @@ -1,58 +0,0 @@ -# Copyright (c) 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included to set clang-specific compiler flags. -# To use this the following variable can be defined: -# clang_warning_flags: list: Compiler flags to pass to clang. -# clang_warning_flags_unset: list: Compiler flags to not pass to clang. -# -# Only use this in third-party code. In chromium_code, fix your code to not -# warn instead! -# -# Note that the gypi file is included in target_defaults, so it does not need -# to be explicitly included. -# -# Warning flags set by this will be used on all platforms. If you want to set -# warning flags on only some platforms, you have to do so manually. -# -# To use this, create a gyp target with the following form: -# { -# 'target_name': 'my_target', -# 'variables': { -# 'clang_warning_flags': ['-Wno-awesome-warning'], -# 'clang_warning_flags_unset': ['-Wpreviously-set-flag'], -# } -# } - -{ - 'variables': { - 'clang_warning_flags_unset%': [], # Provide a default value. - }, - 'conditions': [ - ['clang==1', { - # This uses >@ instead of @< to also see clang_warning_flags set in - # targets directly, not just the clang_warning_flags in target_defaults. - 'cflags': [ '>@(clang_warning_flags)' ], - 'cflags!': [ '>@(clang_warning_flags_unset)' ], - 'xcode_settings': { - 'WARNING_CFLAGS': ['>@(clang_warning_flags)'], - 'WARNING_CFLAGS!': ['>@(clang_warning_flags_unset)'], - }, - 'msvs_settings': { - 'VCCLCompilerTool': { - 'AdditionalOptions': [ '>@(clang_warning_flags)' ], - 'AdditionalOptions!': [ '>@(clang_warning_flags_unset)' ], - }, - }, - }], - ['clang==0 and host_clang==1', { - 'target_conditions': [ - ['_toolset=="host"', { - 'cflags': [ '>@(clang_warning_flags)' ], - 'cflags!': [ '>@(clang_warning_flags_unset)' ], - }], - ], - }], - ], -} diff --git a/build/shim_headers.gypi b/build/shim_headers.gypi deleted file mode 100644 index 56d8d3a719614..0000000000000 --- a/build/shim_headers.gypi +++ /dev/null @@ -1,60 +0,0 @@ -# Copyright (c) 2012 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -# This file is meant to be included into a target to handle shim headers -# in a consistent manner. To use this the following variables need to be -# defined: -# headers_root_path: string: path to directory containing headers -# header_filenames: list: list of header file names - -{ - 'variables': { - 'shim_headers_path': '<(SHARED_INTERMEDIATE_DIR)/shim_headers/<(_target_name)/<(_toolset)', - 'shim_generator_additional_args%': [], - }, - 'include_dirs++': [ - '<(shim_headers_path)', - ], - 'all_dependent_settings': { - # Repeating this with different numbers of plusses is unfortunately required - # to make sure that even if this include is inside nested conditions/etc, it - # still gets inserted at the beginning of the include_dirs list. See - # http://crbug.com/263818 for details. - 'include_dirs+++': [ - '<(shim_headers_path)', - ], - 'include_dirs++++': [ - '<(shim_headers_path)', - ], - 'include_dirs+++++': [ - '<(shim_headers_path)', - ], - }, - 'actions': [ - { - 'variables': { - 'generator_path': '<(DEPTH)/tools/generate_shim_headers/generate_shim_headers.py', - 'generator_args': [ - '--headers-root', '<(headers_root_path)', - '--output-directory', '<(shim_headers_path)', - '<@(shim_generator_additional_args)', - '<@(header_filenames)', - ], - }, - 'action_name': 'generate_<(_target_name)_shim_headers', - 'inputs': [ - '<(generator_path)', - ], - 'outputs': [ - '@(library_dexed_jars_paths)', - ], - 'output_path': '<(output_dex_path)', - }, - 'includes': [ 'android/dex_action.gypi' ], - }, - ], -} diff --git a/build/util/version.gypi b/build/util/version.gypi deleted file mode 100644 index 327a5c2e5f596..0000000000000 --- a/build/util/version.gypi +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright 2014 The Chromium Authors. All rights reserved. -# Use of this source code is governed by a BSD-style license that can be -# found in the LICENSE file. - -{ - 'variables': { - 'variables': { - 'version_py_path': '<(DEPTH)/build/util/version.py', - 'version_path': '<(DEPTH)/chrome/VERSION', - 'lastchange_path': '<(DEPTH)/build/util/LASTCHANGE', - }, - 'version_py_path': '<(version_py_path)', - 'version_path': '<(version_path)', - 'lastchange_path': '<(lastchange_path)', - 'version_full': - '