Building libunwind with new CMakeLists.

The old CMakeLists file of libunwind used the C compiler to compile assembly files. This caused such code not to be hardened.
This commit is contained in:
Raoul Strackx 2020-03-27 16:46:52 +01:00
parent 72a8e6b193
commit 8ca26cca29
3 changed files with 3 additions and 12 deletions

View file

@ -10,7 +10,3 @@ global_asm!(".start_module_asm:
movq (%rdi), %rax
retq
.end_module_asm:" );
// CHECK: .start_module_asm
// TODO add check, when module-level pass is corrected
// CHECK: .end_module_asm

View file

@ -31,12 +31,8 @@ function check {
build
#TODO: re-enable check when newly compiled libunwind is used
#check unw_getcontext unw_getcontext.checks
#TODO: re-enable check when newly compiled libunwind is used
#check "libunwind::Registers_x86_64::jumpto()" jumpto.checks
check unw_getcontext unw_getcontext.checks
check "libunwind::Registers_x86_64::jumpto()" jumpto.checks
check "std::io::stdio::_print::h87f0c238421c45bc" print.checks
check rust_plus_one_global_asm rust_plus_one_global_asm.checks || echo "warning: module level assembly currently not hardened"

View file

@ -1,7 +1,6 @@
CHECK: unw_getcontext
CHECK: lfence
CHECK: lfence
CHECK: notq (%rsp)
CHECK-NEXT: notq (%rsp)
CHECK: shlq $0, (%rsp)
CHECK-NEXT: lfence
CHECK-NEXT: retq