diff options
author | ryoon <ryoon@pkgsrc.org> | 2021-08-27 03:41:41 +0000 |
---|---|---|
committer | ryoon <ryoon@pkgsrc.org> | 2021-08-27 03:41:41 +0000 |
commit | 0512b62924ba2f7a0d5f79e162fa64030151fd48 (patch) | |
tree | 34926c2dadcd2b104e00cc3eb97516a6a9ad96ad /emulators | |
parent | 2a099873fc569c494070c17614bab11bf51e77bf (diff) | |
download | pkgsrc-0512b62924ba2f7a0d5f79e162fa64030151fd48.tar.gz |
xcopilot: Workaround for NetBSD/amd64. Bump PKGREVISION
* Add workaround for NetBSD/amd64. Not tested under other LP64PLATFORMS
and OSes.
* Include some header files to resolve implicit uses.
* Fix some warinigs.
Diffstat (limited to 'emulators')
-rw-r--r-- | emulators/xcopilot/Makefile | 6 | ||||
-rw-r--r-- | emulators/xcopilot/distinfo | 18 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-ac | 16 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-ag | 34 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-aj | 18 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-fakecall.c | 14 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-main.h | 12 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mc68k_newcpu.c | 14 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_basic.c | 14 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_buttons.h | 13 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_libmx.h | 15 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_request.c | 14 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_select.c | 15 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_test__filesel.c | 14 | ||||
-rw-r--r-- | emulators/xcopilot/patches/patch-mx_test__menu.c | 14 |
15 files changed, 202 insertions, 29 deletions
diff --git a/emulators/xcopilot/Makefile b/emulators/xcopilot/Makefile index b0938306da8..395b5e8b03f 100644 --- a/emulators/xcopilot/Makefile +++ b/emulators/xcopilot/Makefile @@ -1,8 +1,8 @@ -# $NetBSD: Makefile,v 1.22 2020/03/27 15:12:27 ryoon Exp $ +# $NetBSD: Makefile,v 1.23 2021/08/27 03:41:41 ryoon Exp $ # DISTNAME= xcopilot-0.6.6 -PKGREVISION= 1 +PKGREVISION= 2 CATEGORIES= emulators #MASTER_SITES= http://xcopilot.cuspy.com/build/ @@ -13,8 +13,6 @@ LICENSE= gnu-gpl-v2 MAKE_JOBS_SAFE= no -BROKEN_ON_PLATFORM= ${LP64PLATFORMS} # suspected LP64 bugs - GNU_CONFIGURE= YES post-extract: diff --git a/emulators/xcopilot/distinfo b/emulators/xcopilot/distinfo index 4cb84fdce19..b7d332f6d86 100644 --- a/emulators/xcopilot/distinfo +++ b/emulators/xcopilot/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.7 2015/11/03 20:31:10 agc Exp $ +$NetBSD: distinfo,v 1.8 2021/08/27 03:41:41 ryoon Exp $ SHA1 (xcopilot-0.6.6.tar.gz) = 91f76d1fd8fc19b6fea18853425aa3076e945d5d RMD160 (xcopilot-0.6.6.tar.gz) = e267495db384070e7e192043f23290f0004ecd4a @@ -6,13 +6,23 @@ SHA512 (xcopilot-0.6.6.tar.gz) = 3f4d789064993a014156caf291db39ab78e6fcf79dc25d6 Size (xcopilot-0.6.6.tar.gz) = 343264 bytes SHA1 (patch-aa) = 3354ed73dfa6c05273c7f430d45bacb0c8adbcf5 SHA1 (patch-ab) = d0e1eba65c0e8c963953856b939629fa0b99ea3c -SHA1 (patch-ac) = 7755e1a2ada8e3ca4f1e7d144b82d166ed2d3360 +SHA1 (patch-ac) = eb056a51d3989be4cba91ff851699a72879f2250 SHA1 (patch-ad) = b59e359dc575f3321385e54b87c9d6342461bf6f SHA1 (patch-ae) = 26067d585aac5fc30fcc8bc58b561acc4bdfae44 SHA1 (patch-af) = 5b1a93a5b08444e53fdbb17e1148149542cc6dd1 -SHA1 (patch-ag) = 68a22072946811f9cc97434f532081a07fda567f +SHA1 (patch-ag) = b68648a69706482b2464c19fea3e3289b2293f08 SHA1 (patch-ah) = fa166c5ecf7458c91f89b216aee5acb6de270292 SHA1 (patch-ai) = 255d997e2ef340a8d4b91ce25c2a3071df5c4520 -SHA1 (patch-aj) = 560a3dd902323ec1d07c292b6e8f95acb6c1c939 +SHA1 (patch-aj) = 1039e3f8c09e5963560c52f2d990d951cf956f02 SHA1 (patch-ak) = 830984e8d2992b3c6ff1229309328717b4f9f473 SHA1 (patch-al) = 991331f9cd004ced4b37253a55e6ecc3e66cc7c3 +SHA1 (patch-fakecall.c) = e4da6004f8a3353847f862587882e6777c743e4e +SHA1 (patch-main.h) = 037092c49353274215232fb07a26328e4a003ade +SHA1 (patch-mc68k_newcpu.c) = 6b96b5f450859377bab8ac360e2a982f8ac17b06 +SHA1 (patch-mx_basic.c) = 4a89ea94eb9467e3363c43695d75f825be36720c +SHA1 (patch-mx_buttons.h) = fbbb4863a4ef846056623de3c35105c5151fea93 +SHA1 (patch-mx_libmx.h) = d3f3e6bc3fa7234f0267d4e8008820ab4d65331c +SHA1 (patch-mx_request.c) = 0dd93dea77633d974993c6ef31981606207520b0 +SHA1 (patch-mx_select.c) = 53c02e231bbf9c3bc0f399c84e058ca7bc7bc403 +SHA1 (patch-mx_test__filesel.c) = 574bfeaa28bd23ad4da1bb87d3de4002a7793d70 +SHA1 (patch-mx_test__menu.c) = d4da66fc284885df42abbf51699a8babec59c942 diff --git a/emulators/xcopilot/patches/patch-ac b/emulators/xcopilot/patches/patch-ac index 3ebe55a582a..b455155bf04 100644 --- a/emulators/xcopilot/patches/patch-ac +++ b/emulators/xcopilot/patches/patch-ac @@ -1,22 +1,22 @@ -$NetBSD: patch-ac,v 1.2 2006/06/30 22:14:49 tron Exp $ +$NetBSD: patch-ac,v 1.3 2021/08/27 03:41:41 ryoon Exp $ ---- mc68k/memory.c.orig 1998-08-25 05:52:56.000000000 +0100 -+++ mc68k/memory.c 2006-06-30 23:09:38.000000000 +0100 -@@ -346,9 +346,11 @@ +--- mc68k/memory.c.orig 1998-08-25 04:52:56.000000000 +0000 ++++ mc68k/memory.c +@@ -346,9 +346,11 @@ verify_entrypoint(const void *rom) 0xff, 0xff, 0x00 }; const unsigned char *bootsign = _bootsign, *bootmask = _bootmask; - + char *p; + -+ p = (const char *)rom; ++ p = (char *)rom; while ((*bootsign & *bootmask) == *bootsign) - if ((*((char *)rom)++ & *bootmask++) != *bootsign++) + if ((*p++ & *bootmask++) != *bootsign++) return 0; return 1; -@@ -377,6 +379,7 @@ +@@ -377,6 +379,7 @@ static int load_rom(const char *dir, con int i; char *rombuf; char *resetv; @@ -24,7 +24,7 @@ $NetBSD: patch-ac,v 1.2 2006/06/30 22:14:49 tron Exp $ int f; struct stat st; -@@ -405,12 +408,24 @@ +@@ -405,12 +408,24 @@ static int load_rom(const char *dir, con rom_size = pow_of_2; } @@ -53,7 +53,7 @@ $NetBSD: patch-ac,v 1.2 2006/06/30 22:14:49 tron Exp $ if (!nocheck) { /* Check if the reset vector looks plausible */ resetv = (char *)rommemory + -@@ -430,23 +445,15 @@ +@@ -430,23 +445,15 @@ static int load_rom(const char *dir, con offset = resetv - find_entrypoint((char *)rommemory); } diff --git a/emulators/xcopilot/patches/patch-ag b/emulators/xcopilot/patches/patch-ag index ebf7ffeba1d..e9427a907d4 100644 --- a/emulators/xcopilot/patches/patch-ag +++ b/emulators/xcopilot/patches/patch-ag @@ -1,8 +1,8 @@ -$NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ +$NetBSD: patch-ag,v 1.2 2021/08/27 03:41:41 ryoon Exp $ ---- display.c.orig Tue Aug 25 15:56:02 1998 -+++ display.c Tue Feb 6 15:02:19 2001 -@@ -272,8 +272,13 @@ +--- display.c.orig 1998-08-25 13:56:02.000000000 +0000 ++++ display.c +@@ -272,8 +272,13 @@ static void xcpPutImage(int x, int y, in } static int xcpHandleExpose(XEvent *event) { @@ -18,7 +18,7 @@ $NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ return event->xexpose.count; } -@@ -360,15 +365,26 @@ +@@ -360,15 +365,26 @@ static void xcpKeyEvent(int down, int ke typedef struct _Key { const char *name; XRectangle bounds; @@ -52,7 +52,7 @@ $NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ static void HandleKey(Widget w, XtPointer client_data, XEvent *event, Boolean *continue_to_dispatch) -@@ -502,7 +518,7 @@ +@@ -502,7 +518,7 @@ static void xcpKBtoASCII(shared_img *shp { static KeySym keysym; static XComposeStatus compose; @@ -61,7 +61,7 @@ $NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ char buffer[8]; bufsize = 8; -@@ -511,16 +527,55 @@ +@@ -511,16 +527,55 @@ static void xcpKBtoASCII(shared_img *shp bufsize, &keysym, &compose); @@ -121,7 +121,7 @@ $NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ static void HandleClientMessage(Widget w, XtPointer client_data, XEvent *event, Boolean *continue_to_dispatch) { -@@ -542,6 +597,8 @@ +@@ -542,6 +597,8 @@ static void HandleXEvents(Widget w, XtPo case KeyPress: xcpKBtoASCII(shptr, event); break; @@ -130,7 +130,7 @@ $NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ case ButtonPress: /* a mouse button was pressed */ if (event->xbutton.button == 3) do_menu(event->xbutton.x_root, event->xbutton.y_root); -@@ -623,7 +680,7 @@ +@@ -623,7 +680,7 @@ char *xcpInitialize(shared_img *shptr, X XtNborder, BlackPixel(xcpDisplay, xcpScreenNum), NULL); XtAddEventHandler(topWidget, ButtonPressMask | KeyPressMask | @@ -139,3 +139,19 @@ $NetBSD: patch-ag,v 1.1 2001/02/12 14:09:25 wiz Exp $ (XtPointer)shptr); /* +@@ -936,8 +993,14 @@ static void xcpUpdateLCD(char *sbuf, con + #ifdef WORDS_BIGENDIAN + #define GOOD_ENDIAN(x) (x) + #else ++# if __INTPTR_WIDTH__ == 32 + /* Wonk: sizeof(unsigned char *) must be == sizeof(uint32) - Ian */ +-#define GOOD_ENDIAN(x) ((unsigned char *)(((uint32)(x))^1UL)) ++# define GOOD_ENDIAN(x) ((unsigned char *)(((uint32)(x))^1UL)) ++# elif __INTPTR_WIDTH__ == 64 ++# define GOOD_ENDIAN(x) ((unsigned char *)(((__uint64_t)(x))^1UL)) ++# else ++# error This architecture is not supported. ++# endif + #endif + + #define PUTPIXEL(type, dstptr, x) { \ diff --git a/emulators/xcopilot/patches/patch-aj b/emulators/xcopilot/patches/patch-aj index 1031f29d72b..2ae6f466e53 100644 --- a/emulators/xcopilot/patches/patch-aj +++ b/emulators/xcopilot/patches/patch-aj @@ -1,8 +1,18 @@ -$NetBSD: patch-aj,v 1.1 2003/09/30 17:47:44 tron Exp $ +$NetBSD: patch-aj,v 1.2 2021/08/27 03:41:41 ryoon Exp $ ---- mc68k/fab_custom.c.orig 1998-07-29 01:08:48.000000000 +0200 -+++ mc68k/fab_custom.c 2003-09-30 19:22:12.000000000 +0200 -@@ -1027,252 +1027,251 @@ +* Include string.h for strlen(). + +--- mc68k/fab_custom.c.orig 1998-07-28 23:08:48.000000000 +0000 ++++ mc68k/fab_custom.c +@@ -30,6 +30,7 @@ + #include <stdio.h> + #include <stdarg.h> + #include <stdlib.h> ++#include <string.h> + + #include "../config.h" + +@@ -1027,252 +1028,251 @@ gen_lput(Fab *f, Reg chip[]) * Max Okumoto *---------------------------------------------------------------------------*/ static char *HACK[] = { diff --git a/emulators/xcopilot/patches/patch-fakecall.c b/emulators/xcopilot/patches/patch-fakecall.c new file mode 100644 index 00000000000..9c3fa8a2834 --- /dev/null +++ b/emulators/xcopilot/patches/patch-fakecall.c @@ -0,0 +1,14 @@ +$NetBSD: patch-fakecall.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Include string.h for mempcy(). + +--- fakecall.c.orig 1998-04-25 17:59:00.000000000 +0000 ++++ fakecall.c +@@ -33,6 +33,7 @@ Update History: (most recent first) + ******************************************************************************/ + #include <stdio.h> + #include <stdlib.h> ++#include <string.h> + #include "sysdeps.h" + #include "shared.h" + #include "memory.h" diff --git a/emulators/xcopilot/patches/patch-main.h b/emulators/xcopilot/patches/patch-main.h new file mode 100644 index 00000000000..79f4df3a732 --- /dev/null +++ b/emulators/xcopilot/patches/patch-main.h @@ -0,0 +1,12 @@ +$NetBSD: patch-main.h,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Forward declare init() in main.c to use from xcopilot.c. + +--- main.h.orig 1998-08-22 20:25:01.000000000 +0000 ++++ main.h +@@ -33,3 +33,5 @@ typedef struct { + /* thread variables */ + int threads; /* number of threads created */ + } Pilot, *Pilot_P; ++ ++int init(Pilot *); diff --git a/emulators/xcopilot/patches/patch-mc68k_newcpu.c b/emulators/xcopilot/patches/patch-mc68k_newcpu.c new file mode 100644 index 00000000000..59fc3b8fe76 --- /dev/null +++ b/emulators/xcopilot/patches/patch-mc68k_newcpu.c @@ -0,0 +1,14 @@ +$NetBSD: patch-mc68k_newcpu.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Include string.h for strlen(). + +--- mc68k/newcpu.c.orig 1998-07-14 03:54:27.000000000 +0000 ++++ mc68k/newcpu.c +@@ -35,6 +35,7 @@ Update History: (most recent first) + #include <unistd.h> + #include <stdio.h> + #include <stdlib.h> ++#include <string.h> + + #include "sysdeps.h" + #include "shared.h" diff --git a/emulators/xcopilot/patches/patch-mx_basic.c b/emulators/xcopilot/patches/patch-mx_basic.c new file mode 100644 index 00000000000..eeb399363a6 --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_basic.c @@ -0,0 +1,14 @@ +$NetBSD: patch-mx_basic.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Include string.h for strlen(). + +--- mx/basic.c.orig 1998-05-07 17:48:26.000000000 +0000 ++++ mx/basic.c +@@ -17,6 +17,7 @@ Update History: (most recent first) + + ******************************************************************************/ + #include <stdlib.h> ++#include <string.h> + #include "X11/Xlib.h" + #include "X11/Xutil.h" + #include "X11/cursorfont.h" diff --git a/emulators/xcopilot/patches/patch-mx_buttons.h b/emulators/xcopilot/patches/patch-mx_buttons.h new file mode 100644 index 00000000000..e318e93c8d4 --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_buttons.h @@ -0,0 +1,13 @@ +$NetBSD: patch-mx_buttons.h,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Declare int as return value type explicitly. + +--- mx/buttons.h.orig 1998-04-25 17:50:14.000000000 +0000 ++++ mx/buttons.h +@@ -29,5 +29,5 @@ typedef struct _mx_button { + unsigned int value; /* bitmap of button states */ + } mx_button; + +-extern mx_popup_button(Display *display, int screen, mx_panel *panel, ++extern int mx_popup_button(Display *display, int screen, mx_panel *panel, + unsigned int value, int *x, int *y); diff --git a/emulators/xcopilot/patches/patch-mx_libmx.h b/emulators/xcopilot/patches/patch-mx_libmx.h new file mode 100644 index 00000000000..c3279c629cc --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_libmx.h @@ -0,0 +1,15 @@ +$NetBSD: patch-mx_libmx.h,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Declare int as return value type explicitly. + +--- mx/libmx.h.orig 1998-08-22 14:46:10.000000000 +0000 ++++ mx/libmx.h +@@ -280,7 +280,7 @@ typedef struct _mx_button { + unsigned int value; /* bitmap of button states */ + } mx_button; + +-extern mx_popup_button(Display *display, int screen, mx_panel *panel, ++extern int mx_popup_button(Display *display, int screen, mx_panel *panel, + unsigned int value, int *x, int *y); + /***************************************************************************** + diff --git a/emulators/xcopilot/patches/patch-mx_request.c b/emulators/xcopilot/patches/patch-mx_request.c new file mode 100644 index 00000000000..57159a434b9 --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_request.c @@ -0,0 +1,14 @@ +$NetBSD: patch-mx_request.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Include string.h for strlen(). + +--- mx/request.c.orig 1998-04-25 17:50:15.000000000 +0000 ++++ mx/request.c +@@ -17,6 +17,7 @@ Update History: (most recent first) + + ******************************************************************************/ + ++#include <string.h> + #include "basic.h" + #include "X11/keysym.h" + #include "alert.h" diff --git a/emulators/xcopilot/patches/patch-mx_select.c b/emulators/xcopilot/patches/patch-mx_select.c new file mode 100644 index 00000000000..eeae055cd7f --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_select.c @@ -0,0 +1,15 @@ +$NetBSD: patch-mx_select.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Declare variables as int. + +--- mx/select.c.orig 1998-04-25 17:50:15.000000000 +0000 ++++ mx/select.c +@@ -27,7 +27,7 @@ Update History: (most recent first) + int mx_scroll_event(Display *display, int screen, XEvent *event, + mx_scroll *scroll, int *done) + { +- static x, y, pick_x, pick_y; ++ static int x, y, pick_x, pick_y; + static int pick_item, item; + int cursor_range, item_range; + switch(event->type) { diff --git a/emulators/xcopilot/patches/patch-mx_test__filesel.c b/emulators/xcopilot/patches/patch-mx_test__filesel.c new file mode 100644 index 00000000000..613283a83b3 --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_test__filesel.c @@ -0,0 +1,14 @@ +$NetBSD: patch-mx_test__filesel.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Include string.h for strcpy(). + +--- mx/test_filesel.c.orig 1998-08-21 00:56:14.000000000 +0000 ++++ mx/test_filesel.c +@@ -19,6 +19,7 @@ Update History: (most recent first) + + ******************************************************************************/ + #include <stdio.h> ++#include <string.h> + #include "libmx.h" + + #define MAIN_N_ITEMS 4 diff --git a/emulators/xcopilot/patches/patch-mx_test__menu.c b/emulators/xcopilot/patches/patch-mx_test__menu.c new file mode 100644 index 00000000000..b3f9152a90f --- /dev/null +++ b/emulators/xcopilot/patches/patch-mx_test__menu.c @@ -0,0 +1,14 @@ +$NetBSD: patch-mx_test__menu.c,v 1.1 2021/08/27 03:41:41 ryoon Exp $ + +* Include string.h for strcpy(). + +--- mx/test_menu.c.orig 1998-08-21 00:56:14.000000000 +0000 ++++ mx/test_menu.c +@@ -19,6 +19,7 @@ Update History: (most recent first) + + ******************************************************************************/ + #include <stdio.h> ++#include <string.h> + #include "libmx.h" + + #define MAIN_N_ITEMS 7 |