Skip to content

Commit 22b7e4d

Browse files
committed
auto merge of #16534 : thestinger/rust/dep, r=huonw
This is already enabled by default for x86_64 executables on Windows, but it needs to be manually enabled on x86. Closes #16533
2 parents 78ec390 + d3c71a5 commit 22b7e4d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/librustc/back/link.rs

+3
Original file line numberDiff line numberDiff line change
@@ -1472,6 +1472,9 @@ fn link_args(cmd: &mut Command,
14721472
// [1] - https://sourceware.org/bugzilla/show_bug.cgi?id=13130
14731473
// [2] - https://code.google.com/p/go/issues/detail?id=2139
14741474
cmd.arg("-Wl,--enable-long-section-names");
1475+
1476+
// Always enable DEP (NX bit) when it is available
1477+
cmd.arg("-Wl,--nxcompat");
14751478
}
14761479

14771480
if sess.targ_cfg.os == abi::OsAndroid {

0 commit comments

Comments
 (0)