MCPcopy Create free account
hub / github.com/facebook/SoLoader / addApplicationSoSource

Method addApplicationSoSource

java/com/facebook/soloader/SoLoader.java:495–509  ·  view source on GitHub ↗

Add a DirectorySoSource for the application's nativeLibraryDir .

(ArrayList<SoSource> soSources, int flags)

Source from the content-addressed store, hash-verified

493
494 /** Add a DirectorySoSource for the application's nativeLibraryDir . */
495 private static void addApplicationSoSource(ArrayList<SoSource> soSources, int flags) {
496
497 // On old versions of Android, Bionic doesn't add our library directory to its
498 // internal search path, and the system doesn't resolve dependencies between
499 // modules we ship. On these systems, we resolve dependencies ourselves. On other
500 // systems, Bionic's built-in resolver suffices.
501
502 if (Build.VERSION.SDK_INT <= Build.VERSION_CODES.JELLY_BEAN_MR1) {
503 flags |= DirectorySoSource.RESOLVE_DEPENDENCIES;
504 }
505
506 SoSource applicationSoSource = new ApplicationSoSource(sApplicationContext, flags);
507 LogUtil.d(TAG, "Adding application source: " + applicationSoSource.toString());
508 soSources.add(0, applicationSoSource);
509 }
510
511 /** Add the SoSources for recovering the dso if the file is corrupted or missed */
512 @SuppressLint("CatchGeneralException")

Callers 1

initSoSourcesMethod · 0.95

Calls 2

dMethod · 0.95
toStringMethod · 0.95

Tested by

no test coverage detected