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

Unified Diff: src/untrusted/irt/irt.gyp

Issue 940993003: Build the IRT with nacl-clang for x86 (Closed) Base URL: https://chromium.googlesource.com/native_client/src/native_client.git@master
Patch Set: fix sbtc build Created 5 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
Index: src/untrusted/irt/irt.gyp
diff --git a/src/untrusted/irt/irt.gyp b/src/untrusted/irt/irt.gyp
index d71264221a23620b55bd17556acedcfa9386fb7f..5be51c1eedc4c4a048d5592885e4adcbec130195 100644
--- a/src/untrusted/irt/irt.gyp
+++ b/src/untrusted/irt/irt.gyp
@@ -43,6 +43,17 @@
'../nacl/sys_private.c',
'../valgrind/dynamic_annotations.c',
],
+# On x86-64 we build the IRT with sandbox base-address hiding. This means that
+# all of its components must be built with LLVM's assembler. Currently the
+# unwinder library is built with nacl-gcc and so does not use base address
+# hiding. The IRT does not use exceptions, so we do not actually need the
+# unwinder at all. To prevent it from being linked into the IRT, we provide
+# stub implementations of its functions that are referenced from libc++abi
+# (which is build with exception handling enabled) and from crtbegin.c.
+ 'stub_sources': [
+ '../../../pnacl/support/bitcode/unwind_stubs.c',
+ 'frame_info_stubs.c',
+ ],
'irt_nonbrowser': [
'irt_core_resource.c',
'irt_entry_core.c',
@@ -89,7 +100,16 @@
'build_newlib': 1,
'build_irt': 1,
},
- 'sources': ['<@(irt_sources)'],
+ 'sources': ['<@(irt_sources)','<@(stub_sources)'],
+ 'conditions': [
+ # Disable stub sources on ARM
+ # TODO(dschuff): remove this when we switch to arm-nacl-clang
+ ['target_arch=="arm"', {
+ 'variables': {
+ 'stub_sources' : []
+ }
+ }],
+ ],
'dependencies': [
'<(DEPTH)/native_client/tools.gyp:prep_toolchain',
'<(DEPTH)/native_client/src/untrusted/nacl/nacl.gyp:nacl_lib_newlib',

Powered by Google App Engine
This is Rietveld 408576698