Trailing-Edge
-
PDP-10 Archives
-
BB-4160E-BM
-
sort-rel/sort.ctl
There are 19 other files named sort.ctl in the archive. Click here to see a list.
!SORT.CTL VERSION 4B
!USED TO MAKE COBOL, FORTRAN AND STAND-ALONE SORT
!THIS FILE RUNS ON EITHER TOPS-20 OR TOPS-10
!SUBMIT WITH COMMAND SUBMIT SORT/TIME:0:30:00/RESTART:YES
!
!THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY ONLY BE USED
! OR COPIED IN ACCORDANCE WITH THE TERMS OF SUCH LICENSE.
!
!COPYRIGHT (C) 1979 BY DIGITAL EQUIPMENT CORPORATION
!
!IF ANY NON-STANDARD ASSEMBLY SWITCHES ARE DESIRED THEY SHOULD BE
! INSERTED IN SRTPRM.MAC
!
!INSTALLATION SPECIFIC ASSIGNMENTS SHOULD BE PUT IN THE FOLLOWING FILE:
! ON TOPS-20 IN A TAKE FILE SORT.CMD
! ON TOPS-10 IN A MIC FILE SORT.MIC
! OR IN A TECO FILE SORT.TEC
!IF THIS FILE IS ABSENT THEN ALL REQUIRED FILES ARE ASSUMED TO EXIST ON DSK:
!
!IF LISTINGS ARE DESIRED, THE EMPTY FILE
!LISTEM.MAC SHOULD BE IN DSK:.
!
!THIS CONTROL FILE CREATES:
! STAND-ALONE SORT ALWAYS,
! COBOL-68 SORT IF LIBOL.REL IS PRESENT,
! COBOL-74 SORT IF C74LIB.REL IS PRESENT, AND
! ON DECSYSTEM-10 FORTRAN SORT IF FORLIB.REL IS PRESENT.
!
!TO CREATE JUST THE COBOL-68 SORT, SUBMIT SORT.CTL WITH '/TAG:COBOL'.
!TO CREATE JUST THE COBOL-74 SORT, SUBMIT SORT.CTL WITH '/TAG:CBL74'.
!ON TOPS-10 TO CREATE JUST THE FORTRAN SORT, SUBMIT SORT.CTL WITH '/TAG:FORTRA'.
!
!NOTE
!COBOL-68 SORT AND COBOL-74 SORT BOTH REQUIRE FTDEFS.UNV AND THAT THAT FILE
!COULD BE IN TWO DIFFERENT AREAS. HOWEVER, FTDEFS IS INDEPENDANT OF COBOL-68
!AND COBOL-74 (THE CHECKSUM IS THE SAME) SO IT DOES NOT MATTER WHICH ONE IS USED.
!IN ALL CIRCUMSTANCES THE COBOL SORT WILL BE BUILT ONLY ONCE AND IF REQUIRED
!THE SAME VERSION WILL BE PUT INTO BOTH COBOL-68 AND COBOL-74.
!
SORT::
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT SORT::
!REQUIRED FILES:
!<FIELD-IMAGE> MACRO.EXE
! MAKLIB.EXE
! CREF.EXE
! LINK.EXE
! PA1050.EXE
! MACTEN.UNV
!
!<RELEASE-4> MACSYM.UNV
! MONSYM.UNV
! MACREL.REL (IF COBOL)
!
!<SELF> SORT.CTL
!
! SORT SOURCES AND DOCUMENTATION
!<SORT-SOURCE> SORT.MAC SRTPRM.MAC SRTSTA.MAC
! SRTCMD.MAC SRTJSS.MAC SRTCMP.MAC
! SRTCBL.MAC SRTCER.MAC
! FORSRT.MAC
! SORT.HLP SRT4B.DOC
!
! COBOL-68 & LIBOL FILES FROM VERSION 12A RELEASE
!<COBOL-68-BUILD> LIBOL.REL
! LIBSHR.REL
! FTDEFS.UNV
!
! COBOL-74 & C74OTS FILES FROM VERSION 12A RELEASE
!<COBOL-74-BUILD> C74LIB.REL
! C74SHR.REL
! FTDEFS.UNV
!
!NOTE
!RELEASE 4B OF SORT REQUIRES THE MONITOR RELEASE 4 VERSION OF
!MACSYM.UNV, MONSYM.UNV AND MACREL.REL. THESE FILES ARE INCLUDED
!IN THE SORT-SOURCE AREA ON THIS RELEASE TAPE.
!
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
!MAKE A RECORD OF WHAT IS BEING USED
!
@GET SYS:MACRO
@INFO VERSION
@GET SYS:MAKLIB
@INFO VERSION
@GET SYS:LINK
@INFO VERSION
@GET SYS:CREF
@INFO VERSION
@GET SYS:PA1050
@INFO VERSION
!
!GET CHECKSUMS SO WE KNOW WHAT WE HAVE
!FIRST THE SYSTEM SOFTWARE
!
@VD SYS:MACRO.EXE,SYS:MAKLIB.EXE,SYS:LINK.EXE,SYS:PA1050.EXE,SYS:CREF.EXE,UNV:MACTEN.UNV,UNV:MACSYM.UNV,UNV:MONSYM.UNV,SYS:MACREL.REL,
@CHECK SEQ
@
!
!NEXT THE SORT SOURCES
!
@VD SORT.MAC,SRT*.MAC,FORSRT.MAC,SORT.CTL,SORT.CMD,
@CHECK SEQ
@
!
!AND FINALLY THE COBOL REL FILES
!
@VD LIBOL.REL,LIBSHR.REL,C74LIB.REL,C74SHR.REL,FTDEFS.UNV,
@CHECK SEQ
@
!
! CREATE STAND-ALONE SORT.
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
*SORT,SORT/C=SRTPRM,SRTSTA,SRTCMD,SRTJSS,SRTCER,SRTCMP,SORT
@IF (ERROR) @GOTO TRUBLE
!
@CREF
*DSK:SORT.LZT=SORT
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
*SORT=SRTPRM,SRTSTA,SRTCMD,SRTJSS,SRTCER,SRTCMP,SORT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
@LINK
*SORT.MAP/MAP=SORT,/SYMSEG:HIGH/GO
@IF (ERROR) @GOTO TRUBLE
@INFO MEM
!
!NOW SAVE IT.
!
@SAVE DSK:SORT
@IF (ERROR) @GOTO TRUBLE
!
! DELETE UNNEEDED FILES.
!
@DELETE SORT.REL
@IF (ERROR)!
@EXPUNGE
@IF (ERROR)!
!
@GOTO LIBOL
TRUBLE::@PLEASE -- STAND-ALONE SORT CREATION UNSUCCESSFUL
@GOTO FAIL
TOPS10::
.CHKPNT SORT::
!REQUIRED FILES:
!DEC: PIP.EXE (LATEST RELEASED VERSIONS)
! TECO.EXE
! MACRO.EXE
! MAKLIB.EXE
! DIRECT.EXE
! CREF.EXE
! COMPIL.EXE
! LINK.EXE+LNK???.EXE
! HELPER.REL
! SCAN.REL
! MACTEN.UNV
! UUOSYN.UNV
! SCNMAC.UNV
!
!DSK: SORT.CTL SORT.VER
! OPTIONAL
! SORT.CTM SORT.TEC SORT.MIC
!
! SORT SOURCES AND DOCUMENTATION
!SRT: SORT.MAC SRTPRM.MAC SRTSTA.MAC
! SRTUUO.MAC SRTSCN.MAC SRTCMP.MAC
! SRTCBL.MAC SRTCER.MAC
! SRTFOR.MAC
! SORT.HLP SRT4B.DOC
!
! COBOL-68 & LIBOL FILES FROM VERSION 12A RELEASE
!C68: LIBOL.REL
! FTDEFS.UNV
!
! COBOL-74 & C74OTS FILES FROM VERSION 12A RELEASE
!C74: C74LIB.REL
! FTDEFS.UNV
!
! FORTRAN FILES
! FORLIB.REL
!
!
!MAKE A RECORD OF WHAT IS BEING USED
!
.ERROR
!SET UP THE DEFAULT LOGICAL NAMES
.ASSIGN DEC: UNV:
.ASSIGN DSK: SRT:
.ASSIGN DSK: C68:
.ASSIGN DSK: C74:
!
!CHANGE THEM IF USER SO DESIRES
!.DO SORT.MIC
.IF (ERROR) !IGNORE IT
!
.RUN DEC:DIRECT
*TTY:/CHECKSUM=DEC:PIP+MACRO+MAKLIB+DIRECT+CREF+LINK+LNK???+TECO
*TTY:/CHECKSUM=DEC:HELPER.REL+SCAN.REL+UNV:MACTEN.UNV+UUOSYM.UNV+SCNMAC.UNV
*TTY:/CHECKSUM=DSK:SORT.*
*TTY:/CHECKSUM=SRT:SORT.MAC+SRT???.MAC
*TTY:/CHECKSUM=C68:LIBOL.REL+FTDEFS.UNV
*TTY:/CHECKSUM=C74:C74LIB.REL+FTDEFS.UNV
*TTY:/CHECKSUM=DSK:FORLIB.REL
!
;
! CREATE STAND-ALONE SORT.
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SORT,SORT/C=SORT.VER,SRTPRM,SRTSTA,SRTSCN,SRTUUO,SRTCMP,SORT
.IF (ERROR) .GOTO TRUBLE
!
.RUN DEC:CREF
*DSK:SORT.LZT=SORT
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SORT=SORT.VER,SRTPRM,SRTSTA,SRTSCN,SRTUUO,SRTCMP,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
.RUN DEC:LINK
*LPT:SORT.MAP/MAP:END=-
*DEC:HELPER,-
*DEC:SCAN/SEGMENT:LOW/INCLUDE:(.VERBO,.TOUTS,.SAVE),-
*DEC:SCAN/EXCLUDE:(.VERBO,.TOUTS,.SAVE,$SCNDC),-
*DSK:SORT/GO
.IF (ERROR) .GOTO TRUBLE
.SSAVE SORT
.IF (ERROR) .GOTO TRUBLE
!
! DELETE UNNEEDED FILES.
!
.DELETE SORT.REL
.IF (ERROR)!
!
.GOTO LIBOL
TRUBLE::.PLEASE -- STAND-ALONE SORT CREATION UNSUCCESSFUL.^[
.GOTO FAIL
LIBOL:: ! NOW FOR COBOL-68 CHANGES.
!
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT LIBOL::
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
! TEST TO SEE IF COBOL-68 SORT REQUIRED.
!
@ERROR %
@DIR LIBOL.REL
@IF (ERROR) @GOTO C74OTS !NOT REQUIRED
@ERROR
!
! ASSEMBLE SOURCES
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
*SRTCBL,SRTCBL/C=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
! CREATE LISTINGS.
!
@CREF
*DSK:SRTCBL.LZT=SRTCBL
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
*SRTCBL=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
! PLACE INTO LIBOL.REL.
!
@MAKLIB
*LIBOL=LIBOL/MASTER:SORT,SRTCBL/REPLACE:SORT
@IF (ERROR) @GOTO TRUBLE
!
! INDEX LIBOL.REL.
!
@MAKLIB
*LIBOL=LIBOL/INDEX
@IF (ERROR) @GOTO TRUBLE
!
!CREATE LIBO12.EXE
!
@LINK
*LIBOL.MAP/MAP=/NOLOCAL LIBSHR,DSK:MACREL/SEG:HIGH,LIBOL/SEARCH,/SYMSEG:HIGH/GO
@IF (ERROR) @GOTO TRUBLE
@INFO MEM
!
!NOW SAVE IT.
!
@SAVE DSK:LIBO12 0 675
@IF (ERROR) @GOTO TRUBLE
!
!
! DELETE UNNEEDED FILES.
!
@EXPUNGE
@IF (ERROR)!
!
@GOTO C74OTS
TRUBLE::@PLEASE -- COBOL-68 SORT CREATION UNSUCCESSFUL!!!
@GOTO FAIL
TOPS10::
.CHKPNT LIBOL::
! TEST TO SEE IF COBOL-68 SORT REQUIRED.
!
.ERROR %
.DIR LIBOL.REL
.IF (ERROR) .GOTO C74OTS !NOT REQUIRED
.ERROR
!
! ASSEMBLE SOURCES WITH LISTINGS.
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SRTCBL,SRTCBL/C=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
! CREATE LISTINGS.
!
.RUN DEC:CREF
*DSK:SRTCBL.LZT=SRTCBL
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SRTCBL=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
.ERROR
! PLACE INTO LIBOL.REL.
! SEE IF WE HAVE ORIGINAL LIBOL OR A SORT MODIFIED ONE.
!
.RUN DEC:MAKLIB
*SRTFOO=LIBOL/EXTRACT:SORT
.IF (NOERROR) .GOTO REPLAC
!
! WE MUST REPLACE OLD CSORT WITH SORT.
!
.RUN DEC:MAKLIB
*LIBOL=LIBOL/MASTER:CSORT,SRTCBL/REPLACE:SORT
.IF (ERROR) .GOTO TRUBLE
.GOTO INDEX
!
REPLAC::
!
! JUST REPLACE SORT MODULE.
!
.RUN DEC:MAKLIB
*LIBOL=LIBOL/MASTER:SORT,SRTCBL/REPLACE:SORT
.DELETE SRTFOO.REL
.IF (ERROR)!
.GOTO INDEX
!
INDEX::
!
! INDEX LIBOL.REL
!
.RUN DEC:MAKLIB
*LIBOL=LIBOL/INDEX
.IF (ERROR) .GOTO TRUBLE
.!
.GOTO C74OTS
TRUBLE::.PLEASE -- COBOL-68 SORT CREATION UNSUCCESSFUL.^[
.GOTO FAIL
C74OTS:: ! NOW FOR COBOL-74 CHANGES.
!
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT C74OTS::
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
! TEST TO SEE IF COBOL-74 SORT REQUIRED.
!
@ERROR %
@DIR C74LIB.REL
@IF (ERROR) @GOTO FORLIB !NOT REQUIRED
@ERROR
!
!TEST TO SEE IF COBOL-68 SORT HAS JUST BEEN ASSEMBLED.
!
@ERROR %
@DIR LIBOL.REL
@IF (NOERROR) @GOTO DONCRF !ASSEMBLY NOT REQUIRED
@ERROR
!
! ASSEMBLE SOURCES
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
*SRTCBL,SRTCBL/C=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
! CREATE LISTINGS.
!
@CREF
*DSK:SRTCBL.LZT=SRTCBL
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
*SRTCBL=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
@ERROR
! PLACE INTO C74LIB.REL.
!
@MAKLIB
*C74LIB=C74LIB/MASTER:SORT,SRTCBL/REPLACE:SORT
@IF (ERROR) @GOTO TRUBLE
!
! INDEX C74LIB.REL.
!
@MAKLIB
*C74LIB=C74LIB/INDEX
@IF (ERROR) @GOTO TRUBLE
!
!CREATE C74OT2.EXE
!
@LINK
*C74OTS.MAP/MAP=/NOLOCAL C74SHR,DSK:MACREL/SEG:HIGH,C74LIB/SEARCH,/SYMSEG:HIGH/GO
@IF (ERROR) @GOTO TRUBLE
@INFO MEM
!
!NOW SAVE IT. NOTE WE MUST GET RID OF PAGE 400 (A LINK BUG)
!BUT SAVE PAGE 0 AS IT MAKES IT EASIER TO PATCH
!ALSO DELETE PAGES 676 AND 677 SINCE COBOL-SORT USES THEM
!
@SAVE DSK:C74O12 0 675
@IF (ERROR) @GOTO TRUBLE
!
!
! DELETE UNNEEDED FILES.
!
@EXPUNGE
@IF (ERROR)!
!
@GOTO FORLIB
TRUBLE::@PLEASE -- COBOL-74 SORT CREATION UNSUCCESSFUL!!!
@GOTO FAIL
TOPS10::
.CHKPNT C74OTS::
! TEST TO SEE IF COBOL-74 SORT REQUIRED.
!
.ERROR %
.DIR C74LIB.REL
.IF (ERROR) .GOTO FORLIB !NOT REQUIRED
.ERROR
!
!TEST TO SEE IF COBOL-68 SORT HAS JUST BEEN ASSEMBLED.
!
.ERROR %
.DIR LIBOL.REL
.IF (NOERROR) .GOTO DONCRF !ASSEMBLY NOT REQUIRED
.ERROR
!
! ASSEMBLE SOURCES WITH LISTINGS.
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SRTCBL,SRTCBL/C=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
! CREATE LISTINGS.
!
.RUN DEC:CREF
*DSK:SRTCBL.LZT=SRTCBL
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SRTCBL=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
.ERROR
! PLACE INTO C74LIB.REL.
!
.RUN DEC:MAKLIB
*C74LIB=C74LIB/MASTER:SORT,SRTCBL/REPLACE:SORT
.IF (ERROR)!
!
! INDEX C74LIB.REL
!
.RUN DEC:MAKLIB
*C74LIB=C74LIB/INDEX
.IF (ERROR) .GOTO TRUBLE
!
FORLIB:: ! NOW FOR FORLIB CHANGES.
!
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT FORLIB::
!
!.GOTO FINISH !FORSRT PART OF FORTRAN RELEASE NOW
!
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
! ASSEMBLE SOURCE
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
FORSRT,FORSRT/C=FORSRT
@IF (ERROR) @GOTO TRUBLE
!
! CREATE LISTING.
!
@CREF
*DSK:FORSRT.LZT=FORSRT
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
FORSRT=FORSRT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
! TEST TO SEE IF FORTRAN SORT REQUIRED.
!
@ERROR %
@DIR FORLIB.REL
@IF (ERROR) @GOTO FINISH !NOT REQUIRED
@ERROR
!
! PLACE INTO FORLIB.REL.
! SEE IF WE HAVE ORIGINAL FORLIB OR A SORT MODIFIED ONE.
!
@MAKLIB
*SRTFOO=FORLIB/EXTRACT:SORT
@IF (NOERROR) @GOTO REPLAC
!
! ORIGINAL FORLIB--PUT SORT AT THE END.
!
@MAKLIB
*FORLIB=FORLIB,FORSRT/APPEND
@IF (ERROR) @GOTO TRUBLE
@GOTO INDEX
!
REPLAC::
!
! JUST REPLACE SORT MODULE.
!
@MAKLIB
*FORLIB=FORLIB/MASTER:SORT,FORSRT/REPLACE:SORT
@DELETE SRTFOO.REL
@IF (ERROR)!
@EXPUNGE
@IF (ERROR)!
!
INDEX::
!
! INDEX FORLIB.REL.
!
@MAKLIB
*FORLIB=FORLIB/INDEX
@IF (ERROR) @GOTO TRUBLE
!
! DELETE UNNEEDED FILES.
!
@DELETE FORSRT.REL
@IF (ERROR)!
@EXPUNGE
@IF (ERROR)!
!
@GOTO FINISH
TRUBLE:@PLEASE -- FORTRAN SORT CREATION UNSUCCESSFUL!!!
@GOTO FAIL
TOPS10::
.CHKPNT FORLIB::
!
! ASSEMBLE SOURCES
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SRTFOR,SRTFOR/C=SORT.VER,SRTPRM,SRTFOR,SRTSTA,SRTSCN,SRTUUO,SRTCER,SRTCMP,SORT
.IF (ERROR) .GOTO TRUBLE
!
! CREATE LISTINGS.
!
.RUN DEC:CREF
*DSK:SRTFOR.LZT=SRTFOR
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SRTFOR=SORT.VER,SRTPRM,SRTFOR,SRTSTA,SRTSCN,SRTUUO,SRTCER,SRTCMP,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
! TEST TO SEE IF FORTRAN SORT REQUIRED.
!
.ERROR %
.DIR FORLIB.REL
.IF (ERROR) .GOTO FINISH !NOT REQUIRED
.ERROR
! PLACE INTO FORLIB.REL.
! SEE IF WE HAVE ORIGINAL FORLIB OR A SORT MODIFIED ONE.
!
.RUN DEC:MAKLIB
*SRTFOO=FORLIB/EXTRACT:SORT
.IF (NOERROR) .GOTO REPLAC
!
! ORIGINAL FORLIB--PUT SORT AT THE END.
!
.RUN DEC:MAKLIB
*FORLIB=FORLIB,SRTFOR/APPEND
.IF (ERROR) .GOTO TRUBLE
.GOTO INDEX
!
REPLAC::
!
! JUST REPLACE SORT MODULE.
!
.RUN DEC:MAKLIB
*FORLIB=FORLIB/MASTER:SORT,SRTFOR/REPLACE:SORT
.DELETE SRTFOO.REL
.IF (ERROR)!
!
INDEX::
!
! INDEX FORLIB.REL.
!
.RUN DEC:MAKLIB
*FORLIB=FORLIB/INDEX
.IF (ERROR) .GOTO TRUBLE
!
! DELETE UNNEEDED FILES.
!
.DELETE SRTFOR.REL
.IF (ERROR)!
!
.GOTO FINISH
TRUBLE::.PLEASE -- FORTRAN SORT CREATION UNSUCCESSFUL.^[
.GOTO FAIL
COBOL:: ! HERE FOR COBOL-68 SORT ONLY.
!
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT COBOL::
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
! MAKE A RECORD OF WHAT IS BEING USED.
!
@GET SYS:MACRO
@INFO VERSION
@GET SYS:MAKLIB
@INFO VERSION
@GET SYS:LINK
@INFO VERSION
@GET SYS:CREF
@INFO VERSION
@GET SYS:PA1050
@INFO VERSION
!
!GET CHECKSUMS SO WE KNOW WHAT WE HAVE
!
@VD SYS:MACRO.EXE,SYS:MAKLIB.EXE,SYS:LINK.EXE,SYS:PA1050.EXE,SYS:CREF.EXE,UNV:MACTEN.UNV,UNV:MACSYM.UNV,UNV:MONSYM.UNV,SYS:MACREL.REL,
@CHECK SEQ
@
!
@VD SORT.*,SRT*.*,LIBOL.REL,LIBSHR.REL,FTDEFS.UNV,
@CHECK SEQ
@
!
! ASSEMBLE SOURCES
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
*SRTCBL,SRTCBL/C=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
! CREATE LISTINGS.
!
@CREF
*DSK:SRTCBL.LZT=SRTCBL
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
*SRTCBL=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
@ERROR
! PLACE INTO LIBOL.REL.
!
@MAKLIB
*LIBOL=LIBOL/MASTER:SORT,SRTCBL/REPLACE:SORT
@IF (ERROR) @GOTO TRUBLE
!
! INDEX LIBOL.REL.
!
@MAKLIB
*LIBOL=LIBOL/INDEX
@IF (ERROR) @GOTO TRUBLE
!
!CREATE LIBO12.EXE
!
@LINK
*LIBOL.MAP/MAP=/NOLOCAL LIBSHR,DSK:MACREL/SEG:HIGH,LIBOL/SEARCH,/SYMSEG:HIGH/GO
@IF (ERROR) @GOTO TRUBLE
@INFO MEM
!
!NOW SAVE IT. NOTE WE MUST GET RID OF PAGE 400 (A LINK BUG)
!BUT SAVE PAGE 0 AS IT MAKES IT EASIER TO PATCH
!
@SAVE DSK:LIBO12 0 675
@IF (ERROR) @GOTO TRUBLE
!
!
! DELETE UNNEEDED FILES.
!
@EXPUNGE
@IF (ERROR)!
!
@GOTO FINISH
TRUBLE::@PLEASE -- COBOL-68 SORT CREATION UNSUCCESSFUL!!!
@GOTO FAIL
TOPS10::
.CHKPNT COBOL::
!MAKE A RECORD OF WHAT IS BEING USED
!
.ERROR
!SET UP THE DEFAULT LOGICAL NAMES
.ASSIGN DEC: UNV:
.ASSIGN DSK: SRT:
.ASSIGN DSK: C68:
.ASSIGN DSK: C74:
!
!CHANGE THEM IF USER SO DESIRES
!.DO SORT.MIC
.IF (ERROR) !IGNORE IT
!
.RUN DEC:DIRECT
*TTY:/CHECKSUM=DEC:PIP+MACRO+MAKLIB+DIRECT+CREF+LINK+LNK???+TECO
*TTY:/CHECKSUM=DEC:HELPER.REL+SCAN.REL+UNV:MACTEN.UNV+UUOSYM.UNV+SCNMAC.UNV
*TTY:/CHECKSUM=SORT.*+SRT???.*
*TTY:/CHECKSUM=LIBOL.REL+FTDEFS.UNV
!
! ASSEMBLE SOURCES
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SRTCBL,SRTCBL/C=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
! CREATE LISTINGS.
!
.RUN DEC:CREF
*DSK:SRTCBL.LZT=SRTCBL
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SRTCBL=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
! PLACE INTO LIBOL.REL.
! SEE IF WE HAVE ORIGINAL LIBOL OR A SORT MODIFIED ONE.
!
.RUN DEC:MAKLIB
*SRTFOO=LIBOL/EXTRACT:SORT
.IF (NOERROR) .GOTO REPLAC
!
! WE MUST REPLACE OLD CSORT WITH SORT.
!
.RUN DEC:MAKLIB
*LIBOL=LIBOL/MASTER:CSORT,SRTCBL/REPLACE:SORT
.IF (ERROR) .GOTO TRUBLE
.GOTO INDEX
!
REPLAC::
!
! JUST REPLACE SORT MODULE.
!
.RUN DEC:MAKLIB
*LIBOL=LIBOL/MASTER:SORT,SRTCBL/REPLACE:SORT
.DELETE SRTFOO.REL
.IF (ERROR)!
.GOTO INDEX
!
INDEX::
!
! INDEX LIBOL.REL
!
.RUN DEC:MAKLIB
*LIBOL=LIBOL/INDEX
.IF (ERROR) .GOTO TRUBLE
!
.GOTO FINISH
TRUBLE::.PLEASE -- COBOL-68 SORT CREATION UNSUCCESSFUL.^[
.GOTO FAIL
CBL74:: ! HERE FOR COBOL-74 SORT ONLY.
!
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT CBL74::
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
! MAKE A RECORD OF WHAT IS BEING USED.
!
@GET SYS:MACRO
@INFO VERSION
@GET SYS:MAKLIB
@INFO VERSION
@GET SYS:LINK
@INFO VERSION
@GET SYS:CREF
@INFO VERSION
@GET SYS:PA1050
@INFO VERSION
!
!GET CHECKSUMS SO WE KNOW WHAT WE HAVE
!
@VD SYS:MACRO.EXE,SYS:MAKLIB.EXE,SYS:LINK.EXE,SYS:PA1050.EXE,SYS:CREF.EXE,UNV:MACTEN.UNV,UNV:MACSYM.UNV,UNV:MONSYM.UNV,SYS:MACREL.REL,
@CHECK SEQ
@
!
@VD SORT.*,SRT*.*,C74LIB.REL,C74SHR.REL,FTDEFS.UNV,
@CHECK SEQ
@
!
! ASSEMBLE SOURCES
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
*SRTCBL,SRTCBL/C=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
! CREATE LISTINGS.
!
@CREF
*DSK:SRTCBL.LZT=SRTCBL
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
*SRTCBL=SRTPRM,SRTCBL,SRTCER,SRTJSS,SORT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
@ERROR
! PLACE INTO C74LIB.REL.
!
@MAKLIB
*C74LIB=C74LIB/MASTER:SORT,SRTCBL/REPLACE:SORT
@IF (ERROR) @GOTO TRUBLE
!
! INDEX C74LIB.REL.
!
@MAKLIB
*C74LIB=C74LIB/INDEX
@IF (ERROR) @GOTO TRUBLE
!
!CREATE C74OT2.EXE
!
@LINK
*C74OTS.MAP/MAP=/NOLOCAL C74SHR,DSK:MACREL/SEG:HIGH,C74LIB/SEARCH,/SYMSEG:HIGH/GO
@IF (ERROR) @GOTO TRUBLE
@INFO MEM
!
!NOW SAVE IT. NOTE WE MUST GET RID OF PAGE 400 (A LINK BUG)
!BUT SAVE PAGE 0 AS IT MAKES IT EASIER TO PATCH
!
@SAVE DSK:C74O12 0 675
@IF (ERROR) @GOTO TRUBLE
!
!
! DELETE UNNEEDED FILES.
!
@EXPUNGE
@IF (ERROR)!
!
@GOTO FINISH
TRUBLE::@PLEASE -- COBOL-74 SORT CREATION UNSUCCESSFUL!!!
@GOTO FAIL
TOPS10::
.CHKPNT CBL74::
!MAKE A RECORD OF WHAT IS BEING USED
!
.ERROR
!SET UP THE DEFAULT LOGICAL NAMES
.ASSIGN DEC: UNV:
.ASSIGN DSK: SRT:
.ASSIGN DSK: C68:
.ASSIGN DSK: C74:
!
!CHANGE THEM IF USER SO DESIRES
!.DO SORT.MIC
.IF (ERROR) !IGNORE IT
!
.RUN DEC:DIRECT
*TTY:/CHECKSUM=DEC:PIP+MACRO+MAKLIB+DIRECT+CREF+LINK+LNK???+TECO
*TTY:/CHECKSUM=DEC:HELPER.REL+SCAN.REL+UNV:MACTEN.UNV+UUOSYM.UNV+SCNMAC.UNV
*TTY:/CHECKSUM=SORT.*+SRT???.*
*TTY:/CHECKSUM=C74LIB.REL+FTDEFS.UNV
!
! ASSEMBLE SOURCES
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SRTCBL,SRTCBL/C=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
! CREATE LISTINGS.
!
.RUN DEC:CREF
*DSK:SRTCBL.LZT=SRTCBL
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SRTCBL=SORT.VER,SRTPRM,SRTCBL,SRTCER,SRTUUO,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
! PLACE INTO C74LIB.REL.
!
.RUN DEC:MAKLIB
*C74LIB=C74LIB/MASTER:SORT,SRTCBL/REPLACE:SORT
.IF (ERROR)!
!
! INDEX C74LIB.REL
!
.RUN DEC:MAKLIB
*C74LIB=C74LIB/INDEX
.IF (ERROR) .GOTO TRUBLE
.!
.GOTO FINISH
TRUBLE::.PLEASE -- COBOL-74 SORT CREATION UNSUCCESSFUL.^[
.GOTO FAIL
FORTRA:: ! HERE FOR FORTRAN SORT ONLY.
!
!TEST FOR WHICH SYSTEM
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT FORTRA::
!
!@PLEASE -- FORTRAN SORT NOW PART OF FORTRAN RELEASE!!!
!@GOTO FINISH
!
@ERROR
@TAKE SORT.CMD
@IF (ERROR) !IGNORE IT
!
! MAKE A RECORD OF WHAT IS BEING USED.
!
@GET SYS:MACRO
@INFO VERSION
@GET SYS:MAKLIB
@INFO VERSION
@GET SYS:CREF
@INFO VERSION
@GET SYS:PA1050
@INFO VERSION
!
@VD SYS:MACRO.EXE,SYS:MAKLIB.EXE,SYS:CREF.EXE,SYS,UNV:MACSYM.UNV,UNV:MONSYM.UNV,SYS:PA1050.EXE,
@CHECK SEQ
@
!
VD FORSRT.MAC,
@CHECK SEQ
@
! TEST TO SEE IF FORTRAN SORT REQUIRED.
!
@ERROR %
@DIR FORLIB.REL
@IF (ERROR) @GOTO FINISH !NOT REQUIRED
@ERROR
!
! ASSEMBLE SOURCES
!
@ERROR %
@DIR LISTEM.MAC
@IF (ERROR) @GOTO NOLIST !CREF NOT WANTED
!
@ERROR
@MACRO
FORSRT,FORSRT/C=FORSRT
@IF (ERROR) @GOTO TRUBLE
!
! CREATE LISTINGS.
!
@CREF
*DSK:FORSRT.LZT=FORSRT
@IF (ERROR) @GOTO TRUBLE
@GOTO DONCRF
!
NOLIST::
@ERROR
@MACRO
FORSRT=FORSRT
@IF (ERROR) @GOTO TRUBLE
!
DONCRF::
! PLACE INTO FORLIB.REL.
! SEE IF WE HAVE ORIGINAL FORLIB OR A SORT MODIFIED ONE.
!
@MAKLIB
*SRTFOO=FORLIB/EXTRACT:SORT
@IF (NOERROR) @GOTO REPLAC
!
! ORIGINAL FORLIB--PUT SORT AT THE END.
!
@MAKLIB
*FORLIB=FORLIB,FORSRT/APPEND
@IF (ERROR) @GOTO TRUBLE
@GOTO INDEX
!
REPLAC::
!
! JUST REPLACE SORT MODULE.
!
@MAKLIB
*FORLIB=FORLIB/MASTER:SORT,FORSRT/REPLACE:SORT
@DELETE SRTFOO.REL
@IF (ERROR)!
@EXPUNGE
@IF (ERROR)!
!
INDEX::
!
! INDEX FORLIB.REL.
!
@MAKLIB
*FORLIB=FORLIB/INDEX
@IF (ERROR) @GOTO TRUBLE
!
! DELETE UNNEEDED FILES.
!
@DELETE FORSRT.REL
@IF (ERROR)!
@EXPUNGE
@IF (ERROR)!
!
@GOTO FINISH
TRUBLE::@PLEASE -- FORTRAN SORT CREATION UNSUCCESSFUL!!!
@GOTO FAIL
TOPS10::
.CHKPNT FORTRA::
!MAKE A RECORD OF WHAT IS BEING USED
!
.ERROR
!SET UP THE DEFAULT LOGICAL NAMES
.ASSIGN DEC: UNV:
.ASSIGN DSK: SRT:
.ASSIGN DSK: C68:
.ASSIGN DSK: C74:
!
!CHANGE THEM IF USER SO DESIRES
!.DO SORT.MIC
.IF (ERROR) !IGNORE IT
!
.RUN DEC:DIRECT
*TTY:/CHECKSUM=DEC:PIP+MACRO+MAKLIB+DIRECT+CREF
*TTY:/CHECKSUM=UNV:MACTEN.UNV+UNV:UUOSYM.UNV+UNV:SCNMAC.UNV
*TTY:/CHECKSUM=SORT.*+SRT???.*
*TTY:/CHECKSUM=FORLIB.REL
! TEST TO SEE IF FORTRAN SORT REQUIRED.
!
.ERROR %
.DIR FORLIB.REL
.IF (ERROR) .GOTO FINISH !NOT REQUIRED
.ERROR
!
! ASSEMBLE SOURCES
!
.ERROR %
.DIR LISTEM.MAC
.IF (ERROR) .GOTO NOLIST !CREF NOT WANTED
!
.ERROR
.RUN DEC:MACRO
*SRTFOR,SRTFOR/C=SORT.VER,SRTPRM,SRTFOR,SRTSTA,SRTSCN,SRTUUO,SRTCER,SRTCMP,SORT
.IF (ERROR) .GOTO TRUBLE
!
! CREATE LISTINGS.
!
.RUN DEC:CREF
*DSK:SRTFOR.LZT=SRTFOR
.IF (ERROR) .GOTO TRUBLE
.GOTO DONCRF
!
NOLIST::
.ERROR
.RUN DEC:MACRO
*SRTFOR=SORT.VER,SRTPRM,SRTFOR,SRTSTA,SRTSCN,SRTUUO,SRTCER,SRTCMP,SORT
.IF (ERROR) .GOTO TRUBLE
!
DONCRF::
.ERROR
! PLACE INTO FORLIB.REL.
! SEE IF WE HAVE ORIGINAL FORLIB OR A SORT MODIFIED ONE.
!
.RUN DEC:MAKLIB
*SRTFOO=FORLIB/EXTRACT:SORT
.IF (NOERROR) .GOTO REPLAC
!
! ORIGINAL FORLIB--PUT SORT AT THE END.
!
.RUN DEC:MAKLIB
*FORLIB=FORLIB,SRTFOR/APPEND
.IF (ERROR) .GOTO TRUBLE
.GOTO INDEX
!
REPLAC::
!
! JUST REPLACE SORT MODULE.
!
.RUN DEC:MAKLIB
*FORLIB=FORLIB/MASTER:SORT,SRTFOR/REPLACE:SORT
.DELETE SRTFOO.REL
.IF (ERROR)!
!
INDEX::
!
! INDEX FORLIB.REL.
!
.RUN DEC:MAKLIB
*FORLIB=FORLIB/INDEX
.IF (ERROR) .GOTO TRUBLE
!
! DELETE UNNEEDED FILES.
!
.DELETE SRTFOR.REL
.IF (ERROR)!
!
.GOTO FINISH
TRUBLE::.PLEASE -- FORTRAN SORT CREATION UNSUCCESSFUL.^[
.GOTO FAIL
FINISH::
!
!TEST FOR WHICH SYSTEM
@GOTO TOPS20 !TOPS20 VERSION
.GOTO TOPS10 !TOPS10 VERSION
!
TOPS20::
@CHKPNT FINISH::
@ERROR
!
! SEE WHAT WE GOT.
!
@VD SORT.*,LIBOL.REL,LIBO*.EXE,FORLIB.REL,C74*.*,
@CHECK SEQ
@
!
! TELL OPERATOR HOW WE DID.
!
@PLEASE -- SORT CREATION SUCCESSFUL
@GOTO OK
TOPS10::
.CHKPNT FINISH::
.ERROR
!
! SEE WHAT WE GOT.
!
.RUN DEC:DIRECT
*TTY:/CHECKSUM=SORT.*+LIBOL.REL+LIBO??.EXE+FORLIB.REL+C74???.*
!
! TELL OPERATOR HOW WE DID.
!
.PLEASE -- SORT CREATION SUCCESSFUL.^[
.GOTO OK
FAIL::
OK::!END OF SORT.CTL