-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'libdwarf-0/libdwarf.h' file not found, but libdwarf installed by pacman #9
Comments
I'd try removing the libdrawf that's installed through pacman and installing manually instead. That's how I build Spray on my machine. There's a tarball of libdwarf's source code here on the libdwarf's GitHub mirror. The root of the extracted folder contains a file called |
I was able to build and install spray, but when in the examples folder I compiled the file, spray gave this error spray: src/debugger.c:1478: void init_load_address(Debugger *): Assertion `parse_base16 (addr, &load_address.value) == SP_OK' failed. P.S. I found out that the last error can be solved if you replace line 17 in the spray_dwarf.h file with "#include "libdwarf.h" and copy that header file to the "src" folder. |
Oh yes, I should consider adding the header locally. That would make the install much easier. Did you try copyting |
Yup, I tried that. |
The function in which the failure occurred is meant to read the load address of the process that the debugger trances (the "tracee"). The way it does this is to open the
EDIT: I just realized that the double free is exactly what should happen when running the example. It's intentionally part of the example so it can be debugged. ASan doesn't catch it because it's not even part of Spray. The output just gets mixed up. |
Also, I hope you are on the v0.0.1 commit. |
Yes, the following three lines from the output are the real issue there. The rest is all printed by the example.
And I don't think this error is related to libdwarf. The function in which the assertion failed ( |
If you want, you could try the following to poke at the problem:
Essentially, we need to find out why an invalid hexadecimal literal is passed to There's probably a blatant bug here 😅. I just while debugging that |
src/spray_dwarf.h:17:10: fatal error: 'libdwarf-0/libdwarf.h' file not found
#include <libdwarf-0/libdwarf.h>
^~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make: *** [Makefile:43: build/info.o] Error 1
P.S. My system: Manjaro(Linux 6.6.8-2-MANJARO)
The text was updated successfully, but these errors were encountered: