'couldn't find ".so" in lib path, when using .aar file in another module which is added as dependency to app module

There are many questions related to this, but nothing works for me. I have a module which is added as dependency module to the app module. I added an .aar file to the gradle file of the dependency module and able to import all objects properly. But when running the app, it is crashing throwing this exception and it is mentioned that one ".so" file couldn't find on nativeLibraryDirectories=[/system/lib/clarotv_launcher_debug_3.2.5, /system/lib, /product/lib, /system/lib, /product/lib]]].

The .aar file added as dependency doesn't generate any lib folder structure . I tried adding the below code in my dependency module's gradle.

 implementation fileTree(dir: 'libs', include: ['*.aar','*.jar'])
implementation project(path: ':LicensedMulticastSolution')

  ndk {
        abiFilters  "armeabi", "mips" ,"arm64-v8a", "armeabi-v7a", "x86", "x86_64"
    }

I tried adding the same in app level gradle as well, but that too didn't work. I to resolve this issue? My requirement is as follows. there are 2 modules, app module and Module1. Module1 is added as a dependency to app. I want to use another .aar file to the Module1.

Any suggestions are appreciated



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source