File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed
src/trusted/service_runtime Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -2688,6 +2688,8 @@ def MakeGenericLinuxEnv(platform=None):
26882688 LINK = '$CXX' ,
26892689 )
26902690
2691+ linux_env .SetDefault (MAX_PAGE_SIZE = '0x1000' )
2692+
26912693 # Prepend so we can disable warnings via Append
26922694 linux_env .Prepend (
26932695 CPPDEFINES = [['_POSIX_C_SOURCE' , '199506' ],
@@ -2710,6 +2712,7 @@ def MakeGenericLinuxEnv(platform=None):
27102712 LINKFLAGS = ['-m64' ] + sysroot_flags ,
27112713 )
27122714 elif linux_env .Bit ('build_arm' ):
2715+ linux_env .Replace (MAX_PAGE_SIZE = '0x10000' )
27132716 SetUpLinuxEnvArm (linux_env )
27142717 elif linux_env .Bit ('build_mips32' ):
27152718 SetUpLinuxEnvMips (linux_env )
@@ -2735,7 +2738,8 @@ def MakeGenericLinuxEnv(platform=None):
27352738 linux_env .Prepend (SHLINKFLAGS = ['$COMMON_LINKFLAGS' ])
27362739 linux_env .Prepend (COMMON_LINKFLAGS = ['-Wl,-z,relro' ,
27372740 '-Wl,-z,now' ,
2738- '-Wl,-z,noexecstack' ])
2741+ '-Wl,-z,noexecstack' ,
2742+ '-Wl,-z,max-page-size=${MAX_PAGE_SIZE}' ])
27392743 linux_env .Prepend (LINKFLAGS = ['-pie' ])
27402744 # The ARM toolchain has a linker that doesn't handle the code its
27412745 # compiler generates under -fPIE.
Original file line number Diff line number Diff line change @@ -427,7 +427,7 @@ if (env.Bit('linux') and not env.Bit('built_elsewhere')):
427427 'nacl_bootstrap_raw' ,
428428 [bootstrap_obj ],
429429 ("env CXX='${CXX}' ${PYTHON} %s %s " +
430- '-m %s --build-id -static -z max-page-size=0x1000 ' +
430+ '-m %s --build-id -static -z max-page-size=${MAX_PAGE_SIZE} ' +
431431 '--defsym RESERVE_TOP=%s --script %s -o ${TARGET} ${SOURCES}' ) %
432432 (bootstrap_env .File ('linux/ld_bfd.py' ), compiler_override , ld_emul ,
433433 reserve_top , bootstrap_env .File ('linux/nacl_bootstrap.x' )),
You can’t perform that action at this time.
0 commit comments