Re: Embedding one .deb inside another
On Thu, Nov 26, 2009 at 12:59:54PM -0800, Joe Smith wrote:
> I'm having an issue with distributing a .deb package that has a dependency
> on another .deb package that might not be in an available repository (or the
> target may not have a network connection at the time of installation). What
> I'd like to do, ideally, is embed the dependency inside the parent package.
> That way, in the preinst script, it could just install it's dependency.
> However, the problem is that when installing the parent package, it locks
> the dpkg system so when it, in the preinst step, goes to run dpkg -i on the
> embedded .deb file, it can't get a lock and fails.
> Is this something that's fundamentally impossible or is there some way to
> achieve what I need?
I'm assuming this is for a private package; this set of circumstances would
never occur in the Debian archives.
>From that perspective, you can do whatever you want. It's not hard to setup
a small apt repo (password/IP access restricted, if necessary), or (worst
case) have a small shell script glued to a sharchive with both debs that can
unshar and dpkg -i both of them.
> Also, I want this all to be able to be done from a single dpkg -i <parent
> package>.deb and not from a script where I could otherwise do dpkg -i
> <parent>.deb <child>.deb. The reasons for this are limitations on the
> current method of distribution.
Can't be done; the lock on the package metadata files will be taken.