I am trying to compile a code under Windows10/Visual Studio 2017, for this code I have to use the dgtsv
function of the LAPACK library.
I've linked Visual Studio with my BLAS and LAPACK libraries and copied the dll's to system32.
I've also installed MinGW with the g++ and fortran compiler.
extern "C" {
void dgtsv(int*, int*, double*, double*, double*, double*, int*, int*);
}
But the compiler gives me the following error:
LNK2019 unresolved external symbol dgtsv referenced in function "private: void __cdecl"
Thank you for any advice you could give me.
The solution was to add an underscore after the function name, i.e. :
extern "C" {
void dgtsv_(int*, int*, double*, double*, double*, double*, int*, int*);
}