Pregunta

Estoy compilando alguna aplicación usando Eclipse CDT, utilizando OpenCV y Armadillo. Obtengo el siguiente error,

In file included from /usr/include/armadillo:108:0,
             from /home/bmmo/workspace/GS/Source/IMU/MagRLS.h:11,
             from /home/bmmo/workspace/GS/Source/IMU/IMU_class.h:11,
             from ../Source/Navigation/NAV2/nav2_get_u.cpp:2:
/usr/include/armadillo_bits/lapack_bones.hpp:235:106: error: expected ‘,’ or ‘...’ before numeric constant
/usr/include/armadillo_bits/lapack_bones.hpp:236:106: error: expected ‘,’ or ‘...’ before numeric constant
/usr/include/armadillo_bits/lapack_bones.hpp:295:139: error: expected ‘,’ or ‘...’ before numeric constant
/usr/include/armadillo_bits/lapack_bones.hpp:296:139: error: expected ‘,’ or ‘...’ before numeric constant
In file included from /usr/include/armadillo:112:0,
             from /home/bmmo/workspace/GS/Source/IMU/MagRLS.h:11,
             from /home/bmmo/workspace/GS/Source/IMU/IMU_class.h:11,
             from ../Source/Navigation/NAV2/nav2_get_u.cpp:2:
/usr/include/armadillo_bits/lapack_wrapper.hpp:184:31: error: expected ‘,’ or ‘...’ before numeric constant
/usr/include/armadillo_bits/lapack_wrapper.hpp: In function ‘void arma::lapack::geev(char*, char*, arma::blas_int*, eT*, arma::blas_int*, eT*)’:
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:74: error: ‘wi’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:82: error: ‘vl’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:86: error: ‘ldvl’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:96: error: ‘vr’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:100: error: ‘ldvr’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:110: error: ‘work’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:116: error: ‘lwork’ was not declared in this scope
/usr/include/armadillo_bits/lapack_wrapper.hpp:195:123: error: ‘info’ was not declared in this scope

Puedo compilar una aplicación más pequeña sin ningún problema, pero con un proyecto más grande (usando las mismas configuraciones) recibo este error.¿Qué podría estar equivocado?

¿Fue útil?

Solución

Incluya el encabezado de Armadillo antes de cualquier encabezado de OpenCV.Sospecho que OpenCV usa algunos #defines errantes que interfieren con la función y / o los nombres de las variables utilizados por Armadillo.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top