		VNPForth Forth compiler and runtime, version 1.1
		------------------------------------------------


Introduction
------------
This program arose from a need to learn the finer details of the Intel
IA32 instruction set, coupled with a desire to implement a 'real'
compiler using Flex and Bison.

VNPForth implements a subset of ANS Forth, though enough of one to
pass most of the 1993 Johns Hopkins University / Applied Physics
Laboratory tests for core ANS Forth words.

Unlike most Forth systems, VNPForth has no word dictionary; instead,
it compiles to modular object (.o) files, just like C and C++
programs, and is then linked into a suitable runtime in the same way
as C programs too.  VNPForth modules can call, and be called by, C and
C++ modules, since they use the same object file format as standard C.

The result of compiling VNPForth is a standalone executable program,
requiring no special runtime on the target system.  In the case of
statically linked programs, the binaries are orders of magnitude
smaller than their C equivalent would be, mostly due to the lack of
any libc requirement.  Such small programs might be useful items to
tuck into a recovery floppy disk, or for use on systems where there is
a real shortage of memory and storage (the so-called "wristwatch"...).

VNPForth is very non-portable.  It contains assembly language code,
written with the GNU assembler in mind, that will run only on IA32
(and perhaps on IA64) CPUs - i386, i486, Pentium...  It also makes
specific system calls directly into the kernel (bypassing libc), so
will not run on operating systems other than Linux, and more
specifically, Linux with at least a 2.2 or 2.4 kernel, without some
considerable modification.


Quick start guide
-----------------

Here is a Forth version of the ubiquitous hello-world program:

    ." Hello from VNPForth" CR 0 DROP

To compile, link, and run this program, first save it in a file
hello.ft:

    $ cat <<EOF >hello.ft
    ." Hello from VNPForth" CR 0 DROP
    EOF

Now compile and link the program to an executable 'hello'.  This
example assumes that you have installed the runtime library and
forthrt.o module in /usr/local/lib, and that the forthc compiler is on
your $PATH:

    $ forthc hello.ft
    $ ld -static -o hello hello.o -L/usr/local/lib -lforth \
            /usr/local/lib/forthrt1.o

You should now be able to run the program:

    $ ./hello
    Hello from VNPForth

Unlike the same thing written in 'C', when statically linked this
binary is still extremely small, especially if you remove debugging
information from it (by default, libforth includes debugging data):

    $ strip ./hello

Compare this with the same small program written in 'C', and compiled
into a static 'chello' binary:

    $ cat <<EOF >chello.c
    main() { printf ("Hello from C\n"); }
    EOF
    $ cc -static -o chello chello.c
    $ strip chello


Building the library and programs
---------------------------------
Please see the file INSTALLING for details on how to build VNPForth
from the distributed sources.  


License
-------
VNPForth is distributed under the GNU GPL.  Please see the COPYING
file for details.


Acknowledgements
----------------
Thanks to Dirk Zoller (duz@roxi.rz.fht-mannheim.de), whose PFE
package, version 0.9.13, I used as a reference when I couldn't follow
the ANSI standard, and from whom I borrowed most of the core.ft test
suite.  

Simon Baldwin,
simonb@caldera.com
