[cfe-dev] Trying again - building 64bit code on Windows

Yaron Keren via cfe-dev cfe-dev at lists.llvm.org
Mon Aug 24 20:38:06 PDT 2015


>Evidently to build a version of clang on Windows targeting mingw-64/gcc,
which can compile 64-bit code, one must build clang with a 64-bit version
of mingw-64/gcc. This may be apparent to you and other clang developers but
it was not apparent to me.

clang may be built with any supported regardless the target. For example,
I'm building clang using Visual C++ 64 bit and targetting the 32-bit
version of mingw. You do need to have the target mingw installed for the
include files, library files and linker.



2015-08-25 5:15 GMT+03:00 Edward Diener via cfe-dev <cfe-dev at lists.llvm.org>
:

> On 8/24/2015 6:27 PM, Hans Wennborg via cfe-dev wrote:
>
>> On Mon, Aug 24, 2015 at 2:36 PM, Edward Diener via cfe-dev
>> <cfe-dev at lists.llvm.org> wrote:
>>
>>> Is clang built form the latest svn source capable of creating 64-bit
>>> code on
>>> a Microsoft Windows 64-bit OS ?
>>>
>>
>> Yes. We build 64-bit Chromium on Windows with Clang continuously.
>>
>> If yes, is this done through the -m64 option
>>> or do I have to build clang from source in some particular way to enable
>>> the
>>> functionality ?
>>>
>>
>> Yes, using clang-cl -m64 is how we do it.
>>
>
> Evidently to build a version of clang on Windows targeting mingw-64/gcc,
> which can compile 64-bit code, one must build clang with a 64-bit version
> of mingw-64/gcc. This may be apparent to you and other clang developers but
> it was not apparent to me.
>
> I would like to add to the documentation on the clang "Getting Started:
> Building and Running Clang" page at http://clang.llvm.org/get_started.html
> a section of documentation following the section "Using Visual Studio"
> called "Using mingw(-64)/gcc". This section would explain how to build
> clang on Windows using ninja, CMake, and a mingw(-64)/gcc implementation
> and how to run clang from the command line using a mingw(-64)/gcc RTL. I am
> willing to completely write this documentation, to be vetted by whatever
> clang developer takes care of that "Getting Started" page, in order to help
> other developers build and run clang on Windows with the mingw(-64)/gcc RTL.
>
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20150825/8999baab/attachment.html>


More information about the cfe-dev mailing list