Auto merge of #21767 - jdm:androidlog, r=paulrouget

Enable use of RUST_LOG with mach run --android.

This allows running `RUST_LOG=layout_thread ./mach run --android` and seeing the appropriate logging output appear in `./adb logcat`.

---
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [x] These changes fix #21764

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/21767)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2018-09-21 06:18:58 -04:00 committed by GitHub
commit f313847b6b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 31 additions and 15 deletions

View file

@ -99,6 +99,9 @@ class PostBuildCommands(CommandBase):
]
json_params = shell_quote(json.dumps(params))
extra = "-e servoargs " + json_params
rust_log = env.get("RUST_LOG", None)
if rust_log:
extra += " -e servolog " + rust_log
script += [
"am start " + extra + " com.mozilla.servo/com.mozilla.servo.MainActivity",
"sleep 0.5",