Yahoo Serious
27-Jan-2009, 12:30 PM
[Using Delphi 2007]
I use the conditional define "EUREKALOG" somewhere in my own code, to determine whether to set some EurekaLog-settings. My .dll got different results when building and testing manually (compiled in the IDE with EurekaLog 6018) and when building and testing automatically (daily build,
using command line, EurekaLog 6016).
I determined the cause of this difference. It happens when the .dproj contains the conditional define EurekaLog, but EurekaLog is NOT activated in the .dproj . It turns out this results in a different binary when building inside versus outside the IDE.
I am not quite sure how we got to this .dproj-situation (maybe due to a merge?), but I can reproduce it manually: Save and close a project in the IDE with EurekaLog activated. Edit the ..dproj manually, by setting Activate=0 (in [Exception Log] ). Make the ..dproj read only.
Now open the project in the IDE. View the conditional define (in: Tools | Options | Directoriers/Conditionals), and notice the conditional define for "EUREKALOG;EUREKALOG_VER6".
Exit the options and build the project. View the conditional define, and notice there is no conditional define for "EUREKALOG;EUREKALOG_VER6". It has been automagically removed by EurekaLog(?). However, this is not 'noticed' by the IDE. The project is not marked as changed and the IDE does not request to save them.
This way building inside the IDE will result in a compile WITHOUT the conditional define for "EUREKALOG;EUREKALOG_VER6". However, building outside the IDE will result in a compile WITH the conditional define for "EUREKALOG;EUREKALOG_VER6".
I don't want the IDE and the command-line to build differently!
(I discovered this by an Exception depending on this conditional define.
However, I could not get the Exception reproduced in a small example.
That might also be a difference between 6016 and 6018?
Anyway, the confusing behavior is obvious in any project.)
Yahoo
I use the conditional define "EUREKALOG" somewhere in my own code, to determine whether to set some EurekaLog-settings. My .dll got different results when building and testing manually (compiled in the IDE with EurekaLog 6018) and when building and testing automatically (daily build,
using command line, EurekaLog 6016).
I determined the cause of this difference. It happens when the .dproj contains the conditional define EurekaLog, but EurekaLog is NOT activated in the .dproj . It turns out this results in a different binary when building inside versus outside the IDE.
I am not quite sure how we got to this .dproj-situation (maybe due to a merge?), but I can reproduce it manually: Save and close a project in the IDE with EurekaLog activated. Edit the ..dproj manually, by setting Activate=0 (in [Exception Log] ). Make the ..dproj read only.
Now open the project in the IDE. View the conditional define (in: Tools | Options | Directoriers/Conditionals), and notice the conditional define for "EUREKALOG;EUREKALOG_VER6".
Exit the options and build the project. View the conditional define, and notice there is no conditional define for "EUREKALOG;EUREKALOG_VER6". It has been automagically removed by EurekaLog(?). However, this is not 'noticed' by the IDE. The project is not marked as changed and the IDE does not request to save them.
This way building inside the IDE will result in a compile WITHOUT the conditional define for "EUREKALOG;EUREKALOG_VER6". However, building outside the IDE will result in a compile WITH the conditional define for "EUREKALOG;EUREKALOG_VER6".
I don't want the IDE and the command-line to build differently!
(I discovered this by an Exception depending on this conditional define.
However, I could not get the Exception reproduced in a small example.
That might also be a difference between 6016 and 6018?
Anyway, the confusing behavior is obvious in any project.)
Yahoo