diff options
author | Ben Murdoch <benm@google.com> | 2010-07-29 17:14:53 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2010-08-04 14:29:45 +0100 |
commit | c407dc5cd9bdc5668497f21b26b09d988ab439de (patch) | |
tree | 7eaf8707c0309516bdb042ad976feedaf72b0bb1 /base/allocator/allocator.gyp | |
parent | 0998b1cdac5733f299c12d88bc31ef9c8035b8fa (diff) | |
download | external_chromium-c407dc5cd9bdc5668497f21b26b09d988ab439de.zip external_chromium-c407dc5cd9bdc5668497f21b26b09d988ab439de.tar.gz external_chromium-c407dc5cd9bdc5668497f21b26b09d988ab439de.tar.bz2 |
Merge Chromium src@r53293
Change-Id: Ia79acf8670f385cee48c45b0a75371d8e950af34
Diffstat (limited to 'base/allocator/allocator.gyp')
-rw-r--r-- | base/allocator/allocator.gyp | 62 |
1 files changed, 37 insertions, 25 deletions
diff --git a/base/allocator/allocator.gyp b/base/allocator/allocator.gyp index fe1aae8..a1ad04d 100644 --- a/base/allocator/allocator.gyp +++ b/base/allocator/allocator.gyp @@ -57,7 +57,8 @@ '<(tcmalloc_dir)/src/base/basictypes.h', '<(tcmalloc_dir)/src/base/commandlineflags.h', '<(tcmalloc_dir)/src/base/cycleclock.h', - '<(tcmalloc_dir)/src/base/dynamic_annotations.cc', + # We don't list dynamic_annotations.c since its copy is already + # present in the dynamic_annotations target. '<(tcmalloc_dir)/src/base/dynamic_annotations.h', '<(tcmalloc_dir)/src/base/elfcore.h', '<(tcmalloc_dir)/src/base/googleinit.h', @@ -145,12 +146,10 @@ '<(tcmalloc_dir)/src/static_vars.h', '<(tcmalloc_dir)/src/symbolize.cc', '<(tcmalloc_dir)/src/symbolize.h', - '<(tcmalloc_dir)/src/symbolize_linux.cc', '<(tcmalloc_dir)/src/system-alloc.cc', '<(tcmalloc_dir)/src/system-alloc.h', '<(tcmalloc_dir)/src/tcmalloc.cc', '<(tcmalloc_dir)/src/tcmalloc_guard.h', - '<(tcmalloc_dir)/src/tcmalloc_linux.cc', '<(tcmalloc_dir)/src/thread_cache.cc', '<(tcmalloc_dir)/src/thread_cache.h', '<(tcmalloc_dir)/src/windows/config.h', @@ -186,10 +185,6 @@ # Included by allocator_shim.cc for maximal inlining. 'generic_allocators.cc', 'win_allocator.cc', - '<(tcmalloc_dir)/src/tcmalloc.cc', - - # Unneeded on Windows, symbolize_linux.cc used there instead. - '<(tcmalloc_dir)/src/symbolize.cc', # We simply don't use these, but list them above so that IDE # users can view the full available source for reference, etc. @@ -212,7 +207,6 @@ '<(tcmalloc_dir)/src/base/spinlock_win32-inl.h', '<(tcmalloc_dir)/src/base/stl_allocator.h', '<(tcmalloc_dir)/src/base/thread_annotations.h', - '<(tcmalloc_dir)/src/debugallocation.cc', '<(tcmalloc_dir)/src/getpc.h', '<(tcmalloc_dir)/src/google/heap-checker.h', '<(tcmalloc_dir)/src/google/heap-profiler.h', @@ -249,12 +243,15 @@ '<(tcmalloc_dir)/src/windows/preamble_patcher.h', '<(tcmalloc_dir)/src/windows/preamble_patcher_with_stub.cc', ], + 'dependencies': [ + '../third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations', + ], 'msvs_settings': { # TODO(sgk): merge this with build/common.gypi settings 'VCLibrarianTool=': { 'AdditionalOptions': ['/ignore:4006,4221'], 'AdditionalLibraryDirectories': - ['<(DEPTH)/third_party/platformsdk_win2008_6_1/files/Lib'], + ['<(DEPTH)/third_party/platformsdk_win7/files/Lib'], }, 'VCLinkerTool': { 'AdditionalOptions': ['/ignore:4006'], @@ -291,9 +288,8 @@ '<(tcmalloc_dir)/src/system-alloc.cc', '<(tcmalloc_dir)/src/system-alloc.h', - # don't use linux forked version - '<(tcmalloc_dir)/src/tcmalloc_linux.cc', - '<(tcmalloc_dir)/src/symbolize_linux.cc', + # included by allocator_shim.cc + '<(tcmalloc_dir)/src/tcmalloc.cc', # heap-profiler/checker/cpuprofiler '<(tcmalloc_dir)/src/base/thread_lister.c', @@ -308,6 +304,9 @@ '<(tcmalloc_dir)/src/profile-handler.cc', '<(tcmalloc_dir)/src/profile-handler.h', '<(tcmalloc_dir)/src/profiler.cc', + + # debugallocation + '<(tcmalloc_dir)/src/debugallocation.cc', ], }], ['OS=="linux" or OS=="freebsd" or OS=="openbsd"', { @@ -327,17 +326,6 @@ '<(jemalloc_dir)/qr.h', '<(jemalloc_dir)/rb.h', - # TODO(willchan): Return to using this when page_heap_linux.cc - # becomes unnecessary. - '<(tcmalloc_dir)/src/page_heap.cc', - ], - # TODO(willchan): This is actually just a branched copy of the - # vanilla upstream page_heap.cc. The current forked copy of - # page_heap.cc has Windows-specific code in it so Linux can't - # use it. These need to be refactored so we can track changes - # to the upstream page_heap.cc without duplication. - 'sources': [ - '<(tcmalloc_dir)/src/page_heap_linux.cc', ], 'cflags!': [ '-fvisibility=hidden', @@ -350,8 +338,32 @@ # 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_debugallocation==1', { + 'sources!': [ + # debugallocation.cc #includes tcmalloc.cc, + # so only one of them should be used. + '<(tcmalloc_dir)/src/tcmalloc.cc', + ], + 'cflags': [ + '-DTCMALLOC_FOR_DEBUGALLOCATION', + ], + }, { # linux_use_debugallocation != 1 + 'sources!': [ + '<(tcmalloc_dir)/src/debugallocation.cc', + ], + }], + [ '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', + ], }], ], }, |