deokgyuhan / flutter_camera_calibration

MIT License
1 stars 0 forks source link

Error compiling the example #1

Open adauhajre opened 2 weeks ago

adauhajre commented 2 weeks ago

Hello,

I'm trying to compile including this in my app and also tested the example and am getting the same error:

 ninja: error: '~/.pub-cache/hosted/pub.dev/flutter_camera_calibration-0.0.5/android/src/main/jniLibs/x86/libopencv_java4.so', needed by '~/src/ZoicAI/src/app/zoic/build/flutter_camera_calibration/intermediates/cxx/Debug/6h3a2d4q/obj/x86/libflutter_camera_calibration.so', missing and no known rule to make it

I've got opencv installed already but not sure if I'm missing something else. I'm running on Linux Ubuntu.

deokgyuhan commented 2 weeks ago

Hello, thank you for showing interest in the project.

The compilation issue is caused by the absence of the x86 directory in flutter_camera_calibration/android/src/main/jniLibs.

Due to GitHub's upload size limits, the plugin was published without the x86 library.

If you need the library, you can add the x86 library and build the project to resolve the issue.

Have a great day and good luck!

adauhajre commented 2 weeks ago

Hello, thank you for showing interest in the project.

The compilation issue is caused by the absence of the x86 directory in flutter_camera_calibration/android/src/main/jniLibs.

Due to GitHub's upload size limits, the plugin was published without the x86 library.

If you need the library, you can add the x86 library and build the project to resolve the issue.

Have a great day and good luck!

Thanks for the info. Where do I get that library? Do I have to compile it myself? Also did you try using git lfs with GitHub?

deokgyuhan commented 2 weeks ago

Hello,

You can refer to init.sh in the root directory. Please execute the following commands:

Download the opencv source code and unzip it

wget -O "opencv-$opencv_version-android-sdk.zip" "https://github.com/opencv/opencv/releases/download/$opencv_version/opencv-$opencv_version-android-sdk.zip" wget -O "opencv-$opencv_version-ios-framework.zip" "https://github.com/opencv/opencv/releases/download/$opencv_version/opencv-$opencv_version-ios-framework.zip" unzip "opencv-$opencv_version-android-sdk.zip" unzip "opencv-$opencv_version-ios-framework.zip"

Good luck!