22 lines · c
1/// Check that LLDB can find a relative DWO file next to a binary just using the2/// filename of that DWO. For example "main.dwo" not "a/b/main.dwo".3// UNSUPPORTED: system-darwin4// RUN: rm -rf %t.compdir/5// RUN: mkdir -p %t.compdir/a/b/6// RUN: cp %s %t.compdir/a/b/main.c7// RUN: cd %t.compdir/a/8/// The produced DWO is named b/main-main.dwo, with a DW_AT_comp_dir of a/.9// RUN: %clang_host -g -gsplit-dwarf -fdebug-prefix-map=%t.compdir=. b/main.c -o b/main10// RUN: cd ../..11/// Move binary and DWO out of expected locations.12// RUN: mv %t.compdir/a/b/main %t.compdir/13// RUN: mv %t.compdir/a/b/*.dwo %t.compdir/14// RUN: %lldb --no-lldbinit %t.compdir/main \15// RUN: -o "b main" -o "run" -o "p num" --batch 2>&1 | FileCheck %s16 17// CHECK-NOT: warning: {{.*}}main unable to locate separate debug file (dwo, dwp). Debugging will be degraded.18// CHECK: (int) 519 20int num = 5;21 22int main(void) { return 0; }