With qnos help I moved all my things to cmake where it is easy (and where I can get reliable debug builds and step debug in CLion). But is t it really just flags+= -DNDEBUG=1 in make land?
I think you really want separate build targets for debug and release. Just setting that flag will disable the asserts for all builds.
Totally agree. Can regular rack makefile do that today?
In cmake I can do it easily like i mentioned.though. So will when I open up. Y rack projects again
It should be a simple matter to add targets.
I rewrote the manual for NMAKE back in the early 90’s but I’ve forgotten almost everything.
I know zip about CMake, and it’s not the default setup for Rack. In the few CMAKE projects I’ve seen, I find tons of generated files littering the folders with impenetrable gobbledegook in them.
1 Like
from my ancient make file:
# Macro to use on any target where we don't normally want asserts
ASSERTOFF = -D NDEBUG
# Make _ASSERT=true will nullify our ASSERTOFF flag, thus allowing them
ifdef _ASSERT
ASSERTOFF =
endif
# This turns asserts off for make (plugin), not for test or perf
$(TARGET) : FLAGS += $(ASSERTOFF)
3 Likes
Done for the report (a little bit late). Will tel you!