Issue with EPSON, couldn't find "libepos2.so" - android

EPSON network printer was working perfect until I integrated mSwipe(Card Swiper) with my Android App.
After integration now mSwipe working perfectly but everything about EPSON is crashing.
libepos2.so is there in src/main/jniLibs/armeabi/libepos2.so but still it says couldn't find.
log below:
FATAL EXCEPTION: main
Process: com.intuition.dine.ivepos, PID: 10908
java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.intuition.dine.ivepos-1/base.apk"],nativeLibraryDirectories=[/data/app/com.intuition.dine.ivepos-1/lib/arm, /data/app/com.intuition.dine.ivepos-1/base.apk!/lib/armeabi-v7a, /system/lib, /vendor/lib]]] couldn't find "libepos2.so"
at java.lang.Runtime.loadLibrary0(Runtime.java:972)
at java.lang.System.loadLibrary(System.java:1567)
at com.epson.epos2.discovery.Discovery.<clinit>(Discovery.java:20)
at com.epson.epos2.discovery.Discovery.start(Discovery.java)
at com.intuition.dine.ivepos.SearchIPActivity.onCreate(SearchIPActivity.java:191)
at android.app.Activity.performCreate(Activity.java:6955)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1126)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2927)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3045)
at android.app.ActivityThread.-wrap14(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1642)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6776)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1496)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1386)
Any help would be appreciated.

Solved : I have some more .so files which are inside app/libs/armeabi.
So, I moved them to app/src/main/jniLibs (Just like below Image)
Also, below code in app level Gradle inside defaultconfig{}
ndk {
abiFilters "armeabi"
}
And
android{
splits {
abi {
enable true
reset()
universalApk true
}
}
}
This worked like charm.

I tried everything in the answers here (and from other questions on stackoverflow), but the only fix for me was making a folder in app/src/main/jniLibs called armeabi-v7a and copying the so files from armeabi to it.

Add this to your app level gradle file, clean, rebuild and try again.
android {
//Other stuff here
splits {
abi {
enable true
reset()
universalApk true
}
}
}

Related

Android java.lang.ClassNotFoundException: Didn't find class

I'm a total Android newbie here, so hopefully someone can help me out.
I have an Android library (myLib.aar) that I am including/using in the HelloAR demo app.
Now, I want to use Instacapture within myLib.aar. I followed the instructions on the README:
dependencies {
...
compile "com.github.tarek360:instacapture:2.0.1"
}
allprojects {
repositories {
...
maven { url "https://jitpack.io" }
}
}
I also tried downloading, compiling instacapture source, adding the instacapture.aar to my libs dir and modifying my Gradle files:
dependencies{
...
implementation(name:'instacapture', ext:'aar')
}
allprojects {
repositories {
...
flatDir {
dirs 'libs'
}
}
In both cases, I get the following exception:
--------- beginning of crash
2020-08-11 22:34:35.965 32761-32761/com.google.ar.core.examples.java.helloar E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.google.ar.core.examples.java.helloar, PID: 32761
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/tarek360/instacapture/Instacapture;
at com.cambridge.myLib.ScreenShotter.takeScreenshot(ScreenShotter.java:139)
at com.google.ar.core.examples.java.helloar.HelloArActivity$2.run(HelloArActivity.java:164)
at com.google.ar.core.examples.java.helloar.HelloArActivity.startRepeatingTask(HelloArActivity.java:171)
at com.google.ar.core.examples.java.helloar.HelloArActivity$1.run(HelloArActivity.java:152)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:237)
at android.app.ActivityThread.main(ActivityThread.java:8107)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:496)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1100)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.tarek360.instacapture.Instacapture" on path: DexPathList[[zip file "/data/app/com.google.ar.core.examples.java.helloar-bhCcJ--GEjsJ6mxAFvnUYw==/base.apk"],nativeLibraryDirectories=[/data/app/com.google.ar.core.examples.java.helloar-bhCcJ--GEjsJ6mxAFvnUYw==/lib/arm64, /data/app/com.google.ar.core.examples.java.helloar-bhCcJ--GEjsJ6mxAFvnUYw==/base.apk!/lib/arm64-v8a, /system/lib64]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:196)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
at com.cambridge.myLib.ScreenShotter.takeScreenshot(ScreenShotter.java:139)
at com.google.ar.core.examples.java.helloar.HelloArActivity$2.run(HelloArActivity.java:164)
at com.google.ar.core.examples.java.helloar.HelloArActivity.startRepeatingTask(HelloArActivity.java:171)
at com.google.ar.core.examples.java.helloar.HelloArActivity$1.run(HelloArActivity.java:152)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:237)
at android.app.ActivityThread.main(ActivityThread.java:8107)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:496)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1100)
However, if I add the dependencies to the main HelloAR app (as per the instructions in the README), the issue resolves.
Can someone please explain what is going on, why I'm getting the error, and how to resolve it without having to add the dependencies to the main HelloAR app?
Considering your quote,
I'm a total Android newbie here, so hopefully someone can help me out.
Follow these steps (in android studio) :
Go to build menu.
Clean the project by clicking on clean project.
Build the project by clicking on make project.
This process is known as clean build which is usually done after adding some dependencies.

E/Unity: Unable to find main

I am using Unity in combination with a custom NDK-Library, inside my app.
My problem is that if I try to start the Activity hosting Unity, the process always crashes with the message:
E/Unity: Unable to find main
and a alertBox from Unity:
Title:Failure to initialize!
Message: Your hardware doesn't support this Application
After some trying arround, I got the solution that I have to add the following into my gradle File:
android{
...
defaultConfig{
...
ndk {
abiFilters 'armeabi-v7a', 'x86'
}
}
...
}
after doing this Unity runs without Errors, but when I start an Activity housing my own NDK-Library it crashes with the Error.
Caused by: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/de.biosign.daimlerhrv-2/base.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_dependencies_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_0_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_1_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_2_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_3_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_4_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_5_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_6_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_7_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_8_apk.apk", zip file "/data/app/de.biosign.daimlerhrv-2/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/de.biosign.daimlerhrv-2/lib/arm64, /system/lib64, /vendor/lib64, /system/vendor/lib64]]] couldn't find "libMyLib.so"
at java.lang.Runtime.loadLibrary0(Runtime.java:972)
at java.lang.System.loadLibrary(System.java:1530)
at de.biosign.sessioncomponents.session.RunningSession.<clinit>(RunningSession.java:34)
at de.biosign.mvc.session.sessionController.SessionController.<init>(SessionController.java:63)
at de.biosign.biofeedbackunity.BiofeedbackUnity.onCreate(BiofeedbackUnity.java:109)
at android.app.Activity.performCreate(Activity.java:6666)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1118)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2677)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2789)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1527)
at android.os.Handler.dispatchMessage(Handler.java:110)
at android.os.Looper.loop(Looper.java:203)
at android.app.ActivityThread.main(ActivityThread.java:6251)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1063)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:924)
Has anyone got a solution for this problem and can give me a Hint.
Thanks
According to your error logs
Caused by: java.lang.UnsatisfiedLinkError: ...... /system/lib64, /vendor/lib64, /system/vendor/lib64
It looks your device is 64-bit. But your abiFilters 'armeabi-v7a', 'x86' is only for 32-bit.
So, the possible solution to your problems may be as below adding 64-bit ABIs into the abiFilters:
abiFilters 'armeabi-v7a', 'x86', 'arm64-v8a', 'x86_64'
Cross check:
Android NDK - Using libraries compiled with a different API level
How do we identify libraries build with NDK is 64-bit supported?
The solution for me was to add the following to my Android.mk:
(See also at https://developer.android.com/ndk/guides/android_mk)
TARGET_ARCH : armeabi-v7a x86
so my libs became, generated for this architecture, it runs again beside Unity,
According to some posts newer Versions of above 2017.4 Unity already support 64 bits, but for my work am using 5.6, so can use this.
For others using 2017.4 or above there is the link:
https://developer.android.com/distribute/best-practices/develop/64-bit#unity_developers

Failed to load .so in android studio

I wanted to load a .so file: System.loadLibrary("example");
but i faced with this error!!
this is the error:
FATAL EXCEPTION: main
Process: com.name.ex, PID: 30737
java.lang.UnsatisfiedLinkError: dlopen failed: file offset for the library "/data/app/com.name.ex-1/lib/arm/example.so" >= file size: 0 >= 0
at java.lang.Runtime.loadLibrary(Runtime.java:372)
at java.lang.System.loadLibrary(System.java:1076)
at com.name.ex.example<clinit>(example.java:582)
at java.lang.Class.newInstance(Native Method)
at android.app.Instrumentation.newApplication(Instrumentation.java:1020)
at android.app.Instrumentation.newApplication(Instrumentation.java:1005)
at android.app.LoadedApk.makeApplication(LoadedApk.java:670)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6395)
at android.app.ActivityThread.access$1800(ActivityThread.java:229)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1887)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:7325)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
you might have placed the native assembly for ARM into the wrong directory ...or the file-size is indeed 0. it's ordinary called armeabi-v7a instead of arm, for example (the jniLibs path might need to be adjusted, depending how your project looks alike):
app/src/main/jniLibs/armeabi-v7a
in the module-level build.gradle one can define the location:
android {
...
sourceSets {
main {
jniLibs.srcDir "src/main/jniLibs"
}
}
}

gradle project dependency with MultiDex

I have two .aar files that I need to add to my project as dependencies. I imported the projects and did the following and it worked just fine.
dependencies {
compile project(':zoomcommonlib')
compile project(':zoomsdk')
}
However, I have added many other libraries and I had to use MultiDex library to support apps over 64K methods
dependencies {
compile 'com.android.support:multidex:1.0.1'
compile project(':zoomcommonlib')
compile project(':zoomsdk')
compile 'com.google.android.gms:play-services-maps:10.2.0'
compile 'com.google.android.gms:play-services-location:10.2.0'
.....
}
Yes, MultiDex is properly setup because I can build the application and run it with no problem.
The problem: When I try to utilize those specific projects, application crashes. Following Log:
18790-18790/com.mypackage.name E/UncaughtException: java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.mypackage.name-1/base.apk", zip file "/data/app/com.mypackage.name-1/split_lib_dependencies_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_0_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_1_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_2_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_3_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_4_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_5_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_6_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_7_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_8_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/com.mypackage.name-1/lib/arm64, /data/app/com.mypackage.name-1/base.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_dependencies_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_0_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_1_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_2_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_3_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_4_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_5_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_6_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_7_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_8_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_9_apk.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]] couldn't find "libzoom_stlport.so"
at java.lang.Runtime.loadLibrary0(Runtime.java:984)
at java.lang.System.loadLibrary(System.java:1530)
at com.zipow.cmmlib.AppContext.<clinit>(AppContext.java:31)
at com.zipow.cmmlib.AppContext.initialize(AppContext.java:64)
at us.zoom.sdk.ZoomSDK.initialize(ZoomSDK.java:225)
at us.zoom.sdk.ZoomSDK.initialize(ZoomSDK.java:184)
at com.mypackage.name.SectionListActivity.getInitializedZoomSDK(SectionListActivity.java:857)
at com.mypackage.name.SectionListActivity.access$1500(SectionListActivity.java:88)
at com.mypackage.name.SectionListActivity$8.onClick(SectionListActivity.java:812)
at android.view.View.performClick(View.java:5637)
at android.view.View$PerformClick.run(View.java:22429)
at android.os.Handler.handleCallback(Handler.java:751)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6119)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)
18790-18899/com.mypackage.name D/FA: Logging event (FE): _ae, Bundle[{_o=crash, _sc=SectionListActivity, _si=7450316610930895524, timestamp=1488996958198, fatal=1}]
18790-18899/com.mypackage.name V/FA: Using measurement service
18790-18899/com.mypackage.name V/FA: Connecting to remote service
--------- beginning of crash
18790-18790/com.mypackage.name E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.mypackage.name, PID: 18790
java.lang.UnsatisfiedLinkError: dalvik.system.PathClassLoader[DexPathList[[zip file "/data/app/com.mypackage.name-1/base.apk", zip file "/data/app/com.mypackage.name-1/split_lib_dependencies_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_0_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_1_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_2_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_3_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_4_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_5_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_6_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_7_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_8_apk.apk", zip file "/data/app/com.mypackage.name-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/com.mypackage.name-1/lib/arm64, /data/app/com.mypackage.name-1/base.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_dependencies_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_0_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_1_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_2_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_3_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_4_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_5_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_6_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_7_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_8_apk.apk!/lib/arm64-v8a, /data/app/com.mypackage.name-1/split_lib_slice_9_apk.apk!/lib/arm64-v8a, /system/lib64, /vendor/lib64]]] couldn't find "libzoom_stlport.so"
at java.lang.Runtime.loadLibrary0(Runtime.java:984)
at java.lang.System.loadLibrary(System.java:1530)
at com.zipow.cmmlib.AppContext.<clinit>(AppContext.java:31)
at com.zipow.cmmlib.AppContext.initialize(AppContext.java:64)
at us.zoom.sdk.ZoomSDK.initialize(ZoomSDK.java:225)
at us.zoom.sdk.ZoomSDK.initialize(ZoomSDK.java:184)
at com.mypackage.name.SectionListActivity.getInitializedZoomSDK(SectionListActivity.java:857)
at com.mypackage.name.SectionListActivity.access$1500(SectionListActivity.java:88)
at com.mypackage.name.SectionListActivity$8.onClick(SectionListActivity.java:812)
at android.view.View.performClick(View.java:5637)
at android.view.View$PerformClick.run(View.java:22429)
at android.os.Handler.handleCallback(Handler.java:751)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6119)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)
From my understanding, those project dependencies are not properly getting added with MultiDex enabled. Is there some configuration that I am missing for project dependencies?
I've also tried the following in my build.gradle file.
dexOptions {
preDexLibraries = false
}
It seems to have no effect on it. It crashes each time.
The ZoomSDK you have doesn't support 64bit Android, unfortunately. In the mean time, you need to disable the use of 64bit libraries in your app and only support the mentioned framework so it builds in 32bit mode.
Add the following to the build.gradle of the main module of your app:
android {
defaultConfig {
ndk {
abiFilters "armeabi-v7a"
}
}
}
From the Zoom forum:
We support only 32 bit libs now. To work on 64 bit devices, you should
not use other 64 bit libs ( from other projects or other third party
SDK). Android OS can support 32 bit libs on 64 bit devices if you
don't have other 64 bit libs in the project
For x86, it can be supported via Intel ARM binary translator
(Houdini). But your app should not contain other x86 targeted native
binaries.
In order for the app to run on x86, all the binary files in your app should target on ARM, binary translator will translate them to
support x86.
If your app contains other binary files that target on x86, you should delete those files to remain only ARM targets. Because on x86
devices, if an app have binary files target on x86, it also should
have the file that target on ARM. Because Zoom Android SDK does not
contains any x86 binaries, so other files also can't have binaries
that target on x86 in order for the SDK to run.
The ARM binary translator works at run time, not at compile time.
You only need to add following to main gradle file
android {
defaultConfig {
ndk {
abiFilters "armeabi-v7a"
}
}
}
and in gradle.properties file add the following line
android.useDeprecatedNdk = true

Fields from imported android library not generated in R file

I need to integrate a certain SDK with my app, I added the .aar file in my gradle dependencies and I added the code they provided me.
The gradle build went with no special problems, but when I tried to start the SDK's activity the app crashed with the following exception:
12-07 16:28:09.991 16236-16236/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.positiveapps.clickins, PID: 16236
java.lang.NoSuchFieldError: No static field action_show_neura of type I in class Lcom/neura/standalonesdk/R$id; or its superclasses (declaration of 'com.neura.standalonesdk.R$id' appears in /data/app/com.positiveapps.clickins-1/base.apk:classes2.dex)
at com.neura.dashboard.R$id.<clinit>(R.java:995)
at com.neura.dashboard.activity.LoginActivity.onCreate(LoginActivity.java:59)
at com.neura.dashboard.activity.AppAuthenticationActivity.onCreate(AppAuthenticationActivity.java:26)
at android.app.Activity.performCreate(Activity.java:5990)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1106)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2278)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2387)
at android.app.ActivityThread.access$800(ActivityThread.java:151)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1303)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5254)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
After I went through the R files that are generated in my application I found out a significant amount of fields that exist in R.txt file in the aar are missing from the generated R.
I've tried building with and without proguard, updating gradle version, I cleaning and rebuilding the project, removing "build" directory manually, adding the aar as a module.
None of these seem to be the problem, the R file is still missing fields.
Thanks for any help, Ilia.
Keep aar file in libs folder. ( as libname.aar )
then in app build.gradle specify following.
repositories {
flatDir {
dirs 'libs'
}
}
dependencies {
compile(name:'libname', ext:'aar')
}
and click sync project with gradle files.
Then clean build the project.

Categories

Resources