Support use_glib==0 on Linux in base

This makes base build on Linux when use_glib is set to 0. The only glib
bits we are currently using in that configuration are g_get_home_dir()
and g_try_malloc().

Use of g_get_home_dir() is not essential. Without glib, we can just rely
on the $HOME environment variable always.

Use of g_try_malloc() is just a way to cause a large memory allocation
from a shared library. We can achieve the same effect using asprintf().

BUG=318315, 318413, 170408

Review URL: https://codereview.chromium.org/69953025

git-svn-id: http://src.chromium.org/svn/trunk/src/build@236162 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
This commit is contained in:
spang@chromium.org 2013-11-20 05:33:46 +00:00
Родитель 9b0e2cbaf0
Коммит ca44c657e1
1 изменённых файлов: 3 добавлений и 0 удалений

Просмотреть файл

@ -2065,6 +2065,9 @@
['use_cras==1', {
'defines': ['USE_CRAS=1'],
}],
['use_glib==1', {
'defines': ['USE_GLIB=1'],
}],
['use_ozone==1', {
'defines': ['USE_OZONE=1'],
}],