Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. 36 compilation errors with msvc2010 when linking libraries
Qt 6.11 is out! See what's new in the release blog

36 compilation errors with msvc2010 when linking libraries

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 851 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    foolah44
    wrote on last edited by
    #1

    Hi,

    I am working on Qt creator 2.4.1 based on Qt 4.7.4. I am compiling with msvc2010.
    I am using two libraries built on VS2010 with multi-threaded (/MT) runtime library.
    After linking those libraries to my project and calling functions from it, I get a lot of errors (36) when building the project.

    I tried a simple library test project on VS2010 and when the multi-threaded (/MT) runtime library is not selected, I get almost the same errors on VS when I call libraries functions. But when the multi-threaded (/MT) runtime library is selected, no error is detected.

    I would then like to know if it is possible to set up the multi-threaded (/MT) on Qt? If yes, how?

    I did a bit of research and I found that I have to modify my *pro file. I added a line with CONFIG += thread and also tried to modify flags.
    But it didnt work.

    @

    CONFIG += thread

    QMAKE_CFLAGS_THREAD += /MT
    QMAKE_LFLAGS_THREAD += /MT

    HEADERS +=
    importisq.h
    mainwindow.h
    batchwindow.h

    SOURCES +=
    importisq.cpp
    mainwindow.cpp
    main.cpp
    batchwindow.cpp

    LIBS += -lFreeImage
    LIBS += -LD:/_straxLibs/DependencyLibray
    LIBS += -lISQ
    LIBS += -LD:/_straxLibs

    @

    here is a snapshot of some of the errors;
    https://docs.google.com/open?id=0B6o3dD3oGpIMTXVXUkZDOEhtekk

    PS: the function void isq2tif (String fileName) is a function from the library.

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved