From patchwork Tue Jul 3 14:32:57 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 28210 Received: (qmail 15605 invoked by alias); 3 Jul 2018 14:33:03 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 14854 invoked by uid 89); 3 Jul 2018 14:33:02 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-25.3 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_SHORT, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.2 spammy=HTo:D*br X-HELO: mail-oi0-f45.google.com Received: from mail-oi0-f45.google.com (HELO mail-oi0-f45.google.com) (209.85.218.45) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 03 Jul 2018 14:33:00 +0000 Received: by mail-oi0-f45.google.com with SMTP id c6-v6so4232173oiy.0; Tue, 03 Jul 2018 07:33:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to:cc; bh=jtR8NNkXVxJPu2KMljHrMRhu0TUgliMKY9nwivFlAlU=; b=cZOPAFg8X9TyJc8ZrJt8t7irrQJur4fcjE76E1tSvNBdnUlkEIY6R2eNaJV5YucbSF lLuAhKD+Im0d1hrHBO8YFOkFaeC+7ou3z+ZCyRQB9hd82yiENPe0Z8CtTXAG73Q0NNxV CwOWkDYPdF4xpWmW2ppfd8kvgSQ9EIhyHo0pR4CIdFwEOapSjRcZh8hIEvYfiLUde3xw EbyUpo/6wavA2zthgQYVp3SoDlQSu3Pp4VuYSIHtJfQJpXpSUQQAsWtdzac4Hxt/NOF5 X6mGlNoepbWcMpPg2tu5+lTwHhv4xAZsXhmcMWHnhcQgcOcBG9c3QriIPhBJ9A1UKw30 cERw== MIME-Version: 1.0 Received: by 2002:a4a:c984:0:0:0:0:0 with HTTP; Tue, 3 Jul 2018 07:32:57 -0700 (PDT) From: "H.J. Lu" Date: Tue, 3 Jul 2018 07:32:57 -0700 Message-ID: Subject: [PATCH] Also install diagnostics.h To: Tulio Magno Quites Machado Filho Cc: Nick Clifton , Pedro Alves , Binutils , GDB X-IsSubscribed: yes On Mon, Jul 2, 2018 at 9:25 AM, Tulio Magno Quites Machado Filho wrote: > "H.J. Lu" 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? From dab73c9e779922f4286ddaa94f4b75ccef2c7d51 Mon Sep 17 00:00:00 2001 From: "H.J. Lu" 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