diff options
author | deanm@google.com <deanm@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-18 13:22:29 +0000 |
---|---|---|
committer | deanm@google.com <deanm@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-18 13:22:29 +0000 |
commit | 7cb98a23d0be29c2b5ceafa6f9e4b1d8e98cd282 (patch) | |
tree | 9f894876d4b969f318d84e354dbce20430968ec3 /build/SConscript.main | |
parent | e1233274b5b187b4afd7392aaa062525f32c380c (diff) | |
download | chromium_src-7cb98a23d0be29c2b5ceafa6f9e4b1d8e98cd282.zip chromium_src-7cb98a23d0be29c2b5ceafa6f9e4b1d8e98cd282.tar.gz chromium_src-7cb98a23d0be29c2b5ceafa6f9e4b1d8e98cd282.tar.bz2 |
Add a COVERAGE=1 argument to the Linux scons build. This compiles the object files with support for gcov.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@983 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build/SConscript.main')
-rw-r--r-- | build/SConscript.main | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/build/SConscript.main b/build/SConscript.main index 3f7623f..eb18a5f 100644 --- a/build/SConscript.main +++ b/build/SConscript.main @@ -338,6 +338,10 @@ elif env['PLATFORM'] == 'posix': # We need pthread for threading, and rt for clock_gettime. LIBS = ['pthread', 'rt'], ) + # Build with support for gcov when COVERAGE=1. + if ARGUMENTS.get('COVERAGE') == '1': + env.Append(CCFLAGS=['-fprofile-arcs', '-ftest-coverage']) + env.Append(LINKFLAGS=['-fprofile-arcs']) else: |