mirror of
https://git.freebsd.org/ports.git
synced 2025-06-05 12:56:28 -04:00
New port, prodosemu:
A text based Apple IIe ProDOS emulator. PR: 2817 Submitted by: Joel Sutton <sutton@aardvark.apana.org.au>
This commit is contained in:
parent
b1086e9873
commit
c774e181e3
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=7230
8 changed files with 237 additions and 0 deletions
20
emulators/prodosemu/Makefile
Normal file
20
emulators/prodosemu/Makefile
Normal file
|
@ -0,0 +1,20 @@
|
|||
# New ports collection makefile for: prodosemu
|
||||
# Version required: 0.1
|
||||
# Date created: 18th February 1997
|
||||
# Whom: Joel Sutton <sutton@aardvark.apana.org.au>
|
||||
#
|
||||
# $Id$
|
||||
#
|
||||
|
||||
DISTNAME= prodosemu.v0.1
|
||||
PKGNAME= prodosemu-0.1
|
||||
CATEGORIES= emulators
|
||||
MASTER_SITES= ftp://ftp.apple.asimov.net/pub/apple_II/emulators/prodosemu/
|
||||
|
||||
MAINTAINER= sutton@aardvark.apana.org.au
|
||||
|
||||
NO_PACKAGE= yes
|
||||
RESTRICTED= apple.rom copyright is owned by Apple and cannot be distributed.
|
||||
WRKSRC= ${WRKDIR}/prodosemu-v0.1
|
||||
|
||||
.include <bsd.port.mk>
|
1
emulators/prodosemu/distinfo
Normal file
1
emulators/prodosemu/distinfo
Normal file
|
@ -0,0 +1 @@
|
|||
MD5 (prodosemu.v0.1.tar.gz) = 0d2669c945f991f2d18dfadba872bf75
|
71
emulators/prodosemu/files/patch-aa
Normal file
71
emulators/prodosemu/files/patch-aa
Normal file
|
@ -0,0 +1,71 @@
|
|||
diff -rc prodosemu-v0.1/Makefile prodosemu/Makefile
|
||||
*** Makefile Tue Jan 9 15:00:03 1996
|
||||
--- Makefile Tue Feb 18 09:40:38 1997
|
||||
***************
|
||||
*** 1,12 ****
|
||||
#
|
||||
! #Makefile for ProDOS Emulator v0.1
|
||||
! #
|
||||
|
||||
all : prodos
|
||||
|
||||
# Linux doesn't seem to like Randy Frank's beep code,
|
||||
# if you're compiling on something else, you could try not defining NOBEEP
|
||||
! OPT = -O2 -DNOBEEP
|
||||
|
||||
# Necessary libraries
|
||||
LIB = -lcurses -ltermcap
|
||||
--- 1,28 ----
|
||||
#
|
||||
! # Makefile for ProDOS Emulator v0.1
|
||||
! # FreeBSD modifications by Joel Sutton 18th Feb, 1997
|
||||
!
|
||||
! # Paths to various places
|
||||
! PREFIX?= /usr/local
|
||||
! BINDIR= ${PREFIX}/bin
|
||||
! LIBDIR= ${PREFIX}/lib
|
||||
! MANDIR= ${PREFIX}/man
|
||||
! ROMDIR= ${LIBDIR}/apple2
|
||||
! ROM= prodos-2e.rom
|
||||
!
|
||||
! # Certain programs
|
||||
! INSTALL= install -c
|
||||
! INSTALL_BIN= ${INSTALL} -s -o bin -g bin
|
||||
! INSTALL_DATA= ${INSTALL} -m 664
|
||||
! INSTALL_MAN= ${INSTALL} -m 444
|
||||
! CP?= /bin/cp
|
||||
! MKDIR?= -/bin/mkdir
|
||||
|
||||
all : prodos
|
||||
|
||||
# Linux doesn't seem to like Randy Frank's beep code,
|
||||
# if you're compiling on something else, you could try not defining NOBEEP
|
||||
! OPT = -O2 -DNOBEEP -DROMFILE=\"${ROMDIR}/${ROM}\"
|
||||
|
||||
# Necessary libraries
|
||||
LIB = -lcurses -ltermcap
|
||||
***************
|
||||
*** 30,35 ****
|
||||
prodos : $(OBJ)
|
||||
cc $(OPT) -o prodos $(OBJ) $(LIB)
|
||||
|
||||
# Clean up
|
||||
clean:
|
||||
! rm *.o *~
|
||||
--- 46,61 ----
|
||||
prodos : $(OBJ)
|
||||
cc $(OPT) -o prodos $(OBJ) $(LIB)
|
||||
|
||||
+ # Install the program
|
||||
+ install: all
|
||||
+ ${MKDIR} ${BINDIR}
|
||||
+ ${MKDIR} ${LIBDIR}
|
||||
+ ${MKDIR} ${ROMDIR}
|
||||
+
|
||||
+ ${INSTALL_BIN} prodos ${BINDIR}/
|
||||
+ ${CP} apple.rom ${ROM}
|
||||
+ ${INSTALL_DATA} ${ROM} ${ROMDIR}/
|
||||
+
|
||||
# Clean up
|
||||
clean:
|
||||
! rm *.o
|
21
emulators/prodosemu/files/patch-ab
Normal file
21
emulators/prodosemu/files/patch-ab
Normal file
|
@ -0,0 +1,21 @@
|
|||
diff -rc prodosemu-v0.1/apple.h prodosemu/apple.h
|
||||
*** apple.h Tue Jan 9 15:00:03 1996
|
||||
--- apple.h Tue Feb 18 07:02:04 1997
|
||||
***************
|
||||
*** 18,25 ****
|
||||
#endif
|
||||
|
||||
#ifndef CBREAK
|
||||
! /*#include <sgtty.h>*/
|
||||
! #include <bsd/sgtty.h>
|
||||
#endif
|
||||
|
||||
#ifndef TIOCGETP
|
||||
--- 18,24 ----
|
||||
#endif
|
||||
|
||||
#ifndef CBREAK
|
||||
! #include <sgtty.h>
|
||||
#endif
|
||||
|
||||
#ifndef TIOCGETP
|
27
emulators/prodosemu/files/patch-ac
Normal file
27
emulators/prodosemu/files/patch-ac
Normal file
|
@ -0,0 +1,27 @@
|
|||
diff -rc prodosemu-v0.1/main.c prodosemu/main.c
|
||||
*** main.c Tue Jan 9 15:00:03 1996
|
||||
--- main.c Tue Feb 18 09:43:54 1997
|
||||
***************
|
||||
*** 9,16 ****
|
||||
|
||||
#include "apple.h"
|
||||
#include <curses.h>
|
||||
#define REF_DELAY 2000
|
||||
! #define ROMFILE "apple.rom"
|
||||
|
||||
extern char prodosroot[];
|
||||
|
||||
--- 9,21 ----
|
||||
|
||||
#include "apple.h"
|
||||
#include <curses.h>
|
||||
+
|
||||
#define REF_DELAY 2000
|
||||
!
|
||||
! /* Where is the default rom file?? */
|
||||
! #ifndef ROMFILE
|
||||
! #define ROMFILE "/usr/local/lib/apple2/prodos-2e.rom"
|
||||
! #endif
|
||||
|
||||
extern char prodosroot[];
|
||||
|
1
emulators/prodosemu/pkg-comment
Normal file
1
emulators/prodosemu/pkg-comment
Normal file
|
@ -0,0 +1 @@
|
|||
A text based Apple IIe ProDOS emulator.
|
93
emulators/prodosemu/pkg-descr
Normal file
93
emulators/prodosemu/pkg-descr
Normal file
|
@ -0,0 +1,93 @@
|
|||
Prodosemu is a text based Apple IIe ProDOS emulator. Unlike most
|
||||
popular Apple emulators it does not use disk images, instead it uses
|
||||
the UNIX file-system. If you have an Apple IIe then you will need to
|
||||
transfer your programs/files into a directory somewhere with your
|
||||
favorite comm's program. Otherwise you will need to install the aftp
|
||||
port to pull the files out from the Apple disk images that are widely
|
||||
available on the net (eg the ProDOS system disk available from
|
||||
asimov).
|
||||
|
||||
The rom file (included) is stored in /usr/local/lib/apple2 (or similar
|
||||
path on your system) under the name "prodos-2e.rom". I've adopted this
|
||||
title so that Prodosemu can co-exist with the other apple emulators in
|
||||
the ports collection.
|
||||
|
||||
There is no man page for this program so I have included the slightly
|
||||
modified README at the end of this document.
|
||||
|
||||
Check out the following for all things Apple II:
|
||||
|
||||
ftp://ftp.apple.asimov.net/ - Apple II archives
|
||||
news://comp.emulators.apple2/ - Apple II news group
|
||||
|
||||
Share and enjoy,
|
||||
Joel...
|
||||
sutton@aardvark.apana.org.au
|
||||
|
||||
===========
|
||||
ProDOS Emulator by Matthew Ghio v0.1 of January 8, 1996
|
||||
|
||||
To use prodosemu you will need a copy of the Apple IIe ROM. To get the
|
||||
ROM from an Apple IIe, boot into prodos/basic and do the following:
|
||||
|
||||
]CALL -151
|
||||
*C007:0
|
||||
*2100<C100.FFFFM
|
||||
*C006:0
|
||||
*bsave apple.rom,a$2100,l$3f00
|
||||
|
||||
Then use your favorite communications software to upload it to your unix
|
||||
system. At this time you should also upload some common programs, such
|
||||
as BASIC.SYSTEM and SHRINKIT. Put these files in the same directory as
|
||||
the prodos emulator. You do not need a copy of ProDOS to run the emulator.
|
||||
|
||||
To run ProDOS applications on your unix system, type 'prodos' and the
|
||||
application name, at your shell prompt. The ProDOS emulator will load
|
||||
the application into a virtual Apple IIe and execute it. Any ProDOS MLI
|
||||
calls are trapped and the equivalent file operations are performed via
|
||||
unix kernel calls. Your current directory appears as a disk named /UNIX
|
||||
mounted on slot 7, drive 1. For example, typing
|
||||
prodos BASIC.SYSTEM
|
||||
will launch Applesoft Basic. Type CAT,S7,D1 to see the files in your
|
||||
directory. Remember that Prodos filenames are UPPERCASE and limited to 15
|
||||
characters. (Prodosemu actually does allow you to create and access
|
||||
filenames longer than 15 characters, but only those filenames 15 characters
|
||||
or less will show up in directory listings. This is due to the fact that
|
||||
Prodos's directory entries have a fixed size buffer which can only hold 15
|
||||
characters.) When you are finished with basic, type BYE to return to the
|
||||
unix shell prompt.
|
||||
|
||||
If you want to make another directory the working directory when running
|
||||
ProDOS applications, use the -w command line option. By default, the
|
||||
working directory becomes the root of the similated ProDOS filesystem.
|
||||
If you wish to make another directory the root of the ProDOS filesystem
|
||||
while launching prodos, use the -r option. The program does not do a
|
||||
chroot, and it is possible to get out of the ProDOS root directory by
|
||||
using .. or following a symbolic link.
|
||||
|
||||
As files are read and written by Prodos applications to the simulated
|
||||
filesystem, they are read and written to the corresponding directory
|
||||
in your unix filesystem. Prodos-specific filetype information is stored
|
||||
in a .prodosdir file, which is automatically created in each directory
|
||||
if it does not already exist. Filetypes are ignored by Prodosemu when
|
||||
launching applications. Because the ProDOS Emulator does not use disk
|
||||
images, disk copiers such as Copy II Plus will not work. Ordinary file
|
||||
copiers and other utilities work fine.
|
||||
|
||||
On an Apple II, the up arrow is Control-K, down is Control-J, left is
|
||||
Control-H, and right is Control-U. You may need to use these control
|
||||
characters in some applications.
|
||||
|
||||
This program uses Randy Frank's 65C02 emulator and I/O code. While the
|
||||
emulation is running, you can use the following key sequences:
|
||||
Ctrl-A Q Quits
|
||||
Ctrl-A D Enters the debugger
|
||||
Ctrl-A 0 Toggles the state of the open-apple key
|
||||
Ctrl-A 1 Toggles the state of the closed-apple key
|
||||
Ctrl-A S Inputs a control-s
|
||||
Ctrl-A Ctrl-A Inputs a real control-a
|
||||
After doing a Control-A 0 to toggle the state of the open-apple key, don't
|
||||
forget to do another Ctrl-A 0 to put it back!
|
||||
|
||||
The files 6502.c, mega2.c, and debug.c are copyright 1990 Randy Frank and
|
||||
are distrbuted under the included license agreement.
|
3
emulators/prodosemu/pkg-plist
Normal file
3
emulators/prodosemu/pkg-plist
Normal file
|
@ -0,0 +1,3 @@
|
|||
bin/prodos
|
||||
lib/apple2/prodos-2e.rom
|
||||
@dirrm lib/apple2
|
Loading…
Add table
Reference in a new issue