summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-03-19 00:32:11 +0000
committerSam James <sam@gentoo.org>2023-03-19 00:32:11 +0000
commit58b32fc67a278d736a891bf917a29de8c22c967f (patch)
tree9a318265a5e2be68c1dbc0f9f79e1e2dab573445 /net-misc/lldpd
parentnet-libs/libsoup: fix HTTP/2 on unsigned char arches, -Wstrict-prototype (diff)
downloadgentoo-58b32fc67a278d736a891bf917a29de8c22c967f.tar.gz
gentoo-58b32fc67a278d736a891bf917a29de8c22c967f.tar.bz2
gentoo-58b32fc67a278d736a891bf917a29de8c22c967f.zip
net-misc/lldpd: fix configure w/ clang 16
Closes: https://bugs.gentoo.org/900286 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'net-misc/lldpd')
-rw-r--r--net-misc/lldpd/files/lldpd-1.0.16-configure-clang16.patch23
-rw-r--r--net-misc/lldpd/lldpd-1.0.16-r2.ebuild (renamed from net-misc/lldpd/lldpd-1.0.16-r1.ebuild)4
2 files changed, 27 insertions, 0 deletions
diff --git a/net-misc/lldpd/files/lldpd-1.0.16-configure-clang16.patch b/net-misc/lldpd/files/lldpd-1.0.16-configure-clang16.patch
new file mode 100644
index 000000000000..bd03399e1b36
--- /dev/null
+++ b/net-misc/lldpd/files/lldpd-1.0.16-configure-clang16.patch
@@ -0,0 +1,23 @@
+https://bugs.gentoo.org/900286
+https://github.com/lldpd/lldpd/commit/01aee0f3601c60e570aeb9040c036c83d053cc5a
+
+From 01aee0f3601c60e570aeb9040c036c83d053cc5a Mon Sep 17 00:00:00 2001
+From: Florian Weimer <fweimer@redhat.com>
+Date: Thu, 8 Dec 2022 13:01:07 +0100
+Subject: [PATCH] m4/progname.m4: Include <stdio.h> for printf in
+ lldp_CHECK___PROGNAME
+
+Otherwise the checks always fails with a compiler that does not
+support implict function declarations.
+--- a/m4/progname.m4
++++ b/m4/progname.m4
+@@ -4,7 +4,7 @@
+ AC_DEFUN([lldp_CHECK___PROGNAME],[
+ AC_CACHE_CHECK([whether libc defines __progname], lldp_cv_check___progname, [
+ AC_LINK_IFELSE([AC_LANG_PROGRAM(
+- [[]],
++ [[#include<stdio.h>]],
+ [[ extern char *__progname; printf("%s", __progname); ]])],
+ [ lldp_cv_check___progname="yes" ],
+ [ lldp_cv_check___progname="no" ])
+
diff --git a/net-misc/lldpd/lldpd-1.0.16-r1.ebuild b/net-misc/lldpd/lldpd-1.0.16-r2.ebuild
index 57f61cc2162b..52edf114f8db 100644
--- a/net-misc/lldpd/lldpd-1.0.16-r1.ebuild
+++ b/net-misc/lldpd/lldpd-1.0.16-r2.ebuild
@@ -44,6 +44,10 @@ REQUIRED_USE="
# tests need root
RESTRICT+=" test"
+PATCHES=(
+ "${FILESDIR}"/${PN}-1.0.16-configure-clang16.patch
+)
+
src_prepare() {
default