On 26/12/2022 23:11, Stéphane Archer wrote:
Dear Coreutils community,

I have a hard debugging the mv binary using GDB.
I modify the Makefile at the root with the following flag hopping it help:
CFLAGS = -g -ggdb -Og -O0
But many of the variables have been optimized out and it's a bit hard to
step into the code.
I think it's probably because I'm stepping in gnulib witch is maybe not
using the same CFLAGS.

Is there anything I should do to make my life easier?

CFLAGS can be overridden, so you could do something like:

  $ cd coreutils
  $ make clean
  $ make CFLAGS='-g -ggdb -Og -O0' -j4
  $ gdb --directory=lib -tui -args src/mv

cheers,
Pádraig

Reply via email to