Friday, 15 March 2019

Installing gzip

GZip is a very useful utility for unzipping files with a *.gz extension.

The latest OpenVMS version I know of is 1.5b, and it can be downloaded either as a pre-built image from here or compilable source from here.

Both archives extract into folder [.gzip-1_5b_vms]

Then MMS or MMK can be run from this folder as follows:

MMS/DESCRIP=[.VMS]DESCRIP.MMS CLEAN_ALL
MMS/DESCRIP=[.VMS]DESCRIP.MMS /MACRO=(LARGE=1)

Once compiled, the newly created executable GZIP.EXE can be copied to SYS$COMMON:[SYSEXE] and the following lines added to SYLOGIN.COM:

$ gzip :== $sys$common:[sysexe]gzip.exe
$ gunzip :== "$sys$common:[sysexe]gzip.exe -d"
$ gzcat :== "$sys$common:[sysexe]gzip.exe -cd"

The [.VMS]descrip.mms describes a CCOPTS macro that can be used to add additional compiler options such as enabling optimisations, but it doesn't seem to work (and I can't find any code for it in any of the .mms files).  So I manually enabled optimisations by changing the descrip.mms file as such before compiling:

# Default C compile rule.

.C.OBJ :
    $(CC) $(CFLAGS) /opt=(tune=host,inline=speed,level=5) /define=($(CDEFS)) $(MMS$SOURCE)

There's also a really useful little utility created called DECC_VER.EXE that when run lists the VMS, DECC, and CRTL version numbers.  Mine are currently:

__VMS_VERSION: >V8.4    <.
__VMS_VER  = 80400022.
__DECC_VER = 70390009.
__CRTL_VER = 80400000.

No comments:

Post a Comment