ack/doc/install.doc

1238 lines
39 KiB
Plaintext
Raw Normal View History

1994-06-24 11:31:16 +00:00
.\" $Id$
.if n .nr PD 1v
.if n .nr LL 78m
.if n .ll 78m
1984-06-29 11:21:50 +00:00
.TL
1986-02-28 18:02:00 +00:00
Amsterdam Compiler Kit Installation Guide
1984-06-29 11:21:50 +00:00
.AU
Ed Keizer
1991-10-16 13:33:50 +00:00
(revised for 3rd, 4th and 5th distribution by Ceriel Jacobs)
1984-06-29 11:21:50 +00:00
.AI
1986-02-28 18:02:00 +00:00
Vakgroep Informatica
1984-06-29 11:21:50 +00:00
Vrije Universiteit
Amsterdam
.NH
Introduction
.PP
This document
describes the process of installing the Amsterdam Compiler Kit (ACK).
1991-11-19 17:25:02 +00:00
It depends on the combination of hard- and software how
1985-04-12 11:20:15 +00:00
hard it will be to install the Kit.
This description is intended for a Sun-3 or SPARC workstation.
Installation on VAXen running Berkeley
.UX
or Ultrix,
Sun-2 systems and most System V
.UX
1991-10-16 13:33:50 +00:00
systems should be easy.
As of this distribution, installation on PDP-11's or other
systems with a small address space is no longer supported.
See section 8 for installation on other systems.
1984-06-29 11:21:50 +00:00
.NH
1991-10-16 13:33:50 +00:00
The ACK installation process
1984-06-29 11:21:50 +00:00
.PP
1991-11-19 17:25:02 +00:00
In the ACK installation process, three directory trees are used:
1991-10-16 13:33:50 +00:00
.IP "-"
the ACK source tree. This is the tree on the ACK distribution medium.
For the rest of this document, we will refer to this directory
as $SRC_HOME;
.IP "-"
a configuration tree. This tree is built by the installation process and
is used to do compilations in. Its structure reflects that of the source tree,
1991-10-16 13:33:50 +00:00
but this tree will mostly contain Makefiles and relocatable objects.
For the rest of this document, we will refer to this directory
as $CONFIG;
.IP "-"
an ACK users tree. This tree is also built by the installation process.
For the rest of this document, we will refer to this directory
as $TARGET_HOME;
1984-06-29 11:21:50 +00:00
.LP
1991-10-16 13:33:50 +00:00
After installation,
the directories in $TARGET_HOME contain the following information:
1991-10-16 13:33:50 +00:00
.if n .sp 1
.if n .nr PD 0
1985-04-12 11:20:15 +00:00
.IP "bin" 14
the few utilities that knot things together.
See the section about "Commands".
.IP "lib"
1991-10-16 13:33:50 +00:00
root of a tree containing almost all libraries used by
1985-04-12 11:20:15 +00:00
commands.
Files specific to a certain machine are collected in one subtree
1985-04-12 11:20:15 +00:00
per machine. E.g. "lib/pdp", "lib/z8000".
1987-03-25 22:43:09 +00:00
The names used here are the same names as used for subtrees
1991-10-16 13:33:50 +00:00
of "$SRC_HOME/mach".
1985-04-12 11:20:15 +00:00
.IP "lib/descr"
command descriptor files used by the program ack.
1985-04-12 11:20:15 +00:00
.IP "lib/LLgen"
files used by the LL(1) parser generator.
1991-10-16 13:33:50 +00:00
.IP "lib/flex"
files used by the lexical analyzer generator Flex.
1991-10-16 13:33:50 +00:00
.IP "lib/m2"
definition modules for Modula-2.
1991-10-16 13:33:50 +00:00
.IP "lib.bin"
root of a tree containing almost all binaries used by
commands.
All programs specific to a certain machine are collected in one subtree
per machine. E.g. "lib.bin/pdp", "lib.bin/z8000".
The names used here are the same names as used for subtrees
of "$SRC_HOME/mach".
.IP "lib.bin/ego"
files used by the global optimizer.
1991-10-16 13:33:50 +00:00
.IP "lib.bin/lint"
binaries for the lint passes and lint libraries.
1991-10-16 13:33:50 +00:00
.IP "lib.bin/ceg"
files used by the code-expander-generator.
1984-06-29 11:21:50 +00:00
.IP "etc"
contains the file "ip_spec.t" needed for EM interpreters and EM documentation.
1991-10-16 13:33:50 +00:00
.IP "config"
contains two include files:
.TS
1991-11-19 17:25:02 +00:00
l l.
em_path.h path names used by \fIack\fP, intended for all utilities
local.h various definitions for local versions
1991-10-16 13:33:50 +00:00
.TE
These include files are specific for the current machine, so they
are in a separate directory.
.IP "include/_tail_cc"
1984-06-29 11:21:50 +00:00
.br
include files needed by modules
1984-06-29 11:21:50 +00:00
in the C library from lang/cem/libcc.
1991-10-16 13:33:50 +00:00
.IP "include/tail_ac"
.br
include files for ANSI C.
1991-10-16 13:33:50 +00:00
.IP "include/occam"
include files for occam.
1988-05-02 10:33:30 +00:00
.IP "include/_tail_mon"
.br
more or less system independent include files needed by modules
in the library lang/cem/libcc/mon.
1984-06-29 11:21:50 +00:00
.IP "h"
the #include files for:
1985-04-12 11:20:15 +00:00
.TS
1991-11-19 17:25:02 +00:00
l l.
arch.h definition of the ACK archive format
as_spec.h used by EM assembler and interpreters
bc_io.h used by the Basic run-time system
bc_string.h used by the Basic run-time system
cg_pattern.h used by the backend program "cg" and its bootstrap
cgg_cg.h used by the backend program "ncg" and its bootstrap
em_abs.h contains trap numbers and address for lin and fil
em_ego.h definition of names for some global optimizer
messages
em_flag.h definition of bits in array em_flag in
$TARGET_HOME/lib.bin/em_data.a. Describes parameters
effect on flow of instructions
em_mes.h definition of names for mes pseudo numbers
em_mnem.h instruction => compact mapping
em_pseu.h pseudo instruction => compact mapping
em_ptyp.h useful for compact code reading/writing,
defines classes of parameters
em_reg.h definition of mnemonics indicating register type
em_spec.h definition of constants used in compact code
ip_spec.h used by programs that read e.out files
m2_traps.h used by the Modula-2 run-time system
ocm_chan.h used by the occam run-time system
ocm_parco.h used by the occam run-time system
ocm_proc.h used by the occam run-time system
out.h defines the ACK a.out format
pc_err.h definitions of error numbers in Pascal
pc_file.h macro's used in file handling in Pascal
pc_math.h used by the Pascal runtime system
ranlib.h defines symbol table format for archives
stb.h defines debugger symbol table types
1985-04-12 11:20:15 +00:00
.TE
.IP "modules"
root of a tree containing modules for compiler writers.
.IP "modules/man"
manual pages for all modules.
.IP "modules/lib"
contains module objects.
.IP "modules/h"
include files for some of the modules.
.IP "modules/pkg"
include files for some of the modules.
1984-06-29 11:21:50 +00:00
.IP "doc"
this directory contains the unformatted documents for the Kit.
1985-04-12 11:20:15 +00:00
A list of the available documents can be found in the last section.
1993-03-31 13:22:17 +00:00
These documents must be processed by [nt]roff.
1991-10-16 13:33:50 +00:00
.IP "man"
man files for various utilities.
1991-10-16 13:33:50 +00:00
.if n .nr PD 1v
.LP
1991-11-19 17:25:02 +00:00
When installing ACK on several types of machines with a shared file system,
it may be useful to know that the "doc", "etc", "h",
1991-10-16 13:33:50 +00:00
"include", "lib" and "man" sub-directories do not depend on this
particular installation. They do not contain binaries or path-dependent
information. These directories can therefore be shared between the
ACK installations. This can be accomplished by creating the tree and
suitable symbolic links before starting the installation process.
.LP
1991-11-19 17:25:02 +00:00
For instance, let us say there is a file-system that is accessible from
the different machines as "/usr/share/local", and the ACK binary tree
must be installed in "/usr/local/ack". In this case, proceed as follows:
.IP \-
create a directory "/usr/share/local/ack", with subdirectories
"doc", "etc", "h", "include", "lib" and "man".
.IP \-
create a directory "/usr/local/ack" and
1991-10-16 13:33:50 +00:00
then create symbolic links "doc" to "/usr/share/local/ack/doc", etc.
.LP
1991-11-19 17:25:02 +00:00
If this is done on all machines on which ACK will be installed, the
1991-10-16 13:33:50 +00:00
machine-independent part only has to be installed once, preferably
on the fastest processor (it takes a long time to install all libraries).
.LP
The directories in the source tree contain the following information:
.if n .sp 1
.if n .nr PD 0
.IP "bin" 14
source of some shell-scripts.
.IP "lib"
mostly description files for the "ack" program.
.IP "etc"
the main description of EM sits here.
1991-10-16 13:33:50 +00:00
Files (e.g. em_table) describing
the opcodes and pseudos in use,
the operands allowed, effect in stack etc. etc.
1984-06-29 11:21:50 +00:00
.IP "mach"
1985-04-12 11:20:15 +00:00
just there to group the directories with all sources for each machine.
The section about "Machines" of this manual indicates which subdirectories
are used for which systems.
.br
These directories have subdirectories named:
.in +3n
.TS
1991-11-19 17:25:02 +00:00
l l.
cg the backend (*.m => *.s)
ncg the new backend (*.m => *.s)
as the assembler (*.s => *.o) or
assembler/linker (*.s + libraries => a.out)
cv conversion programs for a.out files
dl down-load programs
top the target optimizer
int source for an interpreter
1986-02-28 18:02:00 +00:00
1991-11-19 17:25:02 +00:00
libbc to create Basic run-time system and libraries
libcc to create C run-time system and libraries
libcc.ansi to create ANSI C run-time system and libraries
libpc to create Pascal run-time system and libraries
libf77 to create Fortran run-time system and libraries
libm2 to create Modula-2 run-time system and libraries
liboc to create occam run-time system and libraries
libem EM runtime system, only depending on CPU type
libend library defining end, edata, etext
libfp to create floating point library
libdb to create debugger support library
libsys system-dependent EM library
libce fast cc-compatible C compiler library support
1986-02-28 18:02:00 +00:00
1991-11-19 17:25:02 +00:00
ce code expander (fast back-end)
1989-03-07 16:25:32 +00:00
1991-11-19 17:25:02 +00:00
test various tests
1985-04-12 11:20:15 +00:00
.TE
.in -3n
1991-10-16 13:33:50 +00:00
Actually, some of these directories will only appear in the configuration tree.
.br
1986-02-28 18:02:00 +00:00
The directory proto contains files used by most machines,
1985-04-12 11:20:15 +00:00
like machine-independent sources and Makefiles.
.in +3n
.TS
l l.
mach/proto/cg current backend sources
mach/proto/ncg new backend sources
mach/proto/as assembler sources
mach/proto/top target optimizer sources
mach/proto/fp floating point package sources
mach/proto/libg makefiles for compiling libraries
1991-10-16 13:33:50 +00:00
mach/proto/grind machine-independent debugger support
1985-04-12 11:20:15 +00:00
.TE
1984-06-29 11:21:50 +00:00
.IP "emtest"
contains prototype of em test set.
1984-06-29 11:21:50 +00:00
.IP "lang"
just there to group the directories for all front-ends.
1984-06-29 11:21:50 +00:00
.IP "lang/pc"
the Pascal front-end.
1984-06-29 11:21:50 +00:00
.IP "lang/pc/libpc"
.br
source of Pascal run-time system (in EM or C).
1984-06-29 11:21:50 +00:00
.IP "lang/pc/test"
some test programs written in Pascal.
1991-10-16 13:33:50 +00:00
.IP "lang/pc/comp"
the Pascal compiler proper.
1984-06-29 11:21:50 +00:00
.IP "lang/cem"
the C front-end.
1984-06-29 11:21:50 +00:00
.IP "lang/cem/libcc"
.br
directories with sources of C runtime system, libraries (in EM or C).
1984-06-29 11:21:50 +00:00
.IP "lang/cem/libcc/gen"
.br
sources for routines in chapter III of
1991-10-16 13:33:50 +00:00
.UX
programmers manual,
excluding stdio.
1984-06-29 11:21:50 +00:00
.IP "lang/cem/libcc/stdio"
.br
stdio sources.
1988-07-25 12:21:59 +00:00
.IP "lang/cem/libcc/math"
.br
sources for mathematical routines, normally available with the
\fB-lm\fP option to \fIcc\fP.
1984-06-29 11:21:50 +00:00
.IP "lang/cem/libcc/mon"
.br
sources for routines in chapter II, mostly written in EM.
.IP "lang/cem/cemcom"
1984-06-29 11:21:50 +00:00
.br
the compiler proper.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/cemcom.ansi"
.br
the ANSI C compiler proper.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/cpp.ansi"
.br
the ANSI C preprocessor.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/libcc.ansi"
.br
the ANSI C library sources.
1984-06-29 11:21:50 +00:00
.IP "lang/cem/ctest"
.br
the C test set.
1984-06-29 11:21:50 +00:00
.IP "lang/cem/ctest/cterr"
.br
programs developed for pinpointing previous errors.
1984-06-29 11:21:50 +00:00
.IP "lang/cem/ctest/ct*"
.br
the test programs.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/lint"
a C program checker.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/lint/lpass1"
.br
the first pass of lint.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/lint/lpass1.ansi"
.br
the first pass of lint, this time for ANSI C.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/lint/lpass2"
.br
the second pass of lint, shared between ANSI C and "old-fashioned" C.
1991-10-16 13:33:50 +00:00
.IP "lang/cem/lint/llib"
.br
programs for producing lint libraries.
1991-10-16 13:33:50 +00:00
.IP "lang/basic"
the Basic front-end.
1985-04-12 11:20:15 +00:00
.IP "lang/basic/src"
.br
the compiler proper.
1985-04-12 11:20:15 +00:00
.IP "lang/basic/lib"
.br
the Basic run-time library source.
1985-04-12 11:20:15 +00:00
.IP "lang/basic/test"
.br
various Basic programs.
.IP "lang/occam"
the occam front-end.
.IP "lang/occam/comp"
.br
the compiler proper.
.IP "lang/occam/lib"
.br
source of occam run-time system (in EM or C).
.IP "lang/occam/test"
.br
some occam programs.
1988-04-19 14:33:58 +00:00
.IP "lang/m2"
the Modula-2 front-end.
1988-04-19 14:33:58 +00:00
.IP "lang/m2/comp"
the compiler proper.
1988-04-19 14:33:58 +00:00
.IP "lang/m2/libm2"
source of Modula-2 run-time system (in EM, C and Modula-2).
1988-04-19 14:33:58 +00:00
.IP "lang/m2/m2mm"
the Modula-2 makefile generator.
1988-04-19 14:33:58 +00:00
.IP "lang/m2/test"
some Modula-2 example programs.
1991-10-16 13:33:50 +00:00
.IP "lang/fortran"
the Fortran front-end (translates Fortran into C). This compiler is not
a part of ACK, but is included because it adds another language.
The Fortran system carries the following copyright notice:
1991-10-16 13:33:50 +00:00
.IP ""
.nf
1991-11-19 17:25:02 +00:00
/**************************************************************
1991-10-16 13:33:50 +00:00
Copyright 1990, 1991 by AT&T Bell Laboratories and Bellcore.
Permission to use, copy, modify, and distribute this software
and its documentation for any purpose and without fee is hereby
granted, provided that the above copyright notice appear in all
copies and that both that the copyright notice and this
permission notice and warranty disclaimer appear in supporting
documentation, and that the names of AT&T Bell Laboratories or
Bellcore or any of their entities not be used in advertising or
publicity pertaining to distribution of the software without
specific, written prior permission.
AT&T and Bellcore disclaim all warranties with regard to this
software, including all implied warranties of merchantability
and fitness. In no event shall AT&T or Bellcore be liable for
any special, indirect or consequential damages or any damages
whatsoever resulting from loss of use, data or profits, whether
in an action of contract, negligence or other tortious action,
arising out of or in connection with the use or performance of
this software.
1991-11-19 17:25:02 +00:00
**************************************************************/
1991-10-16 13:33:50 +00:00
.fi
.IP "lang/fortran/comp"
1988-04-19 14:33:58 +00:00
.br
the compiler proper.
1991-10-16 13:33:50 +00:00
.IP "lang/fortran/lib"
1984-06-29 11:21:50 +00:00
.br
source of Fortran runtime system and libraries.
.IP "fast"
contains sub-directories for installing the fast ACK compatible compilers.
.IP "fast/driver"
.br
contains the sources of the fast ACK compatible compiler drivers.
.IP "fcc"
contains the fast cc-compatible C compiler for SUN-3 and VAX.
1991-10-16 13:33:50 +00:00
.IP "util"
contains directories with sources for various utilities.
1985-04-12 11:20:15 +00:00
.IP "util/ack"
the program used for translation with the Kit.
1984-06-29 11:21:50 +00:00
.IP "util/opt"
the EM peephole optimizer (*.k => *.m).
.IP "util/ego"
the global optimizer.
.IP "util/topgen"
the target optimizer generator.
1984-06-29 11:21:50 +00:00
.IP "util/misc"
decode (*.[km] => *.e) + encode (*.e => *.k).
1984-06-29 11:21:50 +00:00
.IP "util/data"
the C-code for $TARGET_HOME/lib.bin/em_data.a.
These sources are created by the Makefile in `etc`.
1984-06-29 11:21:50 +00:00
.IP "util/ass"
the EM assembler (*.[km] + libraries => e.out).
1984-06-29 11:21:50 +00:00
.IP "util/arch"
the archivers to be used for all EM utilities.
1984-06-29 11:21:50 +00:00
.IP "util/cgg"
a program needed for compiling backends.
1985-04-12 11:20:15 +00:00
.IP "util/ncgg"
a program needed for compiling the newest backends.
1984-06-29 11:21:50 +00:00
.IP "util/cpp"
the C preprocessor.
1985-04-12 11:20:15 +00:00
.IP "util/shf"
various shell files.
1985-04-12 11:20:15 +00:00
.IP "util/LLgen"
the extended LL(1) parser generator.
.IP "util/amisc"
contains some programs handling ACK a.out format, such as anm, asize.
.IP "util/cmisc"
contains some programs to help in resolving name conflicts, and
a dependency generator for makefiles.
.IP "util/led"
the ACK link-editor, reading ACK relocatable a.out format, and writing
ACK a.out format.
1988-06-27 15:00:08 +00:00
.IP "util/int"
an EM interpreter, written in C. Very useful for checking out software,
1991-10-16 13:33:50 +00:00
but slow.
1989-03-07 16:25:32 +00:00
.IP "util/ceg"
code expander generator.
1991-10-16 13:33:50 +00:00
.IP "util/grind"
a symbolic debugger.
1991-10-16 13:33:50 +00:00
.IP "util/byacc"
this is Berkeley yacc, in the public domain.
1991-10-16 13:33:50 +00:00
.IP "util/flex"
this is a replacement for lex. It carries the following copyright notice:
1991-10-16 13:33:50 +00:00
.IP ""
.nf
Copyright (c) 1990 The Regents of the University of California.
All rights reserved.
This code is derived from software contributed to Berkeley by
Vern Paxson.
The United States Government has rights in this work pursuant
to contract no. DE-AC03-76SF00098 between the United States
Department of Energy and the University of California.
Redistribution and use in source and binary forms are permitted
provided that: (1) source distributions retain this entire
copyright notice and comment, and (2) distributions including
binaries display the following acknowledgement: ``This product
includes software developed by the University of California,
Berkeley and its contributors'' in the documentation or other
materials provided with the distribution and in all advertising
materials mentioning features or use of this software. Neither the
name of the University nor the names of its contributors may be
used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE.
.fi
1985-04-12 11:20:15 +00:00
.ne 4
1991-10-16 13:33:50 +00:00
.if n .nr PD 1v
1984-06-29 11:21:50 +00:00
.LP
All path names mentioned in the text of this document are relative to
$SRC_HOME, unless they start with '/' or one of $SRC_HOME,
1991-10-16 13:33:50 +00:00
$TARGET_HOME or $CONFIG.
.NH
Restoring the ACK tree
.PP
The process of installing the Amsterdam Compiler Kit is quite simple.
The first step is to restore the Amsterdam Compiler Kit
distribution tree structure.
Proceed as follows
.IP " \-" 10
Create a directory, for example /usr/share/local/src/ack, on a device
with at least 15 Megabytes left. This directory will be $SRC_HOME.
1991-10-16 13:33:50 +00:00
.IP " \-"
Change to that directory (cd ...).
.IP " \-"
Extract all files from the distribution medium, for instance
magtape:
\fBtar x\fP.
.IP " \-"
Keep a copy of the original distribution to be able to repeat the process
of installation in case of disasters.
This copy is also useful as a reference point for diff-listings.
1985-04-12 11:20:15 +00:00
.NH
1991-11-19 17:25:02 +00:00
Adapting ACK to the local system
1984-06-29 11:21:50 +00:00
.PP
1985-04-12 11:20:15 +00:00
Before compiling the sources in the Kit some installation dependent
actions have to be taken.
Most of these are performed by an interactive shell script in the file
1991-10-16 13:33:50 +00:00
.I $SRC_HOME/first/first.
1991-11-19 17:25:02 +00:00
Calling this script should be done
from another directory, for instance an empty directory which will later
1991-10-16 13:33:50 +00:00
become $CONFIG.
1985-04-12 11:20:15 +00:00
.LP
1991-10-16 13:33:50 +00:00
The actions of the
.I first
script are:
.if n .sp 1
.if n .nr PD 0
1986-02-28 18:02:00 +00:00
.IP \-
1991-11-19 17:25:02 +00:00
Asking for the path names of the ACK source directory ($SRC_HOME), the
configuration directory ($CONFIG), and the ACK users directory ($TARGET_HOME).
1991-11-19 17:25:02 +00:00
About 5M are needed for the configuration tree. The disk space needed
for the ACK users tree depends on which front-ends and back-ends are to be
installed.
For instance, on our SPARC systems
we have installed all languages and 6 back-ends, including the
system-independent part. This amounts to about 16M.
On our SUN-3 systems, we have installed all front-ends and 5 back-ends,
but only the machine-dependent part. The machine-independent directories are
symbolic links to the SPARC ACK users tree.
We also have the fast ACK compilers
installed on the SUN-3's.
The total amount of disk-space used is less than 8M.
1987-03-25 22:43:09 +00:00
.IP \-
1991-11-19 17:25:02 +00:00
Asking for what type of system the binary tree must be produced for
1985-04-12 11:20:15 +00:00
and creating the shell script "ack_sys" in the Kit's bin directory.
Several utilities make use of "ack_sys" to determine the type of
1991-11-19 17:25:02 +00:00
system.
1985-04-12 11:20:15 +00:00
The current choice is between:
.TS
1991-11-19 17:25:02 +00:00
c c c
l l l.
1985-04-12 11:20:15 +00:00
answer system type default machine
1991-11-19 17:25:02 +00:00
vax_bsd4_1a VAX11 + BSD4.1a vax4
vax_bsd4_2 VAX11 + BSD4.2 vax4
vax_sysV_2 VAX11 + System V.2 vax4
i386 Intel 80386 system + Xenix System V i386
sun3 Sun-3 Motorola 68020 workstation sun3
sun2 Sun-2 Motorola 68010 workstation sun2
m68_sysV_0 68000 + Uniplus System V.0 mantra
m68020 Motorola 68020 VME131 + System V/68 R2V2.1 m68020
1993-10-07 09:52:41 +00:00
sparc Sun-4 or SPARC workstation running SunOs 4 sparc
sparc_solaris Sun-4 or SPARC workstation running Solaris 2 sparc_solaris
1991-11-19 17:25:02 +00:00
ANY Neither of the above ???
1985-04-12 11:20:15 +00:00
.TE
For some of these, the installation procedure has not been tested, as
1988-04-19 14:33:58 +00:00
we don't have them.
For others, the installation procedure has only been tested with earlier
distributions, as we don't have those systems anymore.
However, the sun3 and sparc systems are known to behave reasonably.
The sparc_solaris system has only been tested with the GNU C compiler,
because we don't have the SUN C compiler (it is unbundled in Solaris 2).
1991-10-16 13:33:50 +00:00
The Sun systems should run SunOs Release 3.0 or newer.
The i386 choice may also be used for Intel 80386 or 80486 systems
running
.UX
System V Release 4. These systems are also able to run Xenix System V
binaries.
1991-11-19 17:25:02 +00:00
If the target system is not on this list, choose one that comes close.
If none of them come close, use the "ANY" choice.
1991-11-19 17:25:02 +00:00
For ANY, any name can be used,
but the Kit will not be able to compile programs for the target system.
See the section about "compilation
1985-04-12 11:20:15 +00:00
on a different machine".
1986-02-28 18:02:00 +00:00
.IP \-
1991-10-16 13:33:50 +00:00
Setting the default machine for which code is
1991-11-19 17:25:02 +00:00
produced to the local type of system according to the table above.
1991-10-16 13:33:50 +00:00
This in done in the file "$TARGET_HOME/config/local.h".
1991-11-19 17:25:02 +00:00
See also section 9.1.
1986-02-28 18:02:00 +00:00
.IP \-
1991-11-19 17:25:02 +00:00
Asking for things that don't have to be installed.
1986-02-28 18:02:00 +00:00
.IP \-
1991-10-16 13:33:50 +00:00
Producing a shell script called "INSTALL" that will take care of the
ACK installation process.
1984-06-29 11:21:50 +00:00
.NH
1985-04-12 11:20:15 +00:00
Compiling the Kit
1984-06-29 11:21:50 +00:00
.PP
1991-10-16 13:33:50 +00:00
The next step in the installation process is to run the "INSTALL"
shell-script. When using a Bourne-shell, type:
1991-10-16 13:33:50 +00:00
.DS
sh INSTALL > INSTALL.out 2>&1 &
.DE
When using a C-shell, type:
.DS
sh INSTALL >& INSTALL.out &
.DE
1991-10-16 13:33:50 +00:00
This shell-script performs the following steps:
.if n .sp 1
.if n .nr PD 0
.IP \-
Produce a configuration tree ($CONFIG), reflecting the structure of the
1991-10-16 13:33:50 +00:00
source tree.
.IP \-
Produce Makefiles in $CONFIG.
1991-10-16 13:33:50 +00:00
As mentioned before, compilations
will be done in the configuration tree, not in the source tree.
Most configuration directories will have Makefiles
1985-04-12 11:20:15 +00:00
used to compile and install the programs in that
1984-06-29 11:21:50 +00:00
directory.
1985-04-12 11:20:15 +00:00
All programs needed for compilation and/or cross compilation
1991-10-16 13:33:50 +00:00
with the Kit are installed in $TARGET_HOME by these Makefiles.
These Makefiles are produced from corresponding files called
"proto.make" in the source tree. In fact, the "proto.make" files
are almost complete Makefiles, except for some macro definitions that
are collected by the \fIfirst\fP script.
The Makefiles adhere to a standard which is described in the
1985-04-12 11:20:15 +00:00
section 9.
1991-10-16 13:33:50 +00:00
.IP \-
Copy "Action" files to the configuration tree and editing them to
1991-11-19 17:25:02 +00:00
reflect the choices concerning the parts of ACK that have to be
installed. "Action" files are described below.
1991-10-16 13:33:50 +00:00
.IP \-
Copy part of the source tree to the ACK users tree (include files,
1991-10-16 13:33:50 +00:00
manual pages, documentation, et cetera).
.IP \-
Calling the "TakeAction" script.
1991-11-19 17:25:02 +00:00
All these Makefiles do not have to be called separately.
1985-04-12 11:20:15 +00:00
We wrote a shell script calling the make's needed to install
the whole Kit.
1991-10-16 13:33:50 +00:00
This script consists of the file $SRC_HOME/TakeAction
and a few files called Action in some configuration directories.
1985-04-12 11:20:15 +00:00
The Action files describe in a very simple form which actions
have to be performed in which directories.
The default action is to start "make install && make clean".
1985-04-12 11:20:15 +00:00
The output of each make is diverted to a file called "Out"
in the same directory as the make was started in.
If the make was successful (return code 0) the Out file is removed
1991-11-19 17:25:02 +00:00
and the script TakeAction produces a small message indicating
1985-04-12 11:20:15 +00:00
that it succeeded in fulfilling its goal.
If the make was not successful (any other return code) the Out file
1991-11-19 17:25:02 +00:00
is left alone for further examination and the script TakeAction
produces a small message indicating that it failed.
1991-10-16 13:33:50 +00:00
.br
1985-04-12 11:20:15 +00:00
For some programs the scripts already know they can't be
1991-11-19 17:25:02 +00:00
installed on the local type of system.
1985-04-12 11:20:15 +00:00
In that case they produce a message "Sorry, ....." and
happily proceed with further installation commands.
1991-10-16 13:33:50 +00:00
.if n .sp 1
.if n .nr PD 1v
.LP
1991-11-19 17:25:02 +00:00
Installation of the Kit might take anything from a few
hours to more than a day, depending on the speed of the local machine and
what must be installed.
1991-10-16 13:33:50 +00:00
.LP
1991-11-19 17:25:02 +00:00
If the installation succeeded, the Kit is ready to be used.
Read section 6 and the manuals provided
1991-10-16 13:33:50 +00:00
with the Kit (in the $TARGET_HOME/man directory) on how to use it.
1985-04-12 11:20:15 +00:00
.NH 2
1991-11-19 17:25:02 +00:00
Problems
1985-04-12 11:20:15 +00:00
.NH 3
on Unisoft m68000 systems.
.PP
The Unisoft C compiler has a bug which impedes the correct
translation of the peephole optimizer.
For a more detailed description of this phenomenon see
1991-10-16 13:33:50 +00:00
the file "$SRC_HOME/mach/m68k2/Unisoft_bug".
(This observation was made in 1985 or so, so it is probably
no longer true).
1985-04-12 11:20:15 +00:00
.NH 3
with backends
.PP
1991-10-16 13:33:50 +00:00
The backends for the PDP11, VAX, Motorola 68000 and 68020,
SPARC, Intel 8086, and Intel 80386
1991-10-16 13:33:50 +00:00
have been heavily used by ourselves and are well tested.
1985-04-12 11:20:15 +00:00
The backends for the other machines are known to run our own
test programs,
but might reveal errors when more heavily used.
.NH 2
An example output of TakeAction.
1991-10-16 13:33:50 +00:00
.LP
.sp 1
.nf
System definition -- done
EM definition library -- done
C utilities -- done
Flex lexical analyzer generator -- done
Yacc parser generator -- done
system-call interface module -- done
.
.
.
EM Global optimizer -- done
ACK archiver -- done
Program 'ack' -- done
Bootstrap for backend tables -- done
Bootstrap for newest form of backend tables -- done
.
.
.
C frontend -- done
ANSI-C frontend -- done
ANSI-C preprocessor -- done
ANSI-C header files -- done
Failed for LINT C program checker, see lang/cem/lint/Out
Pascal frontend -- done
Basic frontend -- done
.
.
.
Vax 4-4 assembler -- done
Vax 4-4 backend -- done
Vax target optimizer -- done
ACK a.out to VAX a.out conversion program -- done
Sorry, Vax code expander library can only be made on vax* systems
Vax 4-4 EM library -- done
Vax 4-4 debugger support library -- done
Vax 4-4 etext,edata,end library -- done
Vax 4-4 systemcall interface -- done
.
.
.
.sp 1
.fi
.LP
1991-11-19 17:25:02 +00:00
The lines starting with "Sorry, " indicate that certain programs cannot
be translated on the local machine.
The lines starting with "Failed for" indicate
that certain programs/libraries were expected to,
1985-04-12 11:20:15 +00:00
but did not compile.
1991-10-16 13:33:50 +00:00
In this example, the installation of LINT failed.
1991-11-19 17:25:02 +00:00
To repeat a certain part of the installation, look in
1991-10-16 13:33:50 +00:00
the Action file, which resides in the root of the configuration tree,
for the directory in which that part is to be found.
1985-04-12 11:20:15 +00:00
If that directory contains an Action file issue the command
"sh $CONFIG/bin/TakeAction", otherwise type "make install".
1984-06-29 11:21:50 +00:00
.NH
Commands
.PP
1991-10-16 13:33:50 +00:00
The following commands are available in the $TARGET_HOME/bin directory after compilation
of the Kit:
1991-10-16 13:33:50 +00:00
.IP "\fIack\fP, \fIacc\fP, \fIabc\fP, \fIapc\fP, \fIocm\fP, \fIm2\fP, \fIf2c\fP and their links" 14
1984-06-29 11:21:50 +00:00
.br
the names mentioned here can be used to compile Pascal, C, etc... programs.
1985-04-12 11:20:15 +00:00
Most of the links can be used to generate code for a particular
machine.
1985-04-12 11:32:41 +00:00
See also the section about "Machines".
1984-06-29 11:21:50 +00:00
.IP \fIarch\fP
the archiver used for the EM- and universal assembler/loader.
.IP \fIaal\fP
the archiver used for ACK objects.
1985-04-12 11:20:15 +00:00
.IP \fIem\fP
this program selects a interpreter to execute an e.out file.
1985-04-12 11:20:15 +00:00
Interpreters exist for PDP-11 and Motorola 68000 systems.
.IP \fIeminform\fP
the program to unravel the post-mortem information of
1985-04-12 11:20:15 +00:00
the EM interpretator for the PDP-11.
.IP \fILLgen\fP
the LL(1) parser generator.
1985-04-12 11:20:15 +00:00
.IP \fIack_sys\fP
1991-11-19 17:25:02 +00:00
a shell script producing an identification of the target system.
1985-04-12 11:20:15 +00:00
Used by some utilities to determine what is, and what is
1991-11-19 17:25:02 +00:00
not feasible on the target system.
1985-04-12 11:20:15 +00:00
.IP \fImarch\fP
a shell script used while compiling libraries.
.IP "\fIasize\fP, \fIanm\fP, \fIastrip\fP"
.br
do the same as \fIsize\fP, \fInm\fP and \fIstrip\fP, but for ACK object format.
.IP \fImkdep\fP
a dependency generator for makefiles.
.IP "\fIcid\fP, \fIprid\fP, \fIcclash\fP"
.br
some utilities for handling name clashes in C programs. Some
systems have C-compilers with only 7 or 8 characters significant in
identifiers.
.IP \fItabgen\fP
a utility for generating character tables for C-programs.
1988-06-27 15:08:38 +00:00
.IP \fIint\fP
an EM interpreter. This one is written in C, and is very useful for checking
1988-06-27 15:08:38 +00:00
out programs.
.IP \fIgrind\fP
a source level debugger for C, ANSI-C, Modula-2 and Pascal.
.IP "\fIafcc\fP, \fIafm2\fP, \fIafpc\fP"
.br
these are ACK-compatible fast C, Modula-2 and Pascal compilers,
available for M68020, VAX and Intel 80386 systems. They compile very fast,
but produce slow code.
.IP \fIfcc\fP
this is a cc-compatible fast C compiler, available on SUN-3 and VAX
systems. It compiles very fast, but produces slow code.
1984-06-29 11:21:50 +00:00
.LP
1985-04-12 11:20:15 +00:00
We currently make the Kit available to our users by telling
1991-10-16 13:33:50 +00:00
them that they should include the $TARGET_HOME/bin directory in
1984-06-29 11:21:50 +00:00
their PATH shell variable.
The programs will still work when moved to a different
1985-04-12 11:20:15 +00:00
directory or linked to.
Copying should preferably be done with tar, since links are
1984-06-29 11:21:50 +00:00
heavily used.
Renaming of the programs linked to \fIack\fP will not always
produce the desired result.
This program uses its call name as an argument.
1991-10-16 13:33:50 +00:00
Any call name not being \fIcc\fP, \fIacc\fP, \fIabc\fP, \fIpc\fP, \fIf2c\fP,
1988-05-02 10:33:30 +00:00
\fIocm\fP, \fIm2\fP, or \fIapc\fP will be
1984-06-29 11:21:50 +00:00
interpreted as the name of a 'machine description' and the
program will try to find a description file with that name.
1991-10-16 13:33:50 +00:00
The installation process will only touch the utilities in the $TARGET_HOME/bin
1991-11-19 17:25:02 +00:00
directory, not copies of these utilities.
1984-06-29 11:21:50 +00:00
.NH
1985-04-12 11:20:15 +00:00
Machines
1984-06-29 11:21:50 +00:00
.PP
1991-11-19 17:25:02 +00:00
Below is a table with entries for all commands in
1985-04-12 11:20:15 +00:00
the bin directory used to (cross)compile for a particular machine.
1991-11-19 17:25:02 +00:00
The name in the first column gives the name in the bin directory.
1985-04-12 11:20:15 +00:00
The column headed dir indicates which subdirectories of
$TARGET_HOME/lib and/or $TARGET_HOME/lib.bin are needed for compilation.
1985-04-12 11:20:15 +00:00
The column head i/p contains the integer and pointer size used in units of
bytes.
The subdirectories with the same name in mach contain the sources.
1988-04-11 13:03:14 +00:00
A * in the column headed 'fp' indicates that floating point can be used
for that particular machine. A + in that column indicates that floating
point is available under the '-fp' option. In this case, software
1988-04-11 13:03:14 +00:00
floating point emulation is used.
1985-04-12 11:20:15 +00:00
.TS
l l l l l l l.
command system i/p languages fp dir remarks
1991-10-16 13:33:50 +00:00
pdp PDP/UNIX V7 2/2 C * pdp
1990-02-09 16:27:59 +00:00
Pascal
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1990-02-09 16:27:59 +00:00
vax4 VAX/BSD 4.? 4/4 C * vax4
System V.2 Pascal
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
sparc Sun-4 4/4 C * sparc
Pascal
Basic
occam
1991-10-16 13:33:50 +00:00
Modula-2
Fortran
1985-04-12 11:20:15 +00:00
1993-10-07 09:52:41 +00:00
sparc_solaris Sun-4 4/4 C * sparc_solaris
Pascal
Basic
occam
Modula-2
Fortran
1991-11-19 17:25:02 +00:00
m68k2 M68000/ 2/4 C + m68k2
Unisoft Pascal
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1991-11-19 17:25:02 +00:00
m68k4 M68000/ 4/4 C + m68k4
Unisoft Pascal m68k2
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1985-04-12 11:20:15 +00:00
1991-11-19 17:25:02 +00:00
pmds M68000/ 2/4 C + pmds Philips Micro
PMDS Pascal m68k2 Devel. System
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1991-11-19 17:25:02 +00:00
pmds4 M68000/ 4/4 C + pmds4 Philips Micro
PMDS Pascal m68k2 Devel. System
Basic m68k4
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1991-11-19 17:25:02 +00:00
mantra M68000/ 4/4 C + mantra
Sys V.0 Pascal m68k2
Basic m68k4
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1991-11-19 17:25:02 +00:00
m68020 M68020/ 4/4 C + m68020
Sys V/68 R2V2.1 Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1991-11-19 17:25:02 +00:00
sun3 Sun-3 R4.1 4/4 C + sun3
Pascal m68020
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1985-04-12 11:20:15 +00:00
1991-10-16 13:33:50 +00:00
sun2 Sun-2 R3.0 4/4 C + sun2
Pascal m68k4
Basic m68k2
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1988-04-11 13:03:14 +00:00
i86 IBM PC/IX 2/2 C + i86 IBM PC with PC/IX
Pascal Causes kernel crashes
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1991-11-19 17:25:02 +00:00
xenix3 Microsoft 2/2 C + xenix3 IBM AT with Xenix
Xenix V3 Pascal i86
1988-04-11 13:03:14 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-11-19 17:25:02 +00:00
i386 SCO Xenix 4/4 C + i386 Intel 80386
System V Pascal Xenix System V
1989-10-10 14:42:59 +00:00
Basic
occam
1989-10-10 14:42:59 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1989-10-10 14:42:59 +00:00
1988-04-19 14:33:58 +00:00
minix Minix PC 2/2 C + minix IBM PC running Minix
Pascal i86
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
minixST ST Minix 2/4 C + minixST Atari ST running Minix
Pascal m68k2
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1988-04-11 13:03:14 +00:00
1985-04-12 11:20:15 +00:00
z8000 Zilog 8000 2/2 C z8000 Central Data
Pascal CPU board
1991-11-19 17:25:02 +00:00
Basic Assembler/loader
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1988-05-06 13:46:55 +00:00
em22 EM machine 2/2 C * em22 Needs interpreter
1985-04-12 11:20:15 +00:00
Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1988-05-06 13:46:55 +00:00
em24 EM machine 2/4 C * em24 Needs interpreter
1985-04-12 11:20:15 +00:00
Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1988-05-06 13:46:55 +00:00
em44 EM machine 4/4 C * em44 Needs interpreter
Pascal
1985-04-12 11:20:15 +00:00
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1985-04-12 11:20:15 +00:00
1991-11-19 17:25:02 +00:00
6500 6502/BBC 2/2 C 6500 Assembler/loader
1985-04-12 11:20:15 +00:00
Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
6800 Bare 6800 6800 Assembler only
6805 Bare 6805 6805 Assembler only
6809 Bare 6809 6809 Assembler only
ns Bare NS16032 4/4 C ns
Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1991-10-16 13:33:50 +00:00
Fortran
1985-04-12 11:20:15 +00:00
i80 Hermac/z80 2/2 C i80
Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
z80 Hermac/z80 2/2 C z80 \fIi80\fP is faster
Pascal
Basic
occam
1988-04-19 14:33:58 +00:00
Modula-2
1985-04-12 11:20:15 +00:00
1991-11-19 17:25:02 +00:00
s2650 Signetics s2650 Assembler only
1991-10-16 13:33:50 +00:00
1991-11-19 17:25:02 +00:00
arm Acorn 4/4 C * arm Assembler/loader
Archimedes Pascal
1991-10-16 13:33:50 +00:00
Basic
occam
1991-10-16 13:33:50 +00:00
Modula-2
Fortran
1985-04-12 11:20:15 +00:00
.TE
1991-10-16 13:33:50 +00:00
.LP
1988-05-06 13:46:55 +00:00
The commands \fBem22\fP, \fBem24\fP and \fBem44\fP
1985-04-12 11:20:15 +00:00
produce e.out files with EM machine code which must be interpreted.
1988-06-27 15:08:38 +00:00
The Kit contains three interpreters: one running under PDP 11/V7 UNIX,
1991-10-16 13:33:50 +00:00
one for the M68000, running under the PMDS system, Sun systems,
the Mantra system, etc, and a portable one, written in C.
1985-04-12 11:20:15 +00:00
The first one can only interpret 2/2 e.out files,
1988-06-27 15:08:38 +00:00
the second takes 2/4 and 4/4 files,
and the last one takes 2/2, 2/4 and 4/4.
1985-04-12 11:20:15 +00:00
The PDP 11 interpreter executes floating point instructions.
.LP
1991-10-16 13:33:50 +00:00
The program \fB$TARGET_HOME/bin/em\fP calls the appropriate
1985-04-12 11:20:15 +00:00
interpreter.
1991-10-16 13:33:50 +00:00
The interpreters are looked for in the em22, em24 and em44
subdirectories of $TARGET_HOME/lib.bin.
1991-10-16 13:33:50 +00:00
The third interpreter is available as the program \fB$TARGET_HOME/bin/int\fP
1988-06-27 15:08:38 +00:00
in the bin directory.
1984-06-29 11:21:50 +00:00
.NH
1985-04-12 11:20:15 +00:00
Compilation on a different machine.
1984-06-29 11:21:50 +00:00
.PP
1993-11-11 12:00:22 +00:00
The installation mechanism of the Kit is supposed to be portable across
.UX
machines, so
the Kit can be installed and used as a cross-compiler
for the languages it supports on any
1991-10-16 13:33:50 +00:00
.UX
machine.
The presence of most
.UX
utilities is essential for compilation.
1993-11-11 12:00:22 +00:00
A few of the programs certainly needed are: sh, C-compiler, sed, ed,
make, and awk.
1984-06-29 11:21:50 +00:00
.NH 2
1985-04-12 11:20:15 +00:00
Backend
1984-06-29 11:21:50 +00:00
.PP
1985-04-12 11:20:15 +00:00
The existence of a backend with a system call library
1991-11-19 17:25:02 +00:00
for the target system is essential
for producing executable files for that system.
1985-04-12 11:20:15 +00:00
Rewriting the system call library if the one supplied does
1991-11-19 17:25:02 +00:00
not work on the target system is fairly straightforward.
If no backend exists for the target CPU type, a new backend has to be written
1985-04-12 11:20:15 +00:00
which is a major undertaking.
.NH 2
Universal assembler/loader, link editor
1984-06-29 11:21:50 +00:00
.PP
1991-10-16 13:33:50 +00:00
For most machines, the description files in $TARGET_HOME/lib/*/descr use our
universal assembler and our link editor.
The load file produced is not directly
1984-06-29 11:21:50 +00:00
usable in any system known to us,
but has to be converted before it can be put to use.
1985-04-12 11:20:15 +00:00
The \fIcv\fP programs convert our a.out format into
executable files.
1984-06-29 11:21:50 +00:00
The \fIdl\fP programs present for some machines unravel
our a.out files and transmit commands to load memory
1984-06-29 11:21:50 +00:00
to a microprocessor over a serial line.
The file $TARGET_HOME/man/man5/ack.out.5 contains a description of the format of
the universal assembler load file.
It might be useful to those who wish or need to write their
1984-06-29 11:21:50 +00:00
own conversion programs.
Also, a module is included to read and write our a.out format.
See $TARGET_HOME/man/man3/object.3.
1984-06-29 11:21:50 +00:00
.NH
1985-04-12 11:20:15 +00:00
Options
.NH 2
Default machine
.PP
1991-10-16 13:33:50 +00:00
There is one important option in $TARGET_HOME/config/local.h.
1985-04-12 11:20:15 +00:00
The utility \fIack\fP uses a default machine name when called
1988-04-19 14:33:58 +00:00
as \fIacc\fP, \fIcc\fP, \fIabc\fP, \fIapc\fP, \fIpc\fP, \fIocm\fP,
1991-10-16 13:33:50 +00:00
\fIm2\fP, \fIf2c\fP, or \fIack\fP.
1993-11-11 12:00:22 +00:00
The machine name used by default is determined by the
1991-10-16 13:33:50 +00:00
definition of ACKM in $TARGET_HOME/config/local.h.
1990-02-09 16:27:59 +00:00
The Kit is distributed with "sun3" as the default machine,
1985-04-12 11:20:15 +00:00
but the shell script "first" in the directory "first" alters this
1991-11-19 17:25:02 +00:00
to suit the target system.
1985-04-12 11:20:15 +00:00
There is nothing against using the Kit as a cross-compiler
1991-11-19 17:25:02 +00:00
and by default produce code that can't run on the local system.
1985-04-12 11:20:15 +00:00
.NH 2
Pathnames
.PP
Absolute path names are concentrated in "$TARGET_HOME/config/em_path.h".
1991-10-16 13:33:50 +00:00
Only the utilities \fIack\fP, \fIflex\fP, and \fILLgen\fP use
absolute path names to access files in the Kit.
1985-04-12 11:20:15 +00:00
The tree is distributed with /usr/em as the working
directory.
The definition of EM_DIR in em_path.h should be altered to
specify the root
1991-11-19 17:25:02 +00:00
directory for the Compiler Kit binaries on the local system ($TARGET_HOME).
1990-02-09 16:27:59 +00:00
This is done automatically by the shell script "first" in the
1985-04-12 11:20:15 +00:00
directory "first".
Em_path.h also specifies which directory should be used for
temporary files.
Most programs from the Kit do indeed use that directory
although some remain stubborn and use /tmp or /usr/tmp.
.LP
The shape of the tree should not be altered lightly because
most Makefiles and the
utility \fIack\fP know the shape of the ACK tree.
The knowledge of the utility \fIack\fP about the shape of the tree is
1991-10-16 13:33:50 +00:00
concentrated in the files in the directory $TARGET_HOME/lib/*/descr and $TARGET_HOME/lib/descr/*.
1985-04-12 11:20:15 +00:00
.NH
Makefiles
.PP
1991-10-16 13:33:50 +00:00
Most directories contain a "proto.make", from which a Makefile is derived.
1985-04-12 11:20:15 +00:00
Apart from commands applying to that specific directory these
files all recognize a few special commands.
When called with one of these they will apply the command to
their own directory.
1985-04-12 11:20:15 +00:00
The special commands are:
.sp 1
.IP "install" 20
recompile and install all binaries and libraries.
.br
Some Makefiles allow errors to occur in the programs they call.
They ignore such errors and notify the user with the message
"~....... error code n: ignored".
1991-11-19 17:25:02 +00:00
Whenever such a message appears in the output it can be ignored.
1985-04-12 11:20:15 +00:00
.IP "cmp"
recompile all binaries and libraries and compare them to the
ones already installed.
.IP pr
print the sources and documentation on the standard output.
.IP opr
make pr | opr
.br
Opr should be an off-line printer daemon.
On some systems it exists under another name e.g. lpr.
The easiest way to call such a spooler is using a shell script
with the name opr that calls lpr.
1991-10-16 13:33:50 +00:00
This script should be placed in /usr/bin or $TARGET_HOME/bin or
1991-11-19 17:25:02 +00:00
one of the directories in the PATH environment variable.
1985-04-12 11:20:15 +00:00
.IP clean
remove all files not needed for day-to-day use,
that is binaries not in $TARGET_HOME/bin or $TARGET_HOME/lib.bin, object files etc.
1985-04-12 11:20:15 +00:00
.LP
Example:
1991-10-16 13:33:50 +00:00
.DS
make install
.DE
given as command in a configuration directory will cause
1985-04-12 11:20:15 +00:00
compilation of all programs in the directory and copying of the results
to the $TARGET_HOME/bin and $TARGET_HOME/lib.bin directories.
1984-06-29 11:21:50 +00:00
.NH
Testing
.PP
Test sets are available in Pascal, C, Basic and EM assembly:
.IP EM 8
the directory $SRC_HOME/emtest contains a few EM test programs.
1984-06-29 11:21:50 +00:00
The EM assembly files in these tests must be transformed into
1985-04-12 11:20:15 +00:00
load files.
1984-06-29 11:21:50 +00:00
These tests use the LIN and NOP instructions to mark the passing of each
test.
The NOP instruction prints the current line number during the
test phase.
Each test notifies its correctness by calling LIN with a unique
number followed by a NOP which prints this line number.
The test finishes normally with 0 as the last number printed
In all other cases a bug showed its
existence.
.IP Pascal
the directory $SRC_HOME/lang/pc/test contains a few Pascal test programs.
1984-06-29 11:21:50 +00:00
All these programs print the number of errors found and a
identification of these errors.
1985-04-12 11:20:15 +00:00
.sp 1
.ti +4
We also tested Pascal with the Validation Suite.
The Validation Suite is a collection of more than 200 Pascal programs,
designed by Brian Wichmann and Arthur Sale to test Pascal compilers.
1991-11-19 17:25:02 +00:00
We are not allowed to distribute it, but a copy may
be requested from
1985-04-12 11:20:15 +00:00
.DS
Richard J. Cichelli
A.N.P.A.
1350 Sullivan Trail
P.O. Box 598
Easton, Pennsylvania 18042
USA
.DE
1984-06-29 11:21:50 +00:00
.IP C
the sub-directories in $SRC_HOME/lang/cem/ctest contain C test programs.
1984-06-29 11:21:50 +00:00
The idea behind these tests is:
1991-11-19 17:25:02 +00:00
if there is a program called xx.c, compile it into xx.cem.
1984-06-29 11:21:50 +00:00
Run it with standard output to xx.cem.r, compare this file to
xx.cem.g, a file containing the 'ideal' output.
Any differences will point to implementation differences or
bugs.
Giving the command "run gen" or plain "run" starts this
process.
The differences will be presented on standard output.
The contents of the result files depend on the word size,
1984-06-29 11:21:50 +00:00
the xx.cem.g files on the distribution are intended for a
32-bit machine.
1985-04-12 11:20:15 +00:00
.IP Basic
the directory $SRC_HOME/lang/basic/test contains some forty Basic programs.
1985-04-12 11:20:15 +00:00
Not all of these programs are correct, some have syntactic errors,
some simply don't work.
The Makefile in that directory attempts to compile and run
these tests.
If it compiles its output is compared to a file with suffix .g
which contains the output to be expected.
The make should be started with its standard input diverted
to /dev/null.
An example of the output of a make is present in the file Out.std.
1984-06-29 11:21:50 +00:00
.NH
Documentation
.PP
1993-11-11 12:00:22 +00:00
After installation, the manual pages for Amsterdam Compiler Kit can be found
1993-03-31 13:22:17 +00:00
in the $TARGET_HOME/man directory. Also, the following documents are provided
in the $TARGET_HOME/doc directory:
1985-04-12 11:20:15 +00:00
.TS
l l.
1993-03-31 13:22:17 +00:00
toolkit.doc general overview (CACM article)
em.doc description of the EM machine architecture
ack.doc format of machine description files (lib/*/descr)
ansi_C.doc ANSI C implementation description
basic.doc Basic reference manual
pcref.doc Pascal-frontend reference manual
val.doc results of running the Pascal Validation Suite
crefman.doc C-frontend description
LLgen description of the LL(1) parser generator
peep.doc internal documentation for the peephole optimizer
cg.doc documentation for backend writers and maintainers
regadd.doc addendum to previous document describing register variables
ncg.doc documentation for the newest backends
v7bugs.doc bugs in the V7 system and how to fix them
6500.doc MSC 6500 backend description
i80.doc Intel 8080 backend description
z80.doc Zilog Z80 backend description
m68020.doc Motorola M68000/M68020 backend description
sparc.doc SPARC code expander description
occam.doc occam-frontend description
ego.doc Global Optimizer description
top.doc Target Optimizer description
int.doc description of the EM interpreter written in C
ceg.doc documentation for code-expander writers and maintainers
lint.doc documentation of LINT
m2ref.doc Modula-2 frontend description
install.doc this document
install.pr this document (formatted for a simple line printer)
1985-04-12 11:20:15 +00:00
.TE
1991-10-16 13:33:50 +00:00
.LP
Use the Makefile to get readable copies.
1984-06-29 11:21:50 +00:00
.LP
Good luck.