Only append suffixes to dex2oat(d) on host.

Amends https://r.android.com/1235151 which broke target testing.

Also move the logic for the --host argument out of the argument parsing
loop to work correctly if it's specified multiple times.

Test: art/test/testrunner/testrunner.py --target --64 -t 641-checker-arraycopy
  (in ART test chroot)
Test: lunch sdk-eng && art/tools/buildbot-build.sh --host && \
  art/test/run-test --host --optimizing 641-checker-arraycopy
  (with and without HOST_PREFER_32_BIT=true)
Bug: 148372405

Change-Id: I64277db1a99ed409696dc8aae2f1982fc2a14c9d
1 file changed