Commit 7e894e13 authored by Eugene But's avatar Eugene But Committed by Commit Bot

Remove ios_third_party_material_components_built_as_framework gn flag

False is no longer supported configuration.

Bug: 1017165

Change-Id: I67ec5b56afc2b2363c6013106bf4f4f0123e2114
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2228052Reviewed-by: default avatarSylvain Defresne <sdefresne@chromium.org>
Reviewed-by: default avatarYuwei Huang <yuweih@chromium.org>
Auto-Submit: Eugene But <eugenebut@chromium.org>
Commit-Queue: Eugene But <eugenebut@chromium.org>
Cr-Commit-Position: refs/heads/master@{#775224}
parent 5e94707c
...@@ -10,7 +10,6 @@ import("//ios/build/chrome_build.gni") ...@@ -10,7 +10,6 @@ import("//ios/build/chrome_build.gni")
import("//ios/build/config.gni") import("//ios/build/config.gni")
import("//ios/chrome/features.gni") import("//ios/chrome/features.gni")
import("//ios/public/provider/chrome/browser/build_config.gni") import("//ios/public/provider/chrome/browser/build_config.gni")
import("//ios/third_party/features.gni")
source_set("app") { source_set("app") {
configs += [ "//build/config/compiler:enable_arc" ] configs += [ "//build/config/compiler:enable_arc" ]
...@@ -298,7 +297,6 @@ source_set("main") { ...@@ -298,7 +297,6 @@ source_set("main") {
"//ios/testing/perf:startup", "//ios/testing/perf:startup",
] ]
if (ios_third_party_material_components_built_as_framework) {
if (ios_chrome_links_with_material_components_framework) { if (ios_chrome_links_with_material_components_framework) {
deps += [ deps += [
"//ios/third_party/material_components_ios:material_components_ios+bundle", "//ios/third_party/material_components_ios:material_components_ios+bundle",
...@@ -310,7 +308,6 @@ source_set("main") { ...@@ -310,7 +308,6 @@ source_set("main") {
"//ios/third_party/material_components_ios:material_components_ios+link", "//ios/third_party/material_components_ios:material_components_ios+link",
] ]
} }
}
} }
ios_app_bundle("chrome") { ios_app_bundle("chrome") {
...@@ -369,7 +366,6 @@ ios_app_bundle("chrome") { ...@@ -369,7 +366,6 @@ ios_app_bundle("chrome") {
assert_no_deps = ios_assert_no_deps + ios_chrome_extra_assert_no_deps assert_no_deps = ios_assert_no_deps + ios_chrome_extra_assert_no_deps
if (ios_third_party_material_components_built_as_framework) {
if (ios_chrome_links_with_material_components_framework) { if (ios_chrome_links_with_material_components_framework) {
deps += [ deps += [
"//ios/third_party/material_components_ios:material_components_ios+bundle", "//ios/third_party/material_components_ios:material_components_ios+bundle",
...@@ -381,7 +377,6 @@ ios_app_bundle("chrome") { ...@@ -381,7 +377,6 @@ ios_app_bundle("chrome") {
"//ios/third_party/material_components_ios:material_components_ios+link", "//ios/third_party/material_components_ios:material_components_ios+link",
] ]
} }
}
} }
if (current_toolchain == default_toolchain) { if (current_toolchain == default_toolchain) {
......
...@@ -6,7 +6,6 @@ import("//ios/build/chrome_build.gni") ...@@ -6,7 +6,6 @@ import("//ios/build/chrome_build.gni")
import("//ios/build/config.gni") import("//ios/build/config.gni")
import("//ios/chrome/features.gni") import("//ios/chrome/features.gni")
import("//ios/public/provider/chrome/browser/build_config.gni") import("//ios/public/provider/chrome/browser/build_config.gni")
import("//ios/third_party/features.gni")
import("//testing/test.gni") import("//testing/test.gni")
import("//third_party/protobuf/proto_library.gni") import("//third_party/protobuf/proto_library.gni")
...@@ -131,7 +130,6 @@ source_set("run_all_unittests") { ...@@ -131,7 +130,6 @@ source_set("run_all_unittests") {
"//mojo/core/embedder", "//mojo/core/embedder",
] ]
if (ios_third_party_material_components_built_as_framework) {
if (ios_chrome_links_with_material_components_framework) { if (ios_chrome_links_with_material_components_framework) {
public_deps = [ public_deps = [
"//ios/third_party/material_components_ios:material_components_ios+bundle", "//ios/third_party/material_components_ios:material_components_ios+bundle",
...@@ -143,7 +141,6 @@ source_set("run_all_unittests") { ...@@ -143,7 +141,6 @@ source_set("run_all_unittests") {
"//ios/third_party/material_components_ios:material_components_ios+link", "//ios/third_party/material_components_ios:material_components_ios+link",
] ]
} }
}
} }
test("ios_chrome_perftests") { test("ios_chrome_perftests") {
......
# Copyright 2019 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.
declare_args() {
# Controls whether //ios/third_party/material_components_ios (and its
# dependencies) is build as a framework bundle. This boolean allows
# migrating the internal code to the framework incrementally.
ios_third_party_material_components_built_as_framework = true
}
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
import("//build/config/ios/ios_sdk.gni") import("//build/config/ios/ios_sdk.gni")
import("//build/config/ios/rules.gni") import("//build/config/ios/rules.gni")
import("//build/config/locales.gni") import("//build/config/locales.gni")
import("//ios/third_party/features.gni")
# This variable lists all public headers that are exported by MDC. It is # This variable lists all public headers that are exported by MDC. It is
# there to allow supporting build. It allows not repeating the list if # there to allow supporting build. It allows not repeating the list if
...@@ -709,7 +708,34 @@ _mdc_include_dirs = [ ...@@ -709,7 +708,34 @@ _mdc_include_dirs = [
"src/components/schemes/Typography/src/Scheming", "src/components/schemes/Typography/src/Scheming",
] ]
_mdc_sources = [ config("public_configs") {
visibility = [ ":*" ]
# This is a hack to allow to include the header using the full path but
# still have them function as if they were included using framework style.
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
include_dirs = [ "$root_out_dir/MaterialComponents.framework/Headers" ]
}
config("config") {
visibility = [ ":*" ]
include_dirs = _mdc_include_dirs
}
config("disable_deprecated_errors") {
cflags = [
"-Wno-deprecated",
"-Wno-deprecated-declarations",
]
}
source_set("material_components_ios_public_headers") {
public = _mdc_public_headers
}
target("ios_framework_bundle", "material_components_ios") {
sources = [
# List generated by the following commands: # List generated by the following commands:
# $ cd src/ios/third_party/material_components_ios # $ cd src/ios/third_party/material_components_ios
# $ find src -path 'src/components/*/src/*.[hm]' -a \! -path '*Test*'|\ # $ find src -path 'src/components/*/src/*.[hm]' -a \! -path '*Test*'|\
...@@ -1521,74 +1547,11 @@ _mdc_sources = [ ...@@ -1521,74 +1547,11 @@ _mdc_sources = [
"src/components/schemes/Typography/src/MaterialTypographyScheme.h", "src/components/schemes/Typography/src/MaterialTypographyScheme.h",
"src/components/schemes/Typography/src/Scheming/MDCTypographyScheming.h", "src/components/schemes/Typography/src/Scheming/MDCTypographyScheming.h",
"src/components/schemes/Typography/src/Scheming/MaterialTypographyScheme+Scheming.h", "src/components/schemes/Typography/src/Scheming/MaterialTypographyScheme+Scheming.h",
]
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
if (!ios_third_party_material_components_built_as_framework) {
config("mdc_components_ios_public_headers_config") {
include_dirs = [ "$root_gen_dir/frameworks/material_components_ios" ]
}
copy("mdc_components_ios_public_headers") {
sources = _mdc_public_headers
outputs = [ "$root_gen_dir/frameworks/material_components_ios/MaterialComponents/{{source_file_part}}" ]
public_configs = [ ":mdc_components_ios_public_headers_config" ]
}
} else {
config("public_configs") {
visibility = [ ":*" ]
# This is a hack to allow to include the header using the full path but
# still have them function as if they were included using framework style.
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
include_dirs = [ "$root_out_dir/MaterialComponents.framework/Headers" ]
}
}
config("config") {
visibility = [ ":*" ]
include_dirs = _mdc_include_dirs
}
config("disable_deprecated_errors") {
cflags = [
"-Wno-deprecated",
"-Wno-deprecated-declarations",
] ]
}
# This variable is used to build MDC as either an ios_framework_bundle or a
# source_set if ios_third_party_material_components_built_as_framework is set
# to true/false.
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
if (ios_third_party_material_components_built_as_framework) {
_mdc_target_type = "ios_framework_bundle"
} else {
_mdc_target_type = "source_set"
}
# This target is there to allow code to include framework headers with the
# full path while both framework and source_set compilation mode both need
# to be supported.
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
if (ios_third_party_material_components_built_as_framework) {
source_set("material_components_ios_public_headers") {
public = _mdc_public_headers
}
}
target(_mdc_target_type, "material_components_ios") {
sources = _mdc_sources
if (ios_third_party_material_components_built_as_framework) {
info_plist = "Info.plist" info_plist = "Info.plist"
output_name = "MaterialComponents" output_name = "MaterialComponents"
public_headers = _mdc_public_headers public_headers = _mdc_public_headers
}
frameworks = [ frameworks = [
"CoreGraphics.framework", "CoreGraphics.framework",
...@@ -1607,21 +1570,9 @@ target(_mdc_target_type, "material_components_ios") { ...@@ -1607,21 +1570,9 @@ target(_mdc_target_type, "material_components_ios") {
"//ios/third_party/motion_transitioning_objc", "//ios/third_party/motion_transitioning_objc",
] ]
if (!ios_third_party_material_components_built_as_framework) {
deps += [ ":mdc_components_ios_public_headers" ]
}
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
if (ios_third_party_material_components_built_as_framework) {
public_deps = [ ":material_components_ios_public_headers" ] public_deps = [ ":material_components_ios_public_headers" ]
}
if (ios_third_party_material_components_built_as_framework) {
public_configs = [ ":public_configs" ] public_configs = [ ":public_configs" ]
} else {
public_configs = [ ":config" ]
}
configs -= [ configs -= [
"//build/config/compiler:chromium_code", "//build/config/compiler:chromium_code",
...@@ -1639,18 +1590,6 @@ target(_mdc_target_type, "material_components_ios") { ...@@ -1639,18 +1590,6 @@ target(_mdc_target_type, "material_components_ios") {
] ]
} }
# TODO(crbug.com/1017165): remove once MaterialComponents is always built
# as a framework
if (!ios_third_party_material_components_built_as_framework) {
group("material_components_ios+link") {
public_deps = [ ":material_components_ios" ]
}
group("material_components_ios+bundle") {
public_deps = [ ":material_components_ios" ]
}
}
# Template to declare a bundle_data target to pack localized strings bundle. # Template to declare a bundle_data target to pack localized strings bundle.
# #
# Arguments # Arguments
......
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
# found in the LICENSE file. # found in the LICENSE file.
import("//build/config/ios/rules.gni") import("//build/config/ios/rules.gni")
import("//ios/third_party/features.gni")
declare_args() { declare_args() {
# Authorization service implementation used in ios_web_view_shell. Uses a fake # Authorization service implementation used in ios_web_view_shell. Uses a fake
...@@ -40,7 +39,6 @@ ios_app_bundle("ios_web_view_shell") { ...@@ -40,7 +39,6 @@ ios_app_bundle("ios_web_view_shell") {
] ]
entitlements_path = ios_web_view_shell_entitlements_path entitlements_path = ios_web_view_shell_entitlements_path
if (ios_third_party_material_components_built_as_framework) {
if (ios_web_view_shell_links_with_material_components_framework) { if (ios_web_view_shell_links_with_material_components_framework) {
deps += [ deps += [
"//ios/third_party/material_components_ios:material_components_ios+bundle", "//ios/third_party/material_components_ios:material_components_ios+bundle",
...@@ -52,7 +50,6 @@ ios_app_bundle("ios_web_view_shell") { ...@@ -52,7 +50,6 @@ ios_app_bundle("ios_web_view_shell") {
"//ios/third_party/material_components_ios:material_components_ios+link", "//ios/third_party/material_components_ios:material_components_ios+link",
] ]
} }
}
configs += [ "//build/config/compiler:enable_arc" ] configs += [ "//build/config/compiler:enable_arc" ]
} }
......
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
import("//ios/build/config.gni") import("//ios/build/config.gni")
import("//ios/third_party/earl_grey/ios_eg_test.gni") import("//ios/third_party/earl_grey/ios_eg_test.gni")
import("//ios/third_party/features.gni")
group("all_tests") { group("all_tests") {
testonly = true testonly = true
...@@ -19,19 +18,14 @@ ios_eg_test("ios_web_view_shell_egtests") { ...@@ -19,19 +18,14 @@ ios_eg_test("ios_web_view_shell_egtests") {
deps = [ deps = [
":earl_grey_test_support", ":earl_grey_test_support",
"//ios/testing:http_server_bundle_data", "//ios/testing:http_server_bundle_data",
"//ios/third_party/material_components_ios:material_components_ios+bundle",
"//ios/third_party/material_components_ios:material_components_ios+link",
"//ios/web_view:web_view+link", "//ios/web_view:web_view+link",
"//ios/web_view/shell:shell", "//ios/web_view/shell:shell",
"//ios/web_view/test:test_support", "//ios/web_view/test:test_support",
"//net:test_support", "//net:test_support",
] ]
if (ios_third_party_material_components_built_as_framework) {
deps += [
"//ios/third_party/material_components_ios:material_components_ios+bundle",
"//ios/third_party/material_components_ios:material_components_ios+link",
]
}
configs += [ "//build/config/compiler:enable_arc" ] configs += [ "//build/config/compiler:enable_arc" ]
assert_no_deps = ios_assert_no_deps assert_no_deps = ios_assert_no_deps
......
...@@ -2,7 +2,6 @@ ...@@ -2,7 +2,6 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//ios/third_party/features.gni")
import("//remoting/build/config/remoting_build.gni") import("//remoting/build/config/remoting_build.gni")
import("//remoting/remoting_locales.gni") import("//remoting/remoting_locales.gni")
...@@ -76,6 +75,7 @@ test("ios_remoting_unittests") { ...@@ -76,6 +75,7 @@ test("ios_remoting_unittests") {
deps = [ deps = [
"//base/test:run_all_unittests", "//base/test:run_all_unittests",
"//base/test:test_support", "//base/test:test_support",
"//ios/third_party/material_components_ios:material_components_ios+link",
"//remoting/ios/audio:unit_tests", "//remoting/ios/audio:unit_tests",
"//remoting/ios/facade:unit_tests", "//remoting/ios/facade:unit_tests",
"//remoting/ios/persistence:unit_tests", "//remoting/ios/persistence:unit_tests",
...@@ -85,13 +85,9 @@ test("ios_remoting_unittests") { ...@@ -85,13 +85,9 @@ test("ios_remoting_unittests") {
deps += [ ":unittests_locale_${locale}_bundle_data" ] deps += [ ":unittests_locale_${locale}_bundle_data" ]
} }
if (ios_third_party_material_components_built_as_framework) { bundle_deps = [
deps += [ "//ios/third_party/material_components_ios:material_components_ios+bundle",
"//ios/third_party/material_components_ios:material_components_ios+link",
] ]
bundle_deps = [ "//ios/third_party/material_components_ios:material_components_ios+bundle" ]
}
} }
foreach(locale, remoting_locales_with_underscores) { foreach(locale, remoting_locales_with_underscores) {
......
...@@ -2,7 +2,6 @@ ...@@ -2,7 +2,6 @@
# Use of this source code is governed by a BSD-style license that can be # Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file. # found in the LICENSE file.
import("//ios/third_party/features.gni")
import("//remoting/build/config/remoting_build.gni") import("//remoting/build/config/remoting_build.gni")
import("//remoting/ios/app/remoting_ios_tmpl.gni") import("//remoting/ios/app/remoting_ios_tmpl.gni")
...@@ -145,14 +144,12 @@ ios_remoting_app_tmpl("ios_remoting_app") { ...@@ -145,14 +144,12 @@ ios_remoting_app_tmpl("ios_remoting_app") {
entitlements_path = "resources/Remoting.entitlements" entitlements_path = "resources/Remoting.entitlements"
deps = [ deps = [
":app_source_set", ":app_source_set",
"//ios/third_party/material_components_ios:material_components_ios+link",
"//remoting/ios/app/resources:launchscreen_assets", "//remoting/ios/app/resources:launchscreen_assets",
"//remoting/ios/app/resources:remoting_icons", "//remoting/ios/app/resources:remoting_icons",
] ]
if (ios_third_party_material_components_built_as_framework) { bundle_deps = [
deps += [ "//ios/third_party/material_components_ios:material_components_ios+bundle",
"//ios/third_party/material_components_ios:material_components_ios+link",
] ]
bundle_deps = [ "//ios/third_party/material_components_ios:material_components_ios+bundle" ]
}
} }
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment