xref: /llvm-project/llvm/test/tools/llvm-objdump/MachO/rpaths.test (revision 86b98c60c54cbb661500058c6e0d2f5cffec2690)
1## Validate fetching rpaths from a binary results in the correct output.
2# RUN: llvm-objdump --macho --rpaths --arch x86_64 %p/Inputs/Objc2.64bit.exe.macho-x86_64 | FileCheck --implicit-check-not={{.}} %s
3# RUN: llvm-objdump --macho --rpaths %p/Inputs/Objc2.64bit.exe.macho-x86_64 | FileCheck --implicit-check-not={{.}} %s
4
5# CHECK: {{.*}}Objc2.64bit.exe.macho-x86_64:
6# CHECK: @executable_path/../Frameworks
7
8## Validate binaries with no rpaths should print nothing.
9# RUN: llvm-objdump --macho --no-leading-headers --rpaths %p/Inputs/hello.exe.macho-i386 | count 0
10
11## Validate passing --rpaths without --macho fails.
12# RUN: not llvm-objdump --rpaths %p/Inputs/hello.exe.macho-i386 2>&1 | FileCheck --check-prefix=ERROR %s
13# ERROR: USAGE
14