File tree Expand file tree Collapse file tree 1 file changed +19
-14
lines changed Expand file tree Collapse file tree 1 file changed +19
-14
lines changed Original file line number Diff line number Diff line change 33# Exit if anything fails
44set -e
55
6- # Find out where to look for the pretty printer Python module
7- RUSTC_SYSROOT=` rustc --print sysroot`
8-
96# Find the host triple so we can find lldb in rustlib.
10- host=` rustc -vV | sed -n -e ' s/^host: //p' `
7+ host=$( rustc -vV | sed -n -e ' s/^host: //p' )
8+
9+ # Find out where to look for the pretty printer Python module
10+ RUSTC_SYSROOT=$( rustc --print sysroot)
11+ RUST_LLDB=" $RUSTC_SYSROOT /lib/rustlib/$host /bin/lldb"
1112
1213lldb=lldb
13- if [ -f " $RUSTC_SYSROOT /lib/rustlib/ $host /bin/lldb " ]; then
14- lldb=" $RUSTC_SYSROOT /lib/rustlib/ $host /bin/lldb "
14+ if [ -f " $RUST_LLDB " ]; then
15+ lldb=" $RUST_LLDB "
1516else
16- LLDB_VERSION=` " $lldb " --version 2> /dev/null | head -1 | cut -d. -f1`
17+ if ! command -v " $lldb " > /dev/null; then
18+ echo " $lldb not found! Please install it." >&2
19+ exit 1
20+ else
21+ LLDB_VERSION=$( " $lldb " --version | cut -d ' ' -f3)
1722
18- if [ " $LLDB_VERSION " = " lldb-350 " ]
19- then
20- echo " ***"
21- echo \
22- " WARNING: This version of LLDB has known issues with Rust and cannot \
23- display the contents of local variables! "
24- echo " *** "
23+ if [ " $LLDB_VERSION " = " 3.5.0 " ]; then
24+ cat << EOF >&2
25+ ***
26+ WARNING: This version of LLDB has known issues with Rust and cannot display the contents of local variables!
27+ ***
28+ EOF
29+ fi
2530 fi
2631fi
2732
You can’t perform that action at this time.
0 commit comments