Why Delphi ignores config (Debug/Release) in default location of *.dcp files?

Why Delphi ignores config (Debug/Release) in default location of *.dcp files?

By default ( http://docwiki.embarcadero.com/RADStudio/Tokyo/en/Package_Files_Created_by_Compiling ) Delphi writes *.dcp files for Win32 platform to C:\Users\Public\Documents\Embarcadero\Studio\19.0\DCP . If I use default settings and build a package in Debug and Release config, then Release *.dcp overwrites Debug *.dcp.

I don't like it and never use default *.dcp location; should the default *.dcp location be considered as IDE bug?

Comments

  1. I cannot see why this should be considered a bug. The default locations are configured in the library options per platform. There is no concept for configurations (which are not limited to Release and Debug, BTW) at this level. Even more would that get really confusing as the DCP output path is also part of the global search path. How would that fit when there are DCP files not available in the current configuration.
    Actually, in a project you can select if you want Debug or Release versions of the standard units (Use Debug DCUs) independent of the current configuration. I see no point in coupling that configuration to all other packages from the standard folder.
    If one really wants to separate DCP files (and what about BPL files) per configuration it is pretty easy to accomplish that on the project level. This should cover all your needs. No need to add such complications at the global level.

    ReplyDelete
  2. I've got it now. The purpose of having PackageA.dcp is to build PackageB which requires PackageA, and IDE does not allow to specify config-dependent versions of PackageA.dcp. So you specify a single PackageA.dcp required by PackageB and use the following build process: build PackageA in Debug config, then build PackageB in Debug config; after it build PackageA in Release config, then build PackageB in Release config; the *dcp files are overwritten but they are not needed to build applications, so you can forget about them until you modify the PackageA or PackageB.

    ReplyDelete

Post a Comment