scons: Try to use 'tcmalloc' before 'tcmalloc_minimal'
tcmalloc_minimal doesn't support the heap checker on Debian, while tcmalloc does. Instead of always linking with tcmalloc_minimal, if it exists, we first check for tcmalloc and then use tcmalloc_minimal as a fallback.
This commit is contained in:
parent
468ad10f50
commit
e28e6246fc
1 changed files with 3 additions and 1 deletions
|
@ -925,7 +925,9 @@ have_posix_clock = \
|
|||
conf.CheckLibWithHeader('rt', 'time.h', 'C',
|
||||
'clock_nanosleep(0,0,NULL,NULL);')
|
||||
|
||||
if conf.CheckLib('tcmalloc_minimal'):
|
||||
if conf.CheckLib('tcmalloc'):
|
||||
main.Append(CCFLAGS=main['TCMALLOC_CCFLAGS'])
|
||||
elif conf.CheckLib('tcmalloc_minimal'):
|
||||
main.Append(CCFLAGS=main['TCMALLOC_CCFLAGS'])
|
||||
else:
|
||||
print termcap.Yellow + termcap.Bold + \
|
||||
|
|
Loading…
Reference in a new issue