Component Pascal compiler Wiki
Status: Alpha
Brought to you by:
romiras
This document is a draft version.
Hello.cp
MODULE Hello;
IMPORT Out;
BEGIN
Out.String ("Hello world!"); Out.Ln
END Hello.
[Project]
ProjectName=<project name>
[Compiler]
Module=<relative path to module>
CompilerOptions=<compiler options>
[Linker]
LinkedModules=<list of modules, like: Kernel$+ Math Strings Console WinConsole HostInit Init Out Hello#>
OutputMode=<name of output file>
CompilerOptions is a combination of options in one string. Valid characters are '-', '!', '+', '$', '?' and '@'.
Default compiler options are {checks, assert, obj, ref, allref, srcpos, signatures}.
All paths are relative to root directory of all subsystems.
In order to build program for native system you need create a project document for module "Hello".
Hello.prj
[Project]
ProjectName=hello
[Compiler]
Module=Examples/Mod/Hello.cp
CompilerOptions=
[Linker]
LinkedModules=Kernel$+ Math Strings Console WinConsole HostInit Init Out Hello#
OutputMode=Exe
OutputFile=hello.exe