Install codelldb
This commit is contained in:
@@ -27,7 +27,6 @@ ARG RECIPE=recipe-framework-13.yml
|
||||
# See issue #28 (https://github.com/ublue-os/startingpoint/issues/28).
|
||||
COPY usr/ /usr
|
||||
COPY ${USER_DIR}/ /usr
|
||||
RUN ls /usr
|
||||
|
||||
# Copy the recipe that we're building.
|
||||
COPY ${RECIPE} /usr/share/ublue-os/recipe.yml
|
||||
|
||||
@@ -12,6 +12,7 @@ scripts:
|
||||
- setup-selinux-dockersock.sh
|
||||
- autorun.sh
|
||||
- setup-desktop-audio.sh
|
||||
- install-codelldb.sh
|
||||
rpm:
|
||||
# A list of urls of ".repo" files that should be added to your system.
|
||||
# This is the proper way to add custom COPR repos to your image.
|
||||
|
||||
@@ -12,6 +12,7 @@ scripts:
|
||||
- setup-selinux-dockersock.sh
|
||||
- autorun.sh
|
||||
- setup-framework-13.sh
|
||||
- install-codelldb.sh
|
||||
rpm:
|
||||
# A list of urls of ".repo" files that should be added to your system.
|
||||
# This is the proper way to add custom COPR repos to your image.
|
||||
|
||||
17
scripts/install-codelldb.sh
Normal file
17
scripts/install-codelldb.sh
Normal file
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
cd /usr/bin/
|
||||
|
||||
curl -L "https://github.com/vadimcn/vscode-lldb/releases/download/v1.7.0/codelldb-x86_64-linux.vsix" -o "codelldb-x86_64-linux.zip"
|
||||
|
||||
unzip "codelldb-x86_64-linux.zip" "extension/adapter/*" "extension/lldb/*"
|
||||
|
||||
rm -f "codelldb-x86_64-linux.zip"
|
||||
|
||||
mv extension/ codelldb_adapter
|
||||
|
||||
ln -s $(pwd)/codelldb_adapter/adapter/codelldb /usr/bin/codelldb
|
||||
|
||||
codelldb -h > /dev/null
|
||||
@@ -1,12 +0,0 @@
|
||||
import subprocess
|
||||
import pathlib
|
||||
import lldb
|
||||
|
||||
# determine the sysroot for the active rust interpreter
|
||||
rustlib_etc = pathlib.Path(subprocess.getoutput('rustc --print sysroot')) / 'lib' / 'rustlib' / 'etc'
|
||||
if not rustlib_etc.exists():
|
||||
raise RuntimeError('Unable to determine rustc sysroot')
|
||||
|
||||
# load lldb_lookup.py and execute lldb_commands with the correct path
|
||||
lldb.debugger.HandleCommand(f"""command script import "{rustlib_etc / 'lldb_lookup.py'}" """)
|
||||
lldb.debugger.HandleCommand(f"""command source -s 0 "{rustlib_etc / 'lldb_commands'}" """)
|
||||
Reference in New Issue
Block a user