Add settings.gradle if not present in app folder

After updating to gradle 5.2 we now have a settings.gradle file in the
root of r8. Gradle will automagically look up in the tree for a
settings file and throw an error when the apps are placed under the
$R8/build directory.

Change-Id: I69bfd818b245ac5cb92800d989acd0989e76612d
diff --git a/tools/run_on_as_app.py b/tools/run_on_as_app.py
index d6dd647..ef72d12 100755
--- a/tools/run_on_as_app.py
+++ b/tools/run_on_as_app.py
@@ -394,6 +394,11 @@
       shrinker,
       ' for recompilation' if keepRuleSynthesisForRecompilation else ''))
 
+  # Add settings.gradle file if it is not present to prevent gradle from finding
+  # the settings.gradle file in the r8 root when apps are placed under
+  # $R8/build.
+  as_utils.add_settings_gradle(checkout_dir, app)
+
   # Add 'r8.jar' from top-level build.gradle.
   as_utils.add_r8_dependency(checkout_dir, temp_dir, IsMinifiedR8(shrinker))