VFX Forth is a fast modern Forth that compiles to native code. It is designed for large projects as well as small. There are versions for Windows (64 and 32 bit), macOS (64 and 32 bit), x86/x64 Linux (64 and 32 bit), and ARM Linux (including Raspberry Pi). An ARM64 version is in development for MacOS and Linux.
"VFX has been the most solid and cleanly designed Forth I've used in years (probably ever actually)."
VFX Forth is supplied under the MPE Community licence. Non-commercial use is free of charge. Commercial use requires a subscription. Different subscription levels have different technical support entitlements. For details, go to
https://vfxforth.com/
Install from the tarball. The readme text file tells you what to do.
The main installed directory (folder) structure looks like this:
/usr/bin - issue binaries, copied by install script
<vfx>
Doc
AnsForth.Htm - ANS Forth HTML documentation
VfxLin.htm - VFX Forth HTML documentation
Bin - development binaries (not all versions)
Examples - Examples to look at and use
- has subdirectories
Lib - library of tools maintained by MPE
CIAO - C Inspired Active Objects OOP package
FSL - A port of the Forth Scientific Library
GENIO - Examples of Generic I/O drivers
OOP - A Neon-style OOP package
Lin32 - Linux 32 bit specific code
Lin64 - Linux 64 bit specific code
x86 - x86 specific code
x64 - x64 specific code
ARM - ARM 32 bit specific code
ARM64 - ARM 64 bit specific code
Sources - source code if applicable
- has subdirectories
Kernel - source code if applicable
- has subdirectories
VFXBase - source code if applicable
- has subdirectories
TOOLS - useful third party O/S specific tools
- not present in all versions
XTRA - Additional third party O/S specific tools
- not present in all versions
Binary file names are of the form
VfxForth<t>_<cpu>_<os>.<fe>
e.g.
VfxForthK_x86_win.exe
Where:
<t> = null for main binary
= K for kernel
= KH for high kernel (for shared library builds)
= B for base version (Windows only)
= BH for high base version (Windows, for shared library builds)
<cpu> = x86 for 32 bit AMD/Intel i32
= x64 for 64 bit AMD/Intel
= arm for 32 bit ARM CPUs
= arm64 for 64 bit ARM/Cortex CPUs
<os> = win for Windows
= mac for macOS
= lin for Linux
<fe> = exe for Windows PE and PE+
= elf for Unices/Linuces
= mo for Mach-O files
The installer scripts should have created a short cut for you, either vfxforth or VfxForth, depending on the operating system.
If you do not know Forth, the downloads contain a PDF version of "Programming Forth" by Stephen Pelc. You can also obtain the same PDF file from the MPE website.
http://www.mpeforth.com/books.htm
Books on Forth are available from MPE and others. For more details see:
http://www.mpeforth.com/books.htm
Do not be afraid to play. Forth is an interactive system designed to help you explore its own programming environment. There is plenty of source code in the Examples and Lib directories, so look at it, edit it, and see what happens!
VFX Forth for Linux is not supplied with an editor. If you want to set one, use:
editor-is <editor>
e.g.
editor-is nano
editor-is emacs
editor-is /bin/vi
SetLocate
tells VFX Forth how your editor can be called
to go a particular file and line. Use in the form:
SetLocate <rest of line>
where the text after SetLocate
is used to define
how parameters are passed to the editor, e.g. for Emacs,
use:
SetLocate +%l% "%f%"
The line above is used by many Linux "standard" editors, but not all.
EMACS +%l% "%f%"
--no-wait +%l% "%f%"
Kate --use --line %l% "%f%"
UltraEdit -- "%f%" --lc%l%:1
Nano +%l% "%f%"
Geany +%l% "%f%"
Thanks to Charles Curley for the additional EMACs information. See http://www.charlescurley.com. He also notes that you should add the following to your .emacs file:
(if (or (string-equal system-type "gnu/linux")
(string-equal system-type "cygwin"))
(server-start)
(message "emacsserver started."))
It is essential to place the quote marks around the %f% macro if your source paths include spaces.
For LOCATE
and other source code tools to work, VFX Forth
must know where its source code is. The root of the source code
directory is saved in the VFXPATH
text macro, which is
expanded when needed. To see what the current setting is, use:
ShowMacros
To see how the macro is used, look at the source file list:
.Sources
To set the macro, use something like
c" ~/VfxForth" setMacro VfxPath
For more information on text macros, see the chapter on "Text macro substitution".
For words for which you do not have the source, but are documented
in the manual, you can use HELP <name>
, e.g.
help help
This needs configuration according to which PDF viewer and version you are using. The default incantations are for xpdf.
s" xpdf %h%.pdf %p% &" HelpCmd$ place
s" %LOAD_PATH%/../doc/VfxLin" HelpBase$ place
#17 HelpPage0 !
The first line tells the system how to run a PDF viewer so that it displays the page %p%. The second line defines the PDF file base name, which is used to find the PDF file and its associated index file. The third line defines the page offset from the start of the PDF file to page number 1, i.e. to step over the table of contents and so on.
The configuration information is preserved between sessions in a configuration file, by default ~/.VfxForth.ini.
Changes between versions are documented in reverse chronological order in the file <VFX>/Doc/Release.VFX.txt for 32 bit systems and <VFX>/Doc/Release.VFX64.txt. The files contain the changes for all versions.
The following people have gone out of their way in the production of VFX Forth for Linux.