From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: TODO: user-environment-hook Date: Fri, 02 Jan 2015 22:38:16 +0100 Message-ID: <87a920eud3.fsf@gnu.org> References: <87387tzt9r.fsf@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]:46782) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y79vG-0005Fa-HY for guix-devel@gnu.org; Fri, 02 Jan 2015 16:38:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Y79vD-0000vp-BY for guix-devel@gnu.org; Fri, 02 Jan 2015 16:38:18 -0500 Received: from hera.aquilenet.fr ([2a01:474::1]:52704) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Y79vD-0000vc-3a for guix-devel@gnu.org; Fri, 02 Jan 2015 16:38:15 -0500 In-Reply-To: <87387tzt9r.fsf@gmail.com> (=?utf-8?B?IuWui+aWh+atpiIncw==?= message of "Fri, 02 Jan 2015 12:44:00 +0800") 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: =?utf-8?B?5a6L5paH5q2m?= Cc: guix-devel@gnu.org =E5=AE=8B=E6=96=87=E6=AD=A6 skribis: > Currently, (guix profiles) has code to build 'info-dir' for packages in p= rofile. > As mentioned in TODO, IIUC, we should move the code to 'texinfo'. Yes, that=E2=80=99s the initial idea. However, it=E2=80=99s not clear that= attaching =E2=80=9Cuser environment hooks=E2=80=9D to packages is the right thing. For instance, you can install Info files, and if you only ever use the Info reader of Emacs, you never install Texinfo itself; yet, the =E2=80=98d= ir=E2=80=99 file must be generated. > Other usecases include: > * hicolor-icon-theme: use gtk-update-icon-cache to get 'icon-theme.cache'. > * shared-mime-info: use update-mime-database to get 'mime.cache'. > * desktop-file-utils: use update-desktop-database to get 'mimeinfo.cache'. > ? glib: use glib-compile-schemas to get 'gschema.compiled'. Same problem here: users may never explicitly install GLib, yet these operations should always be performed. So I=E2=80=99m tempted to think we could just augment =E2=80=98profile-deri= vation=E2=80=99 to invoke other hooks similar to =E2=80=98info-dir-file=E2=80=99 in (guix prof= ile). We could specify a list of =E2=80=9Cprofile hooks=E2=80=9D like: `(("share/info" . ,info-dir-file) ("share/foo/mime.cache" . ,mime-cache-file)) WDYT? > For schemas, it's always safe for packages in system profile, > but may broken for user profile: > user had install package A > user update the guix disto, A -> A' has incompatible schema change > user now install package B' which depend on schema of A' > B' will crash if we have schemas from A and B'. > > If we make A a propagated-inputs of B, dose A will be update to A' when > install B'? Yes, when installing a package with propagated inputs, said inputs are installed as well, possibly overriding others. However, if you look at collision handling in (guix build union) is minimalist, so anything can happen. Thanks, Ludo=E2=80=99.