6

Is it possible to create a stand alone deb packages by merging dependancies without manual repacking.??

I've looked at this question but it doesn't really answer what I'm trying to achieve above.

if possible how to do it?

update 1

No tools available yet(?) So what about creating new deb package containing all packages which will copy dependencies to the cache and executing main package. Is it possible?

update 2

Above method appears to be impossible because dpkg cant handle more than one operation at a time. Some scripts may can do it

update 3

this tool is very helpful but it currently wont support oneric and above still waiting for more generic tool

Thanks in advance

2
  • Which package are you trying to create?
    – jokerdino
    Feb 25, 2012 at 17:44
  • i want to get standalone deb of wine, vlc etc :)
    – Tachyons
    Feb 26, 2012 at 7:35

7 Answers 7

5
+50

Use super deb creator. You can make stand alone packages for upto Ubuntu 11.04. For more details check the official website. http://hacktolive.org/wiki/SuperDeb_Creator

4
  • I hope yhey will include oneric too
    – Tachyons
    Feb 28, 2012 at 15:07
  • 1
    That is epic...The guys that built that thing deserve a hug. Mar 1, 2012 at 2:18
  • That is very cool. I'd be surprised if it can't create super debs for later releases too, its possible the author just hasn't updated it since the 11.04 release cycle.
    – SpamapS
    Mar 1, 2012 at 19:22
  • author may be sleeping
    – Tachyons
    Mar 3, 2012 at 12:52
4

No. If you want a single package without dependencies, you will need to repackage it yourself.

To understand how packages work you can read the debian packaging guide.

2
  • 2
    Can you please explain why it is imposiible:) and include how to manually do it links to tutorial is enough:)
    – Tachyons
    Feb 25, 2012 at 12:22
  • It's not possible because dpkg does not support a package format that contains multiple packages. The best you can do is make your own package that has its external dependencies resolved. Depending on the package, this may not be possible at all, but if all of its dependencies are simple library depends, then you can modify the build rules to link statically.
    – psusi
    Feb 25, 2012 at 20:02
3

If all of these things are already in the Ubuntu archive, then all you really want is a meta package that causes their installation, right?

You really just need to create a nearly empty package with dh_make. Tell it you want a single binary, and a native package. In an empty directory:

dh_make --native --indep --packagename --defaultless your-thing

Then edit debian/control, and in the binary package section (the second one) Add all the packages you want installed to the Depends: section, separated by commas.

Then build the package with

debuild binary

If you'd like to upload it to a PPA on Launchpad so others can easily get it:

dch --release --distribution oneiric
debuild -S

Of course, change oneiric to whatever you wish to package this for. Then in the directory above you should have

your-thing_1.0_source.changes

After you've created a PPA just do

dput ppa:yourusername/ppaname your-thin_1.0_source.changes

And then anybody who installs that package will also download and install all of the other bits depended on.

3
  • I mean a stand alone deb package like google chrome,teamviewer etc . meta package is diffrent
    – Tachyons
    Feb 28, 2012 at 0:09
  • Understood. I suppose I just think this is a bad idea. The minute one of the components is updated, your standalone package is out of date. I'd much rather see a meta package that evolves as security updates and fixes are pushed into the release.
    – SpamapS
    Feb 29, 2012 at 22:02
  • May be,but i want to install softwares as in the case of windows (by just double clicking) this is not good for those who have good internet connectivity but for an offline user it is difficult to install tools &installing via copying cache also difficult for normal users
    – Tachyons
    Feb 29, 2012 at 22:29
3

If I was going to have a hack at this, I'd do the following:

  • Download and extract all the packages
  • Keep the main package's copy of the DEBIAN folder, put the others' to one side
  • Alter the DEBIAN/control file so
    • List each package you're providing in the Provides line
    • Add Conflicts entries for the packages you're replacing
    • Remove the dependencies from the Dependencies line
  • Alter the postinst and preinst, prerm and postrm scripts so your new copy handles things for all the packages. This isn't simple because you'll need to understand what each package is doing at each step.
  • Repackage the whole thing back up again so you have all the files and the new DEBIAN files.

At the end you should be left with something you can install but it's not great. You're going to have to manually repeat those steps any time one of the original packages gets an update.

The systems that keep their original packaging systems are much better. You'd even be better just shipping separate debs around. It'll take less time and will be more robust.

0
1

Of course it's possible, but I'm not aware of any tools that will do it for you. So manual repackaging is the way to go.

1

Disclaimer: I have not tried this, this is just my sketch of a solution.

You could perhaps download all the dependencies to a directory, make it into a debian repository, make an ISO image of the repository, and then distribute the ISO.

You would then mount the ISO as a loopback device, and instruct apt to use the mounted directory as a source of packages -- just like you can use your Ubuntu installation disc as a repository.

Seems like an awful lot of work, though, but you would wind up with a single redistributable file that contains all dependencies without requiring you to repackage the deb files.

1
  • it can be done by aptoncd but i need a single deb package oonly suppose i want to install wine from single deb file is it possible?
    – Tachyons
    Feb 25, 2012 at 11:14
0

if they don't have 'good' connectivity, but still some, you can share the files /var/cache/apt/archives directory, which will be used instead of redownloading the file.

This method doesn't solve the problem of how to synchronize the repository index though.

1
  • I am familiar with this method but my question is diffrent. Sorry for my bad english :(
    – Tachyons
    Feb 21, 2012 at 13:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .