bug#22693: `guix refresh -u` updates other packages with same version

2016-02-22 Thread Leo Famulari
On Mon, Feb 22, 2016 at 10:33:12PM +0100, Andreas Enge wrote:
> On Tue, Feb 16, 2016 at 04:27:24AM -0500, Leo Famulari wrote:
> > I've noticed that `guix refresh -u` will update extraneous packages if
> > they happen to have the same version and be in the same module.
> > 
> > For example, from commit d694230ab, you can reproduce the bug:
> > 
> > $ ./pre-inst-env guix environment guix -- ./pre-inst-env guix refresh -u 
> > python-pytest
> > $ git diff
> > diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
> > @@ -796,7 +796,7 @@ Python 3 support.")
> >  (define-public python-pycrypto
> >(package
> >  (name "python-pycrypto")
> > -(version "2.6.1")
> > +(version "2.8.7")
> >  (define-public python-pytest
> >(package
> >  (name "python-pytest")
> > -(version "2.6.1")
> > +(version "2.8.7")
> 
> I wondered about the "./pre-inst-env guix environment guix", but I tried it
> without, and I confirm the problem.

I like to offer my bug reports with './pre-inst-env' and a commit, to
increase the number of factors that are deterministic.

> 
> Andreas
> 





bug#22693: `guix refresh -u` updates other packages with same version

2016-02-22 Thread Andreas Enge
On Tue, Feb 16, 2016 at 04:27:24AM -0500, Leo Famulari wrote:
> I've noticed that `guix refresh -u` will update extraneous packages if
> they happen to have the same version and be in the same module.
> 
> For example, from commit d694230ab, you can reproduce the bug:
> 
> $ ./pre-inst-env guix environment guix -- ./pre-inst-env guix refresh -u 
> python-pytest
> $ git diff
> diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
> @@ -796,7 +796,7 @@ Python 3 support.")
>  (define-public python-pycrypto
>(package
>  (name "python-pycrypto")
> -(version "2.6.1")
> +(version "2.8.7")
>  (define-public python-pytest
>(package
>  (name "python-pytest")
> -(version "2.6.1")
> +(version "2.8.7")

I wondered about the "./pre-inst-env guix environment guix", but I tried it
without, and I confirm the problem.

Andreas






bug#22633: Provide a kvm-less qemu / guix system vm

2016-02-22 Thread Christopher Allan Webber
Ludovic Courtès writes:

> Christopher Allan Webber  skribis:
>
>> Christopher Allan Webber writes:
>>
>>> Ludovic Courtès writes:
>>>
 Libkmod honors ‘modprobe.blacklist’ (in ‘kcmdline_parse_result’ in
 libkmod-config.c) and eudev passes KMOD_PROBE_APPLY_BLACKLIST
 unconditionally in udev-builtin-kmod.c (meaning it honors it too.)

 However, there’s a hyphen-vs-underscore issue, I think.  Namely, the
 file is called ‘kvm-intel.ko’, but the normalized module name is
 ‘kvm_intel’, and this is what libkmod expects (commit 5c7dd5a changes
 our code to normalize module names similarly.)

 Could you try with “modprobe.blacklist=kvm_intel”?
>>>
>>> I tried it, and it works!  This does mean that /dev/kvm doesn't exist,
>>> so I should be able to write a patch to Guix that disables kvm for qemu
>>> when /dev/kvm is absent.  Great! :)
>>
>> This is slightly based off of Leo's preliminary patch, so I included him
>> in the copyright headers.  I've tested and it works (in terms of
>> disabling kvm if no /dev/kvm is present) here.
>
> Cool!  Can you just double-check whether -enable-kvm has any effect when
> /dev/kvm is missing?  If it has no effect when /dev/kvm is missing, then
> we don’t even need a patch.

I checked yes; qemu fails.

>> Let me know if I need to fix something or if I should push...
>>
>> From 852e0049213a0a80cacdcad4aba13ab242c3fbd8 Mon Sep 17 00:00:00 2001
>> From: Christopher Allan Webber 
>> Date: Mon, 22 Feb 2016 11:23:14 -0800
>> Subject: [PATCH] vm: Only pass "-enable-kvm" to qemu if /dev/kvm is present.
>>
>> * gnu/build/vm.scm (load-in-linux-vm): Only pass "-enable-kvm" flag to qemu
>>   if "/dev/kvm" is present.
>> * gnu/system/vm.scm (common-kvm-options): Same as above.
>
> [...]
>
>> +   ;; Only enable kvm if we see /dev/kvm exists.
>> +   ;; This allows uers without hardware virtualization to 
>> still use these
>  ^^
> Typo.
>
> [...]
>
>> + ;; Only enable kvm if we see /dev/kvm exists.
>> + ;; This allows uers without hardware virtualization to still use these
>
> Ditto.

Okay, fixed those.

> Otherwise the patch LGTM.  Make sure to mention:
>
>   Fixes .
>
> in the commit log.

Mentioned, committed, pushed!





bug#22633: Provide a kvm-less qemu / guix system vm

2016-02-22 Thread Christopher Allan Webber
Jookia writes:

> On Mon, Feb 22, 2016 at 11:35:30AM -0800, Christopher Allan Webber wrote:
>>#~(string-append
>> - " -enable-kvm -no-reboot -net nic,model=virtio \
>> + ;; Only enable kvm if we see /dev/kvm exists.
>> + ;; This allows uers without hardware virtualization to still use these
>> + ;; commands.
>> + #$(if (file-exists? "/dev/kvm")
>> +   " -enable-kvm "
>> +   "")
>> + " -no-reboot -net nic,model=virtio \
>>" #$@(map virtfs-option shared-fs) " \
>>-net user \
>>-serial stdio -vga std \
>> -- 
>> 2.6.3
>
> What if I enable KVM then run the script?
>
> Jookia.

Then it should use KVM.





bug#22740: Freshness check blocks upgrading

2016-02-22 Thread Ludovic Courtès
Alex Kost  skribis:

> Andreas Enge (2016-02-19 20:12 +0300) wrote:
>
>> Hello,
>>
>> when upgrading packages, there is a check for new GNU releases.
>> In the presence of network problems preventing to reach the corresponding
>> servers, the command "guix package -u" hangs indefinitely.
>>
>> It would be nice to add a (short) time-out to the procedure looking
>> for updates, or better yet, to add a command line flag to turn it off:
>> Even when the servers are reachable, checking for new versions takes
>> a considerable amount of time that can be saved in many circumstances.
>>
>> Personally, I would not even mind turning this feature off completely;
>
> I totally agree with this!  I didn't like it since the very beginning.

I agree.  I implemented it mostly for the fun of it and to demonstrate
that we could possibly do “clever” things with access to high-level
package objects (the command could automatically offer to use the new
source instead of the old one), but in practice it’s been largely
annoying.

Ludo’, waiting for the patch that removes it.  :-)





bug#22633: Provide a kvm-less qemu / guix system vm

2016-02-22 Thread Ludovic Courtès
Christopher Allan Webber  skribis:

> Christopher Allan Webber writes:
>
>> Ludovic Courtès writes:
>>
>>> Libkmod honors ‘modprobe.blacklist’ (in ‘kcmdline_parse_result’ in
>>> libkmod-config.c) and eudev passes KMOD_PROBE_APPLY_BLACKLIST
>>> unconditionally in udev-builtin-kmod.c (meaning it honors it too.)
>>>
>>> However, there’s a hyphen-vs-underscore issue, I think.  Namely, the
>>> file is called ‘kvm-intel.ko’, but the normalized module name is
>>> ‘kvm_intel’, and this is what libkmod expects (commit 5c7dd5a changes
>>> our code to normalize module names similarly.)
>>>
>>> Could you try with “modprobe.blacklist=kvm_intel”?
>>
>> I tried it, and it works!  This does mean that /dev/kvm doesn't exist,
>> so I should be able to write a patch to Guix that disables kvm for qemu
>> when /dev/kvm is absent.  Great! :)
>
> This is slightly based off of Leo's preliminary patch, so I included him
> in the copyright headers.  I've tested and it works (in terms of
> disabling kvm if no /dev/kvm is present) here.

Cool!  Can you just double-check whether -enable-kvm has any effect when
/dev/kvm is missing?  If it has no effect when /dev/kvm is missing, then
we don’t even need a patch.

> Let me know if I need to fix something or if I should push...
>
> From 852e0049213a0a80cacdcad4aba13ab242c3fbd8 Mon Sep 17 00:00:00 2001
> From: Christopher Allan Webber 
> Date: Mon, 22 Feb 2016 11:23:14 -0800
> Subject: [PATCH] vm: Only pass "-enable-kvm" to qemu if /dev/kvm is present.
>
> * gnu/build/vm.scm (load-in-linux-vm): Only pass "-enable-kvm" flag to qemu
>   if "/dev/kvm" is present.
> * gnu/system/vm.scm (common-kvm-options): Same as above.

[...]

> +   ;; Only enable kvm if we see /dev/kvm exists.
> +   ;; This allows uers without hardware virtualization to 
> still use these
 ^^
Typo.

[...]

> + ;; Only enable kvm if we see /dev/kvm exists.
> + ;; This allows uers without hardware virtualization to still use these

Ditto.

Otherwise the patch LGTM.  Make sure to mention:

  Fixes .

in the commit log.

Thanks,
Ludo’.





bug#22774: Bootstrapping issue with HTTPS downloads

2016-02-22 Thread Ludovic Courtès
Fixed-output derivations for HTTPS downloads depend on GnuTLS.  However,
pkg-config, one of GnuTLS’s dependencies, is now available exclusively
over HTTPS, which creates a bootstrapping issue, as reported by
Christopher W Carpenter and others:

  https://lists.gnu.org/archive/html/guix-devel/2016-02/msg00354.html

Ludo’.





bug#22600: 'Globally-Visible Packages' not shown by 'M-x guix-installed-packages'

2016-02-22 Thread Alex Kost
Alex Kost (2016-02-09 22:21 +0300) wrote:

[...]
> As I suggested in the previous mail, we can add "M-x guix-system-packages".
> Maybe it would be good to add "M-x guix-user-packages", or maybe name them:
>
> - guix-installed-system-packages  (for /run/current-system/profile)
> - guix-installed-user-packages(for ~/.guix-profile)

These commands are added in commit cfb1c62.

-- 
Alex





bug#22607: doc install from *Guix Package Info: profile* fails

2016-02-22 Thread Alex Kost
Alex Kost (2016-02-10 13:14 +0300) wrote:

> myglc2 (2016-02-10 03:58 +0300) wrote:
>
[...]
>> Also, just to be clear, I was not trying to install the curses.6 doc
>> globally. I was trying to install it locally as 1) user, and when that
>> failed as 2) root.
>
> Now I understand your intention, but in fact you tried to install it to
> a system profile both times.
>
> After all I see why you were confused.  Emacs interface has always been
> aimed only for a user profile.  "M-x guix-system-generations" was added
> very recently just to show what systems you have and what global
> packages they contain, and by accident you can perform the same actions on
> these system packages as with user profile.
>
> I'm going to remove this false possibility (I mean, a user shouldn't get
> a chance to install anything to a system profile) to avoid future
> confusions.

Done in commit 260795b.

-- 
Alex





bug#22633: Provide a kvm-less qemu / guix system vm

2016-02-22 Thread Jookia
On Mon, Feb 22, 2016 at 11:35:30AM -0800, Christopher Allan Webber wrote:
>#~(string-append
> - " -enable-kvm -no-reboot -net nic,model=virtio \
> + ;; Only enable kvm if we see /dev/kvm exists.
> + ;; This allows uers without hardware virtualization to still use these
> + ;; commands.
> + #$(if (file-exists? "/dev/kvm")
> +   " -enable-kvm "
> +   "")
> + " -no-reboot -net nic,model=virtio \
>" #$@(map virtfs-option shared-fs) " \
>-net user \
>-serial stdio -vga std \
> -- 
> 2.6.3

What if I enable KVM then run the script?

Jookia.





bug#22633: Provide a kvm-less qemu / guix system vm

2016-02-22 Thread Christopher Allan Webber
Christopher Allan Webber writes:

> Ludovic Courtès writes:
>
>> Libkmod honors ‘modprobe.blacklist’ (in ‘kcmdline_parse_result’ in
>> libkmod-config.c) and eudev passes KMOD_PROBE_APPLY_BLACKLIST
>> unconditionally in udev-builtin-kmod.c (meaning it honors it too.)
>>
>> However, there’s a hyphen-vs-underscore issue, I think.  Namely, the
>> file is called ‘kvm-intel.ko’, but the normalized module name is
>> ‘kvm_intel’, and this is what libkmod expects (commit 5c7dd5a changes
>> our code to normalize module names similarly.)
>>
>> Could you try with “modprobe.blacklist=kvm_intel”?
>
> I tried it, and it works!  This does mean that /dev/kvm doesn't exist,
> so I should be able to write a patch to Guix that disables kvm for qemu
> when /dev/kvm is absent.  Great! :)

This is slightly based off of Leo's preliminary patch, so I included him
in the copyright headers.  I've tested and it works (in terms of
disabling kvm if no /dev/kvm is present) here.

Let me know if I need to fix something or if I should push...

>From 852e0049213a0a80cacdcad4aba13ab242c3fbd8 Mon Sep 17 00:00:00 2001
From: Christopher Allan Webber 
Date: Mon, 22 Feb 2016 11:23:14 -0800
Subject: [PATCH] vm: Only pass "-enable-kvm" to qemu if /dev/kvm is present.

* gnu/build/vm.scm (load-in-linux-vm): Only pass "-enable-kvm" flag to qemu
  if "/dev/kvm" is present.
* gnu/system/vm.scm (common-kvm-options): Same as above.
---
 gnu/build/vm.scm  | 19 ++-
 gnu/system/vm.scm | 10 +-
 2 files changed, 23 insertions(+), 6 deletions(-)

diff --git a/gnu/build/vm.scm b/gnu/build/vm.scm
index a095f9d..823156d 100644
--- a/gnu/build/vm.scm
+++ b/gnu/build/vm.scm
@@ -1,5 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès 
+;;; Copyright © 2016 Christopher Allan Webber 
+;;; Copyright © 2016 Leo Famulari 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -97,7 +99,7 @@ the #:references-graphs parameter of 'derivation'."
 (_ #f))
 
   (unless (zero?
-   (apply system* qemu "-enable-kvm" "-nographic" "-no-reboot"
+   (apply system* qemu "-nographic" "-no-reboot"
   "-m" (number->string memory-size)
   "-net" "nic,model=virtio"
   "-virtfs"
@@ -111,10 +113,17 @@ the #:references-graphs parameter of 'derivation'."
   "-initrd" initrd
   "-append" (string-append "console=ttyS0 --load="
builder)
-  (if make-disk-image?
-  `("-drive" ,(string-append "file=" image-file
- ",if=virtio"))
-  '(
+  (append
+   (if make-disk-image?
+   `("-drive" ,(string-append "file=" image-file
+  ",if=virtio"))
+   '())
+   ;; Only enable kvm if we see /dev/kvm exists.
+   ;; This allows uers without hardware virtualization to still use these
+   ;; commands.
+   (if (file-exists? "/dev/kvm")
+   '("-enable-kvm")
+   '()
 (error "qemu failed" qemu))
 
   (if make-disk-image?
diff --git a/gnu/system/vm.scm b/gnu/system/vm.scm
index a7c03bd..5235ee3 100644
--- a/gnu/system/vm.scm
+++ b/gnu/system/vm.scm
@@ -1,5 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2013, 2014, 2015, 2016 Ludovic Courtès 
+;;; Copyright © 2016 Christopher Allan Webber 
+;;; Copyright © 2016 Leo Famulari 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -457,7 +459,13 @@ with '-virtfs' options for the host file systems listed in SHARED-FS."
  "\" "))
 
   #~(string-append
- " -enable-kvm -no-reboot -net nic,model=virtio \
+ ;; Only enable kvm if we see /dev/kvm exists.
+ ;; This allows uers without hardware virtualization to still use these
+ ;; commands.
+ #$(if (file-exists? "/dev/kvm")
+   " -enable-kvm "
+   "")
+ " -no-reboot -net nic,model=virtio \
   " #$@(map virtfs-option shared-fs) " \
   -net user \
   -serial stdio -vga std \
-- 
2.6.3



bug#22633: Provide a kvm-less qemu / guix system vm

2016-02-22 Thread Christopher Allan Webber
Ludovic Courtès writes:

> Libkmod honors ‘modprobe.blacklist’ (in ‘kcmdline_parse_result’ in
> libkmod-config.c) and eudev passes KMOD_PROBE_APPLY_BLACKLIST
> unconditionally in udev-builtin-kmod.c (meaning it honors it too.)
>
> However, there’s a hyphen-vs-underscore issue, I think.  Namely, the
> file is called ‘kvm-intel.ko’, but the normalized module name is
> ‘kvm_intel’, and this is what libkmod expects (commit 5c7dd5a changes
> our code to normalize module names similarly.)
>
> Could you try with “modprobe.blacklist=kvm_intel”?

I tried it, and it works!  This does mean that /dev/kvm doesn't exist,
so I should be able to write a patch to Guix that disables kvm for qemu
when /dev/kvm is absent.  Great! :)





bug#22650: guixSD default umask is 0000

2016-02-22 Thread myglc2
l...@gnu.org (Ludovic Courtès) writes:

> I can’t reproduce this.  For instance, in the system created with:
>
>   guix system vm gnu/system/examples/bare-bones.tmpl
>
> ‘umask’ returns 0022.
>
> Could it be that your user accounts have shell startup files like
> ~/.bashrc that specify a different umask?

I don't think so. I have attached a log of dot files for a sample user
(glc4) and the most current (feb 12) system config.

'system-generations-package-list' file was generated by 'emacs' 'M-x
guix-system-generations' '"select" (current) generation'

HTH, George


umask.bug.log
Description: Binary data


config.n.scm
Description: Binary data


bug#22543: 404 in Manualpage

2016-02-22 Thread Alex Kost
Ludovic Courtès (2016-02-22 00:30 +0300) wrote:

> The broken links stem from missing/incomplete cross-reference info for
> ‘makeinfo’ in the ‘htmlxref.cnf’ config file (info "(texinfo) HTML Xref
> Configuration").
>
> Commit 49e0ca9 adds this file to the repo, taken from Texinfo 6.1 and
> modified to fix some of the links (like GnuTLS) and include others
> (Shepherd, Guile-Avahi, etc.)
>
> When we update the manual for the next release, everything will be
> alright hopefully.  In the meantime, it’s easier to leave things as is,
> and hopefully not too much of an issue.

Wow, great!  I didn't think this could be fixed on the Guix side.

-- 
Alex





bug#22677: guix lint fails with -dc switch missing

2016-02-22 Thread Ludovic Courtès
Pjotr Prins  skribis:

> On Sun, Feb 21, 2016 at 11:36:50PM +0100, Ludovic Courtès wrote:
>> Running ‘configure’ creates guix/config.scm.  Could you check that this
>> is the case?
>
> Got it:
>
>
> (define %gzip
>   "/home/wrk/.guix-profile/bin/gzip")
>
> (define %bzip2
>   "/home/wrk/opt/guix-build-system/bin/bzip2")
>
> (define %xz
>   "/home/wrk/opt/guix-build-system/bin/xz")

OK, looks good.  Not sure what happened.

Thanks,
Ludo’.





bug#22677: guix lint fails with -dc switch missing

2016-02-22 Thread Pjotr Prins
On Sun, Feb 21, 2016 at 11:36:50PM +0100, Ludovic Courtès wrote:
> Running ‘configure’ creates guix/config.scm.  Could you check that this
> is the case?

Got it:


(define %gzip
  "/home/wrk/.guix-profile/bin/gzip")

(define %bzip2
  "/home/wrk/opt/guix-build-system/bin/bzip2")

(define %xz
  "/home/wrk/opt/guix-build-system/bin/xz")

--