@@ -137,12 +137,12 @@ def test_MACHO(self):
137137 else :
138138 # arm64 darwin doesn't support non-PIE binaries, control flow or executable stacks
139139 self .assertEqual (call_security_check (cc , source , executable , ['-Wl,-flat_namespace' ,'-fno-stack-protector' , '-Wl,-no_fixup_chains' ]),
140- (1 , executable + ': failed NOUNDEFS Canary FIXUP_CHAINS' ))
141- self .assertEqual (call_security_check (cc , source , executable , ['-Wl,-flat_namespace' ,'-fno-stack-protector' , '-Wl,-fixup_chains' ]),
140+ (1 , executable + ': failed NOUNDEFS Canary FIXUP_CHAINS BRANCH_PROTECTION ' ))
141+ self .assertEqual (call_security_check (cc , source , executable , ['-Wl,-flat_namespace' ,'-fno-stack-protector' , '-Wl,-fixup_chains' , '-mbranch-protection=bti' ]),
142142 (1 , executable + ': failed NOUNDEFS Canary' ))
143- self .assertEqual (call_security_check (cc , source , executable , ['-Wl,-flat_namespace' ,'-fstack-protector-all' , '-Wl,-fixup_chains' ]),
143+ self .assertEqual (call_security_check (cc , source , executable , ['-Wl,-flat_namespace' ,'-fstack-protector-all' , '-Wl,-fixup_chains' , '-mbranch-protection=bti' ]),
144144 (1 , executable + ': failed NOUNDEFS' ))
145- self .assertEqual (call_security_check (cc , source , executable , ['-fstack-protector-all' , '-Wl,-fixup_chains' ]),
145+ self .assertEqual (call_security_check (cc , source , executable , ['-fstack-protector-all' , '-Wl,-fixup_chains' , '-mbranch-protection=bti' ]),
146146 (0 , '' ))
147147
148148
0 commit comments