commit:     7d025d917e295e83b5ea466750e278f4d1132002
Author:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
AuthorDate: Thu Nov 10 22:56:19 2022 +0000
Commit:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
CommitDate: Thu Nov 10 23:03:42 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7d025d91

app-misc/graphlcd-base: fix compilation with musl

Closes: https://bugs.gentoo.org/860795
Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>

 .../files/graphlcd-base-2.0.3-musl.patch           | 31 ++++++++++++++++++++++
 .../graphlcd-base/graphlcd-base-2.0.3-r3.ebuild    |  1 +
 2 files changed, 32 insertions(+)

diff --git a/app-misc/graphlcd-base/files/graphlcd-base-2.0.3-musl.patch 
b/app-misc/graphlcd-base/files/graphlcd-base-2.0.3-musl.patch
new file mode 100644
index 000000000000..927d48071520
--- /dev/null
+++ b/app-misc/graphlcd-base/files/graphlcd-base-2.0.3-musl.patch
@@ -0,0 +1,31 @@
+From dd01f3be61f4d3e7078e06b759a890dcf33c2268 Mon Sep 17 00:00:00 2001
+From: Conrad Kostecki <[email protected]>
+Date: Thu, 10 Nov 2022 23:53:40 +0100
+Subject: [PATCH] Fix compilation with >=GCC-12 and Musl
+
+This will fix a compiling failure:
+g++  -O2 -pipe -MMD -MP -MMD -MP -fPIC -I.. -c -D_GNU_SOURCE  skin.c
+In file included from config.c:2:
+type.h:48:17: error: expected ')' before 'Number'
+   48 |     cType(time_t Number): mType(number), mNumber(Number), mUpdateIn(0) 
{}
+      |          ~      ^~~~~~~
+      |                 )
+
+Signed-off-by: Conrad Kostecki <[email protected]>
+---
+ glcdskin/type.h | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/glcdskin/type.h b/glcdskin/type.h
+index 4d54de8..350fa5f 100644
+--- a/glcdskin/type.h
++++ b/glcdskin/type.h
+@@ -19,6 +19,8 @@
+ #include <stdint.h>
+ #include <stdlib.h>
+ 
++#include <time.h>
++
+ namespace GLCD
+ {
+ 

diff --git a/app-misc/graphlcd-base/graphlcd-base-2.0.3-r3.ebuild 
b/app-misc/graphlcd-base/graphlcd-base-2.0.3-r3.ebuild
index 46bedc2b59c4..df811179a910 100644
--- a/app-misc/graphlcd-base/graphlcd-base-2.0.3-r3.ebuild
+++ b/app-misc/graphlcd-base/graphlcd-base-2.0.3-r3.ebuild
@@ -36,6 +36,7 @@ PATCHES=(
        "${FILESDIR}/${PN}-2.0.3-clang.patch"
        "${FILESDIR}/${PN}-2.0.3-cpp.patch"
        "${FILESDIR}/${PN}-2.0.3-imagemagick7.patch"
+       "${FILESDIR}/${PN}-2.0.3-musl.patch"
 )
 
 src_prepare() {

Reply via email to