Hi there

I have problems using a dll in my Qt-project. The library is used to control this device.

In my .pro file I have inserted the following lines to include the top16.dll and the FTD2XX.dll in the lib directory of my project:
Qt Code:
  1. LIBS += -Llib \
  2. -lFTD2XX \
  3. -ltop16
To copy to clipboard, switch view to plain text mode 

The header file top16.h looks like this
Qt Code:
  1. #ifndef TOP16_H
  2. #define TOP16_H
  3.  
  4. #include <qglobal.h>
  5.  
  6. class Q_DECL_IMPORT top16
  7. {
  8. public:
  9. top16();
  10. int dllversion();
  11. };
  12.  
  13.  
  14. class Top16
  15. {
  16. public:
  17. Top16();
  18. };
  19.  
  20. #endif // TOP16_H
To copy to clipboard, switch view to plain text mode 

And the top16.cpp files is this
Qt Code:
  1. #include "top16.h"
  2. #include <QDebug>
  3.  
  4. Top16::Top16()
  5. {
  6. top16 myTop16;
  7. qDebug() << "top16 dll version: " << myTop16.dllversion();
  8. }
To copy to clipboard, switch view to plain text mode 

When compiling the project it returns those errors:
...top16.cpp:6: undefined reference to `_imp___ZN5top16C1Ev'
...top16.cpp:7: undefined reference to `_imp___ZN5top1610dllversionEv'
I guess it is a problem with the definitions in the header file but I can't figure out what the problem is. Has anyone with more experience including libraries an idea?

Cheers, Tom