You are not logged in.
I've always had my AUR package ddnet set with CMAKE_BUILD_TYPE as "Release" as it basically a package that provides stable-release tarballs. So the resulting binary is optimized, no debug symbols, etc. But then I noticed that many local package builds started to generated *-debug package, and that's because /etc/makepkg.conf defaults to options=(debug) as of commit 90bf367e6 from pacman's package. But this didn't apply to ddnet because of the CMAKE_BUILD_TYPE I set.
Quoting this stackoverflow answer on the CMAKE_BUILD_TYPE values and their differences:
1. Release: high optimization level, no debug info, code or asserts.
2. Debug: No optimization, asserts enabled, [custom debug (output) code enabled],
debug info included in executable (so you can step through the code with a
debugger and have address to source-file:line-number translation).
3. RelWithDebInfo: optimized, *with* debug info, but no debug (output) code or asserts.
4. MinSizeRel: same as Release but optimizing for size rather than speed.
My questions are:
1. Should I set (and publish) CMAKE_BUILD_TYPE = "Debug", in order to generated a -debug package and to have debug symbols available?
2. Alternatively, "RelWithDebugInfo" doesn't generate debug, would it a good option?
Offline
Offline