I had a RAD Server package ProjA.bpl with several endpoints and some of them use a unit called UntAccess.pas.
Now I created another server package ProjB.bpl with different endpoints than ProjA and adjusted emsserver.ini configuration file section [Server.Packages] to call both packages .
The problem appeared when EMS Server starts, it shows the following error message :
{"Thread":32068,"Error":{"Type":"Package","Filename":"C:\Users\Public\Documents\Embarcadero\Studio\21.0\Bpl\Win64\ProjDevAPI.bpl","Exception":"EPackageError","Message":"Cannot load package 'ProjB.bpl' It contains unit 'UntAccess.pas', which is also contained in package 'ProjA.bpl'"}}
How can I share same units among tow or more RAD Server .bpl packages ?
Environment : Delphi 10.4.2 , Windows 10
CodePudding user response:
Create a new package containing that common unit (and probably more in the future). Then add this package as required to ProjA and ProjB.