License issue with dll - Partially Solved

License issue with dll - Partially Solved

Postby TillmanZ » Wed 04 Apr 2007 01:56

Hi there,

for the first time I am trying not to package the corelab.dll with an exe file but with a class lib.
I have created a dll which is referencing the corelab.dll and I have tried not only just creating the licenses.licx file (and embedding it) but I have also tried to embedd the dll.licenses file (manually compiled - namespace not empty that's why only "dll.licenses") but whenever I am referencing my library from a new solution and try to initialize the mysql connection I get a license not valid error.
Am I missing something?

So I am feeling I am just doing something wrong here.

Thanks for your support!

Best regards,

Tillman



UPDATE: well, shame on me - I just should have read the doc more carefully. After creating a licenses.config file and placing it into the dll solution root it almost works as expected. Now I can get it to work with referencing my dll and the corelab dll independently from my test solution but as soon as I am referencing the ILMerge'd version I get a license not found error.
TillmanZ
 
Posts: 19
Joined: Sat 13 May 2006 04:11

Postby Alexey » Wed 04 Apr 2007 06:55

Where is the license resource? In dll or in exe? Should be in dll.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby TillmanZ » Wed 04 Apr 2007 09:53

Thanks for getting back to me so quickly Alexey!

The licenses.licx resource is embedded into my dll project.
After compilation I am using ILMERGE to merge this dll with the corelab.dll.
Then I am referencing this in my testproject (simple winform exe) to see if my dll works and I am always facing the license not found error.

When I don't merge the DLLs everything works fine.


Thanks for your support!

Best regards,

Tillman
TillmanZ
 
Posts: 19
Joined: Sat 13 May 2006 04:11

Postby Alexey » Thu 05 Apr 2007 10:39

We are investigating the problem with ILMERGE.
You will be notified on results as soon as possible.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby Alexey » Fri 06 Apr 2007 06:48

The matter is that the name of the assembly, where license resource was initially compiled, and the name of the assembly, where license finally appears, must be equal. So, there are two ways to overcome the problem:
  • set the name of ILMERGE output assembly equal to the name of the compiled assembly;
  • create license resource separately and embed it to the merged assembly.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43


Return to dotConnect for MySQL