Cygwin build from source is broken since binutils-2.42-1
Christian Franke
Christian.Franke@t-online.de
Mon Feb 12 10:10:58 GMT 2024
This is not a binutils regression: A build from cygwin 3.5.0-1 src
package or current newlib-cygwin git main (bfb68a9) with new
binutils-2.42-1 fails with:
"
In file included from ../../../../winsup/utils/dumper.cc:23:
/usr/include/bfd.h:2748:1: error: expected initializer before
‘ATTRIBUTE_WARN_UNUSED_RESULT’
"
Downgrading to binutils 2.41-3 fixes the problem.
A diff of /usr/include/bsd.h shows that ATTRIBUTE_WARN_UNUSED_RESULT is
a new addition in 2.42-1. This requires /usr/include/ansidecl.h. It is
included by /usr/include/bsd.h but this has no effect because Cygwin
source tree provides its own ansidecl.h which lacks
ATTRIBUTE_WARN_UNUSED_RESULT:
$ g++ ....MANY_OPTIONS... -E ../../../../winsup/utils/dumper.cc
...
# 1 "../../../../winsup/utils/dumper.cc"
...
# 1 "../../../../winsup/../include/ansidecl.h" 1 <== #define _ANSIDECL_H
...
# 1 "/usr/include/bfd.h" 1 3 4
...
# 1 "/usr/include/ansidecl.h" 1 3 4 <== #ifndef _ANSIDECL_H
...
--
Regards,
Christian
More information about the Cygwin
mailing list