On Friday, 2 June 2017 at 10:40:48 UTC, Petar Kirov [ZombineDev] wrote:
On Friday, 2 June 2017 at 10:12:27 UTC, Joakim wrote:
On Friday, 2 June 2017 at 09:39:46 UTC, Petar Kirov [ZombineDev] wrote:
On Friday, 2 June 2017 at 08:58:01 UTC, Joakim wrote:
On Friday, 2 June 2017 at 08:36:49 UTC, Dušan Pavkov wrote:
[...]

I'd guess that's the issue, as I haven't tested against those older versions of Android and this app links against Android API 21, ie 5.0 Lollipop:

https://github.com/joakim-noah/android/blob/master/samples/Teapot/build-apk#L17

I'm pretty sure it'd work for your older Android versions if built slightly differently, as I used to support back to Android API 9 until a couple months ago:

https://gist.github.com/joakim-noah/f475b0be37b3834b4e50d68996b6ee1d#file-ldc_1-1-0_android_arm-L3438

It can be still made to so but I set API 21 as the minimum, because anything older has been declining for some time now:

http://blog.davidecoppola.com/2016/12/android-version-distribution-history-visualization-2012-2016/

Just FYI, I have the same issue with Android 6.0.1.

Hmm, is that the 64-bit Xiaomi device you mentioned in the github issues just now?

Yep

My guess there would be that it's because ldc only supports 32-bit Android/ARM devices right now, and 64-bit devices like Xiaomi probably don't run 32-bit native Android libraries in their apps, though I don't know that for sure. I just tried installing the teapot app on another 32-bit 6.0.1 phone that I'd never tried before, worked fine.

Running 32-bit apps on 64-bit Android, shouldn't be an issue as far I know. See:
https://stackoverflow.com/questions/30782848/how-to-use-32-bit-native-libraries-on-64-bit-android-device

64-bit ARMv8 hardware should run 32-bit ARMv7 binaries, but it depends on software support too, like providing the 32-bit system shared libraries that this 32-bit teapot shared library links against. I found that SO link inconclusive, but I just found this blog post from a couple years ago that says that it depends on the device:

https://ph0b.com/android-abis-and-so-files/

With your 64-bit device, either it doesn't list ARMv7 as a supported ABI or there's some bug that's stopping it from running this 32-bit ARMv7 library on ARMv8.

This is not an issue for Java, because the Android runtime compiles Java bytecode to native code _after_ the app is downloaded, but other languages have to provide pre-compiled libraries for each CPU architecture. Not a big deal as there are only really two in wide deployment, 32-bit and 64-bit ARM, with the vast majority 32-bit right now.

Perhaps you can help us get on 64-bit ARM, as you mentioned in the github issues.

Yes, ultimately I'm interested in writing a Vulkan library that runs on both 32 and 64-bit Linux, Windows and Android, so I'm interested in helping with the AArch64 support too, though my compiler-foo is pretty slim. As mentioned in the GH issue [0], what do I need to bootstrap LDC on Android?

[0]: https://github.com/joakim-noah/android/issues/10

I've followed up on github, we can discuss there.

Reply via email to