[lld] r195593 - Fix MSVC buildbot.
Rui Ueyama
ruiu at google.com
Sun Nov 24 18:51:33 PST 2013
Author: ruiu
Date: Sun Nov 24 20:51:33 2013
New Revision: 195593
URL: http://llvm.org/viewvc/llvm-project?rev=195593&view=rev
Log:
Fix MSVC buildbot.
Modified:
lld/trunk/lib/ReaderWriter/PECOFF/SetSubsystemPass.h
Modified: lld/trunk/lib/ReaderWriter/PECOFF/SetSubsystemPass.h
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/PECOFF/SetSubsystemPass.h?rev=195593&r1=195592&r2=195593&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/PECOFF/SetSubsystemPass.h (original)
+++ lld/trunk/lib/ReaderWriter/PECOFF/SetSubsystemPass.h Sun Nov 24 20:51:33 2013
@@ -12,9 +12,7 @@
#include "lld/ReaderWriter/PECOFFLinkingContext.h"
-using llvm::COFF::WindowsSubsystem::IMAGE_SUBSYSTEM_UNKNOWN;
-using llvm::COFF::WindowsSubsystem::IMAGE_SUBSYSTEM_WINDOWS_CUI;
-using llvm::COFF::WindowsSubsystem::IMAGE_SUBSYSTEM_WINDOWS_GUI;
+using llvm::COFF::WindowsSubsystem;
namespace lld {
namespace pecoff {
@@ -26,7 +24,7 @@ public:
SetSubsystemPass(PECOFFLinkingContext &ctx) : _ctx(ctx) {}
virtual void perform(std::unique_ptr<MutableFile> &file) {
- if (_ctx.getSubsystem() != IMAGE_SUBSYSTEM_UNKNOWN)
+ if (_ctx.getSubsystem() != WindowsSubsystem::IMAGE_SUBSYSTEM_UNKNOWN)
return;
StringRef main = _ctx.decorateSymbol("main");
StringRef wmain = _ctx.decorateSymbol("wmain");
@@ -35,11 +33,11 @@ public:
for (auto *atom : file->defined()) {
StringRef s = atom->name();
if (s == main || s == wmain) {
- _ctx.setSubsystem(IMAGE_SUBSYSTEM_WINDOWS_CUI);
+ _ctx.setSubsystem(WindowsSubsystem::IMAGE_SUBSYSTEM_WINDOWS_CUI);
return;
}
if (s == winmain || s == wwinmain) {
- _ctx.setSubsystem(IMAGE_SUBSYSTEM_WINDOWS_GUI);
+ _ctx.setSubsystem(WindowsSubsystem::IMAGE_SUBSYSTEM_WINDOWS_GUI);
return;
}
}
More information about the llvm-commits
mailing list