Date: Mon, 17 Apr 2023 09:30:26 GMT From: Robert Clausecker <fuz@FreeBSD.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org Subject: git: 1092ffe19022 - main - games/uhexen: fix build with -fno-common, on big endian platforms Message-ID: <202304170930.33H9UQV7051444@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by fuz: URL: https://cgit.FreeBSD.org/ports/commit/?id=1092ffe19022aa17a164efc50b8b392d2a4e3f2e commit 1092ffe19022aa17a164efc50b8b392d2a4e3f2e Author: Robert Clausecker <fuz@FreeBSD.org> AuthorDate: 2023-04-15 12:50:27 +0000 Commit: Robert Clausecker <fuz@FreeBSD.org> CommitDate: 2023-04-17 09:27:24 +0000 games/uhexen: fix build with -fno-common, on big endian platforms - turns a duplicate definition into a declaration - replace nonexisting byte swap functions with gcc/clang intrinsics - define LICENSE --- games/uhexen/Makefile | 10 +++++----- games/uhexen/files/patch-include__h2def.h | 17 +++++++++++++++-- games/uhexen/files/patch-src_i__fbsdvideo.c | 20 ++++++++++++++++++++ 3 files changed, 40 insertions(+), 7 deletions(-) diff --git a/games/uhexen/Makefile b/games/uhexen/Makefile index 59d3705b1cdb..1d3f136d5906 100644 --- a/games/uhexen/Makefile +++ b/games/uhexen/Makefile @@ -1,6 +1,6 @@ PORTNAME= uhexen PORTVERSION= 0.601 -PORTREVISION= 11 +PORTREVISION= 12 CATEGORIES= games MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/U-hexen%20version%20${PORTVERSION} @@ -8,10 +8,10 @@ MAINTAINER= ports@FreeBSD.org COMMENT= Yet another port of Hexen, popular game from Raven Software WWW= http://uhexen.sourceforge.net/ -BROKEN_FreeBSD_13= ld: error: duplicate symbol: mouse_scale_factor -BROKEN_FreeBSD_14= ld: error: duplicate symbol: mouse_scale_factor -BROKEN_powerpc= fails to compile -BROKEN_powerpc64= fails to compile: m_misc.o: undefined reference to 'ShortSwap' +LICENSE= ACTIVISION +LICENSE_FILE= ${WRKSRC}/LICENSE +LICENSE_NAME= Activision Software License Agreement +LICENSE_PERMS= no-dist-mirror no-dist-sell no-pkg-mirror no-pkg-sell auto-accept USES= gmake sdl USE_SDL= mixer sdl diff --git a/games/uhexen/files/patch-include__h2def.h b/games/uhexen/files/patch-include__h2def.h index ed1cf5f5edde..87a61ca4f3ff 100644 --- a/games/uhexen/files/patch-include__h2def.h +++ b/games/uhexen/files/patch-include__h2def.h @@ -1,5 +1,5 @@ ---- include/h2def.h 2003/02/10 14:43:33 1.1 -+++ include/h2def.h 2003/02/10 14:46:37 +--- include/h2def.h.orig 2001-12-02 08:51:54 UTC ++++ include/h2def.h @@ -26,7 +26,11 @@ /* XXX ifdefs */ @@ -12,3 +12,16 @@ // Uncomment, to enable all timebomb stuff //#define TIMEBOMB +@@ -894,10 +898,8 @@ fixed_t FixedDiv2 (fixed_t a, fixed_t b); + #endif + + #ifdef __BIG_ENDIAN__ +-short ShortSwap(short); +-long LongSwap(long); +-#define SHORT(x) ShortSwap(x) +-#define LONG(x) LongSwap(x) ++#define SHORT(x) __builtin_bswap16(x) ++#define LONG(x) __builtin_bswap32(x) + #else + #define SHORT(x) (x) + #define LONG(x) (x) diff --git a/games/uhexen/files/patch-src_i__fbsdvideo.c b/games/uhexen/files/patch-src_i__fbsdvideo.c new file mode 100644 index 000000000000..525f2ba0c2ff --- /dev/null +++ b/games/uhexen/files/patch-src_i__fbsdvideo.c @@ -0,0 +1,20 @@ +--- src/i_fbsdvideo.c.orig 2023-04-15 12:37:20 UTC ++++ src/i_fbsdvideo.c +@@ -8,7 +8,7 @@ + #include <sys/fbio.h> + #include <sys/kbio.h> + #include <sys/consio.h> +-#include <sys/termios.h> ++#include <termios.h> + #include <sys/mman.h> + #include <stdlib.h> + #include <unistd.h> +@@ -26,7 +26,7 @@ + #define RestorePalette() SavRstPalette(FBIO_SETPALETTE) + + extern int usemouse; +-int mouse_scale_factor; ++extern int mouse_scale_factor; + + static event_t event; +
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202304170930.33H9UQV7051444>