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

Unified Diff: tools/testing/dart/compiler_configuration.dart

Issue 2784253003: Use -no_compact_unwind when creating dylibs on Mac. (Closed)
Patch Set: Created 3 years, 9 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: tools/testing/dart/compiler_configuration.dart
diff --git a/tools/testing/dart/compiler_configuration.dart b/tools/testing/dart/compiler_configuration.dart
index d8863273c4d849c23b89f55804d71a082f3a992b..1a69df124bc6acf7712b4fa44cb3c59262249387 100644
--- a/tools/testing/dart/compiler_configuration.dart
+++ b/tools/testing/dart/compiler_configuration.dart
@@ -652,7 +652,7 @@ class PrecompilerCompilerConfiguration extends CompilerConfiguration {
List arguments,
Map<String, String> environmentOverrides) {
- var cc, shared;
+ var cc, shared, ld_flags;
if (isAndroid) {
var ndk = "third_party/android_tools/ndk";
var triple;
@@ -675,6 +675,8 @@ class PrecompilerCompilerConfiguration extends CompilerConfiguration {
} else if (Platform.isMacOS) {
cc = 'clang';
shared = '-dynamiclib';
+ // Tell Mac linker to give up generating eh_frame from dwarf.
+ ld_flags = '-Wl,-no_compact_unwind';
} else {
throw "Platform not supported: ${Platform.operatingSystem}";
}
@@ -701,13 +703,14 @@ class PrecompilerCompilerConfiguration extends CompilerConfiguration {
}
var exec = cc;
- var args = (cc_flags != null) ? [ shared, cc_flags ] : [ shared ];
- args.addAll([
- '-nostdlib',
- '-o',
- '$tempDir/out.aotsnapshot',
- '$tempDir/out.S'
- ]);
+ var args = [];
+ if (cc_flags != null) args.add(cc_flags);
+ if (ld_flags != null) args.add(ld_flags);
+ args.add(shared);
+ args.add('-nostdlib');
+ args.add('-o');
+ args.add('$tempDir/out.aotsnapshot');
+ args.add('$tempDir/out.S');
return commandBuilder.getCompilationCommand('assemble', tempDir, !useSdk,
bootstrapDependencies(buildDir), exec, args, environmentOverrides);
« 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