GNOME Bugzilla – Bug 414013
Fails to build with srcdir != builddir
Last modified: 2007-08-18 21:33:15 UTC
Hi, When building gnome-utils out of tree, it fails with: make[4]: entrant dans le répertoire « /home/lool/jhbuild-gnome-2.18/build/gnome-utils/gnome-dictionary/libgdict » make[4]: quittant le répertoire « /home/lool/jhbuild-gnome-2.18/build/gnome-utils/gnome-dictionary/libgdict » make[3]: quittant le répertoire « /home/lool/jhbuild-gnome-2.18/build/gnome-utils/gnome-dictionary/libgdict » Making all in src make[3]: entrant dans le répertoire « /home/lool/jhbuild-gnome-2.18/build/gnome-utils/gnome-dictionary/src » gcc -DHAVE_CONFIG_H -I. -I../.. -I/home/lool/jhbuild-gnome-2.18/checkout/gnome-utils/gnome-dictionary/src -DPREFIX=\""/home/lool/jhbuild-gnome-2.18/prefix"\" -DSYSCONFDIR=\""/home/lool/jhbuild-gnome-2.18/prefix/etc"\" -DLIBDIR=\""/home/lool/jhbuild-gnome-2.18/prefix/lib"\" -DDATADIR=\""/home/lool/jhbuild-gnome-2.18/prefix/share"\" -DUIDATADIR=\""/home/lool/jhbuild-gnome-2.18/prefix/share/gnome-2.0/ui"\" -DPKGDATADIR=\""/home/lool/jhbuild-gnome-2.18/prefix/share/gnome-dictionary"\" -DGNOMELOCALEDIR=\""/home/lool/jhbuild-gnome-2.18/prefix/share/locale"\" -I/home/lool/jhbuild-gnome-2.18/checkout/gnome-utils/gnome-dictionary -DORBIT2=1 -pthread -I/home/lool/jhbuild-gnome-2.18/prefix/include/glib-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/lib/glib-2.0/include -I/home/lool/jhbuild-gnome-2.18/prefix/include/gtk-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/lib/gtk-2.0/include -I/home/lool/jhbuild-gnome-2.18/prefix/include/atk-1.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/cairo -I/home/lool/jhbuild-gnome-2.18/prefix/include/pango-1.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include -I/home/lool/jhbuild-gnome-2.18/prefix/include/libgnome-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/orbit-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/gconf/2 -I/home/lool/jhbuild-gnome-2.18/prefix/include/gnome-vfs-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/lib/gnome-vfs-2.0/include -I/home/lool/jhbuild-gnome-2.18/prefix/include/libbonobo-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/bonobo-activation-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libgnomeui-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libgnomecanvas-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libart-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libbonoboui-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/gnome-keyring-1 -I/usr/include/freetype2 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libxml2 -I/usr/include/libpng12 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libglade-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/gtk-2.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/libxml2 -I/home/lool/jhbuild-gnome-2.18/prefix/lib/gtk-2.0/include -I/home/lool/jhbuild-gnome-2.18/prefix/include/atk-1.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/cairo -I/home/lool/jhbuild-gnome-2.18/prefix/include/pango-1.0 -I/home/lool/jhbuild-gnome-2.18/prefix/include/glib-2.0 -I/home/l ... In file included from /home/lool/jhbuild-gnome-2.18/checkout/gnome-utils/gnome-dictionary/src/gdict-pref-dialog.h:27, from /home/lool/jhbuild-gnome-2.18/checkout/gnome-utils/gnome-dictionary/src/gdict-app.c:44: /home/lool/jhbuild-gnome-2.18/checkout/gnome-utils/gnome-dictionary/libgdict/gdict.h:32:39: error: libgdict/gdict-enum-types.h: Aucun fichier ou répertoire de ce type /home/lool/jhbuild-gnome-2.18/checkout/gnome-utils/gnome-dictionary/libgdict/gdict.h:33:36: error: libgdict/gdict-version.h: Aucun fichier ou répertoire de ce type ... This is due to a missing -I flag to locate libgdict/'s generated files as these are in builddir, not srcdir. I'll attach a patch which adds builddir to the -I flags. Bye,
Created attachment 83757 [details] [review] Add missing -I flag for out of tree builds
Created attachment 83758 [details] [review] Couple of cleanups While I was at it, I found a couple of cleanups which could be applied as well.
FYI, at some points during my builds I saw: gnome-dictionary/src/Makefile.am:17: compiling `gdict-about.c' with per-target flags requires `AM_PROG_CC_C_O' in `configure.in' However the per-target flags seem to have been included as my initial patch fixes the build failure for me, so I'm not sure what the warning means.
thanks for the fixes. applied to SVN trunk.