Results 1 to 4 of 4

Thread: Can link a project with .exe(built using GCC) and another .dll( built using VC)?

  1. #1
    Join Date
    Apr 2010
    Location
    Singapore
    Posts
    156
    Thanks
    47
    Qt products
    Qt4
    Platforms
    Windows

    Default Can link a project with .exe(built using GCC) and another .dll( built using VC)?

    Is it possible to establish a link between a project with .exe(built using GCC) and another .dll ( built using VC)?
    The desired compile and build environment to link the two is GCC.
    If no , what is the reason.And if yes, how to link?

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Can link a project with .exe(built using GCC) and another .dll( built using VC)?

    Maybe, it really depends a lot on the specifics. I am assuming the EXE is a Qt project.
    Is the DLL a COM/ActiveX object? If so, use ActiveQt.
    Is the DLL pure C functions or is it C++? If the former then you will probably have better luck.
    MingW mixing compilers

  3. #3
    Join Date
    Apr 2010
    Location
    Singapore
    Posts
    156
    Thanks
    47
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Can link a project with .exe(built using GCC) and another .dll( built using VC)?

    Quote Originally Posted by ChrisW67 View Post
    Maybe, it really depends a lot on the specifics. I am assuming the EXE is a Qt project.
    Is the DLL a COM/ActiveX object? If so, use ActiveQt.
    Is the DLL pure C functions or is it C++? If the former then you will probably have better luck.
    MingW mixing compilers
    I do not know if DLL is a COM or ActiveX object.How do I confirm? But I only know DLL comes with a .lib(Object File Library) and other header files.
    DLL is in MSVC C++ .

  4. #4
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Can link a project with .exe(built using GCC) and another .dll( built using VC)?

    Do you have to register the DLL to use it? Com/ActiveX DLLs have a bunch of related registry entries that are created by registration. Try it if you don't know:
    Qt Code:
    1. C:\Windows\system32> regsvr32 example.dll
    To copy to clipboard, switch view to plain text mode 
    Non-COM DLLs will generate an error message.

    The binary interface of C++ code differs between GCC and MSVC++ so if the DLL is straight C++ you are probably out of luck.

Similar Threads

  1. qwt cannot be built
    By estradasphere in forum Qt-based Software
    Replies: 1
    Last Post: 20th March 2010, 18:43
  2. Built EXE
    By vinny gracindo in forum Newbie
    Replies: 4
    Last Post: 3rd February 2010, 17:39
  3. Application built, needs DLL's
    By been_1990 in forum Installation and Deployment
    Replies: 2
    Last Post: 9th January 2010, 19:10
  4. "Treat wchar_t as Built-in Type" to "yes" link error
    By sungaoyong in forum Qt Programming
    Replies: 1
    Last Post: 5th June 2008, 11:45
  5. Qt will not be built with XShape support.
    By manfredfr in forum Installation and Deployment
    Replies: 4
    Last Post: 14th March 2006, 08:26

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.