Merge b37ba316643bcfa2b4893f25f0578e23077b1172 on remote branch

Change-Id: I505ed201ee1f01ce2f4555106e24092aaa1bed30
diff --git a/dist/Android.bp b/dist/Android.bp
index 414c84d..3bb9a10 100644
--- a/dist/Android.bp
+++ b/dist/Android.bp
@@ -38,9 +38,13 @@
         "-DSQLITE_SECURE_DELETE",
         "-DSQLITE_ENABLE_BATCH_ATOMIC_WRITE",
         "-DBIONIC_IOCTL_NO_SIGNEDNESS_OVERLOAD",
+        "-DSQLITE_DEFAULT_LEGACY_ALTER_TABLE",
         "-Wno-unused-parameter",
         "-Werror",
 
+        // Default value causes sqlite3_open_v2 to return error if DB is missing.
+        "-ftrivial-auto-var-init=pattern",
+
         // Turn off the new pass manager due to miscompile.
         // http://b/131854833
         "-fno-experimental-new-pass-manager",