Re: [PATCH] import: Add PyPI importer.

2014-09-30 Thread Ludovic Courtès
Alex Kost  skribis:

> David Thompson (2014-09-30 03:31 +0400) wrote:
>
>> Ludovic Courtès  writes:
>>
>>> David Thompson  skribis:
>>>
 Oh yeah, almost forgot about the Automake rule!  My autotools skills are
 weak so I'm not sure how to write this.  Could you point me in the right
 direction?
>>>
>>> In configure.ac, do something like:
>>>
>>>   GUILE_MODULE_AVAILABLE([have_guile_json], [(json)])
>>>   AM_CONDITIONAL([HAVE_GUILE_JSON], [text "x$have_guile_json" = "xyes"])
>>>
>>> and in Makefile.am:
>>>
>>>   if HAVE_GUILE_JSON
>>>   TESTS += tests/pypi.scm
>>>   endif
>>
>> Done and pushed!  Thanks!

Woo!

> Hello, I don't have guile-json and "make" has failed for me because
> (guix import pypi) wants json module.  Is it required now?
>
> Perhaps it would be safe (?) to adjust “Makefile.am” like this:

Alternately, we could do this:

diff --git a/guix/import/pypi.scm b/guix/import/pypi.scm
index d0e776e..da8bd04 100644
--- a/guix/import/pypi.scm
+++ b/guix/import/pypi.scm
@@ -23,7 +23,7 @@
   #:use-module (ice-9 regex)
   #:use-module (srfi srfi-1)
   #:use-module (rnrs bytevectors)
-  #:use-module (json)
+  #:autoload   (json) (json->scm)
   #:use-module (web uri)
   #:use-module (guix utils)
   #:use-module (guix import utils)

That way, the importer would still be compiled (with a warning) and
installed, so that if the user eventually installed guile-json, it will
work.

However, that would fail with old Guile versions:
.

So your patch is probably the right way.  OK to commit!

Ludo’.


Re: [ANN] Guile-SSH 0.7.0 released

2014-09-30 Thread Artyom Poptsov
Hi Ludovic.

> There are still test failures though, so I’m attaching the logs again.
> I’m afraid it’s not that helpful though.   :-/

Thanks for the logs.  I think at least some of the failures may be
related to problems with GCrypt support in libssh 0.6.3.  Did you
compile libssh with GCrypt enabled?

To show that there is some progress: I sent a patch [1] to libssh
mailing list that fixes a problem with GCrypt support.  Developers have
not responded yet, so I'd rather wait for their opinions on the patch.

But the testing shows that when libssh 0.6.3 compiled with the patch
applied Guile-SSH passes almost all the tests, except tests from
`tests/key.scm' that involve ECDSA keys.  And as far as I can see libssh
0.6.3 w/ GCrypt doesn't support ECDSA keys yet.  But that's still under
investigation.

Thanks,

- Artyom

[1] http://www.libssh.org/archive/libssh/2014-09/025.html

-- 
Artyom V. Poptsov ;  GPG Key: 0898A02F
Home page: http://poptsov-artyom.narod.ru/



Guix Pull Failure

2014-09-30 Thread Alex Sassmannshausen
Hello,

When doing `guix pull` this morning it consistently fails with:

---8<>8
copying and compiling to 
'/gnu/store/gjb8zsijysxfcizw1374k5hcadd3x7mf-guix-latest'...
compiling...  8.7% of 335 filesERROR: no code for module (json)
---8<>8

It does this even after I have installed guile-json. Could this be due
to the recent addition of the PyPi Importer?

Best wishes,

Alex

-- 
Sent with my mu4e



Re: Guix Pull Failure

2014-09-30 Thread Ludovic Courtès
Alex Sassmannshausen  skribis:

> When doing `guix pull` this morning it consistently fails with:
>
> ---8<>8
> copying and compiling to 
> '/gnu/store/gjb8zsijysxfcizw1374k5hcadd3x7mf-guix-latest'...
> compiling...  8.7% of 335 filesERROR: no code for module (json)
> ---8<>8

Oops.  Commit 6d7328b fixes that.

However, because of , you will first have to
run ‘guix pull’ from a checkout of master:

  ./pre-inst-env guix pull

Thanks for the heads-up,
Ludo’.



Re: Guix Pull Failure

2014-09-30 Thread Alex Kost
Alex Sassmannshausen (2014-09-30 11:40 +0400) wrote:

> Hello,
>
> When doing `guix pull` this morning it consistently fails with:
>
> ---8<>8
> copying and compiling to 
> '/gnu/store/gjb8zsijysxfcizw1374k5hcadd3x7mf-guix-latest'...
> compiling...  8.7% of 335 filesERROR: no code for module (json)
> ---8<>8
>
> It does this even after I have installed guile-json. Could this be due
> to the recent addition of the PyPi Importer?

Indeed, I thought it would be fixed after
,
but it is not.

Ludovic, need your help!




Re: Guix Pull Failure

2014-09-30 Thread Alex Sassmannshausen
Hi Ludo,

Ludovic Courtès writes:

> Oops.  Commit 6d7328b fixes that.
>
> However, because of , you will first have to
> run ‘guix pull’ from a checkout of master:
>
>   ./pre-inst-env guix pull

That's done the trick. Fab!

Alex

-- 
Sent with my mu4e



[PATCH] gnu: Move flashrom and avrdude to (gnu packages flashing-tools)

2014-09-30 Thread Manolis Ragkousis
As discussed in the irc, here is a module for all the flashing tools.
I added flashrom and avrdude in there.
I will also resend my dfu-programmer patch after I adjust it accordingly.

Please tell me if I should include anything else in there.

Manolis
From 513a28b87576410b247978aede2a3e22263bb9d6 Mon Sep 17 00:00:00 2001
From: Manolis Ragkousis 
Date: Mon, 29 Sep 2014 18:52:57 +0300
Subject: [PATCH] gnu: Move flashrom and avrdude to (gnu packages
 flashing-tools).

* gnu/packages/admin.scm (flashrom): Move this and...
* gnu/packages/avrdude.scm (avrdude): ... this to...
* gnu/packages/flashing-tools.scm: ... this. New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Remove
gnu/packages/avrdude.scm and add
gnu/packages/flashing-tools.scm.
---
 gnu-system.am   |   2 +-
 gnu/packages/admin.scm  |  44 -
 gnu/packages/avrdude.scm|  58 --
 gnu/packages/flashing-tools.scm | 106 
 4 files changed, 107 insertions(+), 103 deletions(-)
 delete mode 100644 gnu/packages/avrdude.scm
 create mode 100644 gnu/packages/flashing-tools.scm

diff --git a/gnu-system.am b/gnu-system.am
index bb944fb..8601a50 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -38,7 +38,6 @@ GNU_SYSTEM_MODULES =\
   gnu/packages/autogen.scm			\
   gnu/packages/autotools.scm			\
   gnu/packages/avahi.scm			\
-  gnu/packages/avrdude.scm			\
   gnu/packages/backup.scm			\
   gnu/packages/base.scm\
   gnu/packages/bash.scm\
@@ -82,6 +81,7 @@ GNU_SYSTEM_MODULES =\
   gnu/packages/enchant.scm			\
   gnu/packages/file.scm\
   gnu/packages/fish.scm\
+  gnu/packages/flashing-tools.scm		\
   gnu/packages/flex.scm\
   gnu/packages/fltk.scm\
   gnu/packages/fonts.scm			\
diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index f6ff32c..a5b84af 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -794,50 +794,6 @@ status for the CPU sockets, expansion slots (e.g. AGP, PCI, ISA) and memory
 module slots, and the list of I/O ports (e.g. serial, parallel, USB).")
 (license gpl2+)))
 
-(define-public flashrom
-  (package
-(name "flashrom")
-(version "0.9.7")
-(source (origin
-  (method url-fetch)
-  (uri (string-append
-"http://download.flashrom.org/releases/flashrom-";
-version ".tar.bz2"))
-  (sha256
-   (base32
-"1s9pc4yls2s1gcg2ar4q75nym2z5v6lxq36bl6lq26br00nj2mas"))
-  (patches (list (search-patch "flashrom-use-libftdi1.patch")
-(build-system gnu-build-system)
-(inputs `(("dmidecode" ,dmidecode)
-  ("pciutils" ,pciutils)
-  ("libusb" ,libusb)
-  ("libftdi" ,libftdi)))
-(native-inputs `(("pkg-config" ,pkg-config)))
-(arguments
- '(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
-   #:tests? #f   ; no 'check' target
-   #:phases
-   (alist-delete
-'configure
-(alist-cons-before
- 'build 'patch-exec-paths
- (lambda* (#:key inputs #:allow-other-keys)
-   (substitute* "dmi.c"
- (("\"dmidecode\"")
-  (format #f "~S"
-  (string-append (assoc-ref inputs "dmidecode")
- "/sbin/dmidecode")
- %standard-phases
-(home-page "http://flashrom.org/";)
-(synopsis "Identify, read, write, erase, and verify ROM/flash chips")
-(description
- "flashrom is a utility for identifying, reading, writing,
-verifying and erasing flash chips.  It is designed to flash
-BIOS/EFI/coreboot/firmware/optionROM images on mainboards,
-network/graphics/storage controller cards, and various other
-programmer devices.")
-(license gpl2)))
-
 (define-public acpica
   (package
 (name "acpica")
diff --git a/gnu/packages/avrdude.scm b/gnu/packages/avrdude.scm
deleted file mode 100644
index 2845604..000
--- a/gnu/packages/avrdude.scm
+++ /dev/null
@@ -1,58 +0,0 @@
-;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2014 Manolis Fragkiskos Ragkousis 
-;;;
-;;; This file is part of GNU Guix.
-;;;
-;;; GNU Guix is free software; you can redistribute it and/or modify it
-;;; under the terms of the GNU General Public License as published by
-;;; the Free Software Foundation; either version 3 of the License, or (at
-;;; your option) any later version.
-;;;
-;;; GNU Guix is distributed in the hope that it will be useful, but
-;;; WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-;;; GNU General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU General Public License
-;;; along with GNU Guix.  If not, see .
-
-(define-module (gnu packages avrdude)
-  #:use-module (guix licenses)
-  #:use-module (guix download)
-  #:use-mod

Re: Guix Pull Failure

2014-09-30 Thread Alex Kost
This message is the answer to myself, so please ignore it and the
previous one.

Alex Kost (2014-09-30 12:13 +0400) wrote:

> Alex Sassmannshausen (2014-09-30 11:40 +0400) wrote:
>
>> Hello,
>>
>> When doing `guix pull` this morning it consistently fails with:
>>
>> ---8<>8
>> copying and compiling to 
>> '/gnu/store/gjb8zsijysxfcizw1374k5hcadd3x7mf-guix-latest'...
>> compiling...  8.7% of 335 filesERROR: no code for module (json)
>> ---8<>8
>>
>> It does this even after I have installed guile-json. Could this be due
>> to the recent addition of the PyPi Importer?
>
> Indeed, I thought it would be fixed after
> ,
> but it is not.

My mistake: this commit couldn't affect “guix pull” in any way.

For some reason I thought that “guix pull” does configure+make process
but it just copies and compiles *.scm files from "gnu/" and "guix/"
directories (and a couple of other scm-files).

And now (with Ludovic's commit 6d7328b), "guile-json" package is being
built (or downloaded from hydra) by “guix pull” before the main
"pulling" process.

Sorry for the noize and thanks Ludovic for a "virtual help" (I looked at
the source of “guix/scripts/pull.scm” and “guix/build/pull.scm” after
your commit).



Re: [ANN] Guile-SSH 0.7.0 released

2014-09-30 Thread Ludovic Courtès
Artyom Poptsov  skribis:

> Hi Ludovic.
>
>> There are still test failures though, so I’m attaching the logs again.
>> I’m afraid it’s not that helpful though.   :-/
>
> Thanks for the logs.  I think at least some of the failures may be
> related to problems with GCrypt support in libssh 0.6.3.  Did you
> compile libssh with GCrypt enabled?

Yes:
.

> To show that there is some progress: I sent a patch [1] to libssh
> mailing list that fixes a problem with GCrypt support.  Developers have
> not responded yet, so I'd rather wait for their opinions on the patch.

OK, cool.

> But the testing shows that when libssh 0.6.3 compiled with the patch
> applied Guile-SSH passes almost all the tests, except tests from
> `tests/key.scm' that involve ECDSA keys.  And as far as I can see libssh
> 0.6.3 w/ GCrypt doesn't support ECDSA keys yet.  But that's still under
> investigation.

I think one would need to use libgcrypt 1.6 for that, but libssh 0.6.3
doesn’t build with 1.6.

Thanks,
Ludo’.



Installing Guix with VirtualBox

2014-09-30 Thread Ludovic Courtès
Ernesto Celis  skribis:

> I know this thread is about qemu, but as you said you are a VitrualBox
> user, it may be interesting to you.
>
> Last weekend I was able to install Guix 0.7 on virtualBox with the USB
> image provided by Guix developers. I put my notes on gitorious.
>
> https://gitorious.org/ecelis-guix/hackathon

Thanks for the note, this will be helpful for others.

Ludo’.



Re: [PATCH] gnu: Move flashrom and avrdude to (gnu packages flashing-tools)

2014-09-30 Thread Ludovic Courtès
Manolis Ragkousis  skribis:

> From 513a28b87576410b247978aede2a3e22263bb9d6 Mon Sep 17 00:00:00 2001
> From: Manolis Ragkousis 
> Date: Mon, 29 Sep 2014 18:52:57 +0300
> Subject: [PATCH] gnu: Move flashrom and avrdude to (gnu packages
>  flashing-tools).
>
> * gnu/packages/admin.scm (flashrom): Move this and...
> * gnu/packages/avrdude.scm (avrdude): ... this to...
> * gnu/packages/flashing-tools.scm: ... this. New file.
> * gnu-system.am (GNU_SYSTEM_MODULES): Remove
> gnu/packages/avrdude.scm and add
> gnu/packages/flashing-tools.scm.

Thanks, pushed with a minor log tweak.

Ludo’.



Re: [PATCH] import: Add PyPI importer.

2014-09-30 Thread David Thompson
Alex Kost  writes:

> Hello, I don't have guile-json and "make" has failed for me because
> (guix import pypi) wants json module.  Is it required now?
>
> Perhaps it would be safe (?) to adjust “Makefile.am” like this:
>

Sorry about that.  Thanks for fixing it!

-- 
David Thompson
Web Developer - Free Software Foundation - http://fsf.org
GPG Key: 0FF1D807
Support the FSF: https://fsf.org/donate



Re: Trying to install Guix with Qemu

2014-09-30 Thread Nate Bargmann
* On 2014 30 Sep 01:59 -0500, Ernesto Celis wrote:
> I know this thread is about qemu, but as you said you are a VitrualBox
> user, it may be interesting to you.
> 
> Last weekend I was able to install Guix 0.7 on virtualBox with the USB
> image provided by Guix developers. I put my notes on gitorious.
> 
> https://gitorious.org/ecelis-guix/hackathon
> 
> Check the Changelog file for some problems.

Nice work, Ernesto.

I actually have a larger hard drive on order for my laptop so I can try
the GNU System w/Guix on bare metal.  There will be some issues such as
the Intel wireless hardware, but I also have an Atheros based USB
adapter from Think Penguin I can try.  If nothing else I'll have far
more drive space for VM disks in the Debian partition.  :-)

Also, your instructions for installing Guix on Slackware is interesting
to me.  With Debian moving to systemd, I am looking back at Slackware
and now GNU should systemd become intolerable.  As Slackware has a
rudimentary concept of package management, Guix seems like a good fit.
At this time this is all a fun experiment for me.

Thanks!

- Nate

-- 

"The optimist proclaims that we live in the best of all
possible worlds.  The pessimist fears this is true."

Ham radio, Linux, bikes, and more: http://www.n0nb.us



Re: [PATCH] gnu: Add dfu-programmer

2014-09-30 Thread Manolis Ragkousis
On 29 September 2014 19:09, Ludovic Courtès  wrote:
> As discussed on #guix, it might be good to move it to a ‘flashing-tools’
> module or something?
Done

> Rather “Device firmware update programmer for Atmel chips”.
Done

> Please wrap lines to less than 80 chars.
Done

> I think the bug is rather that pkg-config is missing, because libusb.pc
> has this line:
>
>   Cflags: -I${includedir}/libusb-1.0
>
> Could you try adding it as a native input and report back?

I did but nothing changed, still couldn't find libusb.h .
In their mailing list there was one such problem, for the previous
version, but they didn't suggested any solution on the issue.
http://sourceforge.net/p/dfu-programmer/mailman/message/30507932/

Updated patch.

Manolis
From 7f17acea56a32013574db6b755fc1a2362c1addc Mon Sep 17 00:00:00 2001
From: Manolis Ragkousis 
Date: Mon, 29 Sep 2014 13:27:30 +0300
Subject: [PATCH] gnu: Add dfu-programmer

* gnu/packages/flashing-tools.scm (dfu-programmer): New variable.
* gnu/packages/patches/dfu-programmer-fix-libusb.patch: New patch.
* gnu-system.am (dist_patch_DATA): Add it.
---
 gnu-system.am  |  1 +
 gnu/packages/flashing-tools.scm| 23 +
 .../patches/dfu-programmer-fix-libusb.patch| 57 ++
 3 files changed, 81 insertions(+)
 create mode 100644 gnu/packages/patches/dfu-programmer-fix-libusb.patch

diff --git a/gnu-system.am b/gnu-system.am
index 642751c..94d8624 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -319,6 +319,7 @@ dist_patch_DATA =		\
   gnu/packages/patches/cursynth-wave-rand.patch			\
   gnu/packages/patches/dbus-localstatedir.patch			\
   gnu/packages/patches/diffutils-gets-undeclared.patch		\
+  gnu/packages/patches/dfu-programmer-fix-libusb.patch		\
   gnu/packages/patches/doxygen-test.patch			\
   gnu/packages/patches/doxygen-tmake.patch			\
   gnu/packages/patches/duplicity-piped-password.patch		\
diff --git a/gnu/packages/flashing-tools.scm b/gnu/packages/flashing-tools.scm
index d2f1b46..648430a 100644
--- a/gnu/packages/flashing-tools.scm
+++ b/gnu/packages/flashing-tools.scm
@@ -104,3 +104,26 @@ programmer devices.")
 EEPROM contents of AVR microcontrollers using the in-system programming
 technique (ISP).")
 (license gpl2+)))
+
+(define-public dfu-programmer
+  (package
+(name "dfu-programmer")
+(version "0.7.0")
+(source
+ (origin
+  (method url-fetch)
+  (uri (string-append "mirror://sourceforge/dfu-programmer/dfu-programmer-"
+  version ".tar.gz"))
+  (sha256
+   (base32
+"17lglglk5xrqd2n0impg5bkq4j96qc51cw3kzcghzmzmn6fvg3gf"))
+  (patches (list (search-patch "dfu-programmer-fix-libusb.patch")
+(build-system gnu-build-system)
+(inputs
+ `(("libusb" ,libusb)))
+(home-page "http://dfu-programmer.github.io/";)
+(synopsis "Device firmware update programmer for Atmel chips")
+(description
+ "Dfu-programmer is a multi-platform command-line programmer for Atmel
+(8051, AVR, XMEGA & AVR32) chips with a USB bootloader supporting ISP")
+(license gpl2+)))
diff --git a/gnu/packages/patches/dfu-programmer-fix-libusb.patch b/gnu/packages/patches/dfu-programmer-fix-libusb.patch
new file mode 100644
index 000..e9e21f3
--- /dev/null
+++ b/gnu/packages/patches/dfu-programmer-fix-libusb.patch
@@ -0,0 +1,57 @@
+Dfu-programmer cannot cannot find libusb. This patch fixes that.
+
+diff --git a/src/dfu-device.h b/src/dfu-device.h
+index bbdfa99..31af0e8 100644
+--- a/src/dfu-device.h
 b/src/dfu-device.h
+@@ -6,7 +6,7 @@
+ #endif
+ #include 
+ #ifdef HAVE_LIBUSB_1_0
+-#include 
++#include 
+ #else
+ #include 
+ #endif
+
+diff --git a/src/main.c b/src/main.c
+index ef2aa16..dcc3636 100644
+--- a/src/main.c
 b/src/main.c
+@@ -24,7 +24,7 @@
+ #include 
+ #include 
+ #ifdef HAVE_LIBUSB_1_0
+-#include 
++#include 
+ #else
+ #include 
+ #endif
+
+diff --git a/src/dfu.c b/src/dfu.c
+index 7dbcc57..952e896 100644
+--- a/src/dfu.c
 b/src/dfu.c
+@@ -27,7 +27,7 @@
+ #include 
+ #include 
+ #ifdef HAVE_LIBUSB_1_0
+-#include 
++#include 
+ #else
+ #include 
+ #endif
+
+diff --git a/src/dfu.h b/src/dfu.h
+index 2a159e8..63510f2 100644
+--- a/src/dfu.h
 b/src/dfu.h
+@@ -25,7 +25,7 @@
+ # include 
+ #endif
+ #ifdef HAVE_LIBUSB_1_0
+-#include 
++#include 
+ #else
+ #include 
+ #endif
-- 
2.1.1