I am trying to run a test for the Armadillo library (5.2) which I have downloaded and I have uncommented the lines ARMA_USE_LAPACK
and ARMA_USE_BLAS
in the config.hpp
file as recommended for Windows here . I have set the .pro file as such
QT += core
QT -= gui
TARGET = armatest
CONFIG += console
CONFIG -= app_bundle
TEMPLATE = app
SOURCES += \
main.cpp
INCLUDEPATH += C:\Armadillo\include
LIBS += -LC:\Armadillo\lib_win64
-llapack_win64_MT
-lblas_win64_MT
Considering that lapack_win64_MT.lib
and blas_win64_MT.lib
are the libraries located in C:\Armadillo\lib_win64\
The error I keep on receiving is
undefined reference to 'dgetrf_'
undefined reference to 'ddot_'
undefined reference to 'dgemv_'
etc. as if I am not linking the libraries properly. What am I missing?
I am using MinGW 4.9.1 as a compiler
The problem was due to two reasons
The libraries were x64 and my compiler was 32-bit (even though my machine is x64)
The LIBS path had to be written with backslashes