Qt World Summit: Register Today!

DLL issue

  • I am having trouble on WIndows with Qt 5.4. I created a dll with QtCreator, the file created is something like foobar.dll
    I am trying to figure out how to properly link it in a Qt application. For this app I have in my project file:

    LIB += -L../lib -lfoobar

    The error I get is:
    LINK : fatal error LNK1181: cannot open input file 'foobar.lib'

    Can someone explain how I fix this, do I create a foobar.lib, if so how

    Oh I am using Qt /QtCreator for MSVS2013

    Thanks in advance for any help or suggestions

  • Qt Champions 2017

    Is it plugin or simple dll ? Look at QPluginLoader or QLibary class for more information on how to load them.

  • It is a regular library, I don't want to load it via QLibrary, not sure if that is even possible for me as the app makes reference to this would be dll code everywhere. I mean if you called the "sin()" function I am pretty sure your code has to link with the shared math lib at compile time or your going to get an unresolved external reference

  • Hi.
    I think before doing anything you should see this

Log in to reply