[Owasp-esapi-c++] make targets and goals

David Anderson david.anderson at aspectsecurity.com
Mon Aug 8 20:32:13 EDT 2011


I think I agree with everything you proposed.  One other debug option that may be handy is the libstdc++ debug mode:

http://gcc.gnu.org/onlinedocs/libstdc++/manual/debug_mode.html

Also, we'll need to integrate Purify into the makefile, when we get it.

-David


-----Original Message-----
From: owasp-esapi-c++-bounces at lists.owasp.org on behalf of Jeffrey Walton
Sent: Mon 8/8/2011 7:23 PM
To: ESAPI C++ List
Subject: [Owasp-esapi-c++] make targets and goals
 
Hi All,

KW and I had a sidebar on make targets and goals. See
https://code.google.com/p/owasp-esapi-cplusplus/issues/detail?id=3.

The short of targets and goals is that we want three:
* Debug when working under the debugger
* Release for production
* Test for boost test cases against Release

All of the above cases will offer symbols (ie, -g). Symbols are
separate form Debug in my minds eye. And symbols do not penalize an
executable: "How does the gcc -g option affect performance?",
http://gcc.gnu.org/ml/gcc-help/2005-03/msg00032.html.

The predominant difference between Debug and Release is
-DEBUG/-NDEBUG, which affects the ASSERT macro. Next is optimization
levels: Debug = O0, and Release = O2.

With the three cases in mind, here's what I propose:

`make` => build release DSO and run test. ASSERT does nothing.
`make debug` => build debug DSO and run test. ASSERT snaps debugger.
`make release` =>  build release DSO and run test. ASSERT does nothing.
'make all` => build release ARCHIVE, DSO, and test. ASSERT does nothing.
`make test` => build release DSO and run test. ASSERT does nothing.
`make check` => same as `make test`

In addition, we can current test compile subsystems without a final
link. This is good for a quick compile or smaoke test. For example,
Kevin and I use `make crypto` to build the crypto sources only.
Currently, other goals include `make codecs` and `make errors`. These
targets can be easily added as logical groups appears in the sources.

Any thoughts?

Jeff
_______________________________________________
Owasp-esapi-c++ mailing list
Owasp-esapi-c++ at lists.owasp.org
https://lists.owasp.org/mailman/listinfo/owasp-esapi-c++

-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://lists.owasp.org/pipermail/owasp-esapi-c++/attachments/20110808/9f9fd9f9/attachment.html 


More information about the Owasp-esapi-c++ mailing list