Need help with flann compile error

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Need help with flann compile error

daveseok
Hi,

I just downloaded flann-1.6.11 and followed the install instructions(mkdir build then cmake .. then make)
When I make, I got the following error message regarding nearest_neighbors.mex.
Is anyone familiar with this error?

FYI, I'm using Red Hat Enterprise Linux Client release 5.6 (Tikanga) on 64bit architecture.

Scanning dependencies of target mex_nearest_neighbors
[ 66%] Building MEX extension /u/vis/song/flann/build/src/matlab/nearest_neighbors.mex
In file included from /u/vis/song/flann/src/cpp/flann/util/dynamic_bitset.h:46,
                 from /u/vis/song/flann/src/cpp/flann/algorithms/kdtree_index.h:41,
                 from /u/vis/song/flann/src/cpp/flann/algorithms/all_indices.h:36,
                 from /u/vis/song/flann/src/cpp/flann/flann.hpp:44,
                 from /u/vis/song/flann/src/cpp/flann/flann.h:461,
                 from /u/vis/song/flann/src/matlab/nearest_neighbors.cpp:30:
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:557: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:558: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:558: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:559: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:559: warning: integer constant is too large for ‘long’ type
/tmp/ccmfqmYD.s: Assembler messages:
/tmp/ccmfqmYD.s:19: Error: suffix or operands invalid for `push'
/tmp/ccmfqmYD.s:27: Error: suffix or operands invalid for `pop'
/tmp/ccmfqmYD.s:42: Error: suffix or operands invalid for `push'

(and errors like these..)

make[2]: *** [src/matlab/nearest_neighbors.mex] Error 1
make[1]: *** [src/matlab/CMakeFiles/mex_nearest_neighbors.dir/all] Error 2
make: *** [all] Error 2


_______________________________________________
[hidden email] / http://pointclouds.org
https://code.ros.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

Marius Muja-2
Hi,

That seems to be an error compiling the flann MATLAB mex extension which I haven't seen before. Can you let me know what version of MATLAB you have installed and what version of gcc are you using?

If you don't need the MATLAB bindings you could just disable building them by setting BUILD_MATLAB_BINDINGS to OFF using the cmake-gui inside the build directory before running make.

--
Marius

On Thu, Jul 14, 2011 at 3:27 PM, dave seok <[hidden email]> wrote:
Hi,

I just downloaded flann-1.6.11 and followed the install instructions(mkdir build then cmake .. then make)
When I make, I got the following error message regarding nearest_neighbors.mex.
Is anyone familiar with this error?

FYI, I'm using Red Hat Enterprise Linux Client release 5.6 (Tikanga) on 64bit architecture.

Scanning dependencies of target mex_nearest_neighbors
[ 66%] Building MEX extension /u/vis/song/flann/build/src/matlab/nearest_neighbors.mex
In file included from /u/vis/song/flann/src/cpp/flann/util/dynamic_bitset.h:46,
                 from /u/vis/song/flann/src/cpp/flann/algorithms/kdtree_index.h:41,
                 from /u/vis/song/flann/src/cpp/flann/algorithms/all_indices.h:36,
                 from /u/vis/song/flann/src/cpp/flann/flann.hpp:44,
                 from /u/vis/song/flann/src/cpp/flann/flann.h:461,
                 from /u/vis/song/flann/src/matlab/nearest_neighbors.cpp:30:
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:557: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:558: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:558: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:559: warning: integer constant is too large for ‘long’ type
/u/vis/song/flann/src/cpp/flann/algorithms/dist.h:559: warning: integer constant is too large for ‘long’ type
/tmp/ccmfqmYD.s: Assembler messages:
/tmp/ccmfqmYD.s:19: Error: suffix or operands invalid for `push'
/tmp/ccmfqmYD.s:27: Error: suffix or operands invalid for `pop'
/tmp/ccmfqmYD.s:42: Error: suffix or operands invalid for `push'

(and errors like these..)

make[2]: *** [src/matlab/nearest_neighbors.mex] Error 1
make[1]: *** [src/matlab/CMakeFiles/mex_nearest_neighbors.dir/all] Error 2
make: *** [all] Error 2


_______________________________________________
[hidden email] / http://pointclouds.org
https://code.ros.org/mailman/listinfo/pcl-users



_______________________________________________
[hidden email] / http://pointclouds.org
https://code.ros.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

daveseok
Hello Marius,

Here are the requested info,

MATLAB version: 7.9.0.529 (R2009b) 64-bit (glnxa64)

gcc version: gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-50)
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

ohmmega
I know your question has been some time ago, nevertheless I stumbled over the same problem.

Solution:
MEX compilation is not working with 64bit, so I had to change back to MATLAB x86.
If you are using the cmake environment given by the FLANN library, don't forget to execute 'mex -setup' in matlab before executing (n)make. Also set the CMAKE_BUILD_TYPE to Release, otherwise you run into the next problem (_iterator_debug_level value '0' doesn't match value '2').

Best
Ohm
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

shibujrm
This post was updated on .
I have run into that problem while compiling PCL 1.8.1.

This error occurs at many locations *'_ITERATOR_DEBUG_LEVEL': value '2' doesn't match value '0'*.
        Please clarify how and where to set the *CMAKE_BUILD_TYPE *to *RELEASE*?



--
Sent from: http://www.pcl-users.org/
_______________________________________________
PCL-users@pointclouds.org / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

Bart Verhagen
Hi Shibujrm,

This is an error resulting from the mismatch between how you are trying to build PCL (or one of its dependencies) and how the Boost dependency is built. You have two options:
1) Match the exact build type of PCL and all other dependencies with your build type of Boost. This answers your question: you have to set the correct build type for both PCL and all dependencies of PCL that depend on Boost. If you use precompiled libraries, you will have to match your build type to the type used in the precompiled one ('2' implies a debug build, '0' a release build, if I am not mistaken).
2) Build and install Boost using both CMAKE_BUILD_TYPE=Debug and CMAKE_BUILD_TYPE=Release. If both these libraries are found during the configure step, FindBoost.cmake will do the right thing and take the debug libraries when building in debug and the release libraries when building in release.

Regards,

Bart Verhagen

Bart Verhagen,
Kapernikov
www.kapernikov.com


On Mon, Jul 2, 2018 at 5:19 PM, shibujrm <[hidden email]> wrote:
I have run into that problem while compiling PCL *'_ITERATOR_DEBUG_LEVEL':
value '2' doesn't match value '0'*.
        Please clarify how and where to set the *CMAKE_BUILD_TYPE *to
*RELEASE*?



--
Sent from: http://www.pcl-users.org/
_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users


_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

shibujrm
This post was updated on .
Hi Bart Verhagen,

Thanks for the reply. Let me elaborate the step in which I encountered this
error.
Also I have a doubt regarding the installation of PCL 1.8.1. Could you
please clarify?

I have already installed all the *Dependencies' stand alone installers*
downloaded from the "http://pointclouds.org/downloads/windows.html" site.
Now I am trying to build PCL 1.8.1 from sources. For this, I have not built
the dependencies from sources. Instead I try to use the libraries from the
already installed precompiled binaries  that are already installed in my
computer.

During installation, DEBUG mode successfully completed the build process. It
is during the RELEASE mode build, I face this error. FYI, during solution
creation process (using cmake), I have given the
CMAKE_BUILD_TYPE=Debug;Release.

Is this kind of installation successfully builds? i.e, building PCL 1.8.1
from sources with pre-installed Dependencies' stand alone installers(Boost
1.50.0, Eigen 3.0.5, VTK 5.8.0 with Qt support, Qt 4.8.0, QHull 2011.1
(6.2.0.1385))? Or should I build all the dependencies from scratch before building the PCL 1.8.1?

I am using Visual Studio Professional 2010 compiler in Windows 8, 32 bit
machine.





--
Sent from: http://www.pcl-users.org/
_______________________________________________
PCL-users@pointclouds.org / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users
Reply | Threaded
Open this post in threaded view
|

Re: Need help with flann compile error

Bart Verhagen
Hi Shibujrm,

First of all: the page you are following is for a version of the PCL library that was released 5 years ago (5 september 2013), which implies that all dependencies that you installed are also at least 5 years old. While using this with a recent version of PCL, as you are doing, may work, I doubt it is an officially supported use case. Perhaps someone else on the list can elaborate on whether this works. I typically build recent versions of the dependencies from source, for which I do know it works. Fortunately, I think it should be possible to fix the error you currently have in this setup.

Secondly, if you are using VS 2010, the CMAKE_BUILD_TYPE is ignored anyway, since Visual Studio is a 'multi-configuration' generator. See "This variable is only meaningful to single-configuration generators (such as make and Ninja)" in the cmake manual (https://cmake.org/cmake/help/v3.0/variable/CMAKE_BUILD_TYPE.html).

Have you tried the solution proposed by John Duke on this Stackoverflowpost: https://stackoverflow.com/questions/4080668/iterator-debug-level-value-0-doesnt-match-value-2? He appears to have the same issue you are having.
In the other case, try compiling with the /MD or /MT options, as proposed by Ganesh Kamath in the same post.

Regards,

Bart Verhagen

Bart Verhagen,
Kapernikov
www.kapernikov.com


On Wed, Jul 4, 2018 at 12:28 PM, shibujrm <[hidden email]> wrote:
Hi Bart Verhagen,

Thanks for the reply. Let me elaborate the step in which I encountered this
error.
Also I have a doubt regarding the installation of PCL 1.8.1. Could you
please clarify?

I have already installed all the *Dependencies' stand alone installers*
downloaded from the "http://pointclouds.org/downloads/windows.html" site.
Now I am trying to build PCL 1.8.1 from sources. For this, I have not built
the dependencies from sources. Instead I try to use the libraries from the
already installed precompiled binaries  that are already installed in my
computer.

During installation, DEBUG mode successfully completed the build process. It
is during the RELEASE mode build, I face this error. FYI, during solution
creation process (using cmake), I have given the
CMAKE_BUILD_TYPE=Debug;Release.

Is this kind of installation successfully builds? i.e, building PCL 1.8.1
from sources with pre-installed Dependencies' stand alone installers(Boost
1.50.0, Eigen 3.0.5, VTK 5.8.0 with Qt support, Qt 4.8.0, QHull 2011.1
(6.2.0.1385))?

I am using Visual Studio Professional 2010 compiler in Windows 8, 32 bit
machine.


_______________________________________________
[hidden email] / http://pointclouds.org
http://pointclouds.org/mailman/listinfo/pcl-users