From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mikhail Kryshen Subject: Re: qt-build-system: prefix or suffix env-variables in wrap-program Date: Wed, 11 Dec 2019 23:25:33 +0300 Message-ID: <878snifw3m.fsf@home.localdomain> References: Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:54356) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1if8YK-0000lo-LC for guix-devel@gnu.org; Wed, 11 Dec 2019 15:25:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1if8YI-0000Or-RI for guix-devel@gnu.org; Wed, 11 Dec 2019 15:25:43 -0500 Received: from mail.kryshen.net ([31.220.44.128]:39386) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1if8YI-0000KX-JL for guix-devel@gnu.org; Wed, 11 Dec 2019 15:25:42 -0500 In-Reply-To: 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" To: Hartmut Goebel , Guix-devel --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hartmut Goebel writes: > Hi, > > it came to my mind that currently the qt-build-system wraps the program > without passing along any environment variables. Thus e.g. > XDG_CONFIG_DIRS will be overwritten, instead of not extended. Furtunatly > ((guix build utils) wrap-program) supports prefixing or suffixing an > existing variable value. > > Shall qt-build-system: prefix or suffix existing env-variables? Should > it become > > =C2=A0=C2=A0=C2=A0 export > XDG_DATA_DIRS=3D"$XDG_DATA_DIRS${XDG_DATA_DIRS:+:}/gnu/store/=E2=80=A6-ka= te-=E2=80=A6" > > or > > =C2=A0=C2=A0=C2=A0 export > XDG_DATA_DIRS=3D"/gnu/store/=E2=80=A6-kate-=E2=80=A6${XDG_DATA_DIRS:+:}$X= DG_DATA_DIRS" Note that XDG Base Directory Specification [1] sets default values to use for empty or unset XDG_* variables, for instance: "If $XDG_DATA_DIRS is either not set or empty, a value equal to /usr/local/share/:/usr/share/ should be used." So the correct way to extend XDG_DATA_DIRS would be export XDG_DATA_DIRS=3D"${XDG_DATA_DIRS:-/usr/local/share/:/usr/share/}:/= gnu/store/=E2=80=A6-kate-=E2=80=A6" or export XDG_DATA_DIRS=3D"/gnu/store/=E2=80=A6-kate-=E2=80=A6:${XDG_DATA_DI= RS:-/usr/local/share/:/usr/share/}" [1] https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest= .html =2D- Mikhail --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAEBCAAdFiEEw6yVFU/UQfkLWikDzxz0c4HWsG4FAl3xUL4ACgkQzxz0c4HW sG48Zwv/fkIzduCDWWu4isMXgPp+5IdYIDQdUj9LswtH0NDbs6akzTh4pLNmsoBj Zl8bFmX0Xb+c17DFtU+agoF51G/FBT1uUJ5R8NFYghYuz5WGcoxzenRzpf61f5gb wgasiDU7eI7koJCwbrS36PHXUe1zria4nfS0hmGLDs5p6pCkz2tVFHKfRd8VqOdo sEW3REOTZ2Z/i5VO4HDN2SxaRPIqdX7Tt/X/C8Hy4wZ7CXXrJoxN4j8hE3hbVjCh 69FMTqF8tV5N2bfVwXwhqpXn8lN0NHyyKl7emxp5OI21q/KjyM6O4pbpP2Lfak7d tb/PCLRVHZXFaRj3GHm3rR05WHnJrXzE/+8ykD/hUR2DAd81McaoAhyYaSZkEiih iJwIFwspT9xKGs/nbr6euOXvoCwsnNy7DqghLQwHeRj0QWiJl5z+PwA5YAaL8sEx O3Tz6hl5BA/qN5dfeSEur6mptewhbFxaUA2flCy8v66SEueN8Oj0VjVElcvne25H aunkg/0s =X6cq -----END PGP SIGNATURE----- --=-=-=--