From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 52478138351 for ; Wed, 29 Jan 2020 11:05:10 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 2866AE087F; Wed, 29 Jan 2020 11:05:09 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id CFBEFE087F for ; Wed, 29 Jan 2020 11:05:08 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 7069B34DF6C for ; Wed, 29 Jan 2020 11:05:07 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 0981FE5 for ; Wed, 29 Jan 2020 11:05:05 +0000 (UTC) From: "Louis Sautier" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Louis Sautier" Message-ID: <1580295847.1c6d84beced12c06ae08c04955d5bb6f799a568e.sbraz@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/nagios-plugins-linux-madrisan/, ... X-VCS-Repository: repo/gentoo X-VCS-Files: net-analyzer/nagios-plugins-linux-madrisan/files/nagios-plugins-linux-madrisan-25-fix-fno-common.patch net-analyzer/nagios-plugins-linux-madrisan/nagios-plugins-linux-madrisan-25-r1.ebuild X-VCS-Directories: net-analyzer/nagios-plugins-linux-madrisan/files/ net-analyzer/nagios-plugins-linux-madrisan/ X-VCS-Committer: sbraz X-VCS-Committer-Name: Louis Sautier X-VCS-Revision: 1c6d84beced12c06ae08c04955d5bb6f799a568e X-VCS-Branch: master Date: Wed, 29 Jan 2020 11:05:05 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: ad03f364-3ba9-4f64-94b4-198a49749fcb X-Archives-Hash: c515566af03708a6e7e129f43973ada6 commit: 1c6d84beced12c06ae08c04955d5bb6f799a568e Author: Louis Sautier gentoo org> AuthorDate: Wed Jan 29 11:01:18 2020 +0000 Commit: Louis Sautier gentoo org> CommitDate: Wed Jan 29 11:04:07 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1c6d84be net-analyzer/nagios-plugins-linux-madrisan: fix build w. -fno-common Closes: https://bugs.gentoo.org/706536 Package-Manager: Portage-2.3.85, Repoman-2.3.20 Signed-off-by: Louis Sautier gentoo.org> ...-plugins-linux-madrisan-25-fix-fno-common.patch | 37 ++++++++++++++++++++++ .../nagios-plugins-linux-madrisan-25-r1.ebuild | 6 +++- 2 files changed, 42 insertions(+), 1 deletion(-) diff --git a/net-analyzer/nagios-plugins-linux-madrisan/files/nagios-plugins-linux-madrisan-25-fix-fno-common.patch b/net-analyzer/nagios-plugins-linux-madrisan/files/nagios-plugins-linux-madrisan-25-fix-fno-common.patch new file mode 100644 index 00000000000..74bddd66e74 --- /dev/null +++ b/net-analyzer/nagios-plugins-linux-madrisan/files/nagios-plugins-linux-madrisan-25-fix-fno-common.patch @@ -0,0 +1,37 @@ +From 4936ca25f3e9a2875ce063033e5e8f3a3590dab2 Mon Sep 17 00:00:00 2001 +From: Davide Madrisan +Date: Mon, 27 Jan 2020 22:00:41 +0100 +Subject: [PATCH] The build fails when '-fno-common' is added to CFLAGS + +As reported by 'sbraz', the build stops with the error message: + + (.bss+0x8): multiple definition of `program_name' + (.bss+0x0): multiple definition of `program_name_short' + +This flag will be apparently enabled by default in gcc 10. + +Fix this build problem by correctly referencing as extern both +the variables in the header file. + +Signed-off-by: Davide Madrisan +--- + include/progname.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/include/progname.h b/include/progname.h +index 576ed16..847122a 100644 +--- a/include/progname.h ++++ b/include/progname.h +@@ -25,10 +25,10 @@ extern "C" { + #endif + + /* String containing name the program is called with. */ +- const char *program_name; ++ extern const char *program_name; + + /* String containing a short version of 'program_name'. */ +- const char *program_name_short; ++ extern const char *program_name_short; + + /* Set program_name, based on argv[0]. + argv0 must be a string allocated with indefinite extent, and must not be diff --git a/net-analyzer/nagios-plugins-linux-madrisan/nagios-plugins-linux-madrisan-25-r1.ebuild b/net-analyzer/nagios-plugins-linux-madrisan/nagios-plugins-linux-madrisan-25-r1.ebuild index 6367fdc2f4e..284d0d9d1a8 100644 --- a/net-analyzer/nagios-plugins-linux-madrisan/nagios-plugins-linux-madrisan-25-r1.ebuild +++ b/net-analyzer/nagios-plugins-linux-madrisan/nagios-plugins-linux-madrisan-25-r1.ebuild @@ -1,4 +1,4 @@ -# Copyright 2019 Gentoo Authors +# Copyright 2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -20,6 +20,10 @@ IUSE="curl" DEPEND="curl? ( net-misc/curl:0= )" RDEPEND="${DEPEND}" +# https://github.com/madrisan/nagios-plugins-linux/issues/48 +# Will be in the next release +PATCHES=( "${FILESDIR}/${P}-fix-fno-common.patch" ) + S="${WORKDIR}/${MY_P}" src_prepare() {