3

I'm using TJvPluginManager to build simple application with ability to load .bpl plugins. I have common interfaces declaration in "uIntfs.pas" file, which is kind of SDK ;)

The problem is, that if I try to load more than one plugin, the app throws an error:

Cannot load package 'test2'. It contains unit 'uIntfs,' which is also contained in package 'test'

It's quite obvious that BOTH bpls contain that file, however I need to make it work ...

Please help!

Wouter van Nifterick
  • 23,603
  • 7
  • 78
  • 122

1 Answers1

8

Put your uIntfs.pas into another BPL, and have your plug-ins both reference that BPL.

You'll have to do that for every unit that's common to both plug-ins.

moobaa
  • 4,482
  • 1
  • 29
  • 31
  • I was afraid of that ... it will be quite inconvinient to do so, as I'm changing the SDK a lot ... :/ is there a way for auto-rebuilding the package? –  Jul 27 '09 at 11:03
  • What I used to do is keep all my packages in a separate project group & do a Build All. With the size of my plug-ins, and the speed of the Delphi compiler, this wasn't too much of an impediment for me, but YMMV :} – moobaa Jul 27 '09 at 21:09