Pietro,

I think your solution is somewhat like mine. I use two project files in
order to place DCUs and EXEs in different directories. This way, if I forget
to build and compile instead, there is no chance of mixing debug and
production compiled units or executables. I have an $IFDEF like yours in the
beginning of every file, but only use $D and $. I will check the other ones.

Eduardo

On Wed, Feb 11, 2009 at 8:02 AM, mikcaau <mikc...@yahoo.com.au> wrote:

>   --- In advanced_delphi@yahoogroups.com<advanced_delphi%40yahoogroups.com>,
> Eduardo C <ecos...@...> wrote:
> >
> > Hi.
> >
> > My solution was to create two project files with basically the same
> files
> > but each writing DCUs and EXEs to different directories and with
> different
> > compiler directives. This way there is no risk of mingling debug and
> final
> > units and the only price to pay is to remember to add new files to both
> > projects and use a little more of disk space. Though I bought Delphi
> 2007
> > some time ago, I'm just starting to use it now but plan to do
> something like
> > that.
> >
> > Eduardo
> >
>
> My really simple solution is to use this include file
>
> here is a sample
> {$Define IsBuild}
>
> {$IfDef IsBuild}
> {$O+} {$R-} {$I-} {$D-} {$L-} {$C-}
> {$Else}
> {$O-} {$R+} {$I+} {$D+} {$L+} {$C+}
> {$EndIf}
>
> If I doing a delivery build then {$Define IsBuild}
> else put all the debugging stuff in
>
> Then a bit further down I have this
> {$IfDef IsBuild}
> {$UnDef CheckEncounterPlaceId}
> {$UnDef AllowEmergencyShutDown }
> {$Else}
> //{$Define CheckEncounterPlaceId}
> {$EndIf}
>
> All nice and simple and in one place. I also include or exclude
> features and objects at my centralised control
>
> Mick
>
>  
>

Reply via email to