From 0a5228a02c32cb5b10d43cb154d6d0abaf360ba7 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Tue, 16 Jun 2020 17:05:29 -0700 Subject: [PATCH] test: add library search path to repair the test Update the test to no longer rely on the testing workaround in the linker and use the external libSystem stub. --- lld/test/MachO/dylink-lazy.s | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lld/test/MachO/dylink-lazy.s b/lld/test/MachO/dylink-lazy.s index a77a23be67f0..1ed509c14f50 100644 --- a/lld/test/MachO/dylink-lazy.s +++ b/lld/test/MachO/dylink-lazy.s @@ -4,13 +4,16 @@ # RUN: -o %t/libhello.o # RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %p/Inputs/libgoodbye.s \ # RUN: -o %t/libgoodbye.o -# RUN: lld -flavor darwinnew -arch x86_64 -dylib -install_name \ -# RUN: @executable_path/libhello.dylib %t/libhello.o -o %t/libhello.dylib -# RUN: lld -flavor darwinnew -arch x86_64 -dylib -install_name \ -# RUN: @executable_path/libgoodbye.dylib %t/libgoodbye.o -o %t/libgoodbye.dylib +# RUN: lld -flavor darwinnew -arch x86_64 -dylib -L%S/Inputs/MacOSX.sdk/usr/lib \ +# RUN: -install_name @executable_path/libhello.dylib %t/libhello.o \ +# RUN: -o %t/libhello.dylib +# RUN: lld -flavor darwinnew -arch x86_64 -dylib -L%S/Inputs/MacOSX.sdk/usr/lib \ +# RUN: -install_name @executable_path/libgoodbye.dylib %t/libgoodbye.o \ +# RUN: -o %t/libgoodbye.dylib # RUN: llvm-mc -filetype=obj -triple=x86_64-apple-darwin %s -o %t/dylink-lazy.o -# RUN: lld -flavor darwinnew -arch x86_64 -o %t/dylink-lazy -L%t -lhello -lgoodbye %t/dylink-lazy.o +# RUN: lld -flavor darwinnew -arch x86_64 -o %t/dylink-lazy \ +# RUN: -L%S/Inputs/MacOSX.sdk/usr/lib \-L%t -lhello -lgoodbye %t/dylink-lazy.o ## When looking at the __stubs section alone, we are unable to easily tell which ## symbol each entry points to. So we call objdump twice in order to get the