使用Visual Studio 2012生成Qt4.8.5时出现错误消息

时间:2013-10-31 16:55:33

标签: c++ qt visual-c++

按照this post的说明,我使用 VisualStudio2012 构建 Qt4.8.5 。我的机器 Win7 。我在 nmake 的舞台上遇到以下错误。

代码触发错误是这样的。最后一行是第327行。

String DefaultLocalizationStrategy::contextMenuItemTagLookUpInDictionary(const String& selectedString)
{
#if defined(BUILDING_ON_LEOPARD) || defined(BUILDING_ON_SNOW_LEOPARD)
    UNUSED_PARAM(selectedString);
    return WEB_UI_STRING("Look Up in Dictionary", "Look Up in Dictionary context menu item");
#else
#if USE(CF)
    RetainPtr<CFStringRef> selectedCFString(AdoptCF, truncatedStringForLookupMenuItem(selectedString).createCFString());
    return formatLocalizedString(WEB_UI_STRING("Look Up “%@”", "Look Up context menu item with selected word"), selectedCFString.get());
#else
    return WEB_UI_STRING("Look Up “<selection>”", "Look Up context menu item with selected word").replace("<selection>", truncatedStringForLookupMenuItem(selectedString));
#endif
#endif
}

错误信息:

ContentType.cpp
CrossThreadCopier.cpp
DateComponents.cpp
DefaultLocalizationStrategy.cpp
DragData.cpp
DragImage.cpp
FileChooser.cpp
platform\DefaultLocalizationStrategy.cpp(327) : error C2001: newline in constant

platform\DefaultLocalizationStrategy.cpp(327) : fatal error C1057: unexpected en
d of file in macro expansion
FileStream.cpp
FileSystem.cpp
GeolocationService.cpp
KillRingNone.cpp
KURL.cpp
Language.cpp
Length.cpp
LinkHash.cpp
Logging.cpp
MIMETypeRegistry.cpp
RuntimeApplicationChecks.cpp
SchemeRegistry.cpp
ScrollableArea.cpp
ScrollAnimator.cpp
Scrollbar.cpp
ScrollbarThemeComposite.cpp
ScrollView.cpp
SharedBuffer.cpp
SharedBufferCRLFLineReader.cpp
ThreadGlobalData.cpp
ThreadTimers.cpp
Timer.cpp
UUID.cpp
Widget.cpp
PlatformStrategies.cpp
LocalizedStrings.cpp
Cursor.cpp
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 11.0
\VC\BIN\cl.EXE"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 11.0
\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.

c:\Qt\Qt4.8.5>

修改

刚刚更新了帖子链接。我错了。

EDIT2:

我也尝试过Qt4.8.4和QT4.8.3。所有人都在同一个地方失败了。有人可以帮帮我吗?

0 个答案:

没有答案