Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(556)

Unified Diff: build/config/compiler/BUILD.gn

Issue 134613002: Modify some Linux flags for better GYP fidelity in GN build. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/compiler/BUILD.gn
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
index 8bfa465d346b1cf996437cb873a104232c0ad2ba..793cbea27aa7ff7f4962f27ea28295db782af097 100644
--- a/build/config/compiler/BUILD.gn
+++ b/build/config/compiler/BUILD.gn
@@ -101,6 +101,19 @@ config("compiler") {
cflags += "-m32"
ldflags += "-m32"
}
+
+ defines += [ "_FILE_OFFSET_BITS=64" ]
+
+ # Omit unwind support in official builds to save space. We can use breakpad
+ # for these builds.
+ if (is_chrome_branded && is_official_build) {
+ cflags += [
+ "-fno-unwind-tables",
+ "-fno-asynchronous-unwind-tables",
+ ]
+ } else {
+ cflags += [ "-funwind-tables" ]
+ }
}
# Linux-specific compiler flags setup.
@@ -114,9 +127,14 @@ config("compiler") {
cflags += [ "-pthread" ]
}
- # Use gold for linking on 64-bit Linux only (on 32-bit it runs out of
- # address space, and it doesn't support cross-compiling).
if (cpu_arch == "x64") {
+ # 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?
scottmg 2014/01/10 19:58:07 indent
+ defines += [ "__GLIBCXX_DEBUG=1" ]
+
+ # Use gold for linking on 64-bit Linux only (on 32-bit it runs out of
+ # address space, and it doesn't support cross-compiling).
gold_path = rebase_path("//third_party/gold", ".", root_build_dir)
ldflags += [
"-B$gold_path",
@@ -164,6 +182,9 @@ config("compiler") {
cflags += [
"-fcolor-diagnostics",
]
+ cflags_cc += [
+ "-std=gnu++11",
+ ]
}
# Android-specific flags setup.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698