PDA

View Full Version : .deb package and automatic installation of dependencies.


moma
January 3rd, 2009, 04:02 PM
Hello,

I have created a .deb package for my gscreendump program. The building of package seems to be ok, but when I run it, it fails to install any depending packages/libraries.

How to make all dependencies to be automatically installed with the program itself?

This is what happens:
$ sudo dpkg -i gscreendump_0.1_amd64.deb

Selecting previously deselected package gscreendump.
(Reading database ... 116499 files and directories currently installed.)
Unpacking gscreendump (from gscreendump_0.1_amd64.deb) ...
dpkg: dependency problems prevent configuration of gscreendump:
gscreendump depends on libgtkimageview0 (>= 1.6.1); however:
Package libgtkimageview0 is not installed.
gscreendump depends on imagemagick; however:
Package imagemagick is not installed.
dpkg: error processing gscreendump (--install):
dependency problems - leaving unconfigured
Errors were encountered while processing:
gscreendump
------------------

I have to run "sudo apt-get install -f" afterwards to rectify bad package database. Then everything is OK and gscreendump runs well.

The Depends line in debian/control file looks like this:
Depends: ${shlibs: Depends}, imagemagick, gnome-web-photo

Here is my current (test) source
http://www.edbl.no/tmp/gscreendump_0.1.tar.gz
----------

2) Setting up a menu item or icon.
How to make .deb package to setup menuitem or icon? The package already contains a gscreendump.desktop file.

moma
January 4th, 2009, 04:37 AM
Bump Bump *1002

moma
January 4th, 2009, 09:47 AM
Hello,

It seems to me that a Debian/Ubuntu packages shall not manage dependencies automatically when they are installed from command line via
dpkg -i packagename.deb.

But Apt (or Aptitude) that is used by Synaptic and apt-get commands will and shall install all dependencies automatically. These commands have also access to repositories while Dpkg is standing on its own.

Uma pergunta/Question: Can I use "debian/preinst" script to install missing packages?
Where are you?
Wake up people! Holidays are over.

See also: http://code.google.com/p/gscreendump/

Flimm
January 7th, 2009, 06:02 PM
Hello,

It seems to me that a Debian/Ubuntu packages shall not manage dependencies automatically when they are installed from command line via
dpkg -i packagename.deb.
I'm pretty sure dpkg -i doesn't install dependencies automatically, try using gdebi or gdebi-gtk.