Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fa37ec0a authored by Bo Hu's avatar Bo Hu Committed by Android (Google) Code Review
Browse files

Merge "mediacas: make it also work on 64bit only guest" into sc-dev

parents 24a732cd b305c804
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@ cc_defaults {
      "TypeConvert.cpp",
    ],

    compile_multilib: "32",
    compile_multilib: "prefer32",

    shared_libs: [
      "android.hardware.cas@1.0",
+10 −0
Original line number Diff line number Diff line
@@ -92,7 +92,12 @@ bool FactoryLoader<T>::findFactoryForScheme(
    }

    // no luck, have to search
#ifdef __LP64__
    String8 dirPath("/vendor/lib64/mediacas");
#else
    String8 dirPath("/vendor/lib/mediacas");
#endif

    DIR* pDir = opendir(dirPath.string());

    if (pDir == NULL) {
@@ -127,7 +132,12 @@ bool FactoryLoader<T>::enumeratePlugins(

    results->clear();

#ifdef __LP64__
    String8 dirPath("/vendor/lib64/mediacas");
#else
    String8 dirPath("/vendor/lib/mediacas");
#endif

    DIR* pDir = opendir(dirPath.string());

    if (pDir == NULL) {
+1 −1
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@ cc_defaults {
      "TypeConvert.cpp",
    ],

    compile_multilib: "32",
    compile_multilib: "prefer32",

    shared_libs: [
      "android.hardware.cas@1.0",
+8 −0
Original line number Diff line number Diff line
@@ -85,7 +85,11 @@ bool FactoryLoader<T>::findFactoryForScheme(int32_t CA_system_id, sp<SharedLibra
    }

    // no luck, have to search
#ifdef __LP64__
    String8 dirPath("/vendor/lib64/mediacas");
#else
    String8 dirPath("/vendor/lib/mediacas");
#endif
    DIR* pDir = opendir(dirPath.string());

    if (pDir == NULL) {
@@ -118,7 +122,11 @@ bool FactoryLoader<T>::enumeratePlugins(vector<HidlCasPluginDescriptor>* results

    results->clear();

#ifdef __LP64__
    String8 dirPath("/vendor/lib64/mediacas");
#else
    String8 dirPath("/vendor/lib/mediacas");
#endif
    DIR* pDir = opendir(dirPath.string());

    if (pDir == NULL) {
+1 −1
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@ cc_defaults {
      "TypeConvert.cpp",
    ],

    compile_multilib: "32",
    compile_multilib: "prefer32",

    shared_libs: [
      "android.hardware.cas@1.0",
Loading