In Codegear RAD Studio 2007, I’m trying to do some file deletion and copying during the pre-build and post-build events that involve folders named after the current configuration. In Visual Studio, this is easily done with the $(ConfigurationName) macro.
Is there any equivalent to this in RAD Studio? If not, is there a workaround I can use?
I think what you’re looking for
$(Config). For example, in a prebuild event, you can addecho $(Config)and it will print a string like “Debug” or “Debug Build”. I’ve tested it in Rad Studio 2010, but not in 2007. I believe they use the same configuration variable, though.If that doesn’t work, open a cbproj file in an editor and look for something like this:
Whatever word appears instead of ‘Config’ there may give you a clue.