pcl-for-android icon indicating copy to clipboard operation
pcl-for-android copied to clipboard

errors building example-app, CMake not finding Eigen3

Open brianm-sra opened this issue 4 years ago • 7 comments

I successfully built the PCL for Android arm64-v8a libraries, but then got an error attempting to build the example app. Appears to be an issue with Gradle configuration.

It is a bit confusing as the message

Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.

conflicts with the fact that Gradle 5.1.1 was apparently downloaded / used

Also I found the message:

Detected a mismatch for the compiler version between your conan profile
settings and CMake:

Compiler version specified in your conan profile: 8

Compiler version detected in CMake: 9.0

So then I changed ~/.conan/profiles/arm64-v8a to specify compiler.version=9 instead of compiler.version=8

and tried the build again

$ cd ~/Downloads/pcl-for-android/example-app $ ./gradlew clean assemble This time it seemed to get stuck at 26% EXECUTING of the :app:generateJsonModelDebug step for a long time

Any suggestions ?

brianm-sra avatar Aug 03 '20 22:08 brianm-sra

Followup:

<===----------> 26% EXECUTING [29m 20s]

Task :app:generateJsonModelDebug FAILED CMake Error at androidsdk/cmake/3.10.2.4988404/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:137 (message): Could NOT find Eigen3 (missing: EIGEN3_INCLUDE_DIR EIGEN3_VERSION_OK) (Required is at least version "2.91.0")

brianm-sra avatar Aug 03 '20 23:08 brianm-sra

Are there instructions for getting pcl-for-android/example-app build CMake to find Eigen which is installed at

/usr/local/include/eigen3: Eigen signature_of_eigen3_matrix_library unsupported

/usr/local/share/eigen3: cmake

brianm-sra avatar Aug 03 '20 23:08 brianm-sra

I uninstalled eigen3-dev since the pcl / conan stuff has its own way of accessing eigen 3.3.7

However I still have two questions for building:

  1. How to build native-lib.so file for Android arm64-v8a ?

  2. Should I be using compiler version 8 or 9 ? Should I change the CMake or conan config ?

brianm-sra avatar Aug 05 '20 23:08 brianm-sra

Hello,brother,I have common question ,Did you compile successfully?

13671447200 avatar Aug 12 '20 09:08 13671447200

I worked around it for now by making a version of the example app that does not use conan, but instead uses local copies of the includes and libs from dependencies. But this is not ideal and I am planning to take another look at the cmake/conan build configuration files etc. to see if I can make the example app build work with conan.

If the original bashbug author can provide any suggestions, it would be appreciated.

brianm-sra avatar Aug 12 '20 18:08 brianm-sra

Oh, and after my August 5 comment, I realized that the example app includes a file named native-lib.cpp , which is supposed to be (should be, if no errors) built to native-lib.so as part of building the example app. Originally I was confused about where that .so is supposed to come from.

brianm-sra avatar Aug 12 '20 18:08 brianm-sra

I met the same problem, Have you solved it ?

mei123hao avatar Dec 25 '20 09:12 mei123hao