On Sat, 27 Mar 2010, Steve Searle wrote:

I have started using autotools for the C++ applications I create (very
much as an amateur). I typically use assert statements during
development, and would disable these by using -DNDEBUG when the release
version is built. How should I configure things so that when a user
installs from the tarball they compile by default with the -DNDEBUG
option?

Do you actually see a performance difference from adding -DNDEBUG? In GraphicsMagick (which uses many assertions) I did not see a tangible performance difference so I did not worry about it.

The Autoconf default is already to compile with debug enabled so it seems that leaving assertions enabled by default is also a reasonable default.

Bob
--
Bob Friesenhahn
[email protected], http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/


_______________________________________________
Autoconf mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/autoconf

Reply via email to