![]() |
|
NetBSD Package System (pkgsrc) Installation and upgrading of packages on NetBSD. |
![]() |
|
Thread Tools | Display Modes |
|
|||
![]()
As there are no 2015Q4 binary packages for evbarmv6hf I compiled Tor (tor-0.2.7.6) natively on my Raspberry (first generation Model-B 256MB) from the 2015Q4-Sources.
When I try to start the service via, for example Code:
# /etc/rc.d/tor (one)start I have no idea how to solve or how to debug this problem from here on. Thanks in advance EDIT: Forgot to mention: Tried NetBSD 7.0 release and NetBSD-7 stable without any differences. No problems on NetBSD-7 amd64 Last edited by pinswats; 30th January 2016 at 02:54 PM. Reason: More OS information |
|
|||
![]() Quote:
How to enable debugging during building? Code:
make show-options |
|
||||
![]()
There are generally three types of debugging:
![]()
Code:
CFLAGS+=-g -O0 CXXFLAGS+=-g -O0 Last edited by jggimi; 30th January 2016 at 05:21 PM. Reason: clarity, and one thinko |
|
|||
![]()
First of all thanks for the extensive and fast answer. It is really helpful since I am now out of my usual Linux/BSD comfort zone
![]() For the next debugging step it will likely take some time since I have a lot of reading manpages, trying and compiling (on raspberry, cross-compiling is no options because of perl dependency ![]() |
|
||||
![]()
The most helpful thing the debugger can do is display the stack trace. You can see them using gdb's backtrace command, shortened to "bt", or its wonderful synonym, "where".
Every time a function gets called, a new stack frame is created, and the calling one gets saved. It contains saved values, such as variables and instruction pointers, so that when the called function returns, the calling one picks up where it left off. The top of the stack trace is the most recent function called -- it will be frame number 0. And all of the other calls to that point will be in the trace. You don't need to know much about programming to use it to see what functions call what, and the code paths taken by the program. The gdb frame command will let you inspect any of them for variable values, too. And you can go up and down through the frames with the up and down commands. ![]() Your loop will either be looping through multiple functions, or stuck inside a single function. Either way, you should be able to watch it progress. The gdb() "step" command will move a program one line at a time through a program, including any called functions, while the "next" command will treat a function call as if it is a single instruction. Both may be helpful. See this recent rant from a non-programmer who increased the security of an unreadable, confusing application, primarily by using stack traces from core files. ![]() |
|
|||
![]()
I did in the meanwhile build tor on the latest Raspbian distribution on the same Rpi, no problems there. So it is likely a NetBSD/pkgsrc issue. But I "solved" it on NetBSD, or better found a workaround, by using clang.
|
![]() |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
alternatives to raspberry pi | osw94k | OpenBSD General | 2 | 15th February 2015 04:58 AM |
Raspberry Pi 2 B | bsdnut82 | FreeBSD General | 3 | 12th February 2015 08:54 PM |
Raspberry Pi-like Box That Runs OpenBSD? | raindog308 | General Hardware | 3 | 31st August 2013 08:37 AM |
OpenBSD availablitity for Raspberry Pi? | dbach | OpenBSD General | 9 | 23rd April 2013 06:56 PM |
FreeBSD on Raspberry Pi | Beastie | News | 0 | 24th January 2013 01:53 PM |