Bug 1360299 - When --enable-hardening is used, --enable-pie will be automatically enabled draft
authorAlex Gaynor <agaynor@mozilla.com>
Mon, 01 May 2017 15:00:50 -0400
changeset 571380 19276914e534
parent 571272 48c0fd9c9ec5
child 626742 939f107e9b58
push id56768
push userbmo:agaynor@mozilla.com
push dateTue, 02 May 2017 13:51:13 +0000
bugs1360299
milestone55.0a1
Bug 1360299 - When --enable-hardening is used, --enable-pie will be automatically enabled r=froydnj MozReview-Commit-ID: 7QFOTzSlXSj
build/moz.configure/toolchain.configure
--- a/build/moz.configure/toolchain.configure
+++ b/build/moz.configure/toolchain.configure
@@ -1003,8 +1003,9 @@ option('--enable-hardening', env='MOZ_SE
        help='Enables security hardening compiler options')
 
 @depends('--enable-hardening', c_compiler)
 def security_hardening_cflags(value, c_compiler):
     if value and c_compiler.type in ['gcc', 'clang']:
         return '-fstack-protector-strong'
 
 add_old_configure_assignment('HARDENING_CFLAGS', security_hardening_cflags)
+imply_option('--enable-pie', depends_if('--enable-hardening')(lambda v: v))