Tuesday, 24 March 2009

How-To: Compile and Install GIMP 2.6.6 in Debian Lenny

GIMP (GNU Image Manipulation Program) is the most popular and powerful image editor on the Linux platform. It benefits from detailed official documentation, as well as a huge number of community-made tutorials and dedicated websites.

The latest stable series, 2.6.x, include several UI improvements, new filters, and the introduction of the GEGL (Generic Graphics Library) framework.

Although the version which comes with Debian Lenny (2.4.7) is stable enough and full-featured, if you want the latest release you can easily compile your own version by following the steps below.

1. Install build-essential and the development libraries

apt-get install build-essential

Next, make sure the sources repositories are enabled (there should be a line which starts with deb-src in /etc/apt/sources.list), for example:

deb-src ftp://ftp.ro.debian.org/debian/ lenny main contrib non-free

Update the package lists:

apt-get update

Install the development libraries:

apt-get build-dep gimp

Install additional dependencies:

apt-get install libgegl-0.0-dev

3. Download the source code
Download the GIMP 2.6.6 source tarball from here, then uncompress it:

tar -xjf gimp-2.6.6.tar.bz2

4. Compile and install GIMP 2.6.6
To compile and install GIMP, just issue the usual commands inside the gimp-2.6.6 directory:

./configure
make
make install

The last one as root. You can also install as normal user using the --prefix parameter, e.g.:

./configure --prefix=/home/USER/usr

13 comments:

Martin said...

Why not just "apt-get install -t unstable gimp"? Or at least use the source package from unstable and create a proper package, that can be installed/uninstalled/upgraded?

Anonymous said...

b\c it installs lot of parts of sid.
rather running "checkinstall" instead of make install could be a good idea, b\c it installs and build a deb package which can be cleanly remove upraged etc.

anyway good guide.
tezla

Jozika said...

I should add only one more thing and that is:

./configure --prefix=/opt/gimp && make && sudo make install

because if you will going to install Gimp in /usr/local it will not run if you have a 2.4.7 version installed in the same time. You will get the Libgimp version mismatch! and it will not start.

Thanks for this How-To!

Best,
Jozsef

Anonymous said...

before the process, i have this message:

Libgimp version mismatch!

The GIMP binary cannot run with a libgimp version
other than its own. This is GIMP 2.6.6, but the
libgimp version is 2.4.7.

Maybe you have GIMP versions in both /usr and /usr/local ?

What can i do? Thanks!

stev said...

When i use the command: "apt-get build-dep gimp", i get the error message: "E: Build-Depends-afhængigheden for gimp kan ikke opfyldes, da ingen af de tilgængelige udgaver af pakken debhelper kan tilfredsstille versions-kravene" Wich translates to "E: Build-Depends-dependence for gimp could not be forfilled, as none of the avaiable versions of debhelper kan satisfy version-demands". Im usen these two; ftp://ftp.dk.debian.org/debian/ lenny main contrib non-free and http://ftp.dk.debian.org/debian/ lenny main non-free contrib; for my deb-src. What my problem?

Anonymous said...

Make sure that the path you place the gimp source in does not contain directories with white spaces in their name. I did, and 'make' aborted with an error.

Andrew said...

For those who want to create a Debian package from source, here's the ultimate howto:

http://forums.debian.net/viewtopic.php?f=16&t=38976

Anonymous said...

Hi, thanks for all but i have a problem ;)

gimp-2.6: error while loading shared libraries: libgimpwidgets-2.0.so.0: cannot open shared object file: No such file or directory

Anonymous said...

hi, thx for all but i have a problem ;)

when i launch gimp-2.6 the terminal:

gimp-2.6: error while loading shared libraries: libgimpwidgets-2.0.so.0: cannot open shared object file: No such file or directory

Anonymous said...

im getting the same problem stev has... build-deps no longer works appearently

Using aptitude it asks to downgrade multiple packages in order to meet dependency requirements.

apt-get only gives the error 'stev' was mentioning. I hesitate to downgrade so many packages but it looks like the same versions only with different branding.

Anonymous said...

now that i downgraded everything, compiled successfully i get the same problem as the other anonymous person "gimp-2.6: error while loading shared libraries: libgimpwidgets-2.0.so.0: cannot open shared object file: No such file or directory"

seems like it's impossible to get gimp working on lenny nowadays

Anonymous said...

I have had to reinstall Lenny AMD64.

I had compiled and installed Gimp 2.6.7 but this time I ran into the problem of needing libgimpwidgets-2.0.so.0

after searching I installed the following lib from debian package.

http://ftp-mirror.internap.com/pub/debian/pool/main/g/gimp/libgimp2.0_2.4.7-1_amd64.deb


Problem solved. I can now run Gimp 2.6.7

Anonymous said...

In some distros (debian), apt does not remove libgimp2.0.

After you do all the previous steps just remove the old library:

apt-get remove libgimp*