mirror of
https://github.com/marketideas/qasm.git
synced 2026-10-24 22:02:28 +00:00
Move the assembler to src/qasm. qlink links OMF 1.0 and 2.0 from a script. makeBin flattens a load file, qomf dumps OMF, and qpro builds ProDOS volumes. APW and MPW assemble through the ORCA front end. Relocatable modules emit OMF objects. Listings stay off unless -l is set. make boot assembles the GS/OS 6.0.1 ProDOS 8 kernel and BASIC.SYSTEM into an 800K volume. BASIC.SYSTEM accepts ls and pfx, and its splash reports PRODOS BASIC 2.0, copyright 1983-2026. IIGS.601.SRC is the source and the BASIC.SYSTEM oracle that image is built from.
1 line
4.3 KiB
NASM
1 line
4.3 KiB
NASM
*******************************************************************************
|
|
*
|
|
* DAInterface for Pascal
|
|
*
|
|
* (C) Copyright Apple Computer, Inc. 1988-93
|
|
* All rights reserved.
|
|
*
|
|
* by Jim Mensch
|
|
* 5/31/89
|
|
*
|
|
*******************************************************************************
|
|
*
|
|
* Modification History:
|
|
*
|
|
* Version 1.0 Mensch (System 6.0)
|
|
*
|
|
* Version 1.1 Lyons (System 6.0.1)
|
|
*
|
|
* 19-Jan-93 DAL -- Added a label in the menu line.
|
|
*
|
|
*
|
|
*******************************************************************************
|
|
|
|
INCLUDE 'All.macros'
|
|
|
|
;==============================================================================
|
|
;
|
|
; Imports from the PASCAL portion of the DA. This will be the addresses of the
|
|
; actual routines that you call.
|
|
;
|
|
|
|
Import ReallyOpen ; PROCEDURE ReallyOpen;
|
|
Import ReallyClose ; PROCEDURE ReallyInit;
|
|
Import ReallyAction ; PROCEDURE ReallyAction;
|
|
Import ReallyInit ; PROCEDURE ReallyClose;
|
|
Import aGlobal
|
|
Import IdleWind ; IdleWind : GrafPortPtr;
|
|
Import QuitFlag ; quitflag : Integer;
|
|
Import eventP ; eventP : EventRecordPtr;
|
|
Import actionCode ; ActionCode:Integer;
|
|
period equ $0010
|
|
Mask equ $0FFF ; use $0FF7 for debug $0FFF for real
|
|
|
|
EJECT
|
|
*******************************************************************************
|
|
*
|
|
BEGINDA PROC Export
|
|
*
|
|
* Description: This is the standard DA header for use with Pascal type DA's
|
|
*
|
|
*
|
|
* Inputs: None
|
|
*
|
|
* Outputs: None
|
|
*
|
|
* External Refs:
|
|
*
|
|
* Entry Points:
|
|
*
|
|
*******************************************************************************
|
|
Import DAOpen
|
|
Import DAClose
|
|
Import DAAction
|
|
Import DAInit
|
|
export ffMenuItemID
|
|
|
|
dc.L DAOpen
|
|
dc.L DAClose
|
|
dc.L DAAction
|
|
dc.L DAInit
|
|
dc.W period
|
|
dc.W Mask
|
|
dc.B ' Find File \H'
|
|
ffMenuItemID dc.b '**',0 ;removed 18 blanks (19-Jan-93 DAL)
|
|
EndP
|
|
|
|
EJECT
|
|
*******************************************************************************
|
|
*
|
|
DAOpen PROC
|
|
*
|
|
* Description: Called when an open is requested by the desk mgr.
|
|
*
|
|
*
|
|
* Inputs: None
|
|
*
|
|
* Outputs: None
|
|
*
|
|
* External Refs:
|
|
*
|
|
* Entry Points:
|
|
*
|
|
*******************************************************************************
|
|
oldDataBank equ 1
|
|
theRTL equ oldDataBank+1
|
|
theResult equ theRTL+3
|
|
phb ; save the old data bank
|
|
|
|
pea IdleWind>>8 ; push the address of our databank on the stack
|
|
plb
|
|
plb ; set as the current data bank!
|
|
|
|
jsl ReallyOpen ; call the pascal open routine
|
|
|
|
lda idleWind ; return the opened window ptr
|
|
sta theResult,s
|
|
lda idleWind+2
|
|
sta theResult+2,s
|
|
|
|
plb ; restore the databank
|
|
RTL
|
|
EndP
|
|
|
|
EJECT
|
|
*******************************************************************************
|
|
*
|
|
DAClose PROC
|
|
*
|
|
* Description: Called in response to a DA close from the desk mgr
|
|
*
|
|
*
|
|
* Inputs: None
|
|
*
|
|
* Outputs: None
|
|
*
|
|
* External Refs:
|
|
*
|
|
* Entry Points:
|
|
*
|
|
*******************************************************************************
|
|
phb ; save the old data bank
|
|
|
|
pea IdleWind>>8 ; push the address of our databank on the stack
|
|
plb
|
|
plb ; set as the current data bank!
|
|
|
|
jsl ReallyClose ; call the pascal open routine
|
|
|
|
plb ; restore the databank
|
|
RTL
|
|
EndP
|
|
|
|
EJECT
|
|
*******************************************************************************
|
|
*
|
|
DAAction PROC
|
|
*
|
|
* Description: Called in response to an Action or RUN event
|
|
*
|
|
*
|
|
* Inputs: None
|
|
*
|
|
* Outputs: None
|
|
*
|
|
* External Refs:
|
|
*
|
|
* Entry Points:
|
|
*
|
|
*******************************************************************************
|
|
phb ; save the old data bank
|
|
|
|
pea IdleWind>>8 ; push the address of our databank on the stack
|
|
plb
|
|
plb ; set as the current data bank!
|
|
|
|
sta actionCode ; save the actionCode
|
|
stx eventP ; and event pointers
|
|
sty eventP+2
|
|
|
|
jsl ReallyAction ; call the pascal open routine
|
|
|
|
lda quitFlag ; test the quit flag
|
|
beq @continue
|
|
|
|
Pushlong IdleWind ; close the DA
|
|
_CloseNDAByWinPtr
|
|
@continue
|
|
lda actionCode ; return in <A> boolean flag
|
|
|
|
plb ; restore the databank
|
|
RTL
|
|
EndP
|
|
|
|
EJECT
|
|
*******************************************************************************
|
|
*
|
|
DAInit PROC
|
|
*
|
|
* Description: Called on Desk manager startup
|
|
*
|
|
*
|
|
* Inputs: None
|
|
*
|
|
* Outputs: None
|
|
*
|
|
* External Refs:
|
|
*
|
|
* Entry Points:
|
|
*
|
|
*******************************************************************************
|
|
phb ; save the old data bank
|
|
|
|
pea IdleWind>>8 ; push the address of our databank on the stack
|
|
plb
|
|
plb ; set as the current data bank!
|
|
|
|
sta ActionCode ; save the flag
|
|
|
|
jsl ReallyInit ; call the pascal open routine
|
|
|
|
plb ; restore the databank
|
|
RTL
|
|
EndP
|
|
|
|
END
|