Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Work around fragile
#include
in binutils
The `bfd.h` header file that is included in `binutils` has the line `#include "ansidecl.h"`, which is fragile because it prefers Cygwin's `include/ansidecl.h` (as opposed to `#include <ansidecl.h>`, which would only look in the system include paths). This matters because as of v2.42, `bfd.h` also makes use of the `ATTRIBUTE_WARN_UNUSED_RESULT` macro. So let's just copy that macro (and while at it, the other `ATTRIBUTE_*` macros) from binutils' `ansidecl.h` file, to avoid compile errors while compiling `dumper.o` that look like this: /usr/include/bfd.h:2770:1: error: expected initializer before ‘ATTRIBUTE_WARN_UNUSED_RESULT’ 2770 | ATTRIBUTE_WARN_UNUSED_RESULT; | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ Signed-off-by: Johannes Schindelin <[email protected]>
- Loading branch information