我已将Armadillo集成到我的工作环境中,遵循此处列出的步骤: How to link Armadillo with Eclipse
我正在尝试运行这个简单的代码:
#include <iostream>
#include <armadillo>
using namespace std;
using namespace arma;
int main()
{
mat A = randu<mat>(4, 5);
mat B = randu<mat>(4, 5);
cout << A*B.t() << endl;
return 0;
}
我正在使用Mingw G ++编译器编译,每次出现以下错误:
***20:45:00 **** Rebuild of configuration Debug for project Trying Armadillo ****
Info: Internal Builder is used for build
g++ "-ID:\\C++ Development\\armadillo-7.800.0\\include" -O0 -g3 -Wall -c -fmessage-length=0 -o TryNow.o "..\\TryNow.cpp"
g++ "-LD:\\C++ Development\\armadillo-7.800.0\\examples\\lib_win64" -o "Trying Armadillo.exe" TryNow.o -llapack_win64_MT -lblas_win64_MT
D:\C++ Development\armadillo-7.800.0\examples\lib_win64/blas_win64_MT.lib: error adding symbols: File in wrong format
collect2.exe: error: ld returned 1 exit status***
同一个库与Microsoft Visual Studio,2015完美协作。这是一个令我困扰的日食问题吗?