Skip to content

Commit 4fd7a27

Browse files
authored
Reverts flutter#152 and flutter#150 until upstream repos are updated (flutter#156)
* Revert "Follow-up to switch to Fuchsia's ICU (flutter#152)" * Revert "Prepare for switch to Fuchsia ICU (flutter#150)"
1 parent 14082d4 commit 4fd7a27

File tree

4 files changed

+39
-45
lines changed

4 files changed

+39
-45
lines changed

build/config/BUILD.gn

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
import("//build/config/allocator.gni")
66
import("//build/config/crypto.gni")
77
import("//build/config/features.gni")
8-
import("//build/config/profiler.gni")
98
import("//build/config/ui.gni")
109

1110
declare_args() {
@@ -222,37 +221,3 @@ config("precompiled_headers") {
222221
cflags = [ "/FI$precompiled_header" ]
223222
}
224223
}
225-
226-
# This config causes functions not to be automatically exported from shared
227-
# libraries. By default, all symbols are exported but this means there are
228-
# lots of exports that slow everything down. In general we explicitly mark
229-
# which functiosn we want to export from components.
230-
#
231-
# Some third_party code assumes all functions are exported so this is separated
232-
# into its own config so such libraries can remove this config to make symbols
233-
# public again.
234-
#
235-
# See http://gcc.gnu.org/wiki/Visibility
236-
config("symbol_visibility_hidden") {
237-
# Note that -fvisibility-inlines-hidden is set globally in the compiler
238-
# config since that can almost always be applied.
239-
if (is_posix && !enable_profiling) {
240-
cflags = [ "-fvisibility=hidden" ]
241-
}
242-
}
243-
244-
# Allows turning Run-Time Type Identification on or off.
245-
config("rtti") {
246-
if (is_win) {
247-
cflags_cc = [ "/GR" ]
248-
}
249-
}
250-
config("no_rtti") {
251-
if (is_win) {
252-
cflags_cc = [ "/GR-" ]
253-
} else {
254-
rtti_flags = [ "-fno-rtti" ]
255-
cflags_cc = rtti_flags
256-
cflags_objcc = rtti_flags
257-
}
258-
}

build/config/BUILDCONFIG.gn

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -411,9 +411,8 @@ _native_compiler_configs = [
411411
"//build/config/compiler:compiler_arm_fpu",
412412
"//build/config/compiler:chromium_code",
413413
"//build/config/compiler:default_include_dirs",
414+
"//build/config/compiler:no_rtti",
414415
"//build/config/compiler:runtime_library",
415-
"//build/config:no_rtti",
416-
"//build/config:symbol_visibility_hidden",
417416
]
418417
if (is_win) {
419418
_native_compiler_configs += [
@@ -427,6 +426,7 @@ if (is_win) {
427426
if (is_posix) {
428427
_native_compiler_configs += [
429428
"//build/config/gcc:no_exceptions",
429+
"//build/config/gcc:symbol_visibility_hidden",
430430
]
431431
}
432432

@@ -561,14 +561,6 @@ set_defaults("test") {
561561
}
562562
}
563563

564-
# Some library targets may be built as different type depending on the target
565-
# platform. This variable specifies the default library type for each target.
566-
if (is_fuchsia) {
567-
default_library_type = "shared_library"
568-
} else {
569-
default_library_type = "static_library"
570-
}
571-
572564
# ==============================================================================
573565
# TOOLCHAIN SETUP
574566
# ==============================================================================

build/config/compiler/BUILD.gn

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -681,6 +681,25 @@ config("no_chromium_code") {
681681
cflags_cc += default_warning_flags_cc
682682
}
683683

684+
# rtti ------------------------------------------------------------------------
685+
#
686+
# Allows turning Run-Time Type Identification on or off.
687+
688+
config("rtti") {
689+
if (is_win) {
690+
cflags_cc = [ "/GR" ]
691+
}
692+
}
693+
config("no_rtti") {
694+
if (is_win) {
695+
cflags_cc = [ "/GR-" ]
696+
} else {
697+
rtti_flags = [ "-fno-rtti" ]
698+
cflags_cc = rtti_flags
699+
cflags_objcc = rtti_flags
700+
}
701+
}
702+
684703
# Warnings ---------------------------------------------------------------------
685704

686705
# This will generate warnings when using Clang if code generates exit-time

build/config/gcc/BUILD.gn

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,24 @@
44

55
import("//build/config/profiler.gni")
66

7+
# This config causes functions not to be automatically exported from shared
8+
# libraries. By default, all symbols are exported but this means there are
9+
# lots of exports that slow everything down. In general we explicitly mark
10+
# which functiosn we want to export from components.
11+
#
12+
# Some third_party code assumes all functions are exported so this is separated
13+
# into its own config so such libraries can remove this config to make symbols
14+
# public again.
15+
#
16+
# See http://gcc.gnu.org/wiki/Visibility
17+
config("symbol_visibility_hidden") {
18+
# Note that -fvisibility-inlines-hidden is set globally in the compiler
19+
# config since that can almost always be applied.
20+
if (!enable_profiling) {
21+
cflags = [ "-fvisibility=hidden" ]
22+
}
23+
}
24+
725
# Settings for executables and shared libraries.
826
config("executable_ldconfig") {
927
if (is_android) {

0 commit comments

Comments
 (0)