From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jean Louis Subject: Re: bug#22970: guix edit mutt -- not working Date: Sun, 13 Mar 2016 11:47:04 +0100 Message-ID: <20160313104703.GE3319@protected.rcdrun.com> References: <20160309232220.GA13286@protected.rcdrun.com> <20160309234433.GA28823@solar> <20160310193442.GA5630__27937.5219288797$1457638581$gmane$org@protected.rcdrun.com> <87mvq5nvco.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]:60874) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1af3ZW-0003Rp-QI for help-guix@gnu.org; Sun, 13 Mar 2016 06:48:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1af3ZS-0000l3-Ox for help-guix@gnu.org; Sun, 13 Mar 2016 06:48:30 -0400 Received: from stw1.rcdrun.com ([217.170.207.13]:55481) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1af3ZS-0000is-IV for help-guix@gnu.org; Sun, 13 Mar 2016 06:48:26 -0400 Content-Disposition: inline In-Reply-To: <87mvq5nvco.fsf@gmail.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org To: Alex Kost Cc: 22970-done@debbugs.gnu.org, help-guix@gnu.org Hello Alex, I have followed your recommendation, and mutt is working modified. However, now I get useless error messages. And I can imagine, if I have modified 10 packages, that I would get 10x that much of error messages. warning: collision encountered: /gnu/store/xxzgai9khdfhk70p06vs6akrarzph9r2-my-mutt-1.5.24/share/man/man1= /mutt.1.gz /gnu/store/vh7ghk1xlrn4crshqrdygp5573aipk44-mutt-1.5.24/share/man/man1/mu= tt.1.gz=20 warning: arbitrarily choosing /gnu/store/xxzgai9khdfhk70p06vs6akrarzph9r2-my-mutt-1.5.24/share/man/man5= /muttrc.5.gz warning: collision encountered: /gnu/store/xxzgai9khdfhk70p06vs6akrarzph9r2-my-mutt-1.5.24/bin/mutt /gnu/store/vh7ghk1xlrn4crshqrdygp5573aipk44-mutt-1.5.24/bin/mutt=20 warning: arbitrarily choosing /gnu/store/xxzgai9khdfhk70p06vs6akrarzph9r2-my-mutt-1.5.24/bin/mutt warning: collision encountered: /gnu/store/xxzgai9khdfhk70p06vs6akrarzph9r2-my-mutt-1.5.24/bin/flea /gnu/store/vh7ghk1xlrn4crshqrdygp5573aipk44-mutt-1.5.24/bin/flea=20 Let me stop with copy and paste, because there are many more lines like that. Maybe it is design of guix package manager, maybe it is my fault.=20 I understood that I can change definitions for guix packages, and such would be installed. There shall be no warnings like this. I do intend to make about 5-10 packages for system I use, and I worry about future warning messages, it will be like 3-4 screens, making guix package manager not user-friendly. I would not see real errors. On Fri, Mar 11, 2016 at 01:48:39PM +0300, Alex Kost wrote: > Jean Louis (2016-03-10 22:34 +0300) wrote: >=20 > > Hello Andreas, > > > > I have now 2 files in gnu/guix/packages/*.scm, for mutt and postgresq= l: > > and now I get each time on running guix, following: > > > > guix package: warning: failed to load '(databases)': > > ERROR: no code for module (databases) > > guix package: warning: failed to load '(mutt)': > > ERROR: no code for module (mutt) > > > > because 2 files are: databases.scm and mutt.scm > > > > I have already installed mutt, with changes, and it works. On the end = of > > file there is word "mutt". Similar for PostgreSQL, only it did not ye= t > > compile. > > > > Now I get a feeling, if I have 20 files to change or adapt to my syst= em, > > I will get 20 warnings by each run of guix package manager. > > > > Somehow it does not feel right. > > > > It would be more logical to have GUIX_PACKAGE_PATH plus one separate > > file where some modified or user related packages are listed, instead = of > > having the package name on the end of *.scm file. >=20 > I agree, using GUIX_PACKAGE_PATH is such a nice way to keep your own > packages. I don't understand why Andreas recommended to use "guix > package -f". I think it is suitable to build some development > "guix.scm" file (not related, but see =C2=B9). But for user packages, = I > think keeping them in GUIX_PACKAGE_PATH directories is a much better > solution. >=20 > I also don't recommend to use the same /gnu/packages/*.scm structure, a= s > there may be problems with this. For example, you copied > /gnu/packages/databases.scm to your GUIX_PACKAGE_PATH dir and modified > some package in it. Then you have to follow the changes in this file > made in Guix, and update your local databases.scm accordingly all the > time. >=20 > So if you want to keep all your packages in a single file, you can make > "/my-guix-packages.scm", add to GUIX_PACKAGE_PATH, > and that's it! This "my-guix-packages.scm" file will look like this: >=20 > (define-module (my-guix-packages) > #:use-module (guix packages) > #:use-module (guix download) > #:use-module (guix utils) > #:use-module (gnu packages mail)) >=20 > (define-public my-mutt > (package > (inherit mutt) > (name "my-mutt") > (arguments > (substitute-keyword-arguments (package-arguments mutt) > ((#:configure-flags cf) > `(cons "--enable-hcache" ,cf)))) > (synopsis (string-append (package-synopsis mutt) > " (configured with --enable-hcache)")))) >=20 > And all guix commands will find packages in this file, for example you > can do: "guix package -i my-mutt". Try it!