From d8b6060f045d93d6b0cfb6a0d8e80fc100df1749 Mon Sep 17 00:00:00 2001 From: "glider@chromium.org" Date: Fri, 26 Mar 2010 09:41:22 +0000 Subject: Add the linux_use_heapchecker GYP variable that should turn the tcmalloc heap lleak checker on and off. Review URL: http://codereview.chromium.org/1334002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42740 0039d316-1c4b-4281-b951-d872f2087c98 --- base/allocator/allocator.gyp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'base/allocator') diff --git a/base/allocator/allocator.gyp b/base/allocator/allocator.gyp index 0734d2e..b8df28f 100644 --- a/base/allocator/allocator.gyp +++ b/base/allocator/allocator.gyp @@ -332,9 +332,19 @@ # Do the same for heap leak checker. '-Wl,-u_Z21InitialMallocHook_NewPKvj,-u_Z22InitialMallocHook_MMapPKvS0_jiiix,-u_Z22InitialMallocHook_SbrkPKvi', '-Wl,-u_Z21InitialMallocHook_NewPKvm,-u_Z22InitialMallocHook_MMapPKvS0_miiil,-u_Z22InitialMallocHook_SbrkPKvl', + ]}, + }], + [ 'linux_use_heapchecker==0', { + # Do not compile and link the heapchecker source. + 'sources!': [ + '<(tcmalloc_dir)/src/heap-checker-bcad.cc', + '<(tcmalloc_dir)/src/heap-checker.cc', ], - }, - }], + # Disable the heap checker in tcmalloc. + 'cflags': [ + '-DNO_HEAP_CHECK', + ], + }], ], }, { -- cgit v1.1