* [PATCH] Also install diagnostics.h
@ 2018-07-03 14:33 H.J. Lu
2018-07-04 11:07 ` Nick Clifton
0 siblings, 1 reply; 2+ messages in thread
From: H.J. Lu @ 2018-07-03 14:33 UTC (permalink / raw)
To: Tulio Magno Quites Machado Filho; +Cc: Nick Clifton, Pedro Alves, Binutils, GDB
[-- Attachment #1: Type: text/plain, Size: 800 bytes --]
On Mon, Jul 2, 2018 at 9:25 AM, Tulio Magno Quites Machado Filho
<tuliom@ascii.art.br> wrote:
> "H.J. Lu" <hjl.tools@gmail.com> writes:
>
>> GCC 8.1 warns about destination size with -Wstringop-truncation:
>>
>> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85643
>>
>> Use DIAGNOSTIC_IGNORE_STRINGOP_TRUNCATION to silence it.
>>
>> bfd/
>>
>> PR binutils/23146
>> * bfd-in.h: Include "diagnostics.h".
>> * bfd-in2.h: Regenerated.
>
> bfd.h is an installed header, while diagnostics.h is not, causing build
> failures on software that include bfd.h, e.g.:
>
> In file included from opagent.c:65:
> bfd.h:44:10: fatal error: diagnostics.h: No such file or directory
> #include "diagnostics.h"
> ^~~~~~~~~~~~~~~
>
Here is a patch. OK for master and 2.31 branch?
--
H.J.
[-- Attachment #2: 0001-Also-install-diagnostics.h.patch --]
[-- Type: text/x-patch, Size: 2205 bytes --]
From dab73c9e779922f4286ddaa94f4b75ccef2c7d51 Mon Sep 17 00:00:00 2001
From: "H.J. Lu" <hjl.tools@gmail.com>
Date: Tue, 3 Jul 2018 07:27:48 -0700
Subject: [PATCH] Also install diagnostics.h
Since bfd.h is an installed header, also install diagnostics.h.
* Makefile.am (bfdinclude_HEADERS): Add $(INCDIR)/diagnostics.h.
* Makefile.in: Regenerated.
---
bfd/Makefile.am | 3 ++-
bfd/Makefile.in | 6 ++++--
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/bfd/Makefile.am b/bfd/Makefile.am
index d7f9ed7c45..3f3487f6a4 100644
--- a/bfd/Makefile.am
+++ b/bfd/Makefile.am
@@ -32,7 +32,8 @@ if INSTALL_LIBBFD
bfdlibdir = @bfdlibdir@
bfdincludedir = @bfdincludedir@
bfdlib_LTLIBRARIES = libbfd.la
-bfdinclude_HEADERS = $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/bfdlink.h
+bfdinclude_HEADERS = $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/diagnostics.h
else !INSTALL_LIBBFD
# Empty these so that the respective installation directories will not be created.
bfdlibdir =
diff --git a/bfd/Makefile.in b/bfd/Makefile.in
index 47a16d94a3..cc27ef0a62 100644
--- a/bfd/Makefile.in
+++ b/bfd/Makefile.in
@@ -247,7 +247,8 @@ am__can_run_installinfo = \
*) (install-info --version) >/dev/null 2>&1;; \
esac
am__bfdinclude_HEADERS_DIST = $(INCDIR)/plugin-api.h bfd.h \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/bfdlink.h
+ $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/bfdlink.h \
+ $(INCDIR)/diagnostics.h
HEADERS = $(bfdinclude_HEADERS)
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
@@ -466,7 +467,8 @@ libbfd_la_LDFLAGS = $(am__append_1) -release `cat libtool-soversion` \
@INSTALL_LIBBFD_FALSE@bfdinclude_HEADERS = $(am__append_2)
@INSTALL_LIBBFD_TRUE@bfdinclude_HEADERS = $(BFD_H) \
@INSTALL_LIBBFD_TRUE@ $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
-@INSTALL_LIBBFD_TRUE@ $(INCDIR)/bfdlink.h $(am__append_2)
+@INSTALL_LIBBFD_TRUE@ $(INCDIR)/bfdlink.h \
+@INSTALL_LIBBFD_TRUE@ $(INCDIR)/diagnostics.h $(am__append_2)
@INSTALL_LIBBFD_FALSE@rpath_bfdlibdir = @bfdlibdir@
@INSTALL_LIBBFD_FALSE@noinst_LTLIBRARIES = libbfd.la
--
2.17.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Also install diagnostics.h
2018-07-03 14:33 [PATCH] Also install diagnostics.h H.J. Lu
@ 2018-07-04 11:07 ` Nick Clifton
0 siblings, 0 replies; 2+ messages in thread
From: Nick Clifton @ 2018-07-04 11:07 UTC (permalink / raw)
To: H.J. Lu, Tulio Magno Quites Machado Filho; +Cc: Pedro Alves, Binutils, GDB
Hi H.J.
>>> bfd/
>>>
>>> PR binutils/23146
>>> * bfd-in.h: Include "diagnostics.h".
>>> * bfd-in2.h: Regenerated.
> Here is a patch. OK for master and 2.31 branch?
Approved - please apply (both master and branch).
Cheers
Nick
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-07-04 11:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-07-03 14:33 [PATCH] Also install diagnostics.h H.J. Lu
2018-07-04 11:07 ` Nick Clifton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).