pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/emulators/xm8
Module Name: pkgsrc
Committed By: tsutsui
Date: Sat Sep 7 00:36:34 UTC 2019
Added Files:
pkgsrc/emulators/xm8: DESCR MESSAGE Makefile PLIST distinfo
pkgsrc/emulators/xm8/patches: patch-Source_UI_app.cpp
patch-Source_UI_emu.cpp patch-Source_UI_emu__sdl.cpp
patch-Source_UI_emu__sdl.h patch-Source_UI_os.h
patch-Source_UI_platform.cpp patch-Source_UI_platform.h
patch-Source_ePC-8801MA_common.h
Log Message:
emulators/xm8: import xm8-1.70.
XM8 is "eXcellent Multi-platform emulator type 8", an emulator of
NEC PC-8801 series, based on "ePC-8801MA".
To generate a diff of this commit:
cvs rdiff -u -r0 -r1.1 pkgsrc/emulators/xm8/DESCR \
pkgsrc/emulators/xm8/MESSAGE pkgsrc/emulators/xm8/Makefile \
pkgsrc/emulators/xm8/PLIST pkgsrc/emulators/xm8/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/emulators/xm8/patches/patch-Source_UI_app.cpp \
pkgsrc/emulators/xm8/patches/patch-Source_UI_emu.cpp \
pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.cpp \
pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.h \
pkgsrc/emulators/xm8/patches/patch-Source_UI_os.h \
pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.cpp \
pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.h \
pkgsrc/emulators/xm8/patches/patch-Source_ePC-8801MA_common.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Added files:
Index: pkgsrc/emulators/xm8/DESCR
diff -u /dev/null pkgsrc/emulators/xm8/DESCR:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/DESCR Sat Sep 7 00:36:34 2019
@@ -0,0 +1,2 @@
+XM8 is "eXcellent Multi-platform emulator type 8", an emulator of
+NEC PC-8801 series, based on "ePC-8801MA".
Index: pkgsrc/emulators/xm8/MESSAGE
diff -u /dev/null pkgsrc/emulators/xm8/MESSAGE:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/MESSAGE Sat Sep 7 00:36:34 2019
@@ -0,0 +1,6 @@
+===========================================================================
+$NetBSD: MESSAGE,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+Note ROM files captured from a real PC-8801 machine are required in
+~/.local/share/retro_pc_pi/xm8/rom dir to use xm8.
+===========================================================================
Index: pkgsrc/emulators/xm8/Makefile
diff -u /dev/null pkgsrc/emulators/xm8/Makefile:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/Makefile Sat Sep 7 00:36:34 2019
@@ -0,0 +1,38 @@
+# $NetBSD: Makefile,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+VERSION= 1.70
+DISTNAME= xm8_${VERSION:S/.//}
+PKGNAME= xm8-${VERSION}
+#PKGREVISION=
+CATEGORIES= emulators
+MASTER_SITES= http://retropc.net/pi/
+EXTRACT_SUFX= .zip
+
+MAINTAINER= tsutsui%NetBSD.org@localhost
+HOMEPAGE= http://retropc.net/pi/
+COMMENT= Multi-platform NEC PC-8801 emulator
+LICENSE= gnu-gpl-v2
+
+EXTRACT_DIR= ${WRKDIR}/${DISTNAME}
+WRKSRC= ${EXTRACT_DIR}
+
+USE_TOOLS+= gmake unzip
+USE_LANGUAGES= c c++
+NO_CONFIGURE= YES
+
+INSTALLATION_DIRS+= bin share/doc/xm8
+
+post-extract:
+ (cd ${WRKSRC}/Source && ${UNZIP_CMD} Source.zip)
+
+do-build:
+ (cd ${WRKSRC}/Source/Linux && ${GMAKE} -f makefile)
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/Source/Linux/xm8 \
+ ${DESTDIR}${PREFIX}/bin
+ ${INSTALL_DATA} ${WRKSRC}/README-XM8.txt \
+ ${DESTDIR}${PREFIX}/share/doc/xm8
+
+.include "../../devel/SDL2/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/emulators/xm8/PLIST
diff -u /dev/null pkgsrc/emulators/xm8/PLIST:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/PLIST Sat Sep 7 00:36:34 2019
@@ -0,0 +1,3 @@
+@comment $NetBSD: PLIST,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+bin/xm8
+share/doc/xm8/README-XM8.txt
Index: pkgsrc/emulators/xm8/distinfo
diff -u /dev/null pkgsrc/emulators/xm8/distinfo:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/distinfo Sat Sep 7 00:36:34 2019
@@ -0,0 +1,14 @@
+$NetBSD: distinfo,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+SHA1 (xm8_170.zip) = 2992590d22f20007fcc5c739be071e39eef5e342
+RMD160 (xm8_170.zip) = 0860b40bdb74bb53ad84b600edaa58b1c994d391
+SHA512 (xm8_170.zip) = c1e49aefec3c4d08cc21f284960d63af2c126883bfc0119d7cf6babe5e14405fae91ea1123eabaaeb41bce8f6ec2e80257b7db8645ce762487ce5ebc94d0d65b
+Size (xm8_170.zip) = 6186595 bytes
+SHA1 (patch-Source_UI_app.cpp) = ca4de2687454c483a153a83d03c5c4b1f1d9b7a7
+SHA1 (patch-Source_UI_emu.cpp) = 9c7c8357ebdaa41a317319d46e24fbcabe283418
+SHA1 (patch-Source_UI_emu__sdl.cpp) = 2fee35253b04ef95375d91258faffdf92386ebba
+SHA1 (patch-Source_UI_emu__sdl.h) = 2ce15da0e3ab68ff21498bd14832b6a632d14efa
+SHA1 (patch-Source_UI_os.h) = b2aba38179a12cc34fbb368e7dfb77241fe51c72
+SHA1 (patch-Source_UI_platform.cpp) = 124872390589a6a952e865d81b9e0bcd8e0b2228
+SHA1 (patch-Source_UI_platform.h) = 7f34ae8d8e2e88ffae86a52fdde54262b6052de3
+SHA1 (patch-Source_ePC-8801MA_common.h) = 64382225e0a92ab55e8e75564ac449f8c33c8b2e
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_app.cpp
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_app.cpp:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_app.cpp Sat Sep 7 00:36:34 2019
@@ -0,0 +1,15 @@
+$NetBSD: patch-Source_UI_app.cpp,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- change rom file directory to ~/.local/share/retro_pc_pi/xm8/rom
+
+--- Source/UI/app.cpp.orig 2018-01-20 05:37:58.000000000 +0000
++++ Source/UI/app.cpp
+@@ -251,7 +251,7 @@ bool App::Init()
+ }
+
+ // emulator i/f wrapper
+- wrapper = new EMU_SDL(video);
++ wrapper = new EMU_SDL(this, video);
+
+ // emulator i/f
+ emu = new EMU(wrapper);
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_emu.cpp
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_emu.cpp:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_emu.cpp Sat Sep 7 00:36:34 2019
@@ -0,0 +1,14 @@
+$NetBSD: patch-Source_UI_emu.cpp,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- change rom file directory to ~/.local/share/retro_pc_pi/xm8/rom
+
+--- Source/UI/emu.cpp.orig 2015-04-20 05:10:30.000000000 +0000
++++ Source/UI/emu.cpp
+@@ -8,6 +8,7 @@
+ */
+
+ #include "common.h"
++#include "classes.h"
+ #include "emu.h"
+ #include "emu_sdl.h"
+
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.cpp
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.cpp:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.cpp Sat Sep 7 00:36:34 2019
@@ -0,0 +1,43 @@
+$NetBSD: patch-Source_UI_emu__sdl.cpp,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- change rom file directory to ~/.local/share/retro_pc_pi/xm8/rom
+
+--- Source/UI/emu_sdl.cpp.orig 2015-05-15 20:47:30.000000000 +0000
++++ Source/UI/emu_sdl.cpp
+@@ -14,6 +14,8 @@
+ #include "common.h"
+ #include "vm.h"
+ #include "classes.h"
++#include "app.h"
++#include "setting.h"
+ #include "video.h"
+ #include "emu_sdl.h"
+
+@@ -25,11 +27,12 @@
+ #define EXTERNAL_PATH_ROM "XM8/"
+ // replace from EXTERNAL_PATH_ANDROID
+
++#define USER_PATH_ROM "rom/"
+ //
+ // EMU_SDL()
+ // constructor
+ //
+-EMU_SDL::EMU_SDL(Video *v)
++EMU_SDL::EMU_SDL(App *a, Video *v)
+ {
+ #ifdef __ANDROID__
+ char *replace;
+@@ -47,7 +50,13 @@ EMU_SDL::EMU_SDL(Video *v)
+ strcpy(replace, EXTERNAL_PATH_ROM);
+ }
+ #else
++#if 0
+ strcpy(base_path, SDL_GetBasePath());
++#else
++ setting = a->GetSetting();
++ strcpy(base_path, setting->GetSettingDir());
++ strcat(base_path, USER_PATH_ROM);
++#endif
+ #endif // __ANDROID__
+ }
+
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.h
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.h:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_emu__sdl.h Sat Sep 7 00:36:34 2019
@@ -0,0 +1,24 @@
+$NetBSD: patch-Source_UI_emu__sdl.h,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- change rom file directory to ~/.local/share/retro_pc_pi/xm8/rom
+
+--- Source/UI/emu_sdl.h.orig 2015-05-15 21:05:04.000000000 +0000
++++ Source/UI/emu_sdl.h
+@@ -20,7 +20,7 @@ class Video;
+ class EMU_SDL
+ {
+ public:
+- EMU_SDL(Video *v);
++ EMU_SDL(App *a, Video *v);
+ // constructor
+ virtual ~EMU_SDL();
+ // destructor
+@@ -47,6 +47,8 @@ private:
+ // full path buffer for get_bios_path()
+ Video *video;
+ // video driver
++ Setting *setting;
++ // setting driver
+ };
+
+ #endif // EMU_SDL_H
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_os.h
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_os.h:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_os.h Sat Sep 7 00:36:34 2019
@@ -0,0 +1,36 @@
+$NetBSD: patch-Source_UI_os.h,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- add NetBSD denitions
+
+--- Source/UI/os.h.orig 2015-06-07 13:33:50.000000000 +0000
++++ Source/UI/os.h
+@@ -31,6 +31,7 @@
+ // Linux
+ //
+ #if defined(__linux__) && !defined(__ANDROID__)
++#define UNIX
+ #include <SDL2/SDL.h>
+ #include <stdio.h>
+ #include <string.h>
+@@ -38,9 +39,21 @@
+ #endif // __linux__ && !__ANDROID__
+
+ //
++// NetBSD
++//
++#if defined(__NetBSD__)
++#define UNIX
++#include <SDL.h>
++#include <stdio.h>
++#include <string.h>
++#include <time.h>
++#endif // __NetBSD__
++
++//
+ // Android
+ //
+ #ifdef __ANDROID__
++#define UNIX
+ #include "SDL.h"
+ #include <stdio.h>
+ #include <string.h>
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.cpp
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.cpp:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.cpp Sat Sep 7 00:36:34 2019
@@ -0,0 +1,193 @@
+$NetBSD: patch-Source_UI_platform.cpp,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- add NetBSD denitions
+
+--- Source/UI/platform.cpp.orig 2017-12-30 13:04:42.000000000 +0000
++++ Source/UI/platform.cpp
+@@ -22,15 +22,15 @@
+ #include "converter.h"
+ #include "platform.h"
+
+-#if defined(__linux__) && !defined(__ANDROID__)
++#if defined(UNIX) && !defined(__ANDROID__)
+ #include <locale.h>
+-#endif // __linux__ && !__ANDROID__
++#endif // UNIX && !__ANDROID__
+
+-#ifdef __linux__
++#if defined(UNIX)
+ #include <dirent.h>
+ #include <sys/types.h>
+ #include <sys/stat.h>
+-#endif // __linux__
++#endif // UNIX
+
+ //
+ // defines
+@@ -63,11 +63,11 @@ Platform::Platform(App *a)
+ ImmDisableIME((DWORD)-1);
+ #endif // _WIN32
+
+-#ifdef __linux__
++#if defined(UNIX)
+ dir_handle = NULL;
+ dir_name[0] = '\0';
+ dir_up = false;
+-#endif // __linux__
++#endif // UNIX
+ }
+
+ //
+@@ -144,7 +144,7 @@ bool Platform::Init(SDL_Window *window)
+ }
+ #endif // _WIN32 && UNICODE
+
+-#if defined(__linux__) && !defined(__ANDROID__)
++#if defined(UNIX) && !defined(__ANDROID__)
+ char *opaque;
+
+ // set locale to UTF-8
+@@ -155,7 +155,7 @@ bool Platform::Init(SDL_Window *window)
+ opaque = setlocale(LC_CTYPE, LOCALE_UTF8);
+ }
+ }
+-#endif // __linux__ && !__ANDROID__
++#endif // UNIX && !__ANDROID__
+
+ return true;
+ }
+@@ -186,12 +186,12 @@ void Platform::Deinit()
+ }
+ #endif // _WIN32
+
+-#ifdef __linux__
++#if defined(UNIX)
+ if (dir_handle != NULL) {
+ closedir((DIR*)dir_handle);
+ dir_handle = NULL;
+ }
+-#endif // __linux__
++#endif // UNIX
+ }
+
+ //
+@@ -282,7 +282,7 @@ const char* Platform::FindFirst(const ch
+ return NULL;
+ #endif // _WIN32 && UNICODE
+
+-#ifdef __linux__
++#if defined(UNIX)
+ DIR *dir_ret;
+
+ // Find ..
+@@ -306,7 +306,7 @@ const char* Platform::FindFirst(const ch
+
+ // find next
+ return FindNext(info);
+-#endif // __liunx__
++#endif // UNIX
+ }
+
+ //
+@@ -384,7 +384,7 @@ const char* Platform::FindNext(Uint32 *i
+ return NULL;
+ #endif // _WIN32 && UNICODE
+
+-#ifdef __linux__
++#if defined(UNIX)
+ struct dirent *entry;
+ Converter *converter;
+
+@@ -420,10 +420,10 @@ const char* Platform::FindNext(Uint32 *i
+ *info = (Uint32)entry->d_type;
+
+ return dir_name;
+-#endif // __liunx__
++#endif // UNIX
+ }
+
+-#ifdef __linux__
++#if defined(UNIX)
+ //
+ // FindUp()
+ // find ..
+@@ -464,7 +464,7 @@ bool Platform::FindUp(const char *dir)
+ closedir(dir_ret);
+ return false;
+ }
+-#endif // __liunx__
++#endif // UNIX
+
+ //
+ // IsDir()
+@@ -487,14 +487,14 @@ bool Platform::IsDir(Uint32 info)
+ }
+ #endif // _WIN32
+
+-#ifdef __linux__
++#if defined(UNIX)
+ if (info == DT_DIR) {
+ return true;
+ }
+ else {
+ return false;
+ }
+-#endif // __linux__
++#endif // UNIX
+ }
+
+ //
+@@ -557,7 +557,7 @@ bool Platform::MakePath(char *dir, const
+ return true;
+ #endif // _WIN32 && UNICODE
+
+-#ifdef __linux__
++#if defined(UNIX)
+ Converter *converter;
+ struct stat filestat;
+
+@@ -588,7 +588,7 @@ bool Platform::MakePath(char *dir, const
+ strcpy(dir, dir_name);
+
+ return true;
+-#endif // __linux__
++#endif // UNIX
+ }
+
+ //
+@@ -637,7 +637,7 @@ bool Platform::GetFileDateTime(const cha
+ return false;
+ #endif // _WIN32
+
+-#ifdef __linux__
++#if defined(UNIX)
+ struct stat filestat;
+ time_t timep;
+ struct tm local_time;
+@@ -660,7 +660,7 @@ bool Platform::GetFileDateTime(const cha
+ }
+
+ return false;
+-#endif // __linux__
++#endif // UNIX
+ }
+
+ //
+@@ -696,7 +696,7 @@ void Platform::MsgBox(SDL_Window *window
+ }
+ #endif // _WIN32
+
+-#if defined(__linux__) && !defined(__ANDROID__)
++#if defined(UNIX) && !defined(__ANDROID__)
+ SDL_MessageBoxData data;
+ SDL_MessageBoxButtonData button;
+ int retid;
+@@ -718,7 +718,7 @@ void Platform::MsgBox(SDL_Window *window
+
+ // show modal message box
+ SDL_ShowMessageBox(&data, &retid);
+-#endif // __linux__ && !__ANDROID__
++#endif // UNIX && !__ANDROID__
+ }
+
+ //
Index: pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.h
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.h:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_UI_platform.h Sat Sep 7 00:36:34 2019
@@ -0,0 +1,24 @@
+$NetBSD: patch-Source_UI_platform.h,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- add NetBSD denitions
+
+--- Source/UI/platform.h.orig 2015-07-08 21:49:42.000000000 +0000
++++ Source/UI/platform.h
+@@ -66,7 +66,7 @@ private:
+ int find_drive;
+ // find drive count
+ #endif // _WIN32
+-#ifdef __linux__
++#if defined(UNIX)
+ bool FindUp(const char *dir);
+ // find ..
+ void *dir_handle;
+@@ -75,7 +75,7 @@ private:
+ // file name (shift-jis)
+ bool dir_up;
+ // FindUp() result
+-#endif // __linux__
++#endif // UNIX
+ };
+
+ #endif // PLATFORM_H
Index: pkgsrc/emulators/xm8/patches/patch-Source_ePC-8801MA_common.h
diff -u /dev/null pkgsrc/emulators/xm8/patches/patch-Source_ePC-8801MA_common.h:1.1
--- /dev/null Sat Sep 7 00:36:34 2019
+++ pkgsrc/emulators/xm8/patches/patch-Source_ePC-8801MA_common.h Sat Sep 7 00:36:34 2019
@@ -0,0 +1,31 @@
+$NetBSD: patch-Source_ePC-8801MA_common.h,v 1.1 2019/09/07 00:36:34 tsutsui Exp $
+
+- add NetBSD denitions
+
+--- Source/ePC-8801MA/common.h.orig 2017-12-20 04:10:42.000000000 +0000
++++ Source/ePC-8801MA/common.h
+@@ -33,6 +33,24 @@ typedef int errno_t;
+ #define strnicmp strncasecmp
+ #define stricmp strcasecmp
+ #endif // __linux__
++// NetBSD
++#ifdef __NetBSD__
++#include <types.h>
++#include <endian.h>
++#include <sys/param.h>
++#if BYTE_ORDER == LITTLE_ENDIAN
++#define __LITTLE_ENDIAN__
++#endif // BYTE_ORDER == LITTLE_ENDIAN
++#define _MAX_PATH MAXPATHLEN
++#define __min min
++#define __stdcall
++typedef int errno_t;
++typedef uint8_t Uint8;
++typedef uint16_t Uint16;
++typedef uint32_t Uint32;
++#define strnicmp strncasecmp
++#define stricmp strcasecmp
++#endif // __NetBSD__
+
+ // max() and min() macro
+ #ifndef max
Home |
Main Index |
Thread Index |
Old Index