zhouwg / kantv

workbench for learing&practising AI tech in real scenario on Android device, powered by GGML(Georgi Gerganov Machine Learning) and NCNN(Tencent NCNN) and FFmpeg
Apache License 2.0
117 stars 19 forks source link

need to build the apk for "armeabi-v7a", there is error: no find libkantv-core.so #103

Closed TaiXu2022 closed 5 months ago

TaiXu2022 commented 5 months ago

Dear zhou thanks for your shared project, which is perfect I need to build the APP for armeabi-v7a, after set the NDK ,
happen the error: ninja: error: 'C:/Users/windd/AndroidStudioProjects/kantv-master/cdeosplayer/kantv/src/main/jniLibs/armeabi-v7a/libkantv-core.so', needed by 'C:/Users/windd/AndroidStudioProjects/kantv-master/cdeosplayer/kantv/build/intermediates/cxx/Debug/4s5h6o55/obj/armeabi-v7a/libwhispercpp.so', missing and no known rule to make it

would you please upload the libkantv-core.so file for armeabi-v7a,

thanks a lot

zhouwg commented 5 months ago

sorry to reply too late, I just see it on 03-28-2024, 10:20 AM.

(1) modify this file manually to generate aarch32 version of libggml-jni.so

https://github.com/zhouwg/kantv/blob/master/cdeosplayer/kantv/build.gradle#L20

(2) original libwhispercpp.so had been renamed to libggml-jni.so since 03-27-2024 , libggml-jni.so is used to unify JNI layer of whisper.cpp and llama.cpp on Android device.

the codes in master branch had been refactored according to new software architecture:

kantv-android-arch

(3) there are very few pure aarch32-based mobile device and they are also not suitable for kantv application scenarios(media and AI related task here are both highly performance sensitive), so the aarch32 version of libkantv-core.so&libkantv-ffmpeg.so are not provided accordingly.

(4) another reason why the aarch32 version of the libs is not provided is to reduce the difficulty of project maintenance(there are some cross-compilation issues between aarch64 and aarch32, it's also one of the reasons why there is no update on step-2 of import customized FFmpeg to KanTV).

(5) the last reason for not providing an aarch32 version of the libs is to keep the generated apk size as small as possible.

zhouwg commented 5 months ago

BTW, thanks for your issue report. it helped find a problem in the build script.

If you do not require further assistance, I will close this opening issue later. of course, this issue could be re-opened in the future as your need.

thanks.

zhouwg commented 5 months ago

Hi,

I'm so sorry that this issue is fixed finally today(04-07-2024, 10:17 April 07, 2024) after sanity check with a NEW clone in a NEW directory.

I suddenly discovered that this project could/might NOT build&run at all on the project user's side.

This is undoubtedly my mistake: my local development environment has always been able to build and run normally.

btw, the software arch is refined to:

kantv-android-arch

A lesson from this stupid mistake: project maintainer should carefully review/check issue report from project's user because the maintainer can run it locally does not mean it can run normally at the user's place.

Sincerely thanks for your issue report again.

Best regards