acktie / Acktie-Mobile-Android-Barcode

Acktie Mobile Barcode module is an easy to use yet powerful barcode reader.
Other
20 stars 13 forks source link

Ti SDK 5.1.2.GA and Android API 23 exception #6

Open EthraZa opened 8 years ago

EthraZa commented 8 years ago

It worked fine on Ti SDK 5.0.2.GA and Android API 21, now it is not working anymore.

[ERROR] :  linker: /data/app/com.myapp-1/lib/arm/libiconv.so: has text relocations
[ERROR] :  TiApplication: (main) [12,178] Sending event: exception on thread: main msg:java.lang.UnsatisfiedLinkError: dlopen failed: /data/app/com.myapp-1/lib/arm/libiconv.so: has text relocations; Titanium 5.1.2,2015/12/16 19:00,ca822b2
[ERROR] :  TiApplication: java.lang.UnsatisfiedLinkError: dlopen failed: /data/app/com.myapp-1/lib/arm/libiconv.so: has text relocations
[ERROR] :  TiApplication:   at java.lang.Runtime.loadLibrary(Runtime.java:372)
[ERROR] :  TiApplication:   at java.lang.System.loadLibrary(System.java:1076)
[ERROR] :  TiApplication:   at com.acktie.mobile.android.barcode.AcktiemobileandroidbarcodeModule.<clinit>(AcktiemobileandroidbarcodeModule.java:24)
[ERROR] :  TiApplication:   at com.myapp.MyappApplication.onCreate(MyappApplication.java:159)
[ERROR] :  TiApplication:   at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1013)
[ERROR] :  TiApplication:   at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4707)
[ERROR] :  TiApplication:   at android.app.ActivityThread.-wrap1(ActivityThread.java)
[ERROR] :  TiApplication:   at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1405)
[ERROR] :  TiApplication:   at android.os.Handler.dispatchMessage(Handler.java:102)
[ERROR] :  TiApplication:   at android.os.Looper.loop(Looper.java:148)
[ERROR] :  TiApplication:   at android.app.ActivityThread.main(ActivityThread.java:5417)
[ERROR] :  TiApplication:   at java.lang.reflect.Method.invoke(Native Method)
[ERROR] :  TiApplication:   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
[ERROR] :  TiApplication:   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

Please, it is by far the best barcode scanner module out there!

jeffatstepup commented 8 years ago

I've made a PR with a fix for Marshmallow

jwogan5 commented 8 years ago

Nexus 6 marshmallow, if I use titanium sdk 5.2 with genymotion I can request camera permission and it shows the barcode scanner. If I use a nexus 6 device with sdk 5.2 I still get the text relocations error.

-- Start application log ----------------------------------------------------- [INFO] : TiApplication: (main) [0,0] checkpoint, app created. [INFO] : TiApplication: (main) [80,80] Titanium 5.2.0 (2016/02/20 08:05 384775e) [INFO] : DatabaseHelper: No value in database for platform key: 'unique_machine_id' returning supplied default '' [INFO] : DatabaseHelper: No value in database for platform key: 'hardware_machine_id' returning supplied default '' [INFO] : TiApplication: (main) [208,288] Titanium Javascript runtime: v8 [ERROR] : linker: /data/app/com.industrial.apollo-1/lib/arm/libiconv.so: has text relocations [ERROR] : TiApplication: (main) [15,317] Sending event: exception on thread: main msg:java.lang.UnsatisfiedLinkError: dlopen failed: /data/app/com.industrial.apollo-1/lib/arm/libiconv.so: has text relocations; Titanium 5.2.0,2016/02/20 08:05,384775e [ERROR] : TiApplication: java.lang.UnsatisfiedLinkError: dlopen failed: /data/app/com.industrial.apollo-1/lib/arm/libiconv.so: has text relocations [ERROR] : TiApplication: at java.lang.Runtime.loadLibrary(Runtime.java:372) [ERROR] : TiApplication: at java.lang.System.loadLibrary(System.java:1076) [ERROR] : TiApplication: at com.acktie.mobile.android.barcode.AcktiemobileandroidbarcodeModule.(AcktiemobileandroidbarcodeModule.java:24) [ERROR] : TiApplication: at com.industrial.apollo.ApolloApplication.onCreate(ApolloApplication.java:103) [ERROR] : TiApplication: at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1013) [ERROR] : TiApplication: at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4707) [ERROR] : TiApplication: at android.app.ActivityThread.-wrap1(ActivityThread.java) [ERROR] : TiApplication: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1405) [ERROR] : TiApplication: at android.os.Handler.dispatchMessage(Handler.java:102) [ERROR] : TiApplication: at android.os.Looper.loop(Looper.java:148) [ERROR] : TiApplication: at android.app.ActivityThread.main(ActivityThread.java:5417) [ERROR] : TiApplication: at java.lang.reflect.Method.invoke(Native Method) [ERROR] : TiApplication: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726) [ERROR] : TiApplication: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

cjadhav commented 8 years ago

Hi @jwogan5 ,

Did it work for you? Which module version you have used? Can you send me the link for updated module if it worked for you..??

I am getting crash i use 1.4.0. The app is not running. and if I use 1.8.0 from one of the fork. I am able to run the app but when i require that module there it crashes.

Your help is highly appreciated. Thanks for your help

jeffatstepup commented 8 years ago

I published my app with 5.1.1 - works with Genymotion.

Does your app work if you set target SDK <23 - rule out the Marshmallow effect, prove you’re using the module correctly, then go back to 23.

On 24 Feb 2016, at 22:40, Jason Wogan notifications@github.com wrote:

It is not throwing the text relocations error with 5.0.2 but it still is with 5.2.0. Also can I ask you if this module will work within genymotion? It seems to always throw the error ( Attempt to invoke virtual method 'void com.acktie.mobile.android.camera.CameraManager.stop()' on a null object reference ) when I try to call stop or try to call toggleLight. Any info on this would be much appreciated. All I can think is that if it cannot create the camera then the barcodeview remains a null object.

— Reply to this email directly or view it on GitHub https://github.com/acktie/Acktie-Mobile-Android-Barcode/issues/6#issuecomment-188492503.

disclaimer http://www.stepupsoftware.co.uk/emaildisclaimer

jwogan5 commented 8 years ago

@cjadhav

Here are the scenarios that are working for me.

Titanium : 5.0.2 , Module : 1.4 , API Level 22 Titanium : 5.2.0 , Module : 1.8 , API Level 23 , Camera Permission Code Titanium : 5.0.2 , Module : 1.8 , API Level 22

Like Jeff says if you stick with api level 22 then you can stick with 1.4 of the module. Now if you raise the titanium api to anything 5.1 or greater then titanium forces you to use api level 23. When I bumped up to API level 23 I was able to get a nexus 6 with 6.0.1 to install and scan a barcode with the new barcode module 1.8 that Jeff created last Thursday. Try the scenarios that I outlined above as all are working on the nexus 6. Let me know what you find.

cjadhav commented 8 years ago

Hi Guys, Thank you so much for your help. It worked with 3rd combination.