You are not logged in.

#1 2022-03-08 11:17:05

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,911

[solved] what debug flags are useful for most packages besides -g ?

I've been doing debug builds packages for many of my installed aur packages for a while using options=(debug strip) .

My /etc/makepkg.conf had "-g -fvar-tracking-assignments" which was default for pacman 6.0.1-3 .
The symbols that added helped a lot with solving bug reports for trunk versions of software I use (only complaint I sometimes got was having too much debug syymbols in crash logs ).

I don't compile anything with clang, so the fact that clang doesn't support "-fvar-tracking-assignments" doesn't bother me for my personal usecase ..

In pacman 6.0.1-4 "-fvar-tracking-assignments" was removed from /etc/makepkg-conf .

I looked at man gcc and found there are lots of debugging options.


My software troubleshooting capabilities are mostly limited to describing, bisecting , testing and such but understanding crash logs or core dumps is not my forte.

For now I'm sticking to "-fvar-tracking-assignments" , but I'd like opinions from other forum users what debug flags they think are useful.

Last edited by Lone_Wolf (2022-03-09 17:48:23)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

#2 2022-03-08 19:43:34

loqs
Member
Registered: 2014-03-06
Posts: 17,322

Re: [solved] what debug flags are useful for most packages besides -g ?

Have you read https://gitlab.archlinux.org/archlinux/ … equests/87 are you not building with any optimization?  In which case you could use -Og.

Offline

#3 2022-03-09 17:47:54

Lone_Wolf
Member
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,911

Re: [solved] what debug flags are useful for most packages besides -g ?

Nope, hadn't seen that.

I did look at gcc man page again and now understand a bit better.

I bulid with -O2 so -g should be enough to get useful symbols in the logfiles.


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Offline

Board footer

Powered by FluxBB