[PATCH 0/2] Update GNU Scientific Library

2015-11-01 Thread Efraim Flashner
GSL has an update to 2.0. As part of the update we no longer need the two
patches that modified the source, and the tests for i686-linux passed when
I tried `guix build gsl -s i686-linux`, so I added a patch to re-enable them.
I haven't written such a complex commit message so I wanted to make sure I got
everything correct.

Efraim Flashner (2):
  gnu: gsl: Update to 2.0.
  gnu: gsl: Enable tests.

 gnu-system.am|  2 -
 gnu/packages/maths.scm   | 21 ++
 gnu/packages/patches/gsl-poly-test-fix-pt1.patch | 84 
 gnu/packages/patches/gsl-poly-test-fix-pt2.patch | 27 
 4 files changed, 4 insertions(+), 130 deletions(-)
 delete mode 100644 gnu/packages/patches/gsl-poly-test-fix-pt1.patch
 delete mode 100644 gnu/packages/patches/gsl-poly-test-fix-pt2.patch

-- 
2.6.2




[PATCH 1/2] gnu: gsl: Update to 2.0.

2015-11-01 Thread Efraim Flashner
* gnu/packages/maths.scm (gsl): Update to 2.0.
  [source]: Remove patches.
* gnu/packages/patches/gsl-poly-test-fix-pt1.patch: Remove file.
* gnu/packages/patches/gsl-poly-test-fix-pt2.patch: Remove file.
* gnu-system.am (dist_patch_DATA): Remove patch.
---
 gnu-system.am|  2 -
 gnu/packages/maths.scm   |  6 +-
 gnu/packages/patches/gsl-poly-test-fix-pt1.patch | 84 
 gnu/packages/patches/gsl-poly-test-fix-pt2.patch | 27 
 4 files changed, 2 insertions(+), 117 deletions(-)
 delete mode 100644 gnu/packages/patches/gsl-poly-test-fix-pt1.patch
 delete mode 100644 gnu/packages/patches/gsl-poly-test-fix-pt2.patch

diff --git a/gnu-system.am b/gnu-system.am
index 3b7e62c..2a1ecf3 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -486,8 +486,6 @@ dist_patch_DATA =   
\
   gnu/packages/patches/grep-CVE-2015-1345.patch\
   gnu/packages/patches/grub-gets-undeclared.patch  \
   gnu/packages/patches/grub-freetype.patch \
-  gnu/packages/patches/gsl-poly-test-fix-pt1.patch \
-  gnu/packages/patches/gsl-poly-test-fix-pt2.patch \
   gnu/packages/patches/guile-1.8-cpp-4.5.patch \
   gnu/packages/patches/guile-arm-fixes.patch   \
   gnu/packages/patches/guile-default-utf8.patch\
diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index b4b930d..1aba362 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -149,7 +149,7 @@ semiconductors.")
 (define-public gsl
   (package
 (name "gsl")
-(version "1.16")
+(version "2.0")
 (source
  (origin
   (method url-fetch)
@@ -157,9 +157,7 @@ semiconductors.")
   version ".tar.gz"))
   (sha256
(base32
-"0lrgipi0z6559jqh82yx8n4xgnxkhzj46v96dl77hahdp58jzg3k"))
-  (patches (map search-patch '("gsl-poly-test-fix-pt1.patch"
-   "gsl-poly-test-fix-pt2.patch")
+"0bfahlsgil0695104a44c3c8vjkyvxmg3s92371fddcrj6qz0qg3"
 (build-system gnu-build-system)
 (arguments
  `(#:parallel-tests? #f
diff --git a/gnu/packages/patches/gsl-poly-test-fix-pt1.patch 
b/gnu/packages/patches/gsl-poly-test-fix-pt1.patch
deleted file mode 100644
index 3d1ed42..000
--- a/gnu/packages/patches/gsl-poly-test-fix-pt1.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From 9cc12d0377dd634b1b97954d076b715f982853b7 Mon Sep 17 00:00:00 2001
-From: Patrick Alken 
-Date: Fri, 4 Apr 2014 13:36:16 -0600
-Subject: [PATCH] bug fix in sorting of complex numbers (bug #39055)
-

- poly/test.c | 49 ++---
- 1 file changed, 30 insertions(+), 19 deletions(-)
-
-diff --git a/poly/test.c b/poly/test.c
-index 9c147f6..d090802 100644
 a/poly/test.c
-+++ b/poly/test.c
-@@ -25,11 +25,21 @@
- #include 
- #include 
- 
-+/* sort by Re(z) then by Im(z) */
- static int
- cmp_cplx(const double *a, const double *b)
- {
--  double t = (a[0] * a[0] + a[1] * a[1]) - (b[0] * b[0] + b[1] * b[1]);
--  return t < 0.0 ? -1 : t > 0.0 ? 1 : 0;
-+  double r = a[0] - b[0];
-+
-+  if (r == 0.0)
-+{
-+  double t = a[1] - b[1];
-+  return t < 0.0 ? -1 : t > 0.0 ? 1 : 0;
-+}
-+  else if (r < 0.0)
-+return -1;
-+  else
-+return 1;
- }
- 
- int
-@@ -534,25 +544,26 @@ main (void)
-Problem reported by Munagala Ramanath (bug #39055)
- */
- 
--double a[16] = { 32, -48, -8, 28, -8, 16, -16, 12, -16, 6, 10, -17, 10, 
2, -4, 1 };
-+double a[16] = { 32, -48, -8, 28, -8, 16, -16, 12,
-+-16, 6, 10, -17, 10, 2, -4, 1 };
- double z[16*2];
- 
--double expected[16*20] = {
-- 1.,  0.0,
-- 1.,  0.0,
---1.,  0.0,
--   -0.65893856175240950,  0.83459757287426684,
--   -0.65893856175240950, -0.83459757287426684,
--  -0.070891117403341281,  -1.1359249087587791,
--  -0.070891117403341281,   1.1359249087587791,
-- 1.1142366961812986, -0.48083981203389980,
-- 1.1142366961812986,  0.48083981203389980,
---1.3066982484920768,  0.0,
--0.57284747839410854,   1.1987808988289705,
--0.57284747839410854,  -1.1987808988289705,
---1.6078107423472359,  0.0,
-- 2.,  0.0,
-- 2.,  0.0 };
-+double expected[16*2] = {
-+ -1.6078107423472359,0.0,
-+ -1.3066982484920768,0.0,
-+ -1.,0.0,
-+ -0.65893856175240950,  -0.83459757287426684,
-+ -0.65893856175240950,   0.83459757287426684,
-+ -0.070891117403341281, -1.1359249087587791,
-+ -0.070891117403341281,  1.1359249087587791,
-+

[PATCH 2/2] gnu: gsl: Enable tests.

2015-11-01 Thread Efraim Flashner
* gnu/packages/maths.scm (gsl): Enable tests for i686-linux.
---
 gnu/packages/maths.scm | 15 ++-
 1 file changed, 2 insertions(+), 13 deletions(-)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 1aba362..4eeb39d 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -8,6 +8,7 @@
 ;;; Copyright © 2015 Ricardo Wurmus 
 ;;; Copyright © 2015 Sou Bunnbu 
 ;;; Copyright © 2015 Mark H Weaver 
+;;; Copyright © 2015 Efraim Flashner 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -160,19 +161,7 @@ semiconductors.")
 "0bfahlsgil0695104a44c3c8vjkyvxmg3s92371fddcrj6qz0qg3"
 (build-system gnu-build-system)
 (arguments
- `(#:parallel-tests? #f
-   #:phases
-(alist-replace
- 'configure
- (lambda* (#:key target system outputs #:allow-other-keys #:rest args)
-   (let ((configure (assoc-ref %standard-phases 'configure)))
- ;; disable numerically unstable test on i686, see thread at
- ;; http://lists.gnu.org/archive/html/bug-gsl/2011-11/msg00019.html
- (if (string=? (or target system) "i686-linux")
- (substitute* "ode-initval2/Makefile.in"
-   (("TESTS = \\$\\(check_PROGRAMS\\)") "TESTS =")))
- (apply configure args)))
- %standard-phases)))
+ `(#:parallel-tests? #f))
 (home-page "http://www.gnu.org/software/gsl/";)
 (synopsis "Numerical library for C and C++")
 (description
-- 
2.6.2




[PATCH] build: Add a scheme custom test driver using SRFI-64.

2015-11-01 Thread Mathieu Lirzin
Hello Guix,

While reading the Automake manual I have discovered that it provides an
API for custom test drivers, so I've tried to implement something for
the scheme API for test suites (SRFI-64) which Guix is using.  The
result provides support for multiple test cases in a single file, and
allow ‘make check’ display the results individually:

  PASS: tests/base32.scm - bytevector->base32-string
  PASS: tests/base32.scm - base32-string->bytevector
  PASS: tests/base32.scm - nix-base32-string->bytevector
  PASS: tests/base32.scm - &invalid-base32-character
  SKIP: tests/base32.scm - sha256 & bytevector->nix-base32-string
  PASS: tests/base64.scm - empty string

It is now possible to define individual XFAIL test cases:

  (test-expect-fail "absurd")
  (test-assert "absurd" (= 0 1))

And the ‘.log’ files now use somekind of recutils format:

  test-name: url-fetch, file
  location: /home/mthl/src/gnu/guix/tests/builders.scm:78
  source:
  + (test-assert
  +   "url-fetch, file"
  +   (let* ((file (search-path %load-path "guix.scm"))
  +  (hash (call-with-input-file file port-sha256))
  +  (out (url-fetch* %store file 'sha256 hash)))
  + (and (file-exists? out) (valid-path? %store out
  value: #t
  result: PASS

Finally the ‘.log’ files are no longer fragmented between
“${top_srcdir}” and “tests/”.  If something went wrong (FAIL, SKIP,
XPASS) then the entire log file is copied in ‘test-suite.log’ so no need
to ask for an additional file when someone is reporting some ‘make
check’ error.

One caveat is that ‘tests/cpio.scm‘ is now failing.

Since this script is not intented to be exclusively used by Guix, I have
used a generic copyright notice.  I guess Guix is the best place to
challenge and improve it, but IMO it will be better hosted elsewhere
like in Gnulib.  Opinions?

Comments are welcome!

--
Mathieu Lirzin


>From 977e0586a6689df204fd9b522f8508ec318180c0 Mon Sep 17 00:00:00 2001
From: Mathieu Lirzin 
Date: Mon, 26 Oct 2015 23:47:24 +0100
Subject: [PATCH] build: Add a scheme custom test driver using SRFI-64.

This provides support for multiple scheme test cases in a unique file and
fixes the fragmentation of '.log' files.

* build-aux/test-driver.scm: New file.
* Makefile.am (SCM_LOG_DRIVER): New variable.
  (SCM_LOG_COMPILER, AM_SCM_LOG_FLAGS): Delete variables.
  (AM_TESTS_ENVIRONMENT): Set GUILE_AUTO_COMPILE to 0.
* tests/base32.scm, tests/build-utils.scm, tests/builders.scm,
  tests/challenge.scm, tests/containers.scm, tests/cpan.scm,
  tests/cpio.scm, tests/cran.scm, tests/derivations.scm, tests/elpa.scm,
  tests/file-systems.scm, tests/gem.scm, tests/gexp.scm,
  tests/graph.scm, tests/gremlin.scm, tests/hackage.scm, tests/hash.scm,
  tests/lint.scm, tests/monads.scm, tests/nar.scm, tests/packages.scm,
  tests/pk-crypto.scm, tests/pki.scm, tests/profiles.scm,
  tests/publish.scm, tests/pypi.scm, tests/records.scm,
  tests/scripts.scm, tests/services.scm, tests/sets.scm, tests/size.scm,
  tests/snix.scm, tests/store.scm, tests/substitute.scm,
  tests/syscalls.scm, tests/ui.scm, tests/union.scm, tests/utils.scm:
  Don't exit at the end of each test.
---
 Makefile.am   |   6 +-
 build-aux/test-driver.scm | 157 ++
 tests/base32.scm  |   3 -
 tests/build-utils.scm |   3 -
 tests/builders.scm|   3 -
 tests/challenge.scm   |   3 -
 tests/containers.scm  |   3 -
 tests/cpan.scm|   3 -
 tests/cpio.scm|   3 -
 tests/cran.scm|   3 -
 tests/derivations.scm |   3 -
 tests/elpa.scm|   3 -
 tests/file-systems.scm|   3 -
 tests/gem.scm |   3 -
 tests/gexp.scm|   3 -
 tests/graph.scm   |   3 -
 tests/gremlin.scm |   3 -
 tests/hackage.scm |   3 -
 tests/hash.scm|   3 -
 tests/lint.scm|   3 -
 tests/monads.scm  |   3 -
 tests/nar.scm |   3 -
 tests/packages.scm|   3 -
 tests/pk-crypto.scm   |   3 -
 tests/pki.scm |   3 -
 tests/profiles.scm|   3 -
 tests/publish.scm |   3 -
 tests/pypi.scm|   3 -
 tests/records.scm |   3 -
 tests/scripts.scm |   3 -
 tests/services.scm|   3 -
 tests/sets.scm|   3 -
 tests/size.scm|   3 -
 tests/snix.scm|   3 -
 tests/store.scm   |   3 -
 tests/substitute.scm  |   3 -
 tests/syscalls.scm|   3 -
 tests/ui.scm  |   3 -
 tests/union.scm   |   3 -
 tests/utils.scm   |   3 -
 40 files changed, 160 insertions(+), 117 deletions(-)
 create mode 100644 build-aux/test-driver.scm

diff --git a/Makefile.am b/Makefile.am
index 4f90b1d..2db6b25 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -268,10 +268,10 @@ TESTS = $(SCM_TESTS) $(SH_TESTS)
 
 TEST_EXTENSIONS = .scm .sh
 
-AM_TESTS_ENVIRONMENT = abs_top_srcdir="$(abs_top_srcdir)"
+AM_TESTS_ENVIRONMENT = abs_top_srcdir="$(abs_top_srcdir)" GUI

Re: [PATCH 1/2] gnu: gsl: Update to 2.0.

2015-11-01 Thread Ricardo Wurmus

Efraim Flashner  writes:

> * gnu/packages/maths.scm (gsl): Update to 2.0.
>   [source]: Remove patches.
> * gnu/packages/patches/gsl-poly-test-fix-pt1.patch: Remove file.
> * gnu/packages/patches/gsl-poly-test-fix-pt2.patch: Remove file.
> * gnu-system.am (dist_patch_DATA): Remove patch.
^  “patches” / “them”?

Does the version bump mean that there have been API changes to GSL?  I
wonder if packages depending on GSL still build.

~~ Ricardo




Re: [PATCH 2/2] gnu: gsl: Enable tests.

2015-11-01 Thread Ricardo Wurmus

Efraim Flashner  writes:

> * gnu/packages/maths.scm (gsl): Enable tests for i686-linux.

I think this should be

  * gnu/packages/maths.scm (gsl)[arguments]: Enable tests for i686-linux.

Looks good otherwise.

~~ Ricardo




Re: [PATCH 1/2] gnu: gsl: Update to 2.0.

2015-11-01 Thread Efraim Flashner
On Sun, 01 Nov 2015 10:06:25 +0100
Ricardo Wurmus  wrote:

> Efraim Flashner  writes:
> 
> > * gnu/packages/maths.scm (gsl): Update to 2.0.
> >   [source]: Remove patches.
> > * gnu/packages/patches/gsl-poly-test-fix-pt1.patch: Remove file.
> > * gnu/packages/patches/gsl-poly-test-fix-pt2.patch: Remove file.
> > * gnu-system.am (dist_patch_DATA): Remove patch.  
> ^  “patches” / “them”?
> 
> Does the version bump mean that there have been API changes to GSL?  I
> wonder if packages depending on GSL still build.
> 
> ~~ Ricardo
> 

I tested pspp and it build without any problems

https://lists.gnu.org/archive/html/info-gnu/2015-10/msg00014.html :
"Version 2.0 of the GNU Scientific Library (GSL) is now available. GSL
provides a large collection of routines for numerical computing in C.
The major version number was increased, since a number of internal
workspaces have changed and so existing binaries must be recompiled
against this new library. There are also a small number of API changes
and deprecated functions."

-- 
Efraim Flashner  אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted


pgpArooTcET9I.pgp
Description: OpenPGP digital signature


Re: [PATCH 1/2] gnu: gsl: Update to 2.0.

2015-11-01 Thread Andreas Enge
Hello,

just nitpicking on the commit message:

On Sun, Nov 01, 2015 at 10:09:59AM +0200, Efraim Flashner wrote:
> * gnu/packages/patches/gsl-poly-test-fix-pt1.patch: Remove file.
> * gnu/packages/patches/gsl-poly-test-fix-pt2.patch: Remove file.

This is usually:
* gnu/packages/patches/gsl-poly-test-fix-pt1.patch,
  gnu/packages/patches/gsl-poly-test-fix-pt2.patch: Remove files.

I wonder if it should not even be (question to the commit log wizards):
* gnu/packages/patches/{gsl-poly-test-fix-pt1.patch,
  gsl-poly-test-fix-pt2.patch}: Remove files.
?

> * gnu/packages/maths.scm (gsl): Enable tests for i686-linux.

Maybe "Reenable test"? as there is only one and not all of them were
disabled previously?

Andreas




Re: Aarddict

2015-11-01 Thread Andreas Enge
On Wed, Oct 28, 2015 at 04:08:56PM +0100, Ludovic Courtès wrote:
> Removing Aarddict is fine with me, especially if upstream has more or
> less abandoned the current code base.
> Maybe wait a couple more days before removing it, just in case.

Done in commit 08859404c0a52af8ef9a083399814d081774893a.

> Maybe we can leave ‘python2-pyqt-4’, though.

Okay. I see it as progress towards removing qt-4, but anyway, there are
other packages left needing qt-4 yet.

Andreas




Re: 2 (possible) problems in documentation

2015-11-01 Thread Alex Kost
Alex Vong (2015-11-01 06:22 +0300) wrote:

> On 01/11/2015, Alex Kost  wrote:
>> Alex Vong (2015-10-31 14:27 +0300) wrote:
[...]
>>> 2. In
>>> ,
>>> it said "To that end, all the command-line tools can be used even if
>>> you have not run make install.". However, in the case of "guix pull",
>>> it is not true. Even if "guix pull" does run properly, it will not
>>> update the source tree you have downloaded, so you end up with running
>>> the original compiled version of Guix. Obviously, I was a victim :)
>>
>> Sorry, I don't understand what you mean here.  "guix pull" can't update
>> the source tree you downloaded.  It fetches the latest guix source,
>> compiles it, put it to the store and link "~/.config/guix/latest" to it.
>> Then the Guix code from this directory when you run "guix ..." commands.
>>
>> If you use the described "pre-inst-env" method, the code from the git
>> directory is used instead, and running "guix pull" doesn't effect
>> ".../pre-inst-env guix" commands in any way.  Here instead of "guix
>> pull" you use "git pull" and "make".
>>
> What I mean is "guix pull" only works after Guix is installed, so what
> the documentation says, "To that end, all the command-line tools can
> be used even if you have not run make install", is inaccurate. Should
> we note this in the documentation?

IMO it is accurate, because "./pre-inst-env guix pull" also works; it
just doesn't work the way you thought.  But if you find the
documentation confusing you are welcome to improve it :-)

-- 
Alex



Re: 2 (possible) problems in documentation

2015-11-01 Thread Mathieu Lirzin
Hi,

Alex Vong  writes:

> On 01/11/2015, Alex Kost  wrote:
>> I think this on-line manual is for the current version (0.8.3).  The
>> typo you mention was fixed in the git repo:
>> 
>>
> Thanks! I wasn't aware that the web version not being up to date.

The online manual is up to date with the current release but not with
the master branch.  Maybe we could provide a link to it like Guile:

  https://www.gnu.org/software/guile/docs/docs.html

> What I mean is "guix pull" only works after Guix is installed, so what
> the documentation says, "To that end, all the command-line tools can
> be used even if you have not run make install", is inaccurate. Should
> we note this in the documentation?

I think you mean that ‘pre-inst-env guix pull’ does not work if you have
not run ‘make install’ before?  What do you think of the following
patch?

>From ee2f4467d84ad9516b14c7bd14f821e4bec443cc Mon Sep 17 00:00:00 2001
From: Mathieu Lirzin 
Date: Sun, 1 Nov 2015 16:27:07 +0100
Subject: [PATCH] doc: Add an exception in "Running Guix Before It Is
 Installed".

* doc/contributing.texi (Running Guix Before It Is Installed): Add an
  exception footnote for `guix pull'.

Suggested-by: Alex Vong 
---
 doc/contributing.texi | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/doc/contributing.texi b/doc/contributing.texi
index f855daf..d033b1f 100644
--- a/doc/contributing.texi
+++ b/doc/contributing.texi
@@ -72,8 +72,9 @@ test the changes made in your local source tree checkout without
 actually installing them.  So that you can distinguish between your
 ``end-user'' hat and your ``motley'' costume.
 
-To that end, all the command-line tools can be used even if you have not
-run @code{make install}.  To do that, prefix each command with
+To that end, all the command-line tools@footnote{@code{guix pull} is an
+exception (@pxref{Invoking guix pull}).} can be used even if you have
+not run @code{make install}.  To do that, prefix each command with
 @command{./pre-inst-env} (the @file{pre-inst-env} script lives in the
 top build tree of Guix), as in:
 
-- 
2.6.1


Thanks,

--
Mathieu Lirzin


Re: 2 (possible) problems in documentation

2015-11-01 Thread Mathieu Lirzin
Hi again,

Mathieu Lirzin  writes:

> What do you think of the following patch?
>
>>From ee2f4467d84ad9516b14c7bd14f821e4bec443cc Mon Sep 17 00:00:00 2001
> From: Mathieu Lirzin 
> Date: Sun, 1 Nov 2015 16:27:07 +0100
> Subject: [PATCH] doc: Add an exception in "Running Guix Before It Is
>  Installed".
>
> * doc/contributing.texi (Running Guix Before It Is Installed): Add an
>   exception footnote for `guix pull'.
>
> Suggested-by: Alex Vong 

Please ignore this patch, my mind was confused. :)

--
Mathieu Lrzin




polkit & udisks

2015-11-01 Thread Ludovic Courtès
Hi!

Commit 222e331 changes ‘polkit-service-type’ so that other services can
extend it with new polkit “actions” and “rules,” which colord and
elogind do.

Commit 2b9e0a9 adds UDisks to ‘%desktop-services’.  Now, one can run
things like:

  udisksctl status
  udisksctl mount -b /dev/foo

Hopefully GUIs (Xfce?) automatically detect things like USB keys that
are inserted and might even be able to mount/unmount them (though I
think that, since this is restricted to people sitting at the computer,
and since we don’t use pam_elogind yet, that only works for ‘root’ ATM.)

Anyway, I would be glad if desktop-savvy people could report back!

This addresses some of the problems that Andy identified when adding
polkit and friends this summer, which led to the service refactoring.
So it sort of closes the loop.

Thanks,
Ludo’.



Re: [PATCH] build: Add a scheme custom test driver using SRFI-64.

2015-11-01 Thread Ludovic Courtès
Mathieu Lirzin  skribis:

> While reading the Automake manual I have discovered that it provides an
> API for custom test drivers, so I've tried to implement something for
> the scheme API for test suites (SRFI-64) which Guix is using.  The
> result provides support for multiple test cases in a single file, and
> allow ‘make check’ display the results individually:
>
>   PASS: tests/base32.scm - bytevector->base32-string
>   PASS: tests/base32.scm - base32-string->bytevector
>   PASS: tests/base32.scm - nix-base32-string->bytevector
>   PASS: tests/base32.scm - &invalid-base32-character
>   SKIP: tests/base32.scm - sha256 & bytevector->nix-base32-string
>   PASS: tests/base64.scm - empty string

Awesome!  Are the “inner” tests displayed by default?  Or is there some
environment variable to control that?

I’d prefer the default to display only file names, as is currently the
case (it’s more concise.)

> And the ‘.log’ files now use somekind of recutils format:

Cool!

> Finally the ‘.log’ files are no longer fragmented between
> “${top_srcdir}” and “tests/”.  If something went wrong (FAIL, SKIP,
> XPASS) then the entire log file is copied in ‘test-suite.log’ so no need
> to ask for an additional file when someone is reporting some ‘make
> check’ error.

Nice.  “Running the Test Suite” needs to be updated accordingly.

> One caveat is that ‘tests/cpio.scm‘ is now failing.

Why is that?  Does it relate to this change?

> Since this script is not intented to be exclusively used by Guix, I have
> used a generic copyright notice.  I guess Guix is the best place to
> challenge and improve it, but IMO it will be better hosted elsewhere
> like in Gnulib.  Opinions?

I think we could start using it and testing it for a while in Guix, and
eventually submit it for inclusion in Gnulib once we are more confident.

> From 977e0586a6689df204fd9b522f8508ec318180c0 Mon Sep 17 00:00:00 2001
> From: Mathieu Lirzin 
> Date: Mon, 26 Oct 2015 23:47:24 +0100
> Subject: [PATCH] build: Add a scheme custom test driver using SRFI-64.
>
> This provides support for multiple scheme test cases in a unique file and
> fixes the fragmentation of '.log' files.
>
> * build-aux/test-driver.scm: New file.
> * Makefile.am (SCM_LOG_DRIVER): New variable.
>   (SCM_LOG_COMPILER, AM_SCM_LOG_FLAGS): Delete variables.
>   (AM_TESTS_ENVIRONMENT): Set GUILE_AUTO_COMPILE to 0.
> * tests/base32.scm, tests/build-utils.scm, tests/builders.scm,
>   tests/challenge.scm, tests/containers.scm, tests/cpan.scm,
>   tests/cpio.scm, tests/cran.scm, tests/derivations.scm, tests/elpa.scm,
>   tests/file-systems.scm, tests/gem.scm, tests/gexp.scm,
>   tests/graph.scm, tests/gremlin.scm, tests/hackage.scm, tests/hash.scm,
>   tests/lint.scm, tests/monads.scm, tests/nar.scm, tests/packages.scm,
>   tests/pk-crypto.scm, tests/pki.scm, tests/profiles.scm,
>   tests/publish.scm, tests/pypi.scm, tests/records.scm,
>   tests/scripts.scm, tests/services.scm, tests/sets.scm, tests/size.scm,
>   tests/snix.scm, tests/store.scm, tests/substitute.scm,
>   tests/syscalls.scm, tests/ui.scm, tests/union.scm, tests/utils.scm:
>   Don't exit at the end of each test.

AIUI each tests/foo.scm file is still run with its own Guile instance,
in ./test-env, right?  (This is important.  It also means tests can run
in parallel.)

If this is OK, it LGTM.

However, I’m unsure if we should push it now, or after the release.  On
one hand, I’d rather avoid potentially disrupting changes like this
now.  On the other hand, since it makes it easier (and different) to
report test failures, it’s nice.

How confident are you?  :-)

What do others think?

Thanks!
Ludo’.



Re: [PATCH] emacs: Add completions for '--type' option of 'refresh' popup.

2015-11-01 Thread Ludovic Courtès
Alex Kost  skribis:

> Ludovic Courtès (2015-10-29 23:14 +0300) wrote:

[...]

>> You could use #:autoload, but only for ‘%updaters’ because
>> ‘upstream-updater-name’ is a macro so it needs to be available at
>> expansion time.
>
> I looked at (info "(guile) Using Guile Modules") and it has the following:
>
>   An autoload is a good way to put off loading a big module
>   until it’s really needed, for instance for faster startup or
>   if it will only be needed in certain circumstances.
>
>   ‘@’ can do a similar thing (see Using Guile Modules), but
>   in that case an ‘@’ form must be written every time a binding
>   from the module is used.
>
> To me it sounds like ‘@’ does the same thing as ‘#:autoload’, no?

I guess I was confused.  A simple example confirms what the manual
explains:

--8<---cut here---start->8---
$ guild compile t.scm
wrote `/home/ludo/.cache/guile/ccache/2.0-LE-8-2.0/home/ludo/src/guix/t.scm.go'
$ guile t.scm
$ cat t.scm
(define (foo)
  (@ (asdfasdfa) sdfsf))
--8<---cut here---end--->8---

> Also #:autoload should be used inside (define-module ...), but
> ‘guix-main.scm’ does not define a module.

Oh, right, I had overlooked that.

So yes, you can go ahead with your initial approach.

Thanks, and sorry for the confusion!

Ludo’.



Re: [PATCH 1/3] emacs: Enable 'guix-build-log-mode' for build log files.

2015-11-01 Thread Ludovic Courtès
Alex Kost  skribis:

> From 11fea59d41063b3511a84a0d783cfa2016ed68c4 Mon Sep 17 00:00:00 2001
> From: Alex Kost 
> Date: Sat, 31 Oct 2015 21:36:41 +0300
> Subject: [PATCH 1/2] emacs: Add 'guix-hash-char-regexp'.
>
> * emacs/guix-utils.el (guix-hash-char-regexp): New constant.
> * emacs/guix-prettify.el (guix-prettify-regexp): Use it.

LGTM.  The only possible downside is if it noticeably slows things down,
which may be the case.  Have you seen any difference?

If it happens to be slower, I’m fine with the current (sloppier)
variant.

> From a9a1b1ef7c272a188745d367745f9ef4fc155be9 Mon Sep 17 00:00:00 2001
> From: Alex Kost 
> Date: Thu, 29 Oct 2015 20:48:53 +0300
> Subject: [PATCH 2/2] emacs: Enable 'guix-build-log-mode' for build log files.
>
> * emacs/guix-build-log.el (auto-mode-alist): Add 'guix-build-log-mode'
>   to 'auto-mode-alist'.

LGTM, thanks!

Ludo’.



Re: [PATCH] emacs: Enable 'guix-build-log-minor-mode' in shell buffers.

2015-11-01 Thread Ludovic Courtès
Alex Kost  skribis:

> Not sure if it's really worth, but this can be done the same way as with
> enabling 'guix-devel-mode' (as in the attached patch).  So it can be
> disabled by:
>
>   (setq guix-build-log-minor-mode-activate nil)

OK.

> But then why don't we enable 'guix-prettify-mode' by default?  As for
> me, I don't think all these features should be automatically enabled,
> dunno what is considered to be a good default: "full-featured" or "as
> simple as possible".

I’m mostly in favor of full-featured.  The Emacs tradition is/was to
provide something that had to be explicitly configured to get the
features: in the old days, font-locking was disabled by default, and
Gnus would do absolutely nothing until you had spent a couple of days
configuring it.

However, given the wealth of features now provided by guix.el, I think
it’s best to enable most of them by default, at least those that are not
controversial.  Otherwise, the risk is that people just won’t know about
them.

‘guix-build-log-minor-mode’ is clearly one of the things to enable by
default IMO.  The situation is less clear for ‘guix-prettify-mode’
because it changes the behavior of Emacs in a way that could be
surprising to a newcomer.

WDYT?

> From 3991193fcc6700b1e198d5befcb6b1c651839ae0 Mon Sep 17 00:00:00 2001
> From: Alex Kost 
> Date: Sat, 31 Oct 2015 22:01:45 +0300
> Subject: [PATCH] emacs: Enable 'guix-build-log-minor-mode' in shell buffers.
>
> * emacs/guix-build-log.el (guix-build-log-minor-mode-activate): New variable.
>   (guix-build-log-minor-mode-activate-maybe): New function.
> * emacs/guix-init.el: Add it to 'shell-mode-hook'.
> * doc/emacs.texi (Emacs Build Log): Mention it.

OK!

Ludo’.



[PATCH] gnu: Add nestopiaue.

2015-11-01 Thread Taylan Ulrich Bayırlı/Kammer
Any opinions on how to handle the xdg-desktop-menu(1) call in the
Makefile?  So far I just remove it.  AFAIUI it's the kind of thing our
profile generator handles.

>From 6bd3c34da4e96ffcd5df34cd5b44adf5ab58086a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
 
Date: Sun, 1 Nov 2015 19:38:53 +0100
Subject: [PATCH] gnu: Add nestopiaue.

---
 gnu/packages/games.scm | 60 ++
 1 file changed, 60 insertions(+)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 546944a..87358e2 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -38,10 +38,12 @@
   #:use-module (guix svn-download)
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
+  #:use-module (gnu packages backup)
   #:use-module (gnu packages base)
   #:use-module (gnu packages admin)
   #:use-module (gnu packages audio)
   #:use-module (gnu packages boost)
+  #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages fribidi)
   #:use-module (gnu packages game-development)
   #:use-module (gnu packages gettext)
@@ -1212,3 +1214,61 @@ world}, @uref{http://evolonline.org, Evol Online} and
 ;; "data/themes/{golden-delicious,jewelry}/*" are under CC-BY-SA.
 ;; The rest is under GPL2+.
 (license (list license:gpl2+ license:zlib license:cc-by-sa4.0
+
+(define-public nestopiaue
+  (package
+(name "nestopiaue")
+(version "1.46.2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/rdanbrook/nestopia/archive/";
+version ".tar.gz"))
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"07h49xwvg61dx20rk5p4r3ax2ar5y0ppvm60cqwqljyi9rdfbh7p"))
+  (modules '((guix build utils)))
+  ;; We don't need libretro for the GNU/Linux build.
+  (snippet
+   '(delete-file-recursively "libretro"
+(build-system gnu-build-system)
+(native-inputs `(("pkg-config" ,pkg-config)
+ ("xdg-utils" ,xdg-utils)))
+(inputs `(("ao" ,ao)
+  ("glu" ,glu)
+  ("gtk+" ,gtk+)
+  ("libarchive" ,libarchive)
+  ("mesa" ,mesa)
+  ("sdl2" ,sdl2)))
+(arguments
+ '(#:phases (modify-phases %standard-phases
+  ;; The Nestopia build system consists solely of a Makefile.
+  (delete 'configure)
+  ;; XXX Should be unnecessary with the next release.
+  (add-before
+   'build 'patch-makefile
+   (lambda _
+ (substitute* "Makefile"
+   (("@mkdir \\$@") "@mkdir -p $@")
+   (("CC =") "CC ?=")
+   (("CXX =") "CXX ?=")
+   (("PREFIX =") "PREFIX ?=")
+   (("^install:\n$")
+"install:\n\tmkdir -p $(BINDIR)\n"
+  (add-before
+   'build 'remove-xdg-desktop-menu-call
+   (lambda _
+ (substitute* "Makefile"
+   (("xdg-desktop-menu install .*") "")
+   #:make-flags (let ((out (assoc-ref %outputs "out")))
+  (list "CC=gcc" "CXX=g++" (string-append "PREFIX=" out)))
+   ;; There are no tests.
+   #:tests? #f))
+(home-page "http://sourceforge.net/projects/nestopiaue/";)
+(synopsis "Nintendo Entertainment System (NES/Famicom) emulator")
+(description
+ "Nestopia UE (Undead Edition) is a fork of the Nintendo Entertainment
+System (NES/Famicom) emulator Nestopia, with enhancements from members of the
+emulation community.  It provides highly accurate emulation.")
+(license license:gpl2+)))
-- 
2.5.0



Re: [PATCH] gnu: Add nestopiaue.

2015-11-01 Thread Taylan Ulrich Bayırlı/Kammer
The homepage was wrong.  Here's an updated patch.

>From f8fcbf5fa4f5616c18df652f93f4b00f85d6f4ea Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
 
Date: Sun, 1 Nov 2015 19:38:53 +0100
Subject: [PATCH] gnu: Add nestopiaue.

---
 gnu/packages/games.scm | 60 ++
 1 file changed, 60 insertions(+)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 546944a..1ba9f3f 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -38,10 +38,12 @@
   #:use-module (guix svn-download)
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
+  #:use-module (gnu packages backup)
   #:use-module (gnu packages base)
   #:use-module (gnu packages admin)
   #:use-module (gnu packages audio)
   #:use-module (gnu packages boost)
+  #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages fribidi)
   #:use-module (gnu packages game-development)
   #:use-module (gnu packages gettext)
@@ -1212,3 +1214,61 @@ world}, @uref{http://evolonline.org, Evol Online} and
 ;; "data/themes/{golden-delicious,jewelry}/*" are under CC-BY-SA.
 ;; The rest is under GPL2+.
 (license (list license:gpl2+ license:zlib license:cc-by-sa4.0
+
+(define-public nestopiaue
+  (package
+(name "nestopiaue")
+(version "1.46.2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/rdanbrook/nestopia/archive/";
+version ".tar.gz"))
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"07h49xwvg61dx20rk5p4r3ax2ar5y0ppvm60cqwqljyi9rdfbh7p"))
+  (modules '((guix build utils)))
+  ;; We don't need libretro for the GNU/Linux build.
+  (snippet
+   '(delete-file-recursively "libretro"
+(build-system gnu-build-system)
+(native-inputs `(("pkg-config" ,pkg-config)
+ ("xdg-utils" ,xdg-utils)))
+(inputs `(("ao" ,ao)
+  ("glu" ,glu)
+  ("gtk+" ,gtk+)
+  ("libarchive" ,libarchive)
+  ("mesa" ,mesa)
+  ("sdl2" ,sdl2)))
+(arguments
+ '(#:phases (modify-phases %standard-phases
+  ;; The Nestopia build system consists solely of a Makefile.
+  (delete 'configure)
+  ;; XXX Should be unnecessary with the next release.
+  (add-before
+   'build 'patch-makefile
+   (lambda _
+ (substitute* "Makefile"
+   (("@mkdir \\$@") "@mkdir -p $@")
+   (("CC =") "CC ?=")
+   (("CXX =") "CXX ?=")
+   (("PREFIX =") "PREFIX ?=")
+   (("^install:\n$")
+"install:\n\tmkdir -p $(BINDIR)\n"
+  (add-before
+   'build 'remove-xdg-desktop-menu-call
+   (lambda _
+ (substitute* "Makefile"
+   (("xdg-desktop-menu install .*") "")
+   #:make-flags (let ((out (assoc-ref %outputs "out")))
+  (list "CC=gcc" "CXX=g++" (string-append "PREFIX=" out)))
+   ;; There are no tests.
+   #:tests? #f))
+(home-page "http://0ldsk00l.ca/nestopia/";)
+(synopsis "Nintendo Entertainment System (NES/Famicom) emulator")
+(description
+ "Nestopia UE (Undead Edition) is a fork of the Nintendo Entertainment
+System (NES/Famicom) emulator Nestopia, with enhancements from members of the
+emulation community.  It provides highly accurate emulation.")
+(license license:gpl2+)))
-- 
2.5.0



Re: [PATCH] build: Add a scheme custom test driver using SRFI-64.

2015-11-01 Thread Mathieu Lirzin
Hi,

l...@gnu.org (Ludovic Courtès) writes:

> Mathieu Lirzin  skribis:
>
>> While reading the Automake manual I have discovered that it provides an
>> API for custom test drivers, so I've tried to implement something for
>> the scheme API for test suites (SRFI-64) which Guix is using.  The
>> result provides support for multiple test cases in a single file, and
>> allow ‘make check’ display the results individually:
>>
>>   PASS: tests/base32.scm - bytevector->base32-string
>>   PASS: tests/base32.scm - base32-string->bytevector
>>   PASS: tests/base32.scm - nix-base32-string->bytevector
>>   PASS: tests/base32.scm - &invalid-base32-character
>>   SKIP: tests/base32.scm - sha256 & bytevector->nix-base32-string
>>   PASS: tests/base64.scm - empty string
>
> Awesome!  Are the “inner” tests displayed by default?  Or is there some
> environment variable to control that?

Yes, each test case is displayed by default.

> I’d prefer the default to display only file names, as is currently the
> case (it’s more concise.)

IMO This would be reasonable to have an option for making the output more
concise since there are 563 test cases in Guix.  this is not part of the
test driver API specification, but it does not seem too hard to add an
additional option to the test driver script like what the TAP driver is
doing:

  
https://www.gnu.org/software/automake/manual/automake.html#Use-TAP-with-the-Automake-test-harness

I think ‘--brief’ could be a good name for this option.  Default
verbosity would specified by adding “AM_SCM_LOG_DRIVER= --brief=yes” in
Makefile.am, then the user can overide that with:

  make check -j4 TESTS=tests/rocket-science.scm SCM_LOG_DRIVER="--brief=no"

>> Finally the ‘.log’ files are no longer fragmented between
>> “${top_srcdir}” and “tests/”.  If something went wrong (FAIL, SKIP,
>> XPASS) then the entire log file is copied in ‘test-suite.log’ so no need
>> to ask for an additional file when someone is reporting some ‘make
>> check’ error.
>
> Nice.  “Running the Test Suite” needs to be updated accordingly.

Thanks for reminding me this.  ;)

>> One caveat is that ‘tests/cpio.scm‘ is now failing.
>
> Why is that?  Does it relate to this change?

I didn't try to debug the problem but it has appeared when I started
messing with redirection of the output/error ports.  Here is the failure
output.

--8<---cut here---start->8---
test-name: bit-identical to GNU cpio's output
location: /home/mthl/src/gnu/guix/tests/cpio.scm:49
source:
+ (test-assert
+   "bit-identical to GNU cpio's output"
+   (call-with-temporary-output-file
+ (lambda (link _)
+   (delete-file link)
+   (symlink "chbouib" link)
+   (let ((files (cons* "/"
+   (canonicalize-path
+ (dirname (search-path %load-path "guix.scm")))
+   link
+   (map (compose
+  canonicalize-path
+  (cut search-path %load-path <>))
+'("guix.scm"
+  "guix/build/syscalls.scm"
+  "guix/packages.scm")
+ (call-with-temporary-output-file
+   (lambda (ref-file _)
+ (let ((pipe (open-pipe*
+   OPEN_WRITE
+   %cpio-program
+   "-o"
+   "-O"
+   ref-file
+   "-H"
+   "newc"
+   "--null")))
+   (for-each
+ (lambda (file) (format pipe "~a\x00" file))
+ files)
+   (and (zero? (close-pipe pipe))
+(call-with-temporary-output-file
+  (lambda (file port)
+(write-cpio-archive files port)
+(close-port port)
+(or (file=? ref-file file)
+(throw 'cpio-archives-differ
+   files
+   ref-file
+   file
+   (stat:size (stat ref-file))
+   (stat:size (stat file))
value: #f
result: FAIL
--8<---cut here---end--->8---

>> Since this script is not intented to be exclusively used by Guix, I have
>> used a generic copyright notice.  I guess Guix is the best place to
>> challenge and improve it, but IMO it will be better hosted elsewhere
>> like in Gnulib.  Opinions?
>
> I think we could start using it and testing it for a while in Guix, and
> eventually submit it for inclusion in Gnulib once we are more confident.

So you recommend to add ”this file is part of GNU Guix” and use “GNU
Guix” instead of “this program” for now?

>> From 977e0586a6689df204fd9b522f8508ec318

Re: [PATCH] gnu: Add nestopiaue.

2015-11-01 Thread Taylan Ulrich Bayırlı/Kammer
Seems I forgot our commit message guidelines; here's a patch with a
fixed commit message.

>From 06d1fe3145052d7b660bba98db751fcc670a6602 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Taylan=20Ulrich=20Bay=C4=B1rl=C4=B1/Kammer?=
 
Date: Sun, 1 Nov 2015 19:38:53 +0100
Subject: [PATCH] gnu: Add nestopiaue.

* gnu/packages/games.scm (nestopiaue): New variable.
---
 gnu/packages/games.scm | 60 ++
 1 file changed, 60 insertions(+)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 546944a..1ba9f3f 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -38,10 +38,12 @@
   #:use-module (guix svn-download)
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
+  #:use-module (gnu packages backup)
   #:use-module (gnu packages base)
   #:use-module (gnu packages admin)
   #:use-module (gnu packages audio)
   #:use-module (gnu packages boost)
+  #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages fribidi)
   #:use-module (gnu packages game-development)
   #:use-module (gnu packages gettext)
@@ -1212,3 +1214,61 @@ world}, @uref{http://evolonline.org, Evol Online} and
 ;; "data/themes/{golden-delicious,jewelry}/*" are under CC-BY-SA.
 ;; The rest is under GPL2+.
 (license (list license:gpl2+ license:zlib license:cc-by-sa4.0
+
+(define-public nestopiaue
+  (package
+(name "nestopiaue")
+(version "1.46.2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/rdanbrook/nestopia/archive/";
+version ".tar.gz"))
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"07h49xwvg61dx20rk5p4r3ax2ar5y0ppvm60cqwqljyi9rdfbh7p"))
+  (modules '((guix build utils)))
+  ;; We don't need libretro for the GNU/Linux build.
+  (snippet
+   '(delete-file-recursively "libretro"
+(build-system gnu-build-system)
+(native-inputs `(("pkg-config" ,pkg-config)
+ ("xdg-utils" ,xdg-utils)))
+(inputs `(("ao" ,ao)
+  ("glu" ,glu)
+  ("gtk+" ,gtk+)
+  ("libarchive" ,libarchive)
+  ("mesa" ,mesa)
+  ("sdl2" ,sdl2)))
+(arguments
+ '(#:phases (modify-phases %standard-phases
+  ;; The Nestopia build system consists solely of a Makefile.
+  (delete 'configure)
+  ;; XXX Should be unnecessary with the next release.
+  (add-before
+   'build 'patch-makefile
+   (lambda _
+ (substitute* "Makefile"
+   (("@mkdir \\$@") "@mkdir -p $@")
+   (("CC =") "CC ?=")
+   (("CXX =") "CXX ?=")
+   (("PREFIX =") "PREFIX ?=")
+   (("^install:\n$")
+"install:\n\tmkdir -p $(BINDIR)\n"
+  (add-before
+   'build 'remove-xdg-desktop-menu-call
+   (lambda _
+ (substitute* "Makefile"
+   (("xdg-desktop-menu install .*") "")
+   #:make-flags (let ((out (assoc-ref %outputs "out")))
+  (list "CC=gcc" "CXX=g++" (string-append "PREFIX=" out)))
+   ;; There are no tests.
+   #:tests? #f))
+(home-page "http://0ldsk00l.ca/nestopia/";)
+(synopsis "Nintendo Entertainment System (NES/Famicom) emulator")
+(description
+ "Nestopia UE (Undead Edition) is a fork of the Nintendo Entertainment
+System (NES/Famicom) emulator Nestopia, with enhancements from members of the
+emulation community.  It provides highly accurate emulation.")
+(license license:gpl2+)))
-- 
2.5.0



[PATCH 1/2] gnu: newt: Build python bindings.

2015-11-01 Thread ericbavier
From: Eric Bavier 

* gnu/packages/slang.scm (slang)[outputs]: New field.
  [arguments]: Add #:make-flags argument.  Add 'move-python' phase.
---
 gnu/packages/slang.scm | 24 ++--
 1 file changed, 22 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/slang.scm b/gnu/packages/slang.scm
index a00fa7b..24ec71e 100644
--- a/gnu/packages/slang.scm
+++ b/gnu/packages/slang.scm
@@ -1,6 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2015 Ludovic Courtès 
 ;;; Copyright © 2015 Mark H Weaver 
+;;; Copyright © 2015 Eric Bavier 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -20,6 +21,7 @@
 (define-module (gnu packages slang)
   #:use-module (guix packages)
   #:use-module (guix download)
+  #:use-module (guix utils)
   #:use-module (guix build-system gnu)
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (gnu packages readline)
@@ -28,7 +30,8 @@
   #:use-module (gnu packages fribidi)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages image)
-  #:use-module (gnu packages pcre))
+  #:use-module (gnu packages pcre)
+  #:use-module (gnu packages python))
 
 (define-public slang
   (package
@@ -85,15 +88,22 @@ slsh, which is part of the S-Lang distribution.")
(base32
 "07n9f2mqsjfj35wx5ldhvl9sqcjqpcl0g4fdd9mawmny9rihw6vp"
 (build-system gnu-build-system)
+(outputs '("out" "python"))
 (inputs
  `(("slang" ,slang)
("popt" ,popt)
+   ("python" ,python)
("fribidi" ,fribidi)))
 (arguments
  `(#:tests? #f; no test suite
#:configure-flags
;; Set the correct RUNPATH in binaries.
(list (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib"))
+   #:make-flags
+   ;; configure does not allow us to override this variable from the
+   ;; command-line.  Fortunately, the Makefile does, so provide it here.
+   (list (string-append "PYTHONVERS=python"
+,(version-major+minor (package-version python
#:phases
(modify-phases %standard-phases
  (add-after
@@ -101,7 +111,17 @@ slsh, which is part of the S-Lang distribution.")
   (lambda _
 (substitute* "po/Makefile"
   (("/usr/bin/install") "install"))
-#t)
+#t))
+ (add-after
+  'install 'move-python
+  (lambda* (#:key outputs #:allow-other-keys)
+(let ((out  (assoc-ref outputs "out"))
+  (py   (assoc-ref outputs "python"))
+  (ver ,(version-major+minor (package-version python
+  (mkdir-p (string-append py "/lib"))
+  (rename-file (string-append out "/lib/python" ver)
+   (string-append py  "/lib/python" ver))
+  #t))
 (home-page "https://fedorahosted.org/newt/";)
 (synopsis "Not Erik's Windowing Toolkit - text mode windowing with slang")
 (description
-- 
2.5.0




[PATCH 2/2] gnu: Add byobu.

2015-11-01 Thread ericbavier
From: Eric Bavier 

* gnu/packages/screen.scm (byobu): New variable.
* gnu/packages/patches/byobu-writable-status.patch: New patch.
* gnu-system.am (dist_patch_DATA): Add it.
---
 gnu-system.am|  1 +
 gnu/packages/patches/byobu-writable-status.patch | 13 ++
 gnu/packages/screen.scm  | 54 
 3 files changed, 68 insertions(+)
 create mode 100644 gnu/packages/patches/byobu-writable-status.patch

diff --git a/gnu-system.am b/gnu-system.am
index 3e976e9..cc4f6fb 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -411,6 +411,7 @@ dist_patch_DATA =   
\
   gnu/packages/patches/binutils-ld-new-dtags.patch \
   gnu/packages/patches/binutils-loongson-workaround.patch  \
   gnu/packages/patches/bitlbee-configure-doc-fix.patch \
+  gnu/packages/patches/byobu-writable-status.patch \
   gnu/packages/patches/boost-mips-avoid-m32.patch  \
   gnu/packages/patches/calibre-drop-unrar.patch\
   gnu/packages/patches/calibre-no-updates-dialog.patch \
diff --git a/gnu/packages/patches/byobu-writable-status.patch 
b/gnu/packages/patches/byobu-writable-status.patch
new file mode 100644
index 000..2858280
--- /dev/null
+++ b/gnu/packages/patches/byobu-writable-status.patch
@@ -0,0 +1,13 @@
+Skeleton status files are installed read-only.  When copying to the config dir
+upon initialization, make sure they end up writable.
+
+--- byobu-5.98/usr/bin/byobu-janitor.in
 byobu-5.98/usr/bin/byobu-janitor.in
+@@ -82,6 +82,7 @@
+   if [ ! -r "$BYOBU_CONFIG_DIR/$f" ]; then
+   # Copy from skeleton, if possible
+   cp -f "$BYOBU_PREFIX/share/$PKG/status/$f" 
"$BYOBU_CONFIG_DIR/$f"
++  chmod +w "$BYOBU_CONFIG_DIR/$f"
+   # Enable ec2_cost, if we're in ec2 and seeding a new setup
+   if metadata_available; then
+   $BYOBU_SED_INLINE -e "s/#ec2_cost/ec2_cost/g" 
"$($BYOBU_READLINK -f $BYOBU_CONFIG_DIR/$f)"
diff --git a/gnu/packages/screen.scm b/gnu/packages/screen.scm
index 84cc8c9..5580060 100644
--- a/gnu/packages/screen.scm
+++ b/gnu/packages/screen.scm
@@ -1,6 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2013 Cyril Roelandt 
 ;;; Copyright © 2014 Mark H Weaver 
+;;; Copyright © 2015 Eric Bavier 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -25,6 +26,8 @@
   #:use-module (gnu packages)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages perl)
+  #:use-module (gnu packages python)
+  #:use-module (gnu packages slang)
   #:use-module (gnu packages texinfo))
 
 (define-public screen
@@ -90,3 +93,54 @@ view to show two terminals at once.")
 allowing you to run a program in an environment that is protected from the
 controlling terminal and attach to it later.")
 (license gpl2+)))
+
+(define-public byobu
+  (package
+(name "byobu")
+(version "5.98")
+(source
+ (origin
+   (method url-fetch)
+   (uri (string-append "https://launchpad.net/byobu/trunk/";
+   version "/+download/byobu_"
+   version ".orig.tar.gz"))
+   (sha256
+(base32
+ "1s8nh4wbds1nh52i0d1hy1b308jjf4siwpq92lna1zh9ll4x71j5"))
+   (patches (list (search-patch "byobu-writable-status.patch")
+(build-system gnu-build-system)
+(inputs
+ `(("python" ,python-wrapper)   ;for config and session GUIs
+   ("python-newt" ,newt "python")))
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-before
+  'configure 'provide-locale
+  (lambda* (#:key inputs #:allow-other-keys)
+(let ((libc   (assoc-ref inputs "libc"))) ;implicit input
+  (substitute* "usr/bin/byobu.in"
+(("locale") (string-append libc "/bin/locale"))
+ (add-after
+  'install 'wrap-python-scripts
+  (lambda* (#:key inputs outputs #:allow-other-keys)
+(let* ((python (string-append (assoc-ref inputs "python")
+  "/bin/python"))
+   (newt   (assoc-ref inputs "python-newt"))
+   (out(assoc-ref outputs "out"))
+   (config (string-append out "/bin/byobu-config"))
+   (select (string-append out "/bin/byobu-select-session")))
+  (wrap-program config
+`("BYOBU_PYTHON" = (,python))
+`("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"
+  (wrap-program select
+`("BYOBU_PYTHON" = (,python)))
+  #t))
+(home-page "http://byobu.co/index.html";)
+(synopsis "Text-based window manager and terminal multiplexer")
+(description
+ "Byobu is a Japanese term for decorative, multi-panel screens that serve
+as folding room dividers.  The Byobu software in

Re: Of sounds and locales

2015-11-01 Thread matias_jose_seco




Nope, these are top-level definition, so it should be done like this:

(define ...)
(operating-system ...)


Very grateful for the hint!


By the way, recently the service API was changed, so those service
definitions will not work anymore.


At this point i was exploring the possibility to completely avoid 
compiling by

defining  only-substitutes installations:
i couldn't find any option for forcing only-substitutes; is there any?

For the powertop service definition i'll have to adapt the code to the 
new API,

or it will be impossible to add custom services at all?

Very very glad.



Re: [PATCH] build: Add a scheme custom test driver using SRFI-64.

2015-11-01 Thread Mathieu Lirzin
Mathieu Lirzin  writes:

> l...@gnu.org (Ludovic Courtès) writes:
>> Awesome!  Are the “inner” tests displayed by default?  Or is there some
>> environment variable to control that?
>
> Yes, each test case is displayed by default.
>
>> I’d prefer the default to display only file names, as is currently the
>> case (it’s more concise.)
>
> IMO This would be reasonable to have an option for making the output more
> concise since there are 563 test cases in Guix.  this is not part of the
> test driver API specification, but it does not seem too hard to add an
> additional option to the test driver script like what the TAP driver is
> doing:
>
>   
> https://www.gnu.org/software/automake/manual/automake.html#Use-TAP-with-the-Automake-test-harness
>
> I think ‘--brief’ could be a good name for this option.  Default
> verbosity would specified by adding “AM_SCM_LOG_DRIVER= --brief=yes” in
   ^^^
   AM_SCM_LOG_DRIVER_FLAGS
> Makefile.am, then the user can overide that with:
>
>   make check -j4 TESTS=tests/rocket-science.scm SCM_LOG_DRIVER="--brief=no"
  ^^^
  SCM_LOG_DRIVER_FLAGS
>
[...]
>> Nice.  “Running the Test Suite” needs to be updated accordingly.
>
> Thanks for reminding me this.  ;)

Here is an updated patch with the implementation of what is described
above.  As a bonus There is a bug fix for the ‘--color-tests’ option and
a few docstring/comment changes.

--
Mathieu Lirzin

>From 8a1f52e08c8d33a33066271f0f39d6072baf9854 Mon Sep 17 00:00:00 2001
From: Mathieu Lirzin 
Date: Mon, 26 Oct 2015 23:47:24 +0100
Subject: [PATCH] build: Add a scheme custom test driver using SRFI-64.

This provides support for multiple scheme test cases in a unique file and
fixes the fragmentation of '.log' files.

* build-aux/test-driver.scm: New file.
* Makefile.am (SCM_LOG_DRIVER, AM_SCM_LOG_DRIVER_FLAGS): New variables.
  (SCM_LOG_COMPILER, AM_SCM_LOG_FLAGS): Delete variables.
  (AM_TESTS_ENVIRONMENT): Set GUILE_AUTO_COMPILE to 0.
* doc/guix.texi (Running the Test Suite): Reporting a bug does not
  require to provide a specific '.log' file anymore.
* tests/base32.scm, tests/build-utils.scm, tests/builders.scm,
  tests/challenge.scm, tests/containers.scm, tests/cpan.scm,
  tests/cpio.scm, tests/cran.scm, tests/derivations.scm, tests/elpa.scm,
  tests/file-systems.scm, tests/gem.scm, tests/gexp.scm,
  tests/graph.scm, tests/gremlin.scm, tests/hackage.scm, tests/hash.scm,
  tests/lint.scm, tests/monads.scm, tests/nar.scm, tests/packages.scm,
  tests/pk-crypto.scm, tests/pki.scm, tests/profiles.scm,
  tests/publish.scm, tests/pypi.scm, tests/records.scm,
  tests/scripts.scm, tests/services.scm, tests/sets.scm, tests/size.scm,
  tests/snix.scm, tests/store.scm, tests/substitute.scm,
  tests/syscalls.scm, tests/ui.scm, tests/union.scm, tests/utils.scm:
  Don't exit at the end of each test.
---
 Makefile.am   |   7 +-
 build-aux/test-driver.scm | 174 ++
 doc/guix.texi |   8 +--
 tests/base32.scm  |   3 -
 tests/build-utils.scm |   3 -
 tests/builders.scm|   3 -
 tests/challenge.scm   |   3 -
 tests/containers.scm  |   3 -
 tests/cpan.scm|   3 -
 tests/cpio.scm|   3 -
 tests/cran.scm|   3 -
 tests/derivations.scm |   3 -
 tests/elpa.scm|   3 -
 tests/file-systems.scm|   3 -
 tests/gem.scm |   3 -
 tests/gexp.scm|   3 -
 tests/graph.scm   |   3 -
 tests/gremlin.scm |   3 -
 tests/hackage.scm |   3 -
 tests/hash.scm|   3 -
 tests/lint.scm|   3 -
 tests/monads.scm  |   3 -
 tests/nar.scm |   3 -
 tests/packages.scm|   3 -
 tests/pk-crypto.scm   |   3 -
 tests/pki.scm |   3 -
 tests/profiles.scm|   3 -
 tests/publish.scm |   3 -
 tests/pypi.scm|   3 -
 tests/records.scm |   3 -
 tests/scripts.scm |   3 -
 tests/services.scm|   3 -
 tests/sets.scm|   3 -
 tests/size.scm|   3 -
 tests/snix.scm|   3 -
 tests/store.scm   |   3 -
 tests/substitute.scm  |   3 -
 tests/syscalls.scm|   3 -
 tests/ui.scm  |   3 -
 tests/union.scm   |   3 -
 tests/utils.scm   |   3 -
 41 files changed, 181 insertions(+), 122 deletions(-)
 create mode 100644 build-aux/test-driver.scm

diff --git a/Makefile.am b/Makefile.am
index b2ee324..ce4cd53 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -268,10 +268,11 @@ TESTS = $(SCM_TESTS) $(SH_TESTS)
 
 TEST_EXTENSIONS = .scm .sh
 
-AM_TESTS_ENVIRONMENT = abs_top_srcdir="$(abs_top_srcdir)"
+AM_TESTS_ENVIRONMENT = abs_top_srcdir="$(abs_top_srcdir)" GUILE_AUTO_COMPILE=0
 
-SCM_LOG_COMPILER = $(top_builddir)/test-env $(GUILE)
-AM_SCM_LOG_FLAGS = --no-auto-compile -L

[PATCH] scripts: environment: Ignore user shell when spawning container.

2015-11-01 Thread David Thompson
Cross this one off the TODO list, Ludo. ;)

>From 655edf899710544d681acacab93f4f671962fc49 Mon Sep 17 00:00:00 2001
From: David Thompson 
Date: Sun, 1 Nov 2015 18:34:53 -0500
Subject: [PATCH] scripts: environment: Ignore user shell when spawning
 container.

* guix/scripts/environment.scm (%default-options): Remove 'exec'
  association.
  (guix-environment): If the user didn't specify a command, use the
  default shell, or use /bin/sh when a container is requested.
---
 guix/scripts/environment.scm | 12 +---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm
index f9ab9a4..45b54a9 100644
--- a/guix/scripts/environment.scm
+++ b/guix/scripts/environment.scm
@@ -160,8 +160,7 @@ COMMAND or an interactive shell in that environment.\n"))
 
 (define %default-options
   ;; Default to opening a new shell.
-  `((exec . (,%default-shell))
-(system . ,(%current-system))
+  `((system . ,(%current-system))
 (substitutes? . #t)
 (max-silent-time . 3600)
 (verbosity . 0)))
@@ -447,7 +446,14 @@ Otherwise, return the derivation for the Bash package."
(network?   (assoc-ref opts 'network?))
(bootstrap? (assoc-ref opts 'bootstrap?))
(system (assoc-ref opts 'system))
-   (command(assoc-ref opts 'exec))
+   (command(or (assoc-ref opts 'exec)
+   ;; Spawn a shell if the user didn't specify
+   ;; anything in particular.
+   (if container?
+   ;; The user's shell is likely not available
+   ;; within the container.
+   '("/bin/sh")
+   (list %default-shell
(packages   (options/resolve-packages opts))
(mappings   (pick-all opts 'file-system-mapping))
(inputs (delete-duplicates
-- 
2.5.0


-- 
David Thompson
GPG Key: 0FF1D807


[PATCH 1/3] gnu: Add c-ares.

2015-11-01 Thread Efraim Flashner
* gnu/packages/aria2.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
---
 gnu-system.am  |  1 +
 gnu/packages/aria2.scm | 59 ++
 2 files changed, 60 insertions(+)
 create mode 100644 gnu/packages/aria2.scm

diff --git a/gnu-system.am b/gnu-system.am
index f140ab6..4884680 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -35,6 +35,7 @@ GNU_SYSTEM_MODULES =  \
   gnu/packages/aidc.scm\
   gnu/packages/apl.scm \
   gnu/packages/apr.scm \
+  gnu/packages/aria2.scm   \
   gnu/packages/asciidoc.scm\
   gnu/packages/aspell.scm  \
   gnu/packages/attr.scm\
diff --git a/gnu/packages/aria2.scm b/gnu/packages/aria2.scm
new file mode 100644
index 000..86497f2
--- /dev/null
+++ b/gnu/packages/aria2.scm
@@ -0,0 +1,59 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2015 Efraim Flashner 
+;;;
+;;; 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 aria2)
+  #:use-module ((guix licenses) #:prefix license:)
+  #:use-module (guix download)
+  #:use-module (guix packages)
+  #:use-module (guix build-system gnu)
+  #:use-module (gnu packages autotools)
+  #:use-module (gnu packages pkg-config))
+
+(define-public c-ares
+  (package
+(name "c-ares")
+(version "1.10.0")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/bagder/c-ares/archive/cares-";
+(string-map (lambda (c) (if (char=? c #\.) #\_ c)) version)
+".tar.gz"))
+  (sha256
+   (base32
+"0cpzf7v91j6rb85pxn98k9mpw880b0hbw4axrvydvgiq043qm4gy"
+(build-system gnu-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'autoreconf
+(lambda _ (zero? (system* "autoreconf" "-vfi")))
+(native-inputs
+ `(("autoconf" ,autoconf)
+   ("automake" ,automake)
+   ("libtool" ,libtool)
+   ("pkg-config" ,pkg-config)))
+(home-page "http://c-ares.haxx.se/";)
+(synopsis "C library for asynchronous DNS requests")
+(description
+  "C-ares is a C library that performs DNS requests and name resolution
+asynchronously.  It is intended for applications which need to perform DNS
+queries without blocking, or need to perform multiple DNS queries in parallel.
+The primary examples of such applications are servers which communicate with
+multiple clients and programs with graphical user interfaces.")
+(license license:x11)))
-- 
2.6.2




[PATCH 0/3] add c-ares and aria2

2015-11-01 Thread Efraim Flashner
This patch has driven me crazy a bit. C-ares is a library for asynchronous DNS
lookups, and aria2 is a cli program to download multiple files/torrents
simultaneously, and also a git-annex dependency. C-ares builds without any
problems, but aria2 was a different story. The first problem is that the tests
seem to need network connectivity, and it tries to access files outside the
build chroot. Disabling the tests was the easy part. The second problem was that
pkg-config wouldn't find c-ares, so it kept on building without it. Looking at
patch 3, where I finally got the flags correct to bypass pkg-config and declare
where to find c-ares, I got errors right at the end of the build phase where it
couldn't find certain features of c-ares. As the patches are, patch 1 and 2 work
well, patch 3 doesn't build, but I've included it in case anyone has an idea of
something I can try. As it currently stands, nothing is currently set to depend
on c-ares, and aria2 works without it.

Efraim Flashner (3):
  gnu: Add c-ares.
  gnu: Add aria2.
  gnu: aria2: Build with c-ares.

 gnu-system.am  |   1 +
 gnu/packages/aria2.scm | 109 +
 2 files changed, 110 insertions(+)
 create mode 100644 gnu/packages/aria2.scm

-- 
2.6.2




[PATCH 3/3] gnu: aria2: Build with c-ares.

2015-11-01 Thread Efraim Flashner
* gnu/packages/aria2.scm (aria2)[inputs]: Add c-ares.
  [arguments]: Add environmental variables for c-ares.
---
 gnu/packages/aria2.scm | 13 +++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/aria2.scm b/gnu/packages/aria2.scm
index dacf4e2..debe53a 100644
--- a/gnu/packages/aria2.scm
+++ b/gnu/packages/aria2.scm
@@ -79,12 +79,21 @@ multiple clients and programs with graphical user 
interfaces.")
 "0gnm1b7yp5q6fcajz1ln2f1rv64p6dv0nz9bcwpqrkcmsinlh19n"
 (build-system gnu-build-system)
 (arguments
- `(#:configure-flags '("--enable-libaria2")
+ `(#:configure-flags '("--enable-libaria2" "--with-libcares")
+   #:phases
+(modify-phases %standard-phases
+ (add-before 'configure 'with-libcares
+ (lambda _ 
+   (setenv "LIBCARES_LIBS" (string-append "-L" (assoc-ref
+   %build-inputs "c-ares") "/lib"))
+   (setenv "LIBCARES_CFLAGS" (string-append "-I" (assoc-ref
+   %build-inputs "c-ares") "/include")
#:tests? #f)) ; tests require network connectivity
 (native-inputs
  `(("pkg-config", pkg-config)))
 (inputs
- `(("gnutls" ,gnutls)
+ `(("c-ares" ,c-ares)
+   ("gnutls" ,gnutls)
("gmp" ,gmp)
("libssh2" ,libssh2)
("libxml2" ,libxml2)
-- 
2.6.2




[PATCH 2/3] gnu: Add aria2.

2015-11-01 Thread Efraim Flashner
* gnu/packages/aria2.scm (aria2): New variable.
---
 gnu/packages/aria2.scm | 43 ++-
 1 file changed, 42 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/aria2.scm b/gnu/packages/aria2.scm
index 86497f2..dacf4e2 100644
--- a/gnu/packages/aria2.scm
+++ b/gnu/packages/aria2.scm
@@ -22,7 +22,14 @@
   #:use-module (guix packages)
   #:use-module (guix build-system gnu)
   #:use-module (gnu packages autotools)
-  #:use-module (gnu packages pkg-config))
+  #:use-module (gnu packages compression)
+  #:use-module (gnu packages databases)
+  #:use-module (gnu packages nettle)
+  #:use-module (gnu packages tls)
+  #:use-module (gnu packages multiprecision)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages ssh)
+  #:use-module (gnu packages xml))
 
 (define-public c-ares
   (package
@@ -57,3 +64,37 @@ queries without blocking, or need to perform multiple DNS 
queries in parallel.
 The primary examples of such applications are servers which communicate with
 multiple clients and programs with graphical user interfaces.")
 (license license:x11)))
+
+(define-public aria2
+  (package
+(name "aria2")
+(version "1.19.2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "https://github.com/tatsuhiro-t/aria2/";
+  "releases/download/release-" version "/"
+  name "-" version ".tar.xz"))
+  (sha256
+   (base32
+"0gnm1b7yp5q6fcajz1ln2f1rv64p6dv0nz9bcwpqrkcmsinlh19n"
+(build-system gnu-build-system)
+(arguments
+ `(#:configure-flags '("--enable-libaria2")
+   #:tests? #f)) ; tests require network connectivity
+(native-inputs
+ `(("pkg-config", pkg-config)))
+(inputs
+ `(("gnutls" ,gnutls)
+   ("gmp" ,gmp)
+   ("libssh2" ,libssh2)
+   ("libxml2" ,libxml2)
+   ("nettle" ,nettle)
+   ("sqlite" ,sqlite)
+   ("zlib" ,zlib)))
+(home-page "http://aria2.sourceforge.net/";)
+(synopsis "Utility for parallel downloading files")
+(description
+  "Aria2 is a lightweight, multi-protocol & multi-source command-line
+downloadu tility.  It supports HTTP/HTTPS, FTP, SFTP, BitTorrent and Metalink.
+Aria2 can be manipulated via built-in JSON-RPC and XML-RPC interfaces.")
+(license license:gpl2+)))
-- 
2.6.2




Re: [PATCH 0/3] add c-ares and aria2

2015-11-01 Thread Efraim Flashner
On Mon,  2 Nov 2015 09:15:20 +0200
Efraim Flashner  wrote:

> This patch has driven me crazy a bit. C-ares is a library for asynchronous DNS
> lookups, and aria2 is a cli program to download multiple files/torrents
> simultaneously, and also a git-annex dependency. C-ares builds without any
> problems, but aria2 was a different story. The first problem is that the tests
> seem to need network connectivity, and it tries to access files outside the
> build chroot. Disabling the tests was the easy part. The second problem was 
> that
> pkg-config wouldn't find c-ares, so it kept on building without it. Looking at
> patch 3, where I finally got the flags correct to bypass pkg-config and 
> declare
> where to find c-ares, I got errors right at the end of the build phase where 
> it
> couldn't find certain features of c-ares. As the patches are, patch 1 and 2 
> work
> well, patch 3 doesn't build, but I've included it in case anyone has an idea 
> of
> something I can try. As it currently stands, nothing is currently set to 
> depend
> on c-ares, and aria2 works without it.

I meant to include the error at the end of the build phase:
  CXXLDaria2c
./.libs/libaria2.so: undefined reference to `ares_fds'
./.libs/libaria2.so: undefined reference to `ares_getsock'
./.libs/libaria2.so: undefined reference to `ares_destroy'
./.libs/libaria2.so: undefined reference to `ares_process'
./.libs/libaria2.so: undefined reference to `ares_gethostbyname'
./.libs/libaria2.so: undefined reference to `ares_library_init'
./.libs/libaria2.so: undefined reference to `ares_strerror'
./.libs/libaria2.so: undefined reference to `ares_process_fd'
./.libs/libaria2.so: undefined reference to `ares_init'
./.libs/libaria2.so: undefined reference to `ares_library_cleanup'
collect2: error: ld returned 1 exit status
Makefile:1796: recipe for target 'aria2c' failed

> Efraim Flashner (3):
>   gnu: Add c-ares.
>   gnu: Add aria2.
>   gnu: aria2: Build with c-ares.
> 
>  gnu-system.am  |   1 +
>  gnu/packages/aria2.scm | 109 
> +
>  2 files changed, 110 insertions(+)
>  create mode 100644 gnu/packages/aria2.scm
> 

-- 
Efraim Flashner  אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted


pgpYeLjdDxGtC.pgp
Description: OpenPGP digital signature