Re: elf-attrs.c compliation errors

Simon Marchi
2018-08-01T12:45:43Z

On 2018-07-31 20:44, Bill Morgan wrote:
> Hello,
>
> I'm building this commit: 33633d9f5b138a211405d482436db2f7661b190e
>
> With this configuration:
>
> ./configure \
> --build=x86_64-w64-mingw64 \
> --host=x86_64-w64-mingw64 \
> --target=arm-none-eabi \
> --with-python \
> --without-tcl \
> --without-tk \
> --without-guile \
> --with-expat \
> --with-lzma \
> --with-system-readline \
> --with-zlib \
> --enable-tui
>
> I am getting the compilation errors below:
>

[snip]

I also get this error when trying to build on Windows. I installed
mingw-w64 using the installer found here:

http://mingw-w64.org/doku.php/download/mingw-builds

I just noticed that the host gets auto-detected as "x86_64-pc-mingw64"
(same as you specified explicitly). I see that when building on mingw,
-Wno-format should be added, specifically ignoring these warnings:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=blob;f=bfd/warning.m4;h=5a7f92d61622c6a0934aa950f8aaa6bf55677d43;hb=HEAD#l75

However, it's only done when the host string contains "mingw32", not
"mingw64". Maybe this needs to be adjusted to "*-*-mingw*"? If you
grep, you'll find a bunch of other things conditionally done if the
triplet is "*-*-mingw32*", maybe they need to be adjusted too?

Simon