Skip to content

Commit 33c520d

Browse files
committed
added function to pull dostrip'd stuff from valgrind
Signed-off-by: Zen <[email protected]>
1 parent c503677 commit 33c520d

File tree

2 files changed

+16
-1
lines changed

2 files changed

+16
-1
lines changed

ugrd/base/debug.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
__author__ = "desultory"
22
__version__ = "0.1.0"
33

4+
from pathlib import Path
5+
46

57
def start_shell(self):
68
"""
@@ -10,3 +12,12 @@ def start_shell(self):
1012
return "bash"
1113
else:
1214
return None
15+
16+
17+
def pull_valgrind_parts(self):
18+
"""
19+
Gets the stuff which was dostrip -x'd from valgrind and adds it to the dependencies.
20+
"""
21+
for file in Path('/usr/lib64/valgrind').glob('*.a'):
22+
self.logger.debug("Found valgrind dependency: %s", file)
23+
self.config_dict['dependencies'] = file

ugrd/base/debug.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
binaries = ['cp', 'mv', 'rm', 'nano', 'find', 'grep', 'dmesg', 'chmod', 'touch', 'valgrind', 'gdb']
1+
binaries = ['cp', 'mv', 'rm', 'nano', 'find', 'grep', 'dmesg', 'chmod', 'touch', 'valgrind', 'gdb', 'python']
2+
3+
[imports.build_pre]
4+
"ugrd.base.debug" = [ "pull_valgrind_parts" ]
5+
26

37
[imports.init_debug]
48
"ugrd.base.debug" = [ "start_shell" ]

0 commit comments

Comments
 (0)