Support to pass <uses-library> option through to dex2oat.

This change takes an app's shared libraries specified by <uses-library>
and passes it through to dex2oat to be used during compilation.

Part of a multi-project change.

Includes fix from c09662d9bbd35840b24cae8d336a0d11c0cbdb7b

Bug: 26880306

(cherry-picked from commmit de7f0cf8a699f6f7a7d29b4a14d800bea9abbef4)

Change-Id: Ideb2aba46f4cf52acb9dd480993513a60dbfd6ce
diff --git a/cmds/installd/otapreopt.cpp b/cmds/installd/otapreopt.cpp
index 245694a..ac511ec 100644
--- a/cmds/installd/otapreopt.cpp
+++ b/cmds/installd/otapreopt.cpp
@@ -365,7 +365,8 @@
                 package_parameters_[5],                   // oat_dir
                 atoi(package_parameters_[6]),             // dexopt_flags
                 package_parameters_[7],                   // compiler_filter
-                ParseNull(package_parameters_[8]));       // volume_uuid
+                ParseNull(package_parameters_[8]),        // volume_uuid
+                ParseNull(package_parameters_[9]));       // shared_libraries
         return ret;
     }
 
@@ -483,7 +484,7 @@
     // to compile, instead of the A properties we could get from init/get_property.
     SystemProperties system_properties_;
 
-    const char* package_parameters_[9];
+    const char* package_parameters_[10];
 
     // Store environment values we need to set.
     std::vector<std::string> environ_;