LEDIT - editor for random LD object libraries.

Syntax:

ledit [Update=]library [options]*
(+|-)Clear (-)      (+|-)error_Stop (+)
(+|-)Verbose (-)
Append=file,file,...
Delete=symbol,symbol,...
Extract=symbol[>file],symbol[>file],...
Include=file,file,...
indeX=file,file,...
Replace=file,file,...

Options:

library
 
Update=library
specifies the name of the file containing the library to be edited. If the file already exists but is not in the proper format for a random library, its contents will remain unaltered unless +Clear is specified.
+Clear
ignores the old contents of the edited library. +Clear must be specified to initialize a new library.
-error_Stop
indicates that LEDIT should not abort if certain simple errors occur. For example, LEDIT will not abort if an Include=file is not found or a Delete=symbol is not found. Other (more serious) errors will still abort the edit.
+Verbose
prints out information on every task LEDIT does.
Append=file,file,...
appends the contents of the given files to the library.
Include=file,file,...
reads LD object code from the specified object files or object libraries. If the library being edited contains SYMDEFs whose names match SYMDEFs in an object file that is being included, the new routines will replace the old ones in the edited library. SYMDEFs that do not match ones in the library will be added to the library. If an object library is named (as in Include=library), all modules in the library will be included in the library being edited.
Delete=symbol,symbol,...
deletes routines from the library. Each "symbol" should be the name of a SYMDEF present in the library. For each symbol, LEDIT will delete the module where the symbol is defined.
Extract=symbol[>file],symbol[>file],...
extracts the modules containing SYMDEFs for each of the given symbols, and saves them in files. If a symbol is followed by ">file", the module will be written into that file. If a symbol is not immediately followed by ">file", the module will be written into a file with the same name as "symbol". For example, in
extract=sym1,sym2>xyz

the module associated with "sym1" will be written into a file called "sym1" and the module associated with "sym2" will be written into "xyz". Files are created if they do not already exist.

indeX=file,file,...
specifies one or more text files called "index files". Each line in an index file contains one or more directives of the form
Include=file
Append=file
Delete=symbol
Extract=symbol>file
Replace=file

The LEDIT instructions given in an index file are executed in the order they appear in the file. A line in an index file may also have the form

!command

in which case "command" is executed as a TSS command.

Replace=file,file,...
replaces the existing definitions of the given files with new definitions supplied from the specified files.

Description:

LEDIT lets you change the contents of a random LD object library, by replacing or deleting individual object decks within the library.

The object decks are always referred to by one of their primary SYMDEFs. Decks are deleted as required to insure the uniqueness of this naming method.

If "Update=" is used to specify the name of the library, the "Include=" keyword may be omitted for modules, as in

ledit u=lib mod

If "Update=" is not used to introduce the name of the library, the "Include=" keyword must be used, as in

ledit lib i=mod

A command line may have any number of Include, Delete, Extract, or indeX directives. Directives appearing on the command line are handled first, in the following order:

After this, directives from index files are executed, line by line. With each line in an index file, the directives are executed in the same order as the command line: Extracts, then Deletes, then Includes. Index files are processed in the order they appear on the command line.

Examples:

The following examples show examples of how to use LEDIT.

ledit mylib i=fc*o*

edits the modules in the file "fc*o*" into the library "mylib". If "mylib" is of bad format, LEDIT will not overwrite it.

Notes:

Users should note that the syntax of the "Extract=" option differs from previous releases and that the minimal abbreviation is now "E=".

Using LEDIT in batch:

LEDIT can be used in batch with JCL of the following form:

$      program ledit
$      limits  ,25k
$      prmfl   **,r/c,r,cmdlib/ledi
$      data    cz
  <LEDIT command line goes here>

For example, the following JCL illustrates a compile and library update.

$      select  &system/profile.prod/nsc
$      run     rufile=&cv00rp/nsc_ru
$      file    o*,o1s,1r    Pass the object on
$      data    cz
nsc /mysource.c form=ld
$      program ledit
$      limits  ,25k
$      prmfl   **,r/c,r,cmdlib/ledi
$      prmfl   ot,w,r,/mylibrary
$      file    o*,o1r
$      data    cz
ledit update=fc*ot fc*o*
$      endjob

See Also:

expl linfo

Copyright © 1996, Thinkage Ltd.