mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 01:39:16 -04:00
lang/spl: patch and unbreak with -fno-common
PR: 257295
This commit is contained in:
parent
ae1fa233bc
commit
f11e9f1541
3 changed files with 40 additions and 7 deletions
|
@ -2,26 +2,23 @@
|
||||||
|
|
||||||
PORTNAME= spl
|
PORTNAME= spl
|
||||||
PORTVERSION= 1.2.1
|
PORTVERSION= 1.2.1
|
||||||
PORTREVISION= 4
|
PORTREVISION= 5
|
||||||
CATEGORIES= lang
|
CATEGORIES= lang
|
||||||
MASTER_SITES= http://shakespearelang.sourceforge.net/download/
|
MASTER_SITES= http://shakespearelang.sourceforge.net/download/
|
||||||
|
|
||||||
MAINTAINER= ports@FreeBSD.org
|
MAINTAINER= fuz@fuz.su
|
||||||
COMMENT= Shakespeare programming language
|
COMMENT= Shakespeare programming language
|
||||||
|
|
||||||
LICENSE= GPLv2+
|
LICENSE= GPLv2+
|
||||||
LICENSE_FILE= ${WRKSRC}/COPYING
|
LICENSE_FILE= ${WRKSRC}/COPYING
|
||||||
|
|
||||||
BROKEN_FreeBSD_13= ld: error: duplicate symbol: cast
|
|
||||||
BROKEN_FreeBSD_14= ld: error: duplicate symbol: cast
|
|
||||||
|
|
||||||
USES= bison gmake
|
USES= bison gmake
|
||||||
|
|
||||||
|
OPTIONS_DEFINE= EXAMPLES
|
||||||
|
|
||||||
ALL_EXAMPLES= Makefile fibonacci.spl fibonacci2.spl guess.spl hello.spl \
|
ALL_EXAMPLES= Makefile fibonacci.spl fibonacci2.spl guess.spl hello.spl \
|
||||||
primes.spl reverse.spl shakesbeer.spl
|
primes.spl reverse.spl shakesbeer.spl
|
||||||
|
|
||||||
OPTIONS_DEFINE= EXAMPLES
|
|
||||||
|
|
||||||
post-patch:
|
post-patch:
|
||||||
.for f in . examples
|
.for f in . examples
|
||||||
${REINPLACE_CMD} -e 's,= gcc,?= gcc,' -e 's,^CCFLAGS.*,CFLAGS += -Wall,' \
|
${REINPLACE_CMD} -e 's,= gcc,?= gcc,' -e 's,^CCFLAGS.*,CFLAGS += -Wall,' \
|
||||||
|
|
10
lang/spl/files/patch-libspl.c
Normal file
10
lang/spl/files/patch-libspl.c
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
--- libspl.c.orig 2021-07-20 09:38:16 UTC
|
||||||
|
+++ libspl.c
|
||||||
|
@@ -27,6 +27,7 @@ USA.
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
+#define GLOBAL
|
||||||
|
#include "spl.h"
|
||||||
|
#include "strutils.h"
|
||||||
|
|
26
lang/spl/files/patch-spl.h
Normal file
26
lang/spl/files/patch-spl.h
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
--- spl.h.orig 2021-07-20 09:35:24 UTC
|
||||||
|
+++ spl.h
|
||||||
|
@@ -43,13 +43,17 @@ typedef struct {
|
||||||
|
|
||||||
|
/* global variables */
|
||||||
|
|
||||||
|
-CHARACTER **cast;
|
||||||
|
-CHARACTER *first_person;
|
||||||
|
-CHARACTER *second_person;
|
||||||
|
+#ifndef GLOBAL
|
||||||
|
+# define GLOBAL extern
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
-int truth_flag;
|
||||||
|
-int num_on_stage;
|
||||||
|
-int num_cast;
|
||||||
|
+GLOBAL CHARACTER **cast;
|
||||||
|
+GLOBAL CHARACTER *first_person;
|
||||||
|
+GLOBAL CHARACTER *second_person;
|
||||||
|
+
|
||||||
|
+GLOBAL int truth_flag;
|
||||||
|
+GLOBAL int num_on_stage;
|
||||||
|
+GLOBAL int num_cast;
|
||||||
|
|
||||||
|
/* function prototypes */
|
||||||
|
extern void activate_character(int line, CHARACTER *character);
|
Loading…
Add table
Reference in a new issue