[cfe-dev] "File too big/too many sections" when building Registry.cpp in MSYS2 Environment
kyra via cfe-dev
cfe-dev at lists.llvm.org
Sun Jan 1 23:35:49 PST 2017
1. Big-obj support in Binutils was absolutely broken till recently (see
my ticket https://sourceware.org/bugzilla/show_bug.cgi?id=19440).
Thus you need relatively fresh version of binutils to get things working
(and they really work now).
2. Binutils do *not* support big-obj for 32-bit COFF target, thus it is
*impossible* to debug build 32-bit hosted clang with GNU toolchain.
3. I believe, we should pay more attention to support self-hosted
mingw-w64 clang, I maintain a couple of patches which allow me to build
it, but I never tried to publish them, because I saw no interest. Btw,
that recent LLVM patch introducing big-obj switch
(https://github.com/llvm-mirror/llvm/commit/e1c9f504c6810be782714b8b39f11579e50fa5c7)
also breaks self-hosted clang because gnu clang driver doesn't
understand -Wa,-mbig-obj option. AFAIUI, LLVM handles COFF format
automatically, selecting bigobj format if necessary, and msvc clang
driver simply ignores '/bigobj' flag. I have a patch fixing gnu driver too.
Kyra
On 02.01.2017 4:32, William D. Jones via cfe-dev wrote:
> Did you cross-compile for MinGW? I've noticed that with the new
> change, native compile, Registry.cpp now compiles, but attempting to link
> bin\clangDynamicASTMatchers.dll causes a link step that takes over 90
> minutes (!!) before bombing with an excessive number of undefined
> symbols. So many, that I cannot even copy and paste them all from my
> scrollback. The linker cannot find any of the symbols from Registry.cpp.
>
> It is dawning on me that building a Debug build of Clang/LLVM on
> Windows is impractical/development seems to mainly be done w/ gold on
> Linux to avoid linker woes.
>
> -----Original Message----- From: William D. Jones via cfe-dev
> Sent: Saturday, December 31, 2016 7:38 PM
> To: Reid Kleckner
> Cc: cfe-dev at lists.llvm.org
> Subject: Re: [cfe-dev] "File too big/too many sections" when
> buildingRegistry.cpp in MSYS2 Environment
>
> Sorry for the delay. I noticed that you pass the assembler options for
> only
> 64-bit builds. Is there any harm for enabling the flags for 32-bit
> builds as
> well? The 64-bit MinGW build appears to be broken on my machine (gcc
> 5.3.0);
> LTO.dll spent 30 minutes compiling before I manually disabled the build.
>
> From: Reid Kleckner
> Sent: Thursday, December 22, 2016 2:30 PM
> To: William D. Jones
> Cc: cfe-dev
> Subject: Re: [cfe-dev] "File too big/too many sections" when building
> Registry.cpp in MSYS2 Environment
>
> To follow up, r290358 should fix this.
>
> --
> William D. Jones
> thor0505 at comcast.net
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>
> --
> William D. Jones
> thor0505 at comcast.net
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
More information about the cfe-dev
mailing list