Date: Sun, 28 Jan 2024 02:32:14 GMT From: Piotr Kubaj <pkubaj@FreeBSD.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org Subject: git: 51624c490261 - main - net/drawterm: fix build on powerpc* Message-ID: <202401280232.40S2WEVU062511@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by pkubaj: URL: https://cgit.FreeBSD.org/ports/commit/?id=51624c4902617da5d2dee11b390ada2fd61e25b3 commit 51624c4902617da5d2dee11b390ada2fd61e25b3 Author: Piotr Kubaj <pkubaj@FreeBSD.org> AuthorDate: 2024-01-26 17:56:18 +0000 Commit: Piotr Kubaj <pkubaj@FreeBSD.org> CommitDate: 2024-01-28 02:32:04 +0000 net/drawterm: fix build on powerpc* arch=`uname -m|sed 's/i.86/386/;s/Power Macintosh/power/; s/x86_64/amd64/'`; (cd posix-$arch && make) cd: posix-powerpc: No such file or directory *** Error code 2 --- net/drawterm/files/patch-Make.freebsd | 27 +++++++-------------------- net/drawterm/files/patch-posix-power_Makefile | 11 +++++++++++ net/drawterm/files/patch-posix-power_tas.c | 27 +++++++++++++++++++++++++++ 3 files changed, 45 insertions(+), 20 deletions(-) diff --git a/net/drawterm/files/patch-Make.freebsd b/net/drawterm/files/patch-Make.freebsd index 127a6bbf63bb..245dc6ff6ae1 100644 --- a/net/drawterm/files/patch-Make.freebsd +++ b/net/drawterm/files/patch-Make.freebsd @@ -1,22 +1,9 @@ ---- Make.freebsd.orig 2023-11-18 06:48:07 UTC +--- Make.freebsd.orig 2023-09-03 17:22:52 UTC +++ Make.freebsd -@@ -1,16 +1,12 @@ - # OpenBSD - PTHREAD=-pthread --AR=ar --AS=as - RANLIB=ranlib --X11=/usr/local --CC=clang --CFLAGS=-Wall -Wno-missing-braces -ggdb -I$(ROOT) -I$(ROOT)/include -I$(ROOT)/kern -c -I$(X11)/include -D_THREAD_SAFE $(PTHREAD) -O2 -+CFLAGS+=-Wall -Wno-missing-braces -ggdb -I$(ROOT) -I$(ROOT)/include -I$(ROOT)/kern -c -I$(X11)/include -D_THREAD_SAFE $(PTHREAD) -O2 - O=o - OS=posix - GUI=x11 --LDADD=-L$(X11)/lib64 -L$(X11)/lib -lX11 -ggdb --LDFLAGS=$(PTHREAD) -+LDADD=-lX11 -ggdb -+LDFLAGS+=$(PTHREAD) - TARG=drawterm - AUDIO=unix +@@ -17,5 +17,5 @@ libmachdep.a: + all: default + libmachdep.a: +- arch=`uname -m|sed 's/i.86/386/;s/Power Macintosh/power/; s/x86_64/amd64/'`; \ ++ arch=`uname -m|sed 's/i.86/386/;s/powerpc.*/power/; s/x86_64/amd64/'`; \ + (cd posix-$$arch && make) diff --git a/net/drawterm/files/patch-posix-power_Makefile b/net/drawterm/files/patch-posix-power_Makefile new file mode 100644 index 000000000000..b38d8ad01923 --- /dev/null +++ b/net/drawterm/files/patch-posix-power_Makefile @@ -0,0 +1,11 @@ +--- posix-power/Makefile.orig 2023-09-03 17:22:52 UTC ++++ posix-power/Makefile +@@ -2,8 +2,6 @@ LIB=../libmachdep.a + include ../Make.config + LIB=../libmachdep.a + +-CFLAGS+= -Wa,-mregnames +- + OFILES=\ + getcallerpc.$O\ + tas.$O diff --git a/net/drawterm/files/patch-posix-power_tas.c b/net/drawterm/files/patch-posix-power_tas.c new file mode 100644 index 000000000000..cb51c07bec77 --- /dev/null +++ b/net/drawterm/files/patch-posix-power_tas.c @@ -0,0 +1,27 @@ +--- posix-power/tas.c.orig 2024-01-26 17:52:14 UTC ++++ posix-power/tas.c +@@ -15,16 +15,16 @@ tas(int *x) + * r4 (x) and r5 (temp). + */ + __asm__("\n sync\n" +- " li r0,0\n" +- " mr r4,%1 /* &l->val */\n" +- " lis r5,0xdead /* assemble constant 0xdeaddead */\n" +- " ori r5,r5,0xdead /* \" */\n" ++ " li 0,0\n" ++ " mr 4,%1 /* &l->val */\n" ++ " lis 5,0xdead /* assemble constant 0xdeaddead */\n" ++ " ori 5,5,0xdead /* \" */\n" + "tas1:\n" +- " dcbf r4,r0 /* cache flush; \"fix for 603x bug\" */\n" +- " lwarx %0,r4,r0 /* v = l->val with reservation */\n" +- " cmp cr0,0,%0,r0 /* v == 0 */\n" ++ " dcbf 4,0 /* cache flush; \"fix for 603x bug\" */\n" ++ " lwarx %0,4,0 /* v = l->val with reservation */\n" ++ " cmp cr0,0,%0,0 /* v == 0 */\n" + " bne tas0\n" +- " stwcx. r5,r4,r0 /* if (l->val same) l->val = 0xdeaddead */\n" ++ " stwcx. 5,4,0 /* if (l->val same) l->val = 0xdeaddead */\n" + " bne tas1\n" + "tas0:\n" + " sync\n"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202401280232.40S2WEVU062511>