From 01dadf65f71fd6bc62267213f00155e0e7bf7cea Mon Sep 17 00:00:00 2001 From: cwen Date: Mon, 19 Aug 2019 18:12:31 +0000 Subject: [PATCH] puzzles: unbreak on archs where char is unsigned by default (ppc, arm) OK landry@ --- games/puzzles/Makefile | 3 ++- games/puzzles/patches/patch-palisade_c | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 games/puzzles/patches/patch-palisade_c diff --git a/games/puzzles/Makefile b/games/puzzles/Makefile index b48f44b4763..149d475f024 100644 --- a/games/puzzles/Makefile +++ b/games/puzzles/Makefile @@ -1,8 +1,9 @@ -# $OpenBSD: Makefile,v 1.18 2019/07/12 20:46:23 sthen Exp $ +# $OpenBSD: Makefile,v 1.19 2019/08/19 18:12:31 cwen Exp $ COMMENT = collection of puzzles games DISTNAME = puzzles-20190415 +REVISION = 0 CATEGORIES = games MASTER_SITES = https://rhaalovely.net/stuff/ diff --git a/games/puzzles/patches/patch-palisade_c b/games/puzzles/patches/patch-palisade_c new file mode 100644 index 00000000000..d8bb2e49bad --- /dev/null +++ b/games/puzzles/patches/patch-palisade_c @@ -0,0 +1,18 @@ +$OpenBSD: patch-palisade_c,v 1.1 2019/08/19 18:12:31 cwen Exp $ + +Fix for archs where char is unsigned by default (ppc, arm): +error: result of comparison of constant -1 with expression of type +'clue' (aka 'char') + +Index: palisade.c +--- palisade.c.orig ++++ palisade.c +@@ -46,7 +46,7 @@ struct game_params { + int w, h, k; + }; + +-typedef char clue; ++typedef signed char clue; + typedef unsigned char borderflag; + + typedef struct shared_state {