ATTRIBUTE_HIDDEN for libbfd.h
Alan Modra
amodra@gmail.com
Fri May 25 00:18:00 GMT 2018
On Thu, May 24, 2018 at 08:19:28AM -0600, Tom Tromey wrote:
> >>>>> "Alan" == Alan Modra <amodra@gmail.com> writes:
>
> Alan> * libbfd-in.h (ATTRIBUTE_HIDDEN): Define and use throughout.
> Alan> * configure.ac (HAVE_HIDDEN): Check compiler support for hidden
> Alan> visibility.
> Alan> * libbfd.h: Regenerate.
> Alan> * configure: Regenerate.
> Alan> * config.in: Regenerate.
>
> I noticed while testing patches on the gdb buildbot that this patch
> seems to have broken the mingw build.
>
> ../../binutils-gdb/bfd/archive.c:187:1: error: visibility attribute not supported in this configuration; ignored [-Werror=attributes]
>
>
> I can reproduce this on Fedora by installing the mingw toolchain and
> then doing a build like:
>
> ../binutils-gdb/configure --disable-{binutils,gas,gold,gprof,ld,sim} --host=i686-w64-mingw32 --target=i686-w64-mingw32 --enable-targets=all
Thanks for the report. I can reproduce the problem on Ubuntu too.
My configure test is broken.
configure:14046: checking compiler support for hidden visibility
configure:14064: x86_64-w64-mingw32-gcc -c -g -O2 -D__USE_MINGW_ACCESS conftest.c >&5
conftest.c:83:1: warning: visibility attribute not supported in this configuration; ignored [-Wattributes]
}
^
configure:14064: $? = 0
configure:14071: result: yes
--
Alan Modra
Australia Development Lab, IBM
More information about the Binutils
mailing list