Search code examples
delphidelphi-units

"Duplicate" units in Delphi by name, referenced by components, problem with compile


We are using several component packages by different vendors, and two of them both have a "regexp.pas" unit available inside their directory structure.

Problem now is that regardless of the order we compile them in, one of them complains about the unit being compiled with the wrong version of various other units.

Is there any way to handle this correctly?


Solution

    1. You must make sure that you have only one version of that unit
    2. Delete all dcu's (of both vendors) to force re-compilation of all the source.
    3. Uninstall the 2 vendor's packages completely (Ensure that every trace of each is removed everywhere)
    4. Recompile & Install one at a time.