User Tools

Site Tools


clarion_project_system_version_7.htm
Navigation:  Advanced Topics > Clarion Project System >====== Clarion Project System ====== Previous pageReturn to chapter overviewNext page

The Clarion Project System Version 7 is a complete rewrite of the TopSpeed Project System used in previous versions of Clarion. It supports almost all commands that the TopSpeed Project System supported, plus adds new features to make it easier to build large systems.

Automatically Included Projects

When a project file is included the project system will first look for a file called solglobals.pi. If this exists it is included at the top of the project. This file is intended to be used to contain solution wide project settings. For example. The file may contain the line:

#pragma define (_MyProductVersion_⇒10)

After solglobals.pi has been included, the project system will then add cwglobals.pi. This file is intended to be used to contain company wide project settings. For example:

#pragma define(_Company_⇒Our Company Name)

Project Commands

#section

#section <;name>

– section commands

#else <;name>

– section commands

#else <;name>

– section commands

#endsection

A section starts a list of commands that are activated on a #activate command. You can can have one or mutually exclusive sections by specifying a #else command. If a #activate command is encountered and a mutually exclusive section had previous been activated via a #activate command, then the previous command is deactivated without the need to call #deactivate.

Only #set and #pragma commands are valid within a section.

Example:

– Contents of cwglobal.pi

#section release

#set outdir=release

#else debug

#pragma debug(line_num⇒on)

#pragma check(stack⇒on)

#pragma check(index⇒on)

#set outdir=debug

#endsection

#section Profile

#set profiling = on

#endsection

#set profiling = off

#section Tracing

#set tracing = on

#pragma define(_TRACING_⇒on)

#endsection

#set tracing = off

#activate release – same as doing #set outdir=release

#activate Profile – same as doing #set profile = on

#activate debug – #deactivate release done automatically

#activate

#activate <;sectionname>

Activates a set of commands previously defined by the #section command.

If the section being activated is part of a list of mutually exclusive sections, and one of these sections is currently active, then an implicit #deactivate othersection is called.

When an #activate command is encountered then all #set and #pragma statements contained within that section are executed.

#deactivate

#deactivate <;sectionname>

Reverts all commands that where activated by a previous call to #activate sectionname.

This command will set the pragmas and project sets back to the value they where at before the matching #activate call was made.

#active (Boolean Operator)

#active SectionName

Returns TRUE (1) if the SectionName is currently active.

Obsolete Commands:

The following project commands are no longer supported:

Command Remarks
#exemod This command was for 16 bit only projects
#getkey There is no way to pause a build
#ignore This optimization is no longer supported
#prompt Use #message
#rundll Integrated compilers are known to the project system now
#scan This optimization is no longer required
clarion_project_system_version_7.htm.txt · Last modified: 2021/04/15 15:57 by 127.0.0.1