diff options
Diffstat (limited to 'source/Host/posix/HostInfoPosix.cpp')
-rw-r--r-- | source/Host/posix/HostInfoPosix.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/source/Host/posix/HostInfoPosix.cpp b/source/Host/posix/HostInfoPosix.cpp index 77fdc2b61a316..018d423ee9d35 100644 --- a/source/Host/posix/HostInfoPosix.cpp +++ b/source/Host/posix/HostInfoPosix.cpp @@ -69,6 +69,7 @@ HostInfoPosix::LookupUserName(uint32_t uid, std::string &user_name) const char * HostInfoPosix::LookupGroupName(uint32_t gid, std::string &group_name) { +#ifndef __ANDROID__ char group_buffer[PATH_MAX]; size_t group_buffer_size = sizeof(group_buffer); struct group group_info; @@ -94,6 +95,9 @@ HostInfoPosix::LookupGroupName(uint32_t gid, std::string &group_name) } } group_name.clear(); +#else + assert(false && "getgrgid_r() not supported on Android"); +#endif return NULL; } @@ -121,6 +125,12 @@ HostInfoPosix::GetEffectiveGroupID() return getegid(); } +FileSpec +HostInfoPosix::GetDefaultShell() +{ + return FileSpec("/bin/sh", false); +} + bool HostInfoPosix::ComputeSupportExeDirectory(FileSpec &file_spec) { @@ -173,6 +183,7 @@ HostInfoPosix::ComputeHeaderDirectory(FileSpec &file_spec) bool HostInfoPosix::ComputePythonDirectory(FileSpec &file_spec) { +#ifndef LLDB_DISABLE_PYTHON FileSpec lldb_file_spec; if (!GetLLDBPath(lldb::ePathTypeLLDBShlibDir, lldb_file_spec)) return false; @@ -190,4 +201,7 @@ HostInfoPosix::ComputePythonDirectory(FileSpec &file_spec) file_spec.GetDirectory().SetCString(raw_path); return true; +#else + return false; +#endif } |