I have a project that uses a BPL developed by me on Delphi Rio or Delphi Tokyo.
With the FLAG "Link With Runtime Link Package" set to TRUE, the project compiles, but with the Flag set to FALSE it does not compile because it does not find the BPL units.
When compiling with the Flag set to False, I want the executable to include the BPL's, otherwise I must distribute my own and Delphi's BPL's with the executable.
Thank you
In order for your project to compile without using the BPL at run time, you must include the path where you have the drives in the library path , so that the compiler is able to find and link them into your executable.
To the compiler you can give:
To do this, you can do it at a global level (it is the most common if the BPL contains its own components).
In the menu, Tools > Options > Language > Delphi Options > Library > Library path includes the path of the folder where you have the mentioned files.
You can also do it within the project options, if you don't want these units to be available for other projects.
With the FLAG set
"Link With Runtime Link Package"
to TRUE, you must have the BPL's/DCP's in order to compile.With the FLAG set
"Link With Runtime Link Package"
to FALSE, you must have the PAS's/DCU's of the correct versions to compile.You cannot mix both options.
A BPL file is the equivalent of a DLL or an executable. What you intend to do is as if from an executable you wanted to include the content of another executable. You can't, because it's already been compiled and linked.
If you want to build an executable with
"Link With Runtime Link Package"
FALSE, you need to have the sources or DCU's so the compiler can resolve references and compile and link the project.