diff --git a/tests/lldb/lldb-dwz/test.sh b/tests/lldb/lldb-dwz/test.sh index ad9ad0c..5fe8508 100755 --- a/tests/lldb/lldb-dwz/test.sh +++ b/tests/lldb/lldb-dwz/test.sh @@ -7,11 +7,12 @@ cp hello1 hello2 dwz hello1 hello2 -m hello.common lldb -b -o 'b main' -o 'run --usage' -o c -- hello1 2>&1 | tee lldb.log +exe=$(command -v lldb) # Until LLVM 23, DW_FORM GNU_ref_alt and GNU_strp_alt are unsupported. # In that case, lldb should report "unsupported DW_FORM values: 0x1f20 0x1f21" # as a warning, and continue the execution without any crash. Support added in: # https://github.com/llvm/llvm-project/commit/16149ca93227d0d26a2f7387e95ad30971e99f43 -if [[ "$(rpm -q --qf "%{version}" lldb | cut -d. -f1)" -lt "23" ]] ; then +if [[ "$(rpm -q --qf "%{version}" -f $exe | cut -d. -f1)" -lt "23" ]] ; then grep "unsupported DW_FORM values" lldb.log fi grep "stop reason = breakpoint" lldb.log