1

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:

image

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.

Remy Lebeau
  • 555,201
  • 31
  • 458
  • 770
Frank Pedro
  • 198
  • 2
  • 10
  • The message usually means that a required package is not found - probably the runtime package. – Uwe Raabe Jun 13 '22 at 13:58
  • 1
    It is likely that the BPL you are trying to install is *dependent* on another BPL/DLL that is not being found. The error in question doesn't always refer to the 1st BPL that you are loading directly. Windows sucks when it comes to reporting *which* module is actually missing. – Remy Lebeau Jun 13 '22 at 18:28
  • @RemyLebeau, Ok I thought the error was referring to the one I'm trying to install. I've updated the answer to show what I'm talking about. I've rebuilt and readded the two required packages again now to make sure they are sound. I don't know which other module it could be wanting/ – Frank Pedro Jun 14 '22 at 08:35
  • @UweRaabe, I've updated with a screenshot to indicate how it looks. The dependant packages are built and installed all ok. – Frank Pedro Jun 14 '22 at 08:36
  • Presumably you are compiling `dclqrd_DXE10_3.bpl` with Runtime Packages enabled (as you should be). In which case, it will depend on `QRD_DXE10_3_W64.bpl` and `QRWRunDXE10_3_W64.bpl` and `vcl260.bpl` when loaded, so make sure those files exist on the IDE'S search path. – Remy Lebeau Jun 14 '22 at 09:10
  • Are `QRD_DXE10_3_W64.bpl` and `QRWRunDXE10_3_W64.bpl` compiled for `Windows 32-bit` platform and in the same folder as `dclqrd_DXE10_3` and all three files have the same timestamp? – Marcodor Jun 14 '22 at 11:14
  • @RemyLebeau, I double checked all of that yes – Frank Pedro Jun 15 '22 at 08:57
  • @Marcodor, all of the packages was outputting to the same folder yes. I've posted an answer since I was able to install it now. – Frank Pedro Jun 15 '22 at 08:58

2 Answers2

2

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.

Marcodor
  • 4,578
  • 1
  • 20
  • 24
0

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.

Frank Pedro
  • 198
  • 2
  • 10
  • There is no sense to use `$(Platform)\$(Config)` as output path for library packages **installed** in IDE. A library contains common code for all projects. Make sense only if you build your project with runtime packages and you have some project specific runtime packages. For libary packages best to stick with default path to avoid headashes. You simply mixed different output folders and most probably had outdated compiled duplicates. – Marcodor Jun 15 '22 at 09:55
  • @Marcodor, The original output folder was putting the build files in an obscure directory that is why I changed it, but they all were outputting to the same folder. Even after I changed it to a fixed directory this didn't change the fact so there was no mixing output folders or any duplicates. – Frank Pedro Jun 20 '22 at 11:23