[LLVMdev] Building LLVM under Mingw. Part I: tools-only
Jeff Cohen
jeffc at jolt-lang.org
Sat Apr 29 11:45:02 PDT 2006
Anton Korobeynikov wrote:
> 2. Patching.
>
> 2.1. Libraries
> Add "LIBS+= -lpsapi -limagehlp" to each makefile (AFTER
> Makefile.common inclusion) building some tool (burg, tablegen, ll*),
> since gcc doesn't support vcpp style #pragma's of form:
> #pragma comment(lib, "dbghelp.lib")
>
I'd fix this, but I don't touch Unix build stuff :) I'll let Reid
handle this one. I suspect he'll prefer to fix Makefile.common rather
than each individual makefile. And dbghelp.lib really ought to be
used. imagehlp is very, very obsolete and vanishes on 64-bit Windows.
Yes, I know mingw doesn't support dbghelp. I can still rant about it :)
> 2.2 CopyFile
> Patch lib/System/Win32/Path.inc in such way, that declaration of
> CopyFile will look like:
>
> void
> CopyFile(const sys::Path &Dest, const sys::Path &Src) {
>
Applied.
> 2.3 X86 stuff
> Patch lib/Target/X86/X86SubTarget.cpp & X86JITInfo.cpp in such way:
>
> X86SubTarget.cpp:
> #if defined(__CYGWIN__) || defined(__MINGW32__)
> TargetType = isCygwin;
> #elif defined(__APPLE__)
> TargetType = isDarwin;
> #elif defined(_WIN32)
> TargetType = isWindows;
> #endif
>
>
This is what's already there. What changed?
> X86JITInfo.cpp:
> #if defined(__CYGWIN__) || defined(__APPLE__) || defined(__MINGW32__)
> ".globl _X86CompilationCallback\n"
> "_X86CompilationCallback:\n"
> #else
> ...
> #if defined(__CYGWIN__) || defined(__APPLE__) || defined(__MINGW32__)
> "call _X86CompilationCallback2\n"
> #else
>
>
Applied.
> 2.4 alarm()'s in Sparc backend
>
> Remove from lib/Target/SparcV9/ModuloScheduling/ModuloScheduling.cpp
> all calls to alarm().
>
This code no longer exists post-1.7.
More information about the llvm-dev
mailing list