From: Bernard Cafarelli Date: Sun, 1 Mar 2020 15:12:33 +0000 (+0100) Subject: x11-plugins/wmdots: fix build with -fno-common X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=59f3ded139d77e75745a3fd95f9999bdb3668a9c;p=gentoo.git x11-plugins/wmdots: fix build with -fno-common Closes: https://bugs.gentoo.org/707532 Package-Manager: Portage-2.3.90, Repoman-2.3.20 Signed-off-by: Bernard Cafarelli --- diff --git a/x11-plugins/wmdots/files/wmdots-0.2_beta-gcc-10.patch b/x11-plugins/wmdots/files/wmdots-0.2_beta-gcc-10.patch new file mode 100644 index 000000000000..f4e522fe5cff --- /dev/null +++ b/x11-plugins/wmdots/files/wmdots-0.2_beta-gcc-10.patch @@ -0,0 +1,27 @@ +diff -Naur wmdots.orig/wmdots/wmdots.c wmdots/wmdots/wmdots.c +--- wmdots.orig/wmdots/wmdots.c 1999-10-11 21:39:11.000000000 +0200 ++++ wmdots/wmdots/wmdots.c 2020-03-01 16:08:39.492275206 +0100 +@@ -315,6 +315,9 @@ + // 10,30,&y_off,-5,30,10 + // }; + ++Display *display; ++Window Root, iconwin, win; ++ + // ----------------------------------------------------------------------- + // draw a point at x/y in specified colour + +diff -Naur wmdots.orig/wmgeneral/wmgeneral.h wmdots/wmgeneral/wmgeneral.h +--- wmdots.orig/wmgeneral/wmgeneral.h 1998-10-16 02:16:59.000000000 +0200 ++++ wmdots/wmgeneral/wmgeneral.h 2020-03-01 16:08:45.412276631 +0100 +@@ -36,8 +36,8 @@ + /* Global variable */ + /*******************/ + +-Display *display; +-Window Root, iconwin, win; ++extern Display *display; ++extern Window Root, iconwin, win; + + + /***********************/ diff --git a/x11-plugins/wmdots/wmdots-0.2_beta-r1.ebuild b/x11-plugins/wmdots/wmdots-0.2_beta-r1.ebuild index 5aaba6401e1c..7c4b91c7072a 100644 --- a/x11-plugins/wmdots/wmdots-0.2_beta-r1.ebuild +++ b/x11-plugins/wmdots/wmdots-0.2_beta-r1.ebuild @@ -21,6 +21,10 @@ DEPEND="${RDEPEND}" S="${WORKDIR}/${PN}" src_prepare() { + pushd "${WORKDIR}" || die + eapply "${FILESDIR}"/${P}-gcc-10.patch + popd || die + default eapply "${FILESDIR}"/${P}-stringh.patch sed -e "s|cc|$(tc-getCC)|g" \