Tamas Berghammer | 00e305d | 2015-02-12 18:13:44 +0000 | [diff] [blame] | 1 | //===-- HostInfoAndroid.cpp -------------------------------------*- C++ -*-===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | |
| 10 | #include "lldb/Host/android/HostInfoAndroid.h" |
| 11 | #include "lldb/Host/linux/HostInfoLinux.h" |
| 12 | |
| 13 | using namespace lldb_private; |
| 14 | |
| 15 | void |
| 16 | HostInfoAndroid::ComputeHostArchitectureSupport(ArchSpec &arch_32, ArchSpec &arch_64) |
| 17 | { |
| 18 | HostInfoLinux::ComputeHostArchitectureSupport(arch_32, arch_64); |
| 19 | |
| 20 | if (arch_32.IsValid()) |
| 21 | { |
| 22 | arch_32.GetTriple().setEnvironment(llvm::Triple::Android); |
| 23 | } |
| 24 | if (arch_64.IsValid()) |
| 25 | { |
| 26 | arch_64.GetTriple().setEnvironment(llvm::Triple::Android); |
| 27 | } |
| 28 | } |
Oleksiy Vyalov | fb9015d | 2015-02-26 02:50:14 +0000 | [diff] [blame] | 29 | |
| 30 | bool |
| 31 | HostInfoAndroid::ComputeSupportExeDirectory(FileSpec &file_spec) |
| 32 | { |
| 33 | file_spec.GetDirectory() = HostInfoLinux::GetProgramFileSpec().GetDirectory(); |
| 34 | return (bool)file_spec.GetDirectory(); |
| 35 | } |
Tamas Berghammer | bd05108 | 2015-03-03 12:14:45 +0000 | [diff] [blame^] | 36 | |
| 37 | FileSpec |
| 38 | HostInfoAndroid::GetDefaultShell() |
| 39 | { |
| 40 | return FileSpec("/system/bin/sh", false); |
| 41 | } |