Skip to content

Commit

Permalink
use debug=1 instead of ndebug=0
Browse files Browse the repository at this point in the history
  • Loading branch information
tokuhirom committed Apr 10, 2012
1 parent 0a4cad1 commit c26d11d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
1 change: 1 addition & 0 deletions README.EXT.mkdn
Expand Up @@ -6,4 +6,5 @@ Notes

* You can wrap a C++ level pointer to the PointerValue. Do not use IntValue, it's not portable.
* You must return the value instance from each methods. You must not return NULL. It cause segv.
* You can use 'scons debug=1' for debugging

10 changes: 3 additions & 7 deletions SConstruct
Expand Up @@ -127,15 +127,11 @@ if ARGUMENTS.get('profile', 0):
env.Append(CXXFLAGS=['-pg', '-Dprofile'])
env.Append(LINKFLAGS=['-pg'])

if ARGUMENTS.get('ndebug', 1) != '0':
if ARGUMENTS.get('debug', 0):
env.Append(CCFLAGS=['-O0'])
else:
env.Append(CCFLAGS=['-DNDEBUG'])
env.Append(CCFLAGS=['-O2'])
else:
env.Append(CCFLAGS=['-O0'])

# scons debug=1
if ARGUMENTS.get('debug', 0):
env.Append(CCFLAGS=['-g'])

re2files = [
Glob('vendor/re2/re2/*.cc'),
Expand Down

0 comments on commit c26d11d

Please sign in to comment.