DOSPLUS build tools - version JE5
=================================

  This archive contains source files for bits of DOSPLUS that I've 
disassembled, and tools that can be used to recombine them into a working
DOSPLUS system.

  The "Quick Start" instructions below describe how to make a boot disc
for DOSPLUS.

Quick start
===========

1. If you already have a copy of DOSPLUS.SYS, skip to step 5.
2. Download 46004.ZIP from <http://web.ukonline.co.uk/cliff.lawson/files.htm>  
3. Follow the instructions in 46004.ZIP to create a 360k DOSPLUS boot 
  floppy.
4. Make DOSPLUS.SYS visible: ATTRIB -R -S -H A:\DOSPLUS.SYS
5. Copy DOSPLUS.SYS to this directory.
6. Type:
	 DPSPLIT DOSPLUS.SYS

  This should create the following files: BDOS.CMD, XIOS.CMD, DOS.CMD and 
CCP.CMD.

7. Insert either:
  a) a blank 720k disc, that has been formatted in the DOS 713k format.
  b) a blank 1440k disc, that has been formatted in the DOS 1423k format.

8. Type:
	MK_720  if you inserted a 720k disc
        MK_1440 if you inserted a 1440k disc

  This should copy the necessary files and boot sectors onto your disc.

9. Boot from the disc!

The files provided are:
=======================

Front ends
~~~~~~~~~~
MK_SYS	.BAT	- Build the XIOS from source and then create DOSPLUS.SYS.
MK_COPY .BAT	- Erase drive A:, then copy DOSPLUS.SYS to it.
MK_DISC .BAT	- The same as MK_SYS followed by MK_COPY
MK_SEC  .BAT	- Create the two boot sectors from .A86 source.
MK_720	.BAT	- As MK_DISC, but also creates the boot sectors and writes the
		 720k one to disc.
MK_1440 .BAT	- As MK_DISC, but also creates the boot sectors and writes the
		 1440k one to disc.
MK_FIXLD.BAT    - Create FIXLDR.COM to install the loader to a hard drive.

Source code:
~~~~~~~~~~~~
XIOS    .A86	- Source code for the DOSPLUS XIOS, based on disassembly.
BOOT360 .A86	- Source code for the standard (360k) boot sector, based
		 on disassembly.
BOOT720 .A86	- Source code for a 720k boot sector.
BOOT1440.A86	- Source code for a 1440k boot sector.
                 (in fact these three are identical except for an EQU
                  directive at the top of the file).
FIXLDR  .A86    - Source code for the program that installs the hard drive
                 loader, based on disassembly.
LOADER  .A86    - Source for the hard drive loader, based on disassembly.

Build utilities:
~~~~~~~~~~~~~~~~
RASM86  .EXE    - Digital Research tool: 8086 assembler
LINKCMD .EXE    - Digital Research tool: linker
DPGEN   .EXE    - Generates DOSPLUS.SYS from its component parts.
DPSPLIT .EXE    - Splits DOSPLUS.SYS into separate component files.
DOSPLUS .COM    - The DOSPLUS version of COMMAND.COM, needed to generate boot
                 discs.
GEMSID  .EXE    - A SID that works under DOSPLUS. Copied to boot discs in case
                 you need to inspect memory or code after DOSPLUS has booted.
CMD2BOOT.EXE	- Extracts a boot sector from the CMD file that LINK86 
                 generates.
BLESS   .EXE    - Writes a boot sector to a floppy. Syntax is 
                  BLESS drive: bootsect.bin - eg: BLESS A: BOOT720.BIN
LDRGEN  .EXE    - Merges an updated LOADER with FIXLDR.COM.

Files for checking:
~~~~~~~~~~~~~~~~~~~
BOOT360 .SEC - The original DOSPLUS boot sector.  See MK_CKSEC.BAT.
XIOS    .0   - The original DOSPLUS XIOS.         See MK_CHECK.BAT.
MK_CHECK.BAT - This will assemble XIOS.A86 into XIOS.CMD and compare it with 
		XIOS.0. The purpose of this is to check that changes made to 
		the A86 file (such as replacing generated labels with
     		meaningful ones, or changing the way data are represented in 
		DB statements) have not caused unexpected changes in the output.
MK_CKSEC.BAT - Assembles the boot sectors, and compares the 360K one with
                BOOT360.SEC. 

C source
~~~~~~~~

CMDIO   .C	} Routines common to DPGEN and DPSPLIT
CMDIO	.H	} 
DPGEN   .C	- C source for DPGEN.EXE
DPSPLIT .C	- C source for DPSPLIT.EXE
BLESS   .C	- C source for BLESS.EXE
CMD2BOOT.C	- C source for CMD2BOOT.EXE
LDRGEN  .C      - C source for LDRGEN.EXE
MK_DPGEN.BAT	- Compiles DPGEN and DPSPLIT from C. You will need to have
		 Pacific C installed and on your path.
MK_DPGEN.BAT	- Compiles CMD2BOOT and BLESS from C. You will need to have
		 Pacific C installed and on your path.

Miscellaneous
~~~~~~~~~~~~~

ZIPIT   .BAT	- Recreate this .Zip file.
README  .TXT	- This file.

_______________________________________________________________________________

Making your own changes to the XIOS
===================================

  The source of the XIOS is in XIOS.A86. Near the top of this is a line:

JE5           EQU      YES

  If "JE5" is set to "NO", then the stock XIOS is generated. If it is set to 
"YES", then the following changes are made:

> [JE1] Cosmetic changes: white text on a blue background, and a "-je4" sign- 
on message.
> Support for a number of additional disc formats: 
  >> [JE2] 720k DOS format.
  >> [JE4] 1440k DOS format.
  >> [JE4] 360k Personal CP/M format (untested).
  >> [JE4] 720k Personal CP/M format (untested).
  >> [JE4] 180k PCW CP/M format (untested).
  >> [JE4] 720k PCW CP/M format.
  >> [JE4] 720k 144FEAT CP/M format.
  >> [JE4] 1200k 144FEAT CP/M format (untested).
  >> [JE4] 1440k 144FEAT CP/M format.
  Note: The detection code for these formats is still experimental, and
  should eventually be replaced by code that reads the boot sector and 
  generates the DPB dynamically.
> [JE2] Bug fix in the code to detect a numeric coprocessor. The bug is
 explained fully near the label "init_8087:" in XIOS.A86.
> [JE3] Experimental support for DOS-format hard drives bigger than 32Mb 
 (partition type 6). Hard drives can now have up to 65535 clusters rather 
 than 32767. Be warned, though, that the FAT is loaded into memory; so if 
 your hard drive has 65536 clusters, you lose 128k of memory.
> [JE3] A nasty bug in the build process has been fixed. The locations of
 data buffers are now set correctly; on -JE1 and -JE2, the data and directory
 buffers overlapped, causing directory corruption.
> [JE3] Boot colours set not to have a high-intensity background, so that
 the whole screen doesn't flash on a CGA system.
> [JE5] The EXEFIX TSR is built-in. This patches the DOSPLUS .EXE loader
 so that it can load .EXE files whose headers are not an exact multiple
 of 512 bytes in length. EXEFIX can be enabled / disabled separately - there
 is an EXEFIX EQU YES line at the top of the file.
> [JE5] A version without hard drive support can be built. This reduces the
 risk of crashes or strange interactions with more modern operating systems. 
 To do this, change the line HARD_DRIVE EQU YES to HARD_DRIVE EQU NO.

Once you have made your changes, use MK_DISC, MK_720 or MK_1440  to rebuild 
the system files and copy them to disc. 
