Clean up log initialization

- Make sure RuntimeInit.redirectLogStreams() is always called even
  without RavenwoodRule is used.

- In RuntimeInit.redirectLogStreams(), make sure the Log class is
  initialized properly before setting up the redirect. Otherwise,
  we'd end up trying to use the Log APIs before the Log native code
  is loaded, which would cause an UnsatisfiedLinkError.

- Use $RAVENWOOD_VERBOSE_LOGGING to force enable verbose logging.
  If it's not set, the normal $ANDROID_LOG_TAGS would be used.

Fix: 363315644
Test: $ANDROID_BUILD_TOP/frameworks/base/ravenwood/scripts/run-ravenwood-tests.sh
Flag: EXEMPT host test change only

Change-Id: Ifa4e4859c39380ebb3500cfb6570dfb78f839c0a
9 files changed