From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: gobject-introspection .gir search path Date: Tue, 06 May 2014 23:11:54 +0200 Message-ID: <87iopi1ujp.fsf@gnu.org> References: <87vbtjn98r.fsf@gnu.org> <536817D0.9020600@gmail.com> <87zjiv49fe.fsf@gnu.org> <53692386.3090201@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:54867) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Whmej-0004NC-Rs for guix-devel@gnu.org; Tue, 06 May 2014 17:12:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Whmea-0001rB-QS for guix-devel@gnu.org; Tue, 06 May 2014 17:12:05 -0400 Received: from hera.aquilenet.fr ([2a01:474::1]:36997) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Whmea-0001qO-Gz for guix-devel@gnu.org; Tue, 06 May 2014 17:11:56 -0400 In-Reply-To: <53692386.3090201@gmail.com> (Cyril Roelandt's message of "Tue, 06 May 2014 20:01:42 +0200") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Cyril Roelandt Cc: guix-devel Cyril Roelandt skribis: > On 05/06/2014 10:07 AM, Ludovic Court=C3=A8s wrote: >> Cyril Roelandt skribis: >>=20 >>> On 05/06/2014 12:36 AM, Ludovic Court=C3=A8s wrote: >>>> While trying to package librsvg, I stumbled upon this: >>>> >>>> --8<---------------cut here---------------start------------->8--- >>>> Couldn't find include 'GdkPixbuf-2.0.gir' (search path: ['.', 'gir-1.0= ', '/gnu/store/xdd5ndl01700w23z206nc36nqg96z94v-gobject-introspection-1.38.= 0/share/gir-1.0', '/usr/share/gir-1.0', '/gnu/store/xdd5ndl01700w23z206nc36= nqg96z94v-gobject-introspection-1.38.0/share/gir-1.0']) >>>> /gnu/store/xdd5ndl01700w23z206nc36nqg96z94v-gobject-introspection-1.38= .0/share/gobject-introspection-1.0/Makefile.introspection:153: recipe for t= arget 'Rsvg-2.0.gir' failed >>>> make[2]: *** [Rsvg-2.0.gir] Error 1 >>>> --8<---------------cut here---------------end--------------->8--- >>>> >>>> Do you remember if the gobject-introspection =E2=80=9Cscanner=E2=80=9D= had a way to >>>> specify a search path, like an env. var.? >>>> >>>> Otherwise, how can we make sure that the .girs of inputs are visible? >>>> >>> >>> Look at the 'gir-directory' function in guix/build/gnome.scm. It's used >>> in gnu/packages/{gtk,gnome}.scm and does exactly what you need. >>=20 >> Oh right, thanks, that does the job. >>=20 >> It=E2=80=99d be great to submit a patch upstream so that g-ir-compiler & >> co. honor a GIR_PATH environment variable or similar. That seems like >> the right thing to do, and definitely helpful for us. >>=20 > > From 'man g-ir-scanner': > > "The g-ir-scanner uses the XDG_DATA_DIRS variable to check for dirs, the > girs are located in XDG_DATA_DIRS/gir-1.0." > > I guess you could also use that; would it solve your problem ? I think > we might be able to remove the ugly use of '--add-include-path' in > gnu/packages/{gtk,gnome}.scm if we were to use this variable. Indeed, adding a search path specification for =E2=80=98XDG_DATA_DIRS=E2=80= =99 in GLib solves this problem (I=E2=80=99ll commit shortly.) Since =E2=80=98XDG_DATA_DIRS=E2=80=99 is also used as the search path env. = var. for GLib=E2=80=99s schemas, it seemed best to put it in GLib rather than gobject-introspection. Thanks, Ludo=E2=80=99.