Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up configuration.gni for Chrobalt #4395

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions starboard/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,6 @@ if (!is_cobalt) {
]
}

if (has_platform_targets) {
deps += [ "//$starboard_path/platform_targets" ]
}

if (platform_tests_path == "") {
deps += [
":starboard_platform_tests($starboard_toolchain)",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@ install_target_path = "//starboard/android/shared/install_target.gni"
sb_widevine_platform = "android"
platform_tests_path = "//starboard/android/shared:starboard_platform_tests"

cobalt_licenses_platform = "android"

cobalt_platform_dependencies = []

cobalt_font_package = "android_system"

separate_install_targets_for_bundling = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,3 @@ import("//starboard/android/shared/platform_configuration/configuration.gni")

android_abi = "x86"
sabi_path = "//starboard/sabi/x86/sabi-v$sb_api_version.json"

sb_enable_opus_sse = false
1 change: 0 additions & 1 deletion starboard/benchmark/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ target(final_executable_type, "benchmark") {
"//starboard:starboard_group",
"//third_party/google_benchmark",
]
deps = cobalt_platform_dependencies

configs += [ "//starboard/build/config:starboard_implementation" ]
}
4 changes: 0 additions & 4 deletions starboard/build/config/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -190,10 +190,6 @@ config("starboard") {
defines += [ "INTERNAL_BUILD" ]
}

if (sb_enable_lib) {
defines += [ "SB_IS_LIBRARY=1" ]
}

if (sb_is_modular) {
defines += [ "SB_IS_MODULAR=1" ]
}
Expand Down
6 changes: 3 additions & 3 deletions starboard/build/config/BUILDCONFIG.gn
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ if (is_starboard) {
default_compiler_configs += [ "//starboard/build/config:starboard" ]
}

if (is_qa || is_gold || sb_use_no_rtti) {
if (is_qa || is_gold) {
default_compiler_configs += [ "//build/config/compiler:no_rtti" ]
}

Expand All @@ -193,11 +193,11 @@ set_defaults("static_library") {
has_pedantic_warnings = false
}
set_defaults("source_set") {
configs = default_compiler_configs + source_set_configs
configs = default_compiler_configs
has_pedantic_warnings = false
}
set_defaults("loadable_module") {
configs = default_compiler_configs + loadable_module_configs
configs = default_compiler_configs
has_pedantic_warnings = false
}
set_defaults("executable") {
Expand Down
47 changes: 0 additions & 47 deletions starboard/build/config/base_configuration.gni
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,13 @@ if (build_with_separate_cobalt_toolchain) {
}

declare_args() {
# Enables the nasm compiler to be used to compile .asm files.
nasm_exists = false

# Where yasm can be found on the host device.
path_to_nasm = "nasm"

# The Starboard API version of the current build configuration. The default
# value is meant to be overridden by a Starboard ABI file.
sb_api_version = 17

# Enables embedding Cobalt as a shared library within another app. This
# requires a 'lib' starboard implementation for the corresponding platform.
sb_enable_lib = false

# Directory path to static contents' data.
sb_static_contents_output_data_dir = "$root_out_dir/content/data"

Expand Down Expand Up @@ -81,11 +74,6 @@ declare_args() {
# ANGLE implementation for the platform.
gl_type = "system_gles2"

# The event polling mechanism available on this platform to support libevent.
# Platforms may redefine to 'poll' if necessary.
# Other mechanisms, e.g. devpoll, kqueue, select, are not yet supported.
sb_libevent_method = "epoll"

# Used to indicate that the player is filter based.
sb_filter_based_player = true

Expand All @@ -98,58 +86,23 @@ declare_args() {
# Set to the starboard_platform_tests target if the platform implements them.
platform_tests_path = ""

# Whether the platform has platform-specific targets to depend on.
has_platform_targets = false

# The path to the gni file containing the install_target template which
# defines how the build should produce the install/ directory.
install_target_path = "//starboard/build/install/no_install.gni"

# Target-specific configurations for static_library targets.
static_library_configs = []

# Target-specific configurations for source_set targets.
source_set_configs = []

# Target-specific configurations for loadable_module targets.
loadable_module_configs = []

# Enables optimizations on SSE compatible platforms.
sb_enable_opus_sse = true

# Enables or disables the DIAL server that runs inside Cobalt.
# Note: Only enable if there's no system-wide DIAL support.
enable_in_app_dial = false

# A symbolizer path for ASAN can be added to allow translation of callstacks.
asan_symbolizer_path = "$clang_base_path/bin/llvm-symbolizer"

# Sub-directory to copy license file to.
cobalt_licenses_platform = "default"

# TODO(b/173248397): Migrate to CobaltExtensions or PlatformServices.
# List of platform-specific targets that get compiled into cobalt.
cobalt_platform_dependencies = []

# Some compiler can not compile with raw assembly(.S files) and v8
# converts asm to inline assembly for these platforms.
cobalt_v8_emit_builtins_as_inline_asm = false

# Set to true to enable pointer compression for v8.
v8_enable_pointer_compression_override = true

# Whether or not to disable run-time type information (adding no_rtti flag).
sb_use_no_rtti = false

# Set to true to separate install target directories.
separate_install_targets_for_bundling = false

# Enables an NPLB audit of C++17 support.
sb_enable_cpp17_audit = true

# Enables an NPLB audit of C++20 support.
sb_enable_cpp20_audit = true

# Set this to true if the modular toolchain linker doesn't strip
# all unused symbols and nplb fails to link.
# TODO: b/297808555 Remove this flag after nplb is fixed
Expand Down
4 changes: 1 addition & 3 deletions starboard/build/config/components.gni
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,7 @@ template("component") {
forward_variables_from(invoker, "*", TESTONLY_AND_VISIBILITY)

if (is_starboard) {
if (_component_mode == "source_set") {
configs += source_set_configs
} else if (_component_mode == "static_library") {
if (_component_mode == "static_library") {
configs += static_library_configs
} else if (_component_mode == "shared_library") {
configs += shared_library_configs
Expand Down
10 changes: 0 additions & 10 deletions starboard/content/fonts/font_configuration.gni
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,4 @@ declare_args() {
# See content/fonts/README.md for details on the specific values used for the
# variables below.
cobalt_font_package = "standard"
cobalt_font_package_override_named_sans_serif = -1
cobalt_font_package_override_named_serif = -1
cobalt_font_package_override_named_fcc_fonts = -1
cobalt_font_package_override_fallback_lang_non_cjk = -1
cobalt_font_package_override_fallback_lang_cjk = -1
cobalt_font_package_override_fallback_lang_cjk_low_quality = -1
cobalt_font_package_override_fallback_historic = -1
cobalt_font_package_override_fallback_color_emoji = -1
cobalt_font_package_override_fallback_emoji = -1
cobalt_font_package_override_fallback_symbols = -1
}
34 changes: 0 additions & 34 deletions starboard/content/fonts/variables.gni
Original file line number Diff line number Diff line change
Expand Up @@ -96,40 +96,6 @@ if (cobalt_font_package == "standard") {
copy_font_files = false
}

if (cobalt_font_package_override_named_sans_serif >= 0) {
package_named_sans_serif = cobalt_font_package_override_named_sans_serif
}
if (cobalt_font_package_override_named_serif >= 0) {
package_named_serif = cobalt_font_package_override_named_serif
}
if (cobalt_font_package_override_named_fcc_fonts >= 0) {
package_named_fcc_fonts = cobalt_font_package_override_named_fcc_fonts
}
if (cobalt_font_package_override_fallback_lang_non_cjk >= 0) {
package_fallback_lang_non_cjk =
cobalt_font_package_override_fallback_lang_non_cjk
}
if (cobalt_font_package_override_fallback_lang_cjk >= 0) {
package_fallback_lang_cjk = cobalt_font_package_override_fallback_lang_cjk
}
if (cobalt_font_package_override_fallback_lang_cjk_low_quality >= 0) {
package_fallback_lang_cjk_low_quality =
cobalt_font_package_override_fallback_lang_cjk_low_quality
}
if (cobalt_font_package_override_fallback_historic >= 0) {
package_fallback_historic = cobalt_font_package_override_fallback_historic
}
if (cobalt_font_package_override_fallback_color_emoji >= 0) {
package_fallback_color_emoji =
cobalt_font_package_override_fallback_color_emoji
}
if (cobalt_font_package_override_fallback_emoji >= 0) {
package_fallback_emoji = cobalt_font_package_override_fallback_emoji
}
if (cobalt_font_package_override_fallback_symbols >= 0) {
package_fallback_symbols = cobalt_font_package_override_fallback_symbols
}

package_categories = [
"sans-serif=${package_named_sans_serif}",
"serif=${package_named_serif}",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
import("//starboard/build/config/modular/configuration.gni")

size_config_path = "//starboard/evergreen/shared/platform_configuration:size"
cobalt_licenses_platform = "evergreen"

# Evergreen relies on the underlying platform for the player.
sb_filter_based_player = false
3 changes: 0 additions & 3 deletions starboard/extension/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,4 @@ target(gtest_target_type, "extension_test") {
"//testing/gmock",
"//testing/gtest",
]
if (sb_is_modular && current_toolchain == cobalt_toolchain) {
deps += cobalt_platform_dependencies
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ sb_enable_benchmark = true

install_target_path = "//starboard/build/install/install_target.gni"

sb_enable_opus_sse = false

speed_config_path = "//starboard/linux/shared/platform_configuration:speed"
size_config_path = "//starboard/linux/shared/platform_configuration:size"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,5 @@ if (current_toolchain == default_toolchain &&

gl_type = "system_gles2"

cobalt_v8_emit_builtins_as_inline_asm = true

v8_enable_webassembly = false
}
10 changes: 2 additions & 8 deletions starboard/nplb/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -262,19 +262,13 @@ test("nplb") {
"//testing/gtest",
]

deps += cobalt_platform_dependencies

if (is_internal_build) {
deps += [ "//internal/starboard/private/nplb:nplb_private" ]
}

if (sb_enable_cpp17_audit) {
deps += [ "//starboard/nplb/compiler_compliance:cpp17_supported" ]
}
deps += [ "//starboard/nplb/compiler_compliance:cpp17_supported" ]

if (sb_enable_cpp20_audit) {
deps += [ "//starboard/nplb/compiler_compliance:cpp20_supported" ]
}
deps += [ "//starboard/nplb/compiler_compliance:cpp20_supported" ]

data_deps = [
"//starboard/content/ssl:copy_ssl_certificates",
Expand Down
66 changes: 31 additions & 35 deletions starboard/nplb/compiler_compliance/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -35,44 +35,40 @@ static_library("cpp14_supported") {
deps = [ "//starboard:starboard_group" ]
}

if (sb_enable_cpp17_audit) {
static_library("cpp17_supported") {
sources = [ "cpp17_support.cc" ]
configs += [
"//starboard/build/config:starboard",
"//starboard/build/config/sabi",
":no_unused",
]
deps = [
":cpp17_supported_config_shim",
"//starboard:starboard_group",
]
}
static_library("cpp17_supported") {
sources = [ "cpp17_support.cc" ]
configs += [
"//starboard/build/config:starboard",
"//starboard/build/config/sabi",
":no_unused",
]
deps = [
":cpp17_supported_config_shim",
"//starboard:starboard_group",
]
}

# We do this to ensure the -std=c++17 flag is added after any other -std flag
# so it overrides any other one.
group("cpp17_supported_config_shim") {
public_configs = [ ":cpp17_supported_config" ]
}
# We do this to ensure the -std=c++17 flag is added after any other -std flag
# so it overrides any other one.
group("cpp17_supported_config_shim") {
public_configs = [ ":cpp17_supported_config" ]
}

config("cpp17_supported_config") {
cflags_cc = [ "-std=c++17" ]
}
config("cpp17_supported_config") {
cflags_cc = [ "-std=c++17" ]
}

if (sb_enable_cpp20_audit) {
static_library("cpp20_supported") {
sources = [ "cpp20_support.cc" ]
configs += [ ":no_unused" ]
deps = [
":cpp20_supported_config_shim",
"//starboard:starboard_group",
]
}
static_library("cpp20_supported") {
sources = [ "cpp20_support.cc" ]
configs += [ ":no_unused" ]
deps = [
":cpp20_supported_config_shim",
"//starboard:starboard_group",
]
}

# We do this to ensure the -std=c++20 flag is added after any other -std flag
# so it overrides any other one.
group("cpp20_supported_config_shim") {
public_configs = [ "//starboard/build/config:cpp20_supported_config" ]
}
# We do this to ensure the -std=c++20 flag is added after any other -std flag
# so it overrides any other one.
group("cpp20_supported_config_shim") {
public_configs = [ "//starboard/build/config:cpp20_supported_config" ]
}
4 changes: 0 additions & 4 deletions starboard/shared/starboard/player/filter/testing/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@ if (current_toolchain == starboard_toolchain) {
"//testing/gmock",
]

deps = cobalt_platform_dependencies

data_deps =
[ "//starboard/shared/starboard/player:player_download_test_data" ]
}
Expand All @@ -62,8 +60,6 @@ if (current_toolchain == starboard_toolchain) {
":test_util",
"//third_party/google_benchmark",
]

deps = cobalt_platform_dependencies
}

static_library("test_util") {
Expand Down
Loading