diff options
author | Nicolas Geoffray <ngeoffray@google.com> | 2014-02-07 18:33:04 +0000 |
---|---|---|
committer | Nicolas Geoffray <ngeoffray@google.com> | 2014-02-12 09:54:40 +0000 |
commit | 1f5a90f28443886ebefcfbd531b8e41ece298cca (patch) | |
tree | 55aa67a2549526ed14d51092663be0fd9803ba19 /runtime/runtime.cc | |
parent | a52214230ad091359956ed7566670963aedf2045 (diff) | |
download | art-1f5a90f28443886ebefcfbd531b8e41ece298cca.zip art-1f5a90f28443886ebefcfbd531b8e41ece298cca.tar.gz art-1f5a90f28443886ebefcfbd531b8e41ece298cca.tar.bz2 |
Add a script for running art standalone.
Change-Id: I0c48856d811c40662a6e4a4782478a0bc8e0f697
Diffstat (limited to 'runtime/runtime.cc')
-rw-r--r-- | runtime/runtime.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/runtime/runtime.cc b/runtime/runtime.cc index 4e90478..86fae82 100644 --- a/runtime/runtime.cc +++ b/runtime/runtime.cc @@ -754,6 +754,12 @@ Runtime::ParsedOptions* Runtime::ParsedOptions::Create(const Options& options, b parsed->image_ += GetAndroidRoot(); parsed->image_ += "/framework/boot.art"; } + if (!kIsTargetBuild && parsed->host_prefix_.empty()) { + const char* build_top = getenv("ANDROID_BUILD_TOP"); + if (build_top != NULL) { + parsed->host_prefix_ = build_top; + } + } if (parsed->heap_growth_limit_ == 0) { parsed->heap_growth_limit_ = parsed->heap_maximum_size_; } @@ -823,7 +829,7 @@ jobject CreateSystemClassLoader() { bool Runtime::Start() { VLOG(startup) << "Runtime::Start entering"; - CHECK(host_prefix_.empty()) << host_prefix_; + CHECK(!kIsTargetBuild || host_prefix_.empty()) << host_prefix_; // Restore main thread state to kNative as expected by native code. Thread* self = Thread::Current(); |