Serialosc and libmonome compilation with debug option (solved)

I made a copy of libmonome and serialosc from github and built everything for the mac. I want to experiment with the code but need debug symbols for gdb.
I have no experience with waf and could not find where to set the debug option in the wafscript.

Can anyone help? Many thanks!

AFAIK by default all symbols are present, there’s no call to strip in wscript (the waf "definition"file).
Have you tried it?

Also, did you run into this issue?

Thanks. I did not run into the linked issue. I’ve complied libmonome and serialosc sucessfully on the may. I’ve also did some changes in the code and could excuse the bin files.
Only issue is the debugger so far.

Here is the output of gdb:

Reading symbols from serialosc-detector…(no debugging symbols found)…done.

When i type the run command I get an additional error:

(gdb) run
Starting program: /Users/taichber/Documents/Development/monome/serialosc_emulator/build/bin/serialosc-detector
Unable to find Mach task port for process-id 17264: (os/kern) failure (0x5).
(please check gdb is codesigned - see taskgated(8))

I will do some further investigation.

Seems to be a macOS issue, see

Did the steps to create a certificate. Still same error message.
But “sudo gdb …” did it.
It is possible now to run the program. But I still miss the debug symbols:

“No symbol table is loaded. Use the “file” command.”

"Reading symbols from serialosc-detector…(no debugging symbols found)…done.
(gdb) "

Debugging works :slight_smile:
I’ve added in the wscript “-g”:

“conf.env.append_unique(“CFLAGS”, [”-std=c99", “-Wall”, “-Werror”, “-g”])"

1 Like

if it makes sense, please submit a PR on github so others can benefit!

never used github so far (only downloaded code). I will look into it.

If you create a PR please add it as an option or make it macOS (and maybe Windows?) specific.
The generation of debugging symbols is normally a property that’s managed by the OS/package manager.