git: 975c082fd1c4 - main - math/gkmap: fix build with -fno-common
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 08 Dec 2021 04:54:17 UTC
The branch main has been updated by tagattie:
URL: https://cgit.FreeBSD.org/ports/commit/?id=975c082fd1c451a3ad276e398df7eb4c60698b02
commit 975c082fd1c451a3ad276e398df7eb4c60698b02
Author: Robert Clausecker <fuz@fuz.su>
AuthorDate: 2021-12-08 04:52:35 +0000
Commit: Hiroki Tagato <tagattie@FreeBSD.org>
CommitDate: 2021-12-08 04:54:03 +0000
math/gkmap: fix build with -fno-common
PR: 259615
Approved by: javad.kouhi@gmail.com (maintainer timeout, 5 weeks)
---
math/gkmap/Makefile | 8 +++-----
math/gkmap/files/patch-src_init.c | 14 ++++++++++++++
math/gkmap/files/patch-src_kmap__struct.h | 26 ++++++++++++++++++++++++++
3 files changed, 43 insertions(+), 5 deletions(-)
diff --git a/math/gkmap/Makefile b/math/gkmap/Makefile
index f60d57f636ad..3b598de8316e 100644
--- a/math/gkmap/Makefile
+++ b/math/gkmap/Makefile
@@ -2,7 +2,7 @@
PORTNAME= gkmap
PORTVERSION= 0.2
-PORTREVISION= 3
+PORTREVISION= 4
CATEGORIES= math
MASTER_SITES= SF/gkmap/gkmap/gkmap-${PORTVERSION}/
@@ -11,11 +11,9 @@ COMMENT= Simplification of Boolean Functions using Karnaugh Map
LICENSE= GPLv2
-BROKEN_FreeBSD_13= ld: error: duplicate symbol: cell_array
-BROKEN_FreeBSD_14= ld: error: duplicate symbol: cell_array
-
LIB_DEPENDS= libfontconfig.so:x11-fonts/fontconfig \
- libfreetype.so:print/freetype2
+ libfreetype.so:print/freetype2 \
+ libharfbuzz.so:print/harfbuzz
USES= gnome pkgconfig dos2unix
USE_GNOME= cairo gdkpixbuf2 gtk20 libglade2 libxml2
diff --git a/math/gkmap/files/patch-src_init.c b/math/gkmap/files/patch-src_init.c
new file mode 100644
index 000000000000..03466c7bc4de
--- /dev/null
+++ b/math/gkmap/files/patch-src_init.c
@@ -0,0 +1,14 @@
+--- src/init.c.orig 2021-11-02 09:37:31 UTC
++++ src/init.c
+@@ -1,5 +1,11 @@
+ #include "kmap_struct.h"
+
++/* globals */
++struct cell cell_array[4][4];
++struct output out_array[20];
++char semi_final_out[70];
++char final_out[100];
++
+ void init_kmap(void)
+ {
+ int i,j;
diff --git a/math/gkmap/files/patch-src_kmap__struct.h b/math/gkmap/files/patch-src_kmap__struct.h
new file mode 100644
index 000000000000..b2b22d1c410f
--- /dev/null
+++ b/math/gkmap/files/patch-src_kmap__struct.h
@@ -0,0 +1,26 @@
+--- src/kmap_struct.h.orig 2021-11-02 09:33:21 UTC
++++ src/kmap_struct.h
+@@ -36,7 +36,7 @@ struct cell
+ struct cell *left,*right,*down,*up;
+ char col_string[3], row_string[3];
+ };
+-struct cell cell_array[4][4];
++extern struct cell cell_array[4][4];
+
+ struct output
+ {
+@@ -44,10 +44,10 @@ struct output
+ char cell_num_string[10];
+ int status;
+ };
+-struct output out_array[20];
+-
+-char semi_final_out[70];
+-char final_out[100];
++extern struct output out_array[20];
++
++extern char semi_final_out[70];
++extern char final_out[100];
+
+
+