I'm trying to link the ftd2xx.lib (amd64 https://www.ftdichip.com/Drivers/CDM/CDM%20v2.12.28%20WHQL%20Certified.zip) static file to my test program in codeblocks. I'm running codeblocks(mingw) on a intel i3-7020, x64 based processor. I'm getting the linker error obj\Debug\main.o:main.cpp|| undefined reference to `_imp__FT_ListDevices@12'. Can someone please tell me how to link the static library of ftd2xx.lib 64bit version in codeblocks.
#include <iostream>
#include "ftd2xx.h"
using namespace std;
int main()
{
FT_STATUS ftStatus;
int numDevs;
ftStatus = FT_ListDevices(&numDevs,NULL,FT_LIST_NUMBER_ONLY);
cout<<numDevs<<endl;
return 0;
}
It is supposed to compile successfully and display the number of devices connected.