SYSDOC POPC John Gibson June 1988 extended by A.Sloman July 1988 Ian Rogers March 1990 This is a quick summary of the new compilation/linking setup, using command files pgcomp, pglink, pglibr, and mksyscomp. This extended description was produced by A.Sloman based on ~johng/newsys plus examination of the sh command scripts pgcomp, pglink and pglibr I may have made errors. Proceed with caution, and examine the scripts yourself if in doubt. I am least confident about the options for pglibr. Aaron Fri Jul 8 17:27:28 BST 1988 A more up to date file can be found in REF POPC $usepop/pop/ref/popc http://www.cs.bham.ac.uk/research/projects/poplog/doc/popref/popc CONTENTS - (Use g to access required sections) -- Terminology -- Three basic programs: popc, poplink, poplibr -- Rebuilding saved images: mksyscomp -- Other command files -- pgcomp: run popc on a .p or .s file -- Options for pgcomp: -imd , -pl, -ql -- pglink: run poplink to re-build newpop11 -- Options for pglink: -imd , -srd , -q, etc.. -- pglibr: run poplibr -- Possible arguments for pglibr -- mksyscomp: rebuild popc, poplink, or poplibr -- Options for the basic programs popc, poplink and poplibr -- Terminology -------------------------------------------------------- Some of the flags to these programs, and scripts, indicate that there will follow zero, one, or more pieces of data, eg -lf to poplink. These data lists are represented below by , and will take one of two forms: 1. If there is exactly one piece of data then it can simply follow the flag. eg. pglink -lo stuff.o 2. If there is zero or more pieces of data then it is written, in sequence, between parentheses. eg. pglink -lf ( -Lmydir/lib -Lotherdir/lib ) Note that this form can also be used for the case where there is exactly one piece of data. -- Three basic programs: popc, poplink, poplibr ----------------------- popc: compiles .p and .s files, producing .w/.o files poplink: links a POP-11 program from .w/.o files and libraries (Unless given the -q flag, it first creates poplink_?.o and poplink_cmnd files) poplibr: maintains .w/.o libraries NOTE: The information below gives descriptions of the most commonly used arguments and flags available for these commands. However, in some cases additional flags are possible. For full details you will need to look at the source files, e.g. syscomp/poplink_main.p for pglink. -- Rebuilding saved images: mksyscomp --------------------------------- For now, each of the programs has a saved image in the src directory, based on safepop11. The command file -mksyscomp- takes one or more of the arguments 'popc', 'poplink' and 'poplibr' and creates the corresponding saved images: popc.psv poplink.psv poplibr.psv -- Other command files ------------------------------------------------ The above programs are general, and take a number of arguments (documentation on that to follow). For the normal full POPLOG system, there is a command file to run each program with appropriate arguments: -- pgcomp: run popc on a .p or .s file -------------------------------- The most commonly used formats are pgcomp foo.p ... pgcomp foo.s ... Other formats are explained below. -pgcomp- is similar to the old -popas- command -- it runs -popc- on .p and .s source files, and produces .o and .w files. After using -pgcomp- successfully on a new file, you should edit the file W_FILES to include the name of the .w file produced. This will be used by the linker pglink and by pglibr as explained below. If there is no corresponding entry in W_FILES, then the -pglink- command will use the version of the program in the src.wlb and wrc.olb instead of the new version. [pgcomp should be changed to append to W_FILES if necessary - aaron] -- Options for pgcomp: -imd , -pl, -ql --------------------------- Full format: pgcomp [-imd ] [-cs] [-pl | -ql] files .... Options: -imd look in the named for the safepop11 and popc.psv files. Defaults to current directory. -cs Compile the result of `pglibr -lcs src.wlb`, i.e. any .s or .p source files that have changed since they were updated in src.wlb. Then does 'ls *.w > W_FILES' to create W_FILES. -pl Run pglink after compiling the files. This will do a full link. -ql Run pglink -q after compiling the files. This will do a quick link without re-building the poplink*.o files etc. -- pglink: run poplink to re-build newpop11 --------------------------- -pglink- replaces both the old -poplink- and -link- commands. It uses the .w files listed in the file $popsrc/W_FILES together with the remaining files in the $popsrc/src.wlb and $popsrc/../x/src/src.wlb libraries to create files called poplink_?.o for building the dictionary and other structures required at run time, and also creates the file poplink_cmnd which is used to run the linker and build newpop11. The most common forms of invocation of -pglink- are pglink produce poplink_?.o and poplink_cmnd, then link newpop11 pglink -q use existing poplink_?.o and poplink_cmnd, link newpop11 Additional options are explained below. -pglink- assumes that the files $popsrc/src.wlb and $popsrc/src.olb represent the Poplog library (plus $popsrc/../x/src/src.[ow]lb) if linking with X). It also takes the file W_FILES, if it exists, to be a list of .w names for modules that have been recompiled to .w/.o form since the library was last updated (using -pglibr-). -pglink- therefore takes these as separate, and excludes any modules in the src.olb/src.wlb library with the same names. Using the list of .w files in W_FILES it lists the corresponding .o files explicitly in poplink_cmnd. -- Options for pglink: -imd , -srd , -q, etc.. -------------- Full format: pglink [-imd ] [-srd ] [-xsrd ] [-q] [-nox] [-noved] [-noshare] [-safe] [-a] [-map] [-rsv] [-port] [-sunfp