This entire article is a republication of a message/explanation Przemysław Czerpak did in Feb 2010 about how to compile Harbour applications when also creating and using Harbour build dlls that are compiled in pCode mode (default method).
Przemysław Czerpak is one of the core contributors to Harbour.
I found the email at
https://www.mail-archive.com/harbour@harbour-project.org/msg26049.html
Some clarifications and concepts.
Harbour programs can be created is such manner that the C generated code relies on pCode, a series of C arrays and Symbol tables.
It is also possible to create Harbour code that do not rely on pCode.
The pCode (portable code machine ) method relies on a Virtual Machine. The generated EXEs and DLLs are smaller and only slightly slower (20% worst case scenario) than pure C code base compilation.
The Harbour pCode IS NOT like VFP fxp, C#, Python or Java bytecode . Harbour's pCode is still pure C, meaning extremely fast.
1. There are two methods to include the Virtual Machine and runtime functions (core Harbour functions), including everything in your EXE (non shared mode), or linked in shared mode with harbour*-dll supporting files.
2. There are two methods to use Harbour DLLs, statically linked to your main EXE, or like most Windows DLLs dynamically (where the acronym is from "dynamic link library").
The term DLL is not properly used here, since it could be linked statically.
Since Harbour also runs on Linux, iOd (Based indirectly from BSD) and any platform supporting C,
here is an explanation of DLLs:
DLL - An external software module used by the Linux operating system. The official name for this type of module is a "shared object" or "shared library," but due to the universal embrace of Windows, which uses DLLs, the DLL term occasionally creeps into Linux lingo.
So between the two methods in 1. and 2., we now have 4 (2*2) solutions for building EXEs that also use DLLs.