GIMP build: XDG_DATA_DIRS causing "Unrecognized image file format"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Elle, we traded notes about a week ago about environment variables
needed for GIMP's build, and you gave this example that worked for
you on Debian Sid:

Elle Stone writes:
> PREFIX=$HOME/code-install/gimp210/install
> export SRC_DIR=/home/elle/code-build/gimp210/build
> export PATH=$PREFIX/bin:$PATH
> export ACLOCAL_FLAGS="-I $PREFIX/share/aclocal"
> export LD_LIBRARY_PATH=$PREFIX/lib:$LD_LIBRARY_PATH
> export LD_LIBRARY_PATH=$PREFIX/lib/x86_64-linux-gnu:$LD_LIBRARY_PATH
> export PKG_CONFIG_PATH=$PREFIX/lib/pkgconfig:$PKG_CONFIG_PATH
> export PKG_CONFIG_PATH=$PREFIX/lib/x86_64-linux-gnu:$PKG_CONFIG_PATH
> export PKG_CONFIG_PATH=$PREFIX/lib/x86_64-linux-gnu/pkgconfig:$PKG_CONFIG_PATH
> export PKG_CONFIG_PATH=$PREFIX/share/pkgconfig:$PKG_CONFIG_PATH
> export XDG_DATA_DIRS="$XDG_DATA_DIRS:$PREFIX/share:/usr/local/share/:/usr/share/"

plus a similar stanza for Gentoo.

I've been struggling with my build lately because of gdk-pixbuf
problems: I kept running into problems like:

    gtk-encode-symbolic-svg -o 64 scalable/dialog-warning-symbolic.svg 64x64

    Can't load file: Unrecognized image file format

I finally came across a note you posted at the beginning of this year:
http://gimp.1065349.n5.nabble.com/Unable-to-build-GIMP-2-99-on-Debian-Sid-td55023.html
where you tracked this down to setting XDG_DATA_DIRS, covered in
the Hacking:Problems_and_solutions page (a wonderful page I hadn't known
about which wasn't showing up in any of my searches):
https://www.wiki.gimp.org/wiki/Hacking:Problems_and_solutions#GIMP_build_fails_with_message_.27Couldn.27t_recognize_the_image_file_format_for_file_..2Fcursor-bad.png.27

and the solution was not to set XDG_DATA_DIRS for the build.
I tried unsetting XDG_DATA_DIRS and indeed, the problem went away.

Does setting
XDG_DATA_DIRS="$XDG_DATA_DIRS:$PREFIX/share:/usr/local/share/:/usr/share/"
actually work for you, and you don't see the "Unrecognized image
file format" problem any more?

I've been updating the various wiki Hacking: pages with some issues
I've hit recently, and I changed the example for the variables I
used to omit XDG_DATA_DIRS and added a warning that it can cause
problems, but I left it in to the two examples you provided in case
they're actually needed on your system. I'm curious why this seems
to vary so much. Maybe in your case, XDG_DATA_DIRS is already set,
and since you set it to add the system version before the $PREFIX
directories, it uses that? In my case, it wasn't set before I run
the GIMP build; I had
XDG_DATA_DIRS=$GIMP_PREFIX/share:$XDG_DATA_DIRS
so it was set to "$GIMP_PREFIX/share:", and that broke the build.

I've added links to Hacking:Problems_and_solutions from the
Hacking:Building pages hoping to make it easier to find, because
there are a lot of great solutions there.

        ...Akkana
_______________________________________________
gimp-developer-list mailing list
List address:    gimp-developer-list@xxxxxxxxx
List membership: https://mail.gnome.org/mailman/listinfo/gimp-developer-list
List archives:   https://mail.gnome.org/archives/gimp-developer-list



[Index of Archives]     [Video For Linux]     [Photo]     [Yosemite News]     [gtk]     [GIMP for Windows]     [KDE]     [GEGL]     [Gimp's Home]     [Gimp on GUI]     [Gimp on Windows]     [Steve's Art]

  Powered by Linux