summaryrefslogtreecommitdiffstats
path: root/chrome/chrome.gyp
diff options
context:
space:
mode:
authormseaborn@chromium.org <mseaborn@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-22 05:48:39 +0000
committermseaborn@chromium.org <mseaborn@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-07-22 05:48:39 +0000
commit631cfecf211bb9d50fe22c274df79769defa95df (patch)
tree9ad85b61c9f768b804f59197a94a439a20296344 /chrome/chrome.gyp
parentd1d40e94a5de57935aaf693c16a7f5752d1f0a98 (diff)
downloadchromium_src-631cfecf211bb9d50fe22c274df79769defa95df.zip
chromium_src-631cfecf211bb9d50fe22c274df79769defa95df.tar.gz
chromium_src-631cfecf211bb9d50fe22c274df79769defa95df.tar.bz2
Mac: Disable ASLR for the helper app because ASLR breaks NaCl
This disables Address Space Layout Randomisation for the renderer process, NaCl process and other sandboxed processes, but leaves ASLR enabled for the browser process. ASLR breaks NaCl because it fragments the address space and means that NaCl often cannot allocate 1GB for the x86-32 sandbox's address space. BUG=http://code.google.com/p/nativeclient/issues/detail?id=2043 TEST=nacl_integration This command should print a non-zero value, indicating PIE: otool -l xcodebuild/Debug/Chromium.app/Contents/MacOS/Chromium | grep rebase_off This command should print zero, indicating non-PIE: otool -l 'xcodebuild/Debug/Chromium.app/Contents/Versions/14.0.827.0/Chromium Helper.app/Contents/MacOS/Chromium Helper' | grep rebase_off Review URL: http://codereview.chromium.org/7482015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@93558 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/chrome.gyp')
-rw-r--r--chrome/chrome.gyp8
1 files changed, 8 insertions, 0 deletions
diff --git a/chrome/chrome.gyp b/chrome/chrome.gyp
index eb760e0..647ad32 100644
--- a/chrome/chrome.gyp
+++ b/chrome/chrome.gyp
@@ -974,6 +974,14 @@
'CHROMIUM_SHORT_NAME': '<(branding)',
'CHROMIUM_STRIP_SAVE_FILE': 'app/app.saves',
'INFOPLIST_FILE': 'app/helper-Info.plist',
+ # Stop the helper executable from being position-independent
+ # since that turns on ASLR, which breaks NaCl. ASLR breaks
+ # NaCl's ability to reliably allocate 1GB of address space for
+ # untrusted code to run in.
+ # See http://code.google.com/p/nativeclient/issues/detail?id=2043
+ # TODO(mseaborn): Create a separate helper executable for NaCl
+ # so that the renderer process can still use ASLR.
+ 'OTHER_LDFLAGS!': ['-Wl,-pie'],
},
'copies': [
{