I have just downloaded the latest Qt 4.6.1 and also the trunk version of Qwt 6.0.0-svn. Because I am using MSVC 2005 I recompiled from scratch the Qt libraries without issue. I then tried to compile the Qwt library (note both done with debug-and-release build settings) which went smoothly until it tried to compile the refreshtest example. This it compiled but failed the link stage with:
Microsoft (R) Program Maintenance Utility Version 8.00.50727.762
Copyright (C) Microsoft Corporation. All rights reserved.
rc -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -DQT_DLL -DQWT_DLL -DQT_THREAD_SUPPORT -DQT_DLL -DQT_NO_DEBUG -DQT_NO_KEYWORDS -DQT_GUI_LIB -DQT_CORE_LIB -fo obj\refreshtest_resource.res refreshtest_resource.rc
compiling .\circularbuffer.cpp .\panel.cpp .\plot.cpp .\mainwindow.cpp .\main.cpp
circularbuffer.cpp
panel.cpp
plot.cpp
mainwindow.cpp
main.cpp
Generating Code...
compiling moc\moc_panel.cpp moc\moc_plot.cpp
moc_panel.cpp
moc_plot.cpp
Generating Code...
linking ..\..\examples\bin\refreshtest.exe
panel.obj : fatal error LNK1179: invalid or corrupt file: duplicate COMDAT '??0<unnamed-tag>@Settings@@QAE@XZ'
NMAKE : fatal error U1077: 'echo' : return code '0x49b'
Stop.
It seems to fail in the same way regardless of whether release or debug builds are selected. All other examples build fine so I just commented this one out.
I have seen an MS reference to this error here, but it seemed to indicate a situation which I don't believe is valid in this case, where there can be a name comflict due to certain compiler flag options. I also got this error when I tried Qt 4.6.0 and Qwt 5.2.0 and 5.x-svn.
The only workaround for this I have found was by way of a reference to a problem under VC 6.0 here, where if you explicitly set the Inline Function Expansion to Only __inline (/Ob1) then the problem goes away, but I don't understand why.
Correction, the above only worked for the debug build within MSVC not the release build!
Any suggestions?
Bookmarks