I get a Can't load package error although the BPL is there - delphi

This issue is driving me crazy. I'm trying to compile and install The QR Designer from QuickReports 6. I have an issue just with the one package. When I right the package in the IDE > Install the IDE gives me:
Can't load package C:\xe10_3\QRDesign\Win32\Debug\dclqrd_DXE10_3.bpl.
The specified module could not be found.
But the exact file is there.
I've also tried installing it via the menu under Components > Install Packages and then choosing the BPL from there, with the same issue.
I've tried to use Process Monitor as on this post here to find the issue:
Delphi Can't load package the specified module cannot be found
I couldn't fix the issue, but what I did pick up from Process Monitor was that some process was looking for the package here:
Computer\HKEY_CURRENT_USER\Software\Embarcadero\BDS\21.0\Package Cache\dclqrd_DXE10_3.bpl
That key didn't exists. I tried manually creating the key, but that didn't do a thing.
Any ideas?
UPDATE
Here is the list of packages:
As you can see, dclqrd_DXE10_3 is dependant on two others. Which I already built and installed. I removed its references and re-added them again now, to make sure the references are sound. I guess its like Remy said, the Specified module not found is probably not referring to dclqrd_DXE10_3 although I don't know what other module it could be referring to.

To install a package successfully in IDE, follow the steps:
Open the dpk/dproj/groupproj file in IDE
Build the package(s) for Windows 32-bit platform.
IDE itself is a 32-bit applicaton, so it should match.
Normally, it will build all dependent/required packages
Check if all chain of BPL & DCP files are generated in package Output directory.
It defaults to $(BDSCOMMONDIR)\Bpl & Dcp folders, but can be changed individually for each Package in Settings.
PBL packages are like DLL files. In order to load them, it requires all dependent BPLs.
If you have custom package output paths:
Check if your DCP output path is included in Tools\Options\Language\Delphi\Library Library Path for Windows 32-bit platform
Check if no duplicates of outdated compiled packages in default $(BDSCOMMONDIR)\Bpl & Dcp directories
Add the paths to library source pas files in Tools\Options\Language\Delphi\Library Browsing path or Library path
In some specific cases, if the package requires some extra dll-s like DB Client libraries, check if these dlls are 32-bit and are loadable, like included in %path% environement variable.
Note, some libraries offers package installer tools, that automagically do all mentioned things for you.
Also, there are universal package installer tools for quick working environement setup in one click.

I don't know why this fixed my issue, but it did.
The output directories for the bpl and dcp was set to be $(Platform)\$(Config)
The project files for the different packages exists in the same folder so the above config was supposed to be the debug folder or the release folder. Why only this package was thrown off I still don't know, but since changing the above packages to have a fixed path suddenly I could now install dclqrd_DXE10_3.bpl.
Thank you all for helping.

Related

Delphi Jedi components manual installation

I'm using Delphi CE 10.4, and it has the DCC32.exe disabled line compilation.
I'm trying to manually install Jedi components, in the readme of JCL it says that it's needed to open and edit included file to customize options, in my case, source\include\jcld27win32.inc.
I'm starting to learn Delphi, and I didn't understand whats is it is necessary to do in this file, and didn't find videos showing a manual installation.
Someone who already installed this way could help me?
Manual Installation Although it is not recommended, a manual
installation is possible. You will have to manually configure options
for the library. That is done by modifying an included file. For each
tool you want to install the JCL in, repeat the following steps:
Open and edit included file to customize options: ... For Delphi 10.4 and C++Builder 10.4 Win32: source\include\jcld27win32.inc ...
In the IDE, open and compile package Jcl.dpk (or Jcl.bpk for C++Builder) located in a subdirectory of the "packages" directory
matching your version of the IDE. This package doesn't have to be
installed since it doesn't provide any components.
If you want to install experts, open package JclBaseExpert.dpk and compile it, then you can install all the experts you want (packages
are located in the same directory).

How can I Generate Setup Installation in Rad Studio?

What files must I add while building the installation file in Rad Studio using Advanced installer? When I chose the project file, I launched the file created with Advanced Installer, but it says that:
file_name.bpl missing
What should I do ?
If you don't build with runtime packages (Project->Options->Packages->Runtime packages->Link with runtime packages is False), then you only have to distribute your application executable (.exe).
If you build with runtime packages (Project->Options->Packages->Runtime packages->Link with runtime packages is True), you have to include those packages when you distribute your application executable (.exe). This requires at a minimum that you include the VCL and RTL packages (vclXXX.bpl and rtlXXX.bpl, where XXX depends on the specific version of RAD Studio that you're using).
Depending on what your application does, you may also have to include other runtime packages in your installer. You can find the list of packages that your application needs by looking at the runtime package list in Project->Options->Packages->Runtime Packages->Runtime packages (click the ... button to open the dialog).
For more information, see the RAD Studio documentation topic Deciding Which Runtime Packages to Use.
You should be able to find a list of names of the packages used from the menu at Project/Information for YourApplication This list should be available once the project has successfully compiled and linked.
Even more useful may be the Project/Deployment menu item. This item is designed to actually deploy your application and its files to a remote machine using paserver, and perhaps could be used to do that in the process of making your installation file.
However, the big advantage of Project/Deployment is that it lists not only the name of each file, but also the Directory where that file can be found.
It looks to me like there may be files under Project/Deployment, such as localization language files, that might not always be needed, so I would cross-check Project/Deployment (which shows the Directory) with the Project/Information for YourApplication list. However, Project/Deployment is where I would look to find the directory where the missing file_name.bpl that Advanced Installer needs can be found.

Procedure Entry Point invalid in JVCL (jclsysinfo)

I've installed latest Jedi VCL for Delphi (JVCL 3.49) using install.bat (from jcl and jvcl folders respectively), without errors. The problem is when I run Delphi 2010, I get a lot of errors about invalid entry point in jvcl bpls.
entry point invalid #jclsysinfo#jclcheckwinversion$qqrri in JvCore140.pbl
I get this error in all Jv*.bpl files, and always with the same entry point.
I've checked I don't have old jcl/jvcl files or jv*.bpl/jc*.bpl files. I don't know how to fix this problem. Any sugestion?
When compiling packages in Delphi (as the JCL and JVCL do) that require other packages at compiletime the compiler uses the dcp files for the required packages and not the bpl files of those packages.
For example the JvCore.dpk has Jcl and JclVcl in its required clause among some RTL packages. That means when compiling it will take Jcl.dcp and JclVcl.dcp to get the information where the procedures/classes it needs are located in the bpl.
These dcp files are most of the time (unless specified differently - see next paragraph) located in the DCP folder which is right next to the BPL folder.
If the dcp it uses is not compatible to the bpl it finds when loading you will get those errors. Make sure you don't have any old bpl and dcp files anywhere that the compiler may find. In the JCL setup you can specify where it puts those while the JVCL setup puts them into the same directory as the dcu files.
Additionally if you have different Delphi versions installed it can get worse because usually the dcp files don't have a suffix. If the directory it puts those happens to be in the PATH variable wrong versions might be found. However the DCP directory is not put into PATH by the Delphi installation but only the BPL directory.
(While I've been writing this, Stefan Glienke has posted an answer which has a lot more useful info in it, but I'll post it anyway because it's easy to test if you're only interested in one Delphi version)
I'm not sure the following will work for you because I don't have D2010
installed to test it against. You could check it out quite quickly by
trying it using only one .Dpk file in step 4.
Note that I always set the Output paths for BPL,
DCP and DCU files to a Lib2 folder under the Delphi version's install folder.
That way I know where they all are so it's easier to tidy up if something goes
wrong.
I uninstalled the JCL and JVCL and deleted all the JV*.BPL, .DCP and
.DCU files
I ran the JCL install .bat, and ignored all the prompts to add folders to
the system PATH, because my Lib2 folder is already on the PATH.
In the folder for my Delphi version below JVCL\Packages, I edited all the
.Dpk files to use my Lib2 folder for the BPL, DCP and DCU output files. this is
a bit tedious but only needs to be done once and can be made easier by doing it
using a keyboard macro.
Then, using the IDE package tool, compiled and installed all the JVCL .Dpk
files that have "Design" in their names and that I want to install.
They all installed without ther error message you are getting.

How to install Spring4D

I have downloaded the latest build of the Delphi Spring Framework. As directed in the readme file, I ran Build.exe and selected my two versions of Delphi (XE5 and Seattle). In neither Delphi installation can I see that a package has been installed nor my library search path modified. What am I missing or is there something else I must do to install and use it?
Thanks in advance for your help.
There are no packages to install in Spring4D because only designtime packages are actually installed (as in they show up in the IDE). Everything the Build.exe does it compile the runtime packages for the selected Delphi versions and add the dcu folder to your library path (if you have checked that in the options).
The registry keys where it looks for the library path is specified in the Build.Settings.Compilers.ini (which are default values that every Delphi installation has).

Installing Indy - which folders should be added to Delphi's Library list?

The directions on how to install Indy10 are (at least to me) a little vague in one place, and I'm hoping someone here can clarify a little.
The installation directions (From http://www.indyproject.org/sockets/Docs/Indy10Installation.en.aspx) state:
After Compiling
In your Indy directory you should now see some compiled .dcu files.
Open the IDE and go to the "Tools > Environment options > Select
Library" dialog tab. Now add the path to your files into the filepath
collection. Click Ok.
My Indy10 folder does not have any .dcu files in the root folder. It does have a bunch of DCU files in C:\code\Indy10\Output\DCU\Win32\Debug ... does this mean I should be adding C:\code\Indy10\Output\DCU\Win32\Debug to my library path? (And for that matter, should I be building Indy in Debug or Release mode, or does it matter?) Are there any other subfolders I need to add to the library path? Indy 10 has a much more complex folder structure than Indy 9 and I'm not convinced I've configured things "correctly".
Nearly every component package I install I touch the project options for the runtime package(s) to get a clean install.
Project Options
General Configuration
Output directory {componentpath}\lib\XE4\$(platform)\$(config)
Release Configuration
Output directory {componentpath}\lib\XE4\$(platform)
After that I compile the whole package for all target platforms in release and debug mode. Using a Build-Group is very useful to do that.
Now it is time to add the library paths (for each platform)
Library path {componentpath}\lib\XE4\$(platform)
Debug DCU path {componentpath}\lib\XE4\$(platform)\debug
Browse path all directories containing the source
In your own projects you can control which .dcu versions are used by setting the Use Debug-DCU option.

Resources