Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to load native library ... is 64-bit instead of 32 bit #4

Closed
dreua opened this issue May 12, 2020 · 5 comments
Closed

Unable to load native library ... is 64-bit instead of 32 bit #4

dreua opened this issue May 12, 2020 · 5 comments

Comments

@dreua
Copy link
Collaborator

dreua commented May 12, 2020

I was curios and tried to make this work but I'm struggling to fix this error:
05-12 23:39:27.783 22959 22959 E AndroidRuntime: java.lang.UnsatisfiedLinkError: Unable to load native library "/data/app/org.yourorg.cnfgtest-1/lib/arm/libcnfgtest.so": dlopen failed: "/data/app/org.yourorg.cnfgtest-1/lib/arm/libcnfgtest.so" is 64-bit instead of 32-bit
Android displays that App crashed.
I tried so far: API 24 (btw: needs change in Manifest to work: remove android:requestLegacyExternalStorage="true") -> Same result

History

First I got this error on make push run:

echo "Installing" org.yourorg.cnfgtest
Installing org.yourorg.cnfgtest
adb install makecapk.apk
adb: failed to install makecapk.apk: Failure [INSTALL_FAILED_NO_MATCHING_ABIS: Failed to extract native libraries, res=-113]
make: *** [Makefile:128: push] Error 1

I could fix it by setting TARGETS?=makecapk/lib/armeabi-v7a/lib$(APPNAME).so (My uname -a says its armv7l not sure what that means or if that is the correct way of checking my phones ABI though.)

@dreua
Copy link
Collaborator Author

dreua commented May 12, 2020

One more thought for tonight: I think adding uninstall to push target (i.e. push : makecapk.apk uninstall) would make sense. (i.e. always uninstall first to avoid installation error in case it is already installed)

@cnlohr
Copy link
Owner

cnlohr commented May 13, 2020

You should probably be building with this extra flag: https://github.com/cnlohr/rawdrawandroidexample/blob/master/Makefile#L9

@dreua dreua changed the title Unable to load native library ... is 64-bit instanead of 32 bit Unable to load native library ... is 64-bit instead of 32 bit May 13, 2020
@cnlohr
Copy link
Owner

cnlohr commented May 13, 2020

Looks like it was a bug on my side. Do you mind re-testing @dreua ?

@dreua
Copy link
Collaborator Author

dreua commented May 13, 2020

Yes, that fixed it, thank you @Jcd1230 and @cnlohr !

The Demo looks really cool on my Android! I feel some urge to port cnping to Android now...

@dreua dreua closed this as completed May 13, 2020
@cnlohr
Copy link
Owner

cnlohr commented May 13, 2020

cntools/cnping#19 beckons.

All the stuff to request permissions is already here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants