git: a0f774de061d - main - games/iortcw: fix build on powerpc*

From: Piotr Kubaj <pkubaj_at_FreeBSD.org>
Date: Wed, 24 Apr 2024 21:21:46 UTC
The branch main has been updated by pkubaj:

URL: https://cgit.FreeBSD.org/ports/commit/?id=a0f774de061d2c484393fcadeda2817bc5fda19b

commit a0f774de061d2c484393fcadeda2817bc5fda19b
Author:     Piotr Kubaj <pkubaj@FreeBSD.org>
AuthorDate: 2024-04-19 17:17:22 +0000
Commit:     Piotr Kubaj <pkubaj@FreeBSD.org>
CommitDate: 2024-04-24 21:21:13 +0000

    games/iortcw: fix build on powerpc*
---
 games/iortcw/Makefile                |  2 +-
 games/iortcw/files/patch-MP_Makefile | 11 +++++++++++
 games/iortcw/files/patch-SP_Makefile | 11 +++++++++++
 3 files changed, 23 insertions(+), 1 deletion(-)

diff --git a/games/iortcw/Makefile b/games/iortcw/Makefile
index 9c20425cd256..86dff84e9df0 100644
--- a/games/iortcw/Makefile
+++ b/games/iortcw/Makefile
@@ -30,7 +30,7 @@ MAKE_ARGS=	BINDIR="${STAGEDIR}${PREFIX}/bin" \
 
 LDFLAGS_i386=	-Wl,-znotext
 
-PLIST_SUB=	ARCH="${ARCH:S/amd64/x86_64/:S/i386/x86/:S/powerpc/ppc/}" \
+PLIST_SUB=	ARCH="${ARCH:S/amd64/x86_64/:S/i386/x86/}" \
 		WOLFDIR="${WOLFDIR}"
 
 SUB_FILES=	iowolfded iowolfmp iowolfsp pkg-message
diff --git a/games/iortcw/files/patch-MP_Makefile b/games/iortcw/files/patch-MP_Makefile
index be11bab35ea7..195d8804563a 100644
--- a/games/iortcw/files/patch-MP_Makefile
+++ b/games/iortcw/files/patch-MP_Makefile
@@ -1,5 +1,16 @@
 --- MP/Makefile.orig	2019-03-16 18:09:48 UTC
 +++ MP/Makefile
+@@ -5,8 +5,8 @@ COMPILE_PLATFORM=$(shell uname | sed -e 's/_.*//' | tr
+ #
+ 
+ COMPILE_PLATFORM=$(shell uname | sed -e 's/_.*//' | tr '[:upper:]' '[:lower:]' | sed -e 's/\//_/g')
+-COMPILE_ARCH=$(shell uname -m | sed -e 's/i.86/x86/' | sed -e 's/^arm.*/arm/')
+-ARM_VER_CHECK=$(shell uname -m)
++COMPILE_ARCH=$(shell uname -p | sed -e 's/i.86/x86/' | sed -e 's/^arm.*/arm/')
++ARM_VER_CHECK=$(shell uname -p)
+ 
+ ifeq ($(COMPILE_PLATFORM),sunos)
+   # Solaris uname and GNU uname differ
 @@ -101,14 +101,6 @@ export ARCH
  endif
  export ARCH
diff --git a/games/iortcw/files/patch-SP_Makefile b/games/iortcw/files/patch-SP_Makefile
index 294a9b7c76d6..40cd99e00098 100644
--- a/games/iortcw/files/patch-SP_Makefile
+++ b/games/iortcw/files/patch-SP_Makefile
@@ -1,5 +1,16 @@
 --- SP/Makefile.orig	2019-03-16 18:09:48 UTC
 +++ SP/Makefile
+@@ -5,8 +5,8 @@ COMPILE_PLATFORM=$(shell uname | sed -e 's/_.*//' | tr
+ #
+ 
+ COMPILE_PLATFORM=$(shell uname | sed -e 's/_.*//' | tr '[:upper:]' '[:lower:]' | sed -e 's/\//_/g')
+-COMPILE_ARCH=$(shell uname -m | sed -e 's/i.86/x86/' | sed -e 's/^arm.*/arm/')
+-ARM_VER_CHECK=$(shell uname -m)
++COMPILE_ARCH=$(shell uname -p | sed -e 's/i.86/x86/' | sed -e 's/^arm.*/arm/')
++ARM_VER_CHECK=$(shell uname -p)
+ 
+ ifeq ($(COMPILE_PLATFORM),sunos)
+   # Solaris uname and GNU uname differ
 @@ -98,14 +98,6 @@ export ARCH
  endif
  export ARCH