The compile statement lets you compile programs in Progress ABL:
Basic usage:
COMPILE hello-world.p SAVE.
With a variable:
DEFINE VARIABLE prog AS CHARACTER   NO-UNDO.
prog = "hello.p".
COMPILE VALUE(prog) SAVE.
There are several options to the COMPILE-statement:
SAVE states that the .r-code should be saved for future use.
COMPILE hello-world.p SAVE.
SAVE INTO dir OR SAVE INTO VALUE(dir-variable) saves the r-code in the specified directory:
COMPILE hello-world.p SAVE INTO /usr/sources.
LISTING file. Creates a listing file containing debug information regarding blocks, includes etc.
COMPILE program.p SAVE LISTING c:\temp\listing.txt.
Listing has a couple of options for appending files, page-size and page-width:
APPEND PAGE-SIZE num PAGE-WIDTH num 
XREF xreffile will save a compiler xref file containing information about string and index usage etc. You can also APPEND this one.
COMPILE checkFile.p SAVE XREF c:\directory\xref-file.txt.
XREF-XML xreffile-or-dir will do the same thing as XREF but save the file in an xml-format instead. If you use a directory the xref-file will be named programname.xref.xml.
COMPILE file.p SAVE XREF c:\temp\.
NO-ERROR will supress any errors from stopping your program.
COMPILE program SAVE NO-ERROR.
DEBUG-LIST file generates a debug file with line numbers.
COMPILE checkFile.p SAVE DEBUG-LIST c:\temp\debug.txt.
PREPROCESS file will first translate all preprocessors and then create a new .p-file with the code prior to compiling.
 COMPILE checkFile.p SAVE PREPROCESS c:\temp\PREPROC.txt.
XCODE key will compile an encrypted source code with key as key. You cannot use XCODE with the XREF, XREF-XML, STRING-XREF, or LISTING options together.
COMPILE program.p SAVE XCODE myKey.
You can combine several options:
COMPILE prog.p SAVE INTO /usr/r-code XREF /usr/xrefs/xref.txt APPEND LISTING /usr/listings.txt APPEND NO-ERROR.