Use Conditionals from Project Settins File (BDS 2006 and 2007)

  I was upgranding my scripts to allow builds in BDS 2006 and 2007 (we hope use them soon) and as I could see the "Use Conditionals from Project Settins File" in the "Compile Delphi Win32 Project" action isn't working, it didn't get the project conditionals witch are declared in the dof, cfg, bdsproj and dproj files. With Delphi 5 and 7 it works fine.

 

  Best regards,

  Daniel Mirapalheta

Any news about this? We just got an issue with dbExpress and the new DB2 version (9) witch has been solved using the dbExpress version bundled with BDS 2006. Unfortunally we have two project to build our data access layer, both to the same sources but with conditionals DBX and BDE. So I’m under pressured to allow building it with BDS 2006.

Best regards,
DM

Hi Daniel

I have just been looking at this issue and have not been able to reproduce the problem. To test this, I created a test app in BDS2006, with a simple form with a button in it. In the button click event I put this code :

{$IFDEF DODAH}
ShowMessage(‘Dodah’);
{$ELSE}
ShowMessage(‘NOT’);
{$ENDIF}

and then set the conditionals for the project to DODAH.

In the finalbuilder delphi action, I set the conditionals to blank, compiled and tested… button click shows NOT, as expected. Then I checked the “use conditionals from project settings file” option, recompiled and tested, button click shows DODAH, as expected. I also tested in D2007, the only difference is you have to remember to set the conditionals in the Config that you want to build.

If you have a reproducible case that shows the problem you are seeing please email it to support so I can what is going on.

Well, I just tried it and could make it work (support e-mail with a reproducible case sent).

But it’s not so urgent any more (I edited my project so it reads the conditionals from the dof, bdsproj or dproj). I had to read the dof also because I didn’t found how to disable read setting from dof in the action using script, so the compile action won’t read anymore the conditionals from the project config (until I get it solved).

Best regards,
DM