I have a project (C:\Test\Test.dpr) that uses a file (External.pas) belonging to library (MyLib.DPK). All files in the library are accessible via 'Search' path but I also included External.pas directly in my DPR file:
program Test;
uses
External in '..\Packages\MyLib\External.pas', <------ the 'external' file
FormMain in 'FormMain.pas' {frmMain};
For this project I set the 'Output directory' and 'Output DCU dir' to ".\$(Platform)_$(Config)".
When I compile, the exe file all DCUs of this project are written in the correct output folder: c:\Test\Win64_Debug\
However, the External.dcu is generated in ..\Packages\MyLib\External.dcu
instead of c:\Test\Win64_Debug\
Why is that?
Let me ask the question in a different way: if to a DPR project I append a PAS file that is in a different folder, shouldn't all DCU files (including the external file) be generated in the same folder as the EXE file?