[PATCH] gnu: yubico.scm: Rename to security-token.scm.

2016-10-26 Thread Marius Bakke
This is an attempt to make it generic enough for middleware and drivers
such as pcsc-lite and ccid, in addition to tools for other devices.

Other options include "authentication.scm", "auth-token.scm",
"security.scm" and a lot more..

What do you think?

>From 615733b5d0ea6af5cd858f7e258a64a9fb3bc394 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 26 Oct 2016 07:33:24 +0100
Subject: [PATCH] gnu: yubico.scm: Rename to security-token.scm.

* gnu/packages/yubico.scm: Delete file.
* gnu/packages/security-token.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adjust accordingly.
---
 gnu/local.mk| 2 +-
 gnu/packages/{yubico.scm => security-token.scm} | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
 rename gnu/packages/{yubico.scm => security-token.scm} (98%)

diff --git a/gnu/local.mk b/gnu/local.mk
index ff2d976..cd6c715 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -325,6 +325,7 @@ GNU_SYSTEM_MODULES =\
   %D%/packages/scsi.scm\
   %D%/packages/sdcc.scm\
   %D%/packages/sdl.scm\
+  %D%/packages/security-token.scm		\
   %D%/packages/search.scm			\
   %D%/packages/serialization.scm		\
   %D%/packages/serveez.scm			\
@@ -385,7 +386,6 @@ GNU_SYSTEM_MODULES =\
   %D%/packages/xdisorg.scm			\
   %D%/packages/xorg.scm\
   %D%/packages/xfce.scm\
-  %D%/packages/yubico.scm			\
   %D%/packages/zile.scm\
   %D%/packages/zip.scm\
 		\
diff --git a/gnu/packages/yubico.scm b/gnu/packages/security-token.scm
similarity index 98%
rename from gnu/packages/yubico.scm
rename to gnu/packages/security-token.scm
index 469d93d..48a9346 100644
--- a/gnu/packages/yubico.scm
+++ b/gnu/packages/security-token.scm
@@ -17,7 +17,7 @@
 ;;; You should have received a copy of the GNU General Public License
 ;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
 
-(define-module (gnu packages yubico)
+(define-module (gnu packages security-token)
   #:use-module (gnu packages)
   #:use-module (guix licenses)
   #:use-module (guix packages)
-- 
2.10.1



Re: [PATCH] gnu: mupdf: Fix CVE-2016-8674.

2016-10-26 Thread Marius Bakke
Kei Kebreau <k...@openmailbox.org> writes:

> Is it frowned upon to revert that commit on its own (it's the third to
> last commit as I write this), or should I attempt to patch on top of it?

I've modified the patch to apply to 1.9a, but it was far from trivial
due to many context changes in upstream git. The attached patch makes
mupdf build at least, and viewing PDF still works...

The interdiff is rather unintelligible, so to verify this you should
compare the final patch with the 1.9a sources.

Ideally we should try and reproduce this vulnerability (and others!)
after applying this patch, but I don't know how to use AFL.

Another option is to simply package up the git version, as there appears
to be no users of mupdf in the tree.

WDYT, is this patch safe?



signature.asc
Description: PGP signature
>From c51f44edf3293aae323eded49dcba750f54607cb Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 26 Oct 2016 06:39:34 +0100
Subject: [PATCH] gnu: mupdf: Modify CVE-2016-8674 patch to apply to 1.9a.

The fix from upstream did not apply cleanly due to many context changes.
This was adapted by cloning mupdf 1.9a from git and fixing conflicts
after applying our patches and cherry-picking upstream commit 1e03c06.

* gnu/packages/patches/mupdf-CVE-2016-8674.patch: Adapt to 1.9a.
---
 gnu/packages/patches/mupdf-CVE-2016-8674.patch | 83 +-
 1 file changed, 41 insertions(+), 42 deletions(-)

diff --git a/gnu/packages/patches/mupdf-CVE-2016-8674.patch b/gnu/packages/patches/mupdf-CVE-2016-8674.patch
index 62e4a02..2a35619 100644
--- a/gnu/packages/patches/mupdf-CVE-2016-8674.patch
+++ b/gnu/packages/patches/mupdf-CVE-2016-8674.patch
@@ -3,17 +3,17 @@ Fix CVE-2016-8674 (use-after-free in pdf_to_num()).
 https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2016-8674
 https://security-tracker.debian.org/tracker/CVE-2016-8674
 
-Patch copied from upstream source repository:
+Patch adapted from upstream source repository:
 http://git.ghostscript.com/?p=mupdf.git;h=1e03c06456d997435019fb3526fa2d4be7dbc6ec
 
 diff --git a/include/mupdf/pdf/document.h b/include/mupdf/pdf/document.h
-index aabf05f..0078c4a 100644
+index f8ef0cd..e8345b7 100644
 --- a/include/mupdf/pdf/document.h
 +++ b/include/mupdf/pdf/document.h
-@@ -269,6 +269,10 @@ struct pdf_document_s
- 		fz_hash_table *images;
- 		fz_hash_table *fonts;
- 	} resources;
+@@ -258,6 +258,10 @@ struct pdf_document_s
+	fz_font **type3_fonts;
+
+	pdf_resource_tables *resources;
 +
 +	int orphans_max;
 +	int orphans_count;
@@ -22,10 +22,10 @@ index aabf05f..0078c4a 100644
  
  /*
 diff --git a/include/mupdf/pdf/object.h b/include/mupdf/pdf/object.h
-index 5bc3dca..bf57455 100644
+index 346a2f1..02d4119 100644
 --- a/include/mupdf/pdf/object.h
 +++ b/include/mupdf/pdf/object.h
-@@ -110,6 +110,7 @@ pdf_obj *pdf_dict_gets(fz_context *ctx, pdf_obj *dict, const char *key);
+@@ -109,6 +109,7 @@ pdf_obj *pdf_dict_gets(fz_context *ctx, pdf_obj *dict, const char *key);
  pdf_obj *pdf_dict_getsa(fz_context *ctx, pdf_obj *dict, const char *key, const char *abbrev);
  void pdf_dict_put(fz_context *ctx, pdf_obj *dict, pdf_obj *key, pdf_obj *val);
  void pdf_dict_put_drop(fz_context *ctx, pdf_obj *dict, pdf_obj *key, pdf_obj *val);
@@ -34,10 +34,10 @@ index 5bc3dca..bf57455 100644
  void pdf_dict_puts_drop(fz_context *ctx, pdf_obj *dict, const char *key, pdf_obj *val);
  void pdf_dict_putp(fz_context *ctx, pdf_obj *dict, const char *path, pdf_obj *val);
 diff --git a/source/pdf/pdf-object.c b/source/pdf/pdf-object.c
-index b4e33f3..1c19ba4 100644
+index f2e4551..a0d0d8e 100644
 --- a/source/pdf/pdf-object.c
 +++ b/source/pdf/pdf-object.c
-@@ -1265,11 +1265,14 @@ pdf_dict_geta(fz_context *ctx, pdf_obj *obj, pdf_obj *key, pdf_obj *abbrev)
+@@ -1240,9 +1240,13 @@ pdf_dict_geta(fz_context *ctx, pdf_obj *obj, pdf_obj *key, pdf_obj *abbrev)
  	return pdf_dict_get(ctx, obj, abbrev);
  }
  
@@ -46,27 +46,26 @@ index b4e33f3..1c19ba4 100644
 +static void
 +pdf_dict_get_put(fz_context *ctx, pdf_obj *obj, pdf_obj *key, pdf_obj *val, pdf_obj **old_val)
  {
- 	int i;
- 
++
 +	if (old_val)
 +		*old_val = NULL;
 +
  	RESOLVE(obj);
- 	if (!OBJ_IS_DICT(obj))
- 		fz_throw(ctx, FZ_ERROR_GENERIC, "not a dict (%s)", pdf_objkindstr(obj));
-@@ -1295,7 +1298,10 @@ pdf_dict_put(fz_context *ctx, pdf_obj *obj, pdf_obj *key, pdf_obj *val)
- 		{
- 			pdf_obj *d = DICT(obj)->items[i].v;
- 			DICT(obj)->items[i].v = pdf_keep_obj(ctx, val);
--			pdf_drop_obj(ctx, d);
-+			if (old_val)
-+*old_val = d;
-+			else
-+pdf_drop_obj(ctx, d);
+	if (obj >= PDF_OBJ__LIMIT)
+	{
+@@ -1282,7 +1286,10 @@ pdf_dict_put(fz_context *ctx, pdf_obj *obj, pdf_obj *key, pdf_obj *val)
+			{
+pdf_obj *d = DICT(obj)->items[i].v;
+DICT(obj)->items[i].v = pdf_keep_obj(ctx, val);
+-pdf_drop_obj(ctx, d);
++if (old_val)
++	*old_val = d;
++else
++	pdf_drop_obj(ctx, d);
+			}
  		}
- 	}
- 	else
-@@ -1316,10 +1322,27 @@ pdf_d

Re: [PATCH 4/4] gnu: vlc: Add x265 support.

2016-10-25 Thread Marius Bakke
Efraim Flashner  writes:

> * gnu/packages/video.scm (vlc)[inputs]: Add x265.

I've built vlc, gst-plugins-bad and ffmpeg with these patches and x265
is referenced.

Not sure how to test it, but LGTM overall.


signature.asc
Description: PGP signature


[PATCH] gnu: notmuch: Update to 0.23.1.

2016-10-25 Thread Marius Bakke

If you can read this message, this seems to work for me.. ;)

>From afb9160f1968447c318aa0f2508de2ab396ce1ba Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 25 Oct 2016 20:10:35 +0100
Subject: [PATCH] gnu: notmuch: Update to 0.23.1.

* gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch: Delete
file.
* gnu/local.mk (dist_patch_DATA): Remove it.
* gnu/packages/mail.scm (notmuch): Update to 0.23.1. Remove patch.
---
 gnu/local.mk   |  1 -
 gnu/packages/mail.scm  |  8 +---
 .../notmuch-emacs-25-compatibility-fix.patch   | 46 --
 3 files changed, 2 insertions(+), 53 deletions(-)
 delete mode 100644 gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index ff2d976..87fb76d 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -728,7 +728,6 @@ dist_patch_DATA =		\
   %D%/packages/patches/ninja-tests.patch			\
   %D%/packages/patches/ninja-zero-mtime.patch			\
   %D%/packages/patches/node-9077.patch\
-  %D%/packages/patches/notmuch-emacs-25-compatibility-fix.patch	\
   %D%/packages/patches/nss-pkgconfig.patch			\
   %D%/packages/patches/nvi-assume-preserve-path.patch		\
   %D%/packages/patches/nvi-dbpagesize-binpower.patch		\
diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index eee7d18..ff711ef 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -501,18 +501,14 @@ invoking @command{notifymuch} from the post-new hook.")
 (define-public notmuch
   (package
 (name "notmuch")
-(version "0.23")
+(version "0.23.1")
 (source (origin
   (method url-fetch)
   (uri (string-append "https://notmuchmail.org/releases/notmuch-;
   version ".tar.gz"))
   (sha256
(base32
-"1f51l34rdhjf8lvafrwybkxdsdwx8k9397m7qxd8rdg2irjmpry5"))
-  (patches
-   ;; Remove this for the next release. See this thread for context:
-   ;; https://notmuchmail.org/pipermail/notmuch/2016/023227.html
-   (search-patches "notmuch-emacs-25-compatibility-fix.patch"
+"106ijsnilqf8760z4cq99rqzjsvyaw86d0lgnzz7v95gm4d2l0g8"
 (build-system gnu-build-system)
 (arguments
  '(#:make-flags (list "V=1") ; Verbose test output.
diff --git a/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch b/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch
deleted file mode 100644
index 9ddfd4f..000
--- a/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-This fixes a test failure with emacs-25. Picked from
-https://git.notmuchmail.org/git?p=notmuch;a=commit;h=f575a346df09c82691bb9e7c462836d982fe31f7
-
-From f575a346df09c82691bb9e7c462836d982fe31f7 Mon Sep 17 00:00:00 2001
-From: David Bremner <da...@tethera.net>
-Date: Sun, 9 Oct 2016 19:30:44 -0300
-Subject: [PATCH] emacs/show: force notmuch-show-buttonise-links to act on
- lines
-
-This seems to fix a problem with emacs 25 creating partial buttons by
-calling n-s-b-l with a region that does not include the whole button.
-I'm not 100% sure it's legit to act outside the region passed by
-jit-lock, but goto-address-fontify-region (where I borrowed the code
-from) already does this, so this patch to not make things worse.

- emacs/notmuch-show.el | 12 +++-
- 1 file changed, 7 insertions(+), 5 deletions(-)
-
-diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
-index 641398d..e7d16f8 100644
 a/emacs/notmuch-show.el
-+++ b/emacs/notmuch-show.el
-@@ -1174,13 +1174,15 @@ This also turns id:\"\"-parts and mid: links into
- buttons for a corresponding notmuch search."
-   (goto-address-fontify-region start end)
-   (save-excursion
--(let (links)
--  (goto-char start)
--  (while (re-search-forward notmuch-id-regexp end t)
-+(let (links
-+	  (beg-line (progn (goto-char start) (line-beginning-position)))
-+	  (end-line (progn (goto-char end) (line-end-position
-+  (goto-char beg-line)
-+  (while (re-search-forward notmuch-id-regexp end-line t)
- 	(push (list (match-beginning 0) (match-end 0)
- 		(match-string-no-properties 0)) links))
--  (goto-char start)
--  (while (re-search-forward notmuch-mid-regexp end t)
-+  (goto-char beg-line)
-+  (while (re-search-forward notmuch-mid-regexp end-line t)
- 	(let* ((mid-cid (match-string-no-properties 1))
- 	   (mid (save-match-data
- 		  (string-match "^[^/]*" mid-cid)
--- 
-2.10.1
-
-- 
2.10.1



Re: [PATCH 0/1] Perl-www-curl: Fix build failure

2016-10-25 Thread Marius Bakke
Leo Famulari  writes:

> This fixes the build failure of perl-www-curl build on core-updates:
> https://hydra.gnu.org/build/1553325/nixlog/2
>
> The patch is copied from the upstream bug tracker, but the maintainers
> don't seem to have done anything with the patch yet.
>
> What do you think?
>
> Leo Famulari (1):
>   gnu: perl-www-curl: Fix build failure.
>
>  gnu/local.mk   |  1 +
>  .../patches/perl-www-curl-remove-symbol.patch  | 39 
> ++
>  gnu/packages/web.scm   |  1 +
>  3 files changed, 41 insertions(+)
>  create mode 100644 gnu/packages/patches/perl-www-curl-remove-symbol.patch

I dug into the curl history and managed to find the commits[0][1] that
lead to this. Combined with the bug report[2] linked in the patch, this
seems sensible.

Last maintainer activity on the upstream tracker was two years ago, so
we may have to carry this a while.

0: https://github.com/curl/curl/commit/d6604524ad24daf4581efbe0020da058d2b3af84
1: https://github.com/curl/curl/commit/5fce88aa8c1256486377471186fc353c50d610b1
2: https://rt.cpan.org/Public/Bug/Display.html?id=117793


signature.asc
Description: PGP signature


Re: [PATCH] gnu: gcc-4.9: Update to 4.9.4.

2016-10-24 Thread Marius Bakke
Carlos Sánchez de La Lama  writes:

>
> BTW, is there described somewhere which kind of updates go to
> core-updates first? Does everything go first to core-updates?

Only packages with a large impact in terms of rebuilds (as calculated by
`guix refresh -l `). Obviously gcc is one such package.

Soon there will also be a "staging" branch for packages with a lesser
impact, but still large enough that it's worth building and testing them
on Hydra before merging to master.

See this post for more information:

http://lists.gnu.org/archive/html/guix-devel/2016-10/msg00933.html


signature.asc
Description: PGP signature


Re: [PATCH] gnu: Add whois.

2016-10-24 Thread Marius Bakke
ng0  writes:

> * gnu/packages/networking.scm (whois): New variable.

I pushed the updated version of this as
9c798f9036d2d3f90e567052efb06b269c08ed14 with a minor modification to
the description.


signature.asc
Description: PGP signature


Re: [PATCH 0/2] gnu: Add libpcsclite

2016-10-24 Thread Marius Bakke
Mike Gerwitz <m...@gnu.org> writes:

> Hey, Marius:
>
> Thanks for the quick reply. :)

Hi again,

Sorry for the late reply this time! :)

> On Sat, Oct 22, 2016 at 22:16:34 +0100, Marius Bakke wrote:
>>> * gnu/packages/gnupg.scm (libpcsclite): New variable.
>>
>> I think this should be named "pcsc-lite" to match the upstream name.
>
> I wasn't sure what the Guix naming convention was here---in Debian it's
> libpcsclite1.  I'll make the change, though.

Debian typically separates libraries into their own packages distinct
from any executable binaries. Guix doesn't, although for some very large
packages the libraries may be a separate "output" [0].

Since this package provides both the "pcscd" binary (which is a separate
package in Debian) and libpcsclite.so, using the "project name" is the
correct convention.

[0]: Search the Guix manual for "multiple outputs" for more information
about this. At ~500KiB, multiple outputs is not necessary for pcsc-lite.

>>> * gnu/packages/gnupg.scm (gnupg): Add libpcsclite as propagated-input
>> [...]
>>
>>> +(propagated-inputs
>>> + `(("libpcsclite" ,libpcsclite)))
>>> (arguments
>>> -`(#:configure-flags '("--enable-gpg2-is-gpg")
>>> +`(#:configure-flags
>>> +  (list "--enable-gpg2-is-gpg"
>>> +(string-append "LDFLAGS=-Wl,-rpath="
>>> +   (assoc-ref %build-inputs "libpcsclite")
>>> +   "/lib"))
>>
>> The intention here is to make gnupg locate the libpcsclite library at
>> runtime, since it has no build-time checks for it, correct?
>
> Correct.  This is where I spent most of my time Guix-wise.
>
>> I think this approach is fine, if there is no way to make it search
>> the Guix profile paths for the library.
>
> It uses dlopen which looks in RUNPATH.  I used strace to try to figure
> out what else it might be doing, but it looked like the RUNPATH paths
> were all it was checking.
>
> That said, I have no idea what I'm doing, so I'd love to hear a better
> way!  I saw other packages doing this, so I hoped it was somewhat
> acceptable, however dirty.
>
>> However, the LDFLAGS need to be in #:make-flags for this to work, and
>> then pcsc-lite does not need to be propagated, since Guix will scan the
>> output for store references (including rpath entries) and add them as
>> runtime dependencies.
>
> Ah!  Awesome.
>
> Right now I'm using %build-inputs, but that's not going to work anymore
> if pcsc-lite isn't an input.  Should I be adding it to the `input' list
> instead, or is there a better way?
>
> I assume you're looking for something like this:
>
>(arguments
> `(#:configure-flags '("--enable-gpg2-is-gpg")
>   #:make-flags (string-append "LDFLAGS=-Wl,-rpath="
>   (assoc-ref %build-inputs "pcsc-lite")
>   "/lib")

Yes, that's exactly what I meant (note that #:make-flags should be a
list). Then "pcsc-lite" can be moved to (inputs), yet gnupg should be
able to find the library at run-time since it will be added to RUNPATH.

However, since this is only needed for "scdaemon", I noticed NixOS
substitutes the libpcsclite.so with the full path in scdaemon.c [0]
instead of adding it to the RUNPATH of all GPG executables. Can you try
that?

You can verify that an input is referenced after building by running
e.g. `guix gc -R $(./pre-inst-env guix build gnupg)`. These "tricks"
enables us to avoid propagation, so that dependencies of a package does
not end up in your profile.

[1]: 
https://github.com/NixOS/nixpkgs/blob/master/pkgs/tools/security/gnupg/21.nix#L31

>> Meanwhile I'll see if I can find a way to test this with a Yubikey.
>> Currently I get:
>> scdaemon[4600]: pcsc_list_readers failed: unknown PC/SC error code 
>> (0x8010002e)
>> ..when using the "gpg-agent --debug-all" command mentioned earlier.
>
> I'm trying to figure out how I got myself into that situation by undoing
> configuration changes, but I'm having trouble reproducing it.  Is that
> the error you're getting from gpg-agent itself, or from gpg based on
> gpg-agent's reply?
>
> I'm not Guix SD yet, but on Trisquel+Guix using my Nitrokey I had to
> modify /etc/libccid_Info.plist, which is part of libccid, according to
> this:
>
>   https://www.nitrokey.com/documentation/installation
>   (Just disable CSS to view without JS.)
>
> I actually completely forgot about libccid.  Perhaps I should add a
> package for that too.


Re: [PATCH 0/2] gnu: Add libpcsclite

2016-10-22 Thread Marius Bakke
Mike Gerwitz  writes:

> This adds libpcsclite for smartcard support.
>
> This is my first Guix package, and I surely screwed something up. :)
> I'd appreciate any help or criticism you can give.  This was not a
> trivial change.

Hi Mike,

Thanks a lot for working on this! The patches look mostly good, see
comments below.

> * gnu/packages/gnupg.scm (libpcsclite): New variable.

I think this should be named "pcsc-lite" to match the upstream name.

> +(propagated-inputs
> + `(("libudev" ,eudev)))

Generally, libraries do not need to be propagated, as they will be added
to rpath by the Guix ld wrapper when they are linked. More on this below.

> +(home-page "https://pcsclite.alioth.debian.org/pcsclite.html;)
> +(synopsis "Middleware to access a smart card using PC/SC")
> +(description
> + "The purpose of PC/SC Lite is to provide a Windows(R) SCard interface in
> +a very small form factor for communicating to smartcards and readers.  The
> +PC/SC Lite library is used to connect to the PC/SC daemon from a client
> +application and provide access to the desired reader.")

I agree that the Windows reference here is unnecessary. Perhaps the
first sentence could be changed to something generic like "pcsc-lite
provides an interface to communicate with smartcards and readers using
the SCard API".

> * gnu/packages/gnupg.scm (gnupg): Add libpcsclite as propagated-input
[...]

> +(propagated-inputs
> + `(("libpcsclite" ,libpcsclite)))
> (arguments
> -`(#:configure-flags '("--enable-gpg2-is-gpg")
> +`(#:configure-flags
> +  (list "--enable-gpg2-is-gpg"
> +(string-append "LDFLAGS=-Wl,-rpath="
> +   (assoc-ref %build-inputs "libpcsclite")
> +   "/lib"))

The intention here is to make gnupg locate the libpcsclite library at
runtime, since it has no build-time checks for it, correct? I think this
approach is fine, if there is no way to make it search the Guix profile
paths for the library.

However, the LDFLAGS need to be in #:make-flags for this to work, and
then pcsc-lite does not need to be propagated, since Guix will scan the
output for store references (including rpath entries) and add them as
runtime dependencies.

Can you see if these changes work for you and send an updated patch?

Meanwhile I'll see if I can find a way to test this with a Yubikey.
Currently I get:
scdaemon[4600]: pcsc_list_readers failed: unknown PC/SC error code (0x8010002e)
..when using the "gpg-agent --debug-all" command mentioned earlier.



Re: [PATCH] gnu: Add whois.

2016-10-22 Thread Marius Bakke
ng0 <n...@we.make.ritual.n0.is> writes:

> Marius Bakke <mba...@fastmail.com> writes:
>
>> ng0 <n...@we.make.ritual.n0.is> writes:
>>
>>
>>> I have my uclibc-ng system not booted: When I specify libiconv in the
>>> inputs, shouldn't it get reported by ldd?
>>>
>>> ng0@shadowwalker 
>>> /gnu/store/fkkvgiqa0x01j6cxipddmn7k20hax1xn-whois-5.2.12/bin$ ls
>>> mkpasswd  whois
>>> ng0@shadowwalker 
>>> /gnu/store/fkkvgiqa0x01j6cxipddmn7k20hax1xn-whois-5.2.12/bin$ ldd whois 
>>> linux-vdso.so.1 (0x7ffcd84fe000)
>>> libidn.so.11 => 
>>> /gnu/store/sbj1kgn8bs91bn7ba9qk4n3l2rr7dxbr-libidn-1.32/lib/libidn.so.11 
>>> (0x7f311084e000)
>>> libgcc_s.so.1 => 
>>> /gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/libgcc_s.so.1 
>>> (0x7f3110638000)
>>> libc.so.6 => 
>>> /gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/libc.so.6 
>>> (0x7f3110296000)
>>> 
>>> /gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/ld-linux-x86-64.so.2
>>>  (0x7f3110a81000)
>>> ng0@shadowwalker 
>>> /gnu/store/fkkvgiqa0x01j6cxipddmn7k20hax1xn-whois-5.2.12/bin$ ldd mkpasswd 
>>> linux-vdso.so.1 (0x7ffed81c7000)
>>> libcrypt.so.1 => 
>>> /gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/libcrypt.so.1 
>>> (0x7fc0328e5000)
>>> libgcc_s.so.1 => 
>>> /gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/libgcc_s.so.1 
>>> (0x7fc0326cf000)
>>> libc.so.6 => 
>>> /gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/libc.so.6 
>>> (0x7fc03232d000)
>>> 
>>> /gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib/ld-linux-x86-64.so.2
>>>  (0x7fc032b1c000)
>>
>> I'm guessing it silently picks the glibc one. FWIW the Gentoo ebuild
>> does the same thing.
>
> That is if your toolchain is glibc based. I have no uclibc-ng or musl
> gentoo system at the moment to check this.
>
>> Does uclibc-ng provide an iconv interface at all?
>
> Yes, but so far I wasn't able to get a response by the hardened project
> to get a comment on their "the iconv of uclibc and uclibc-ng is horrible
> at the moment" comment.. so I'll ask on gentoo-dev list about this, irc
> didn't work.
>
>> Maybe it can be circumvented by having [libc implementation] propagate
>> libiconv, instead of adding it as a direct input to packages.
>
> Possibly. I'm not yet at the point where I can build a system I like
> with this.

I'm happy to commit this package now with the changes mentioned earlier,
if that's okay with you. Making it use an external iconv library feels
like "premature optimization", since it works fine with what we have.



Re: [PATCH] Add iPerf

2016-10-19 Thread Marius Bakke
Benz Schenk <benz.sch...@uzh.ch> writes:

> On Tue, 18 Oct 2016 22:37:40 +0100
> Marius Bakke <mba...@fastmail.com> wrote:
>
>> Benz Schenk <benz.sch...@uzh.ch> writes:
>> 
>> > Hi
>> >
>> > This is my first patch, it's really straight-forward.
>> > But I'm not quite sure about the naming because there's iperf, iperf2
>> > and iperf3 which are different projects. The original iperf is
>> > abandoned and iperf2 is backwards compatible and still gets bug fixes
>> > and iperf3, which this patch is for, is in active development and adds a
>> > lot of new features but also lacks some of the options of previous
>> > versions. Thus it's often referred to as iperf3, which is also the name
>> > of the binary, so I'm not sure wheter the package should better be
>> > called iperf3 or iperf.  
>> 
>> Hi Benz,
>> 
>> Thanks for this patch! I think naming it "iperf" is fine, even though
>> the binary and manual is called iperf3. If we need iperf2 later it can
>> be packaged as "iperf@2".
>> 
>> I'm not sure about the home page: the manual and github page both list
>> http://software.es.net/iperf/ as the home. What is the relation between
>> iperf.fr and this project? Should we not go with the official source?
>> 
>> Other than that I'd like to make the following modifications. This can
>> be done before pushing, no need to send an updated patch:
>> 
>> * Change synopsis to "TCP, UDP and SCTP bandwidth measurement tool".
>> * Update license to match what's in the LICENSE file.
>> * Fix minor typos in the description (bandwith->bandwidth).
>> * Change commit message to match our current convention.
>> * Download the tarball from http://downloads.es.net/pub/iperf/
>> 
>> Are you okay with these changes (including the home page)?
>> 
>> Thanks again, and welcome! :)
>
> Sure thing, I just need the software for uni and got this homepage from
> my advisor.

Thanks for clarifying. I've tested this and pushed it with the mentioned
changes as b747718e230eba267ae158d03d506527bfe1a67a !



Re: [PATCH] Update torsocks to 2.2.0

2016-10-18 Thread Marius Bakke
ng0  writes:

> torsocks 2.2.0 has been released.
> I changed the method from git to url fetch and removed the patch we
> included as it seems to be no longer necessary.

Thanks for paying attention to this.

I couldn't find a link to the download page at first glance, but the
GPG signature is good, and the sources are identical to git apart from
the generated autotools stuff.

I updated local.mk to reflect the removed patch, removed the 'bootstrap'
phase and autotools inputs and adjusted commit message accordingly. I
also updated home-page to HTTPS and removed the 'perl-test-harness'
input as they seem to have switched to a different test framework:

https://gitweb.torproject.org/torsocks.git/commit/?id=e124961ba739861351e3e674f29798a43e4cd734

Pushed as 91988aee126376ea9e111882afb511e3a555936d !



Re: [PATCH 4/4] gnu: xapian: Update to 1.4.0.

2016-10-18 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Mon, Oct 17, 2016 at 05:55:06PM +0100, Marius Bakke wrote:
>> * gnu/packages/search.scm (xapian): Update to 1.4.0.
>> [source]: Use https URL.
>> [home-page]: Use https URL.
>> [arguments]: Remove 'patch-remotetcp-harness' phase. Replace 'check'
>> phase with a list of custom test targets.
>
> Works for me with mu.

Thanks a lot for reviewing, Leo. I'll go ahead and push these tomorrow
with the mentioned changes unless there are other comments. Not happy
about excluding those Xapian tests, but don't know what to do about it.



Re: [PATCH] Add iPerf

2016-10-18 Thread Marius Bakke
Benz Schenk  writes:

> Hi
>
> This is my first patch, it's really straight-forward.
> But I'm not quite sure about the naming because there's iperf, iperf2
> and iperf3 which are different projects. The original iperf is
> abandoned and iperf2 is backwards compatible and still gets bug fixes
> and iperf3, which this patch is for, is in active development and adds a
> lot of new features but also lacks some of the options of previous
> versions. Thus it's often referred to as iperf3, which is also the name
> of the binary, so I'm not sure wheter the package should better be
> called iperf3 or iperf.

Hi Benz,

Thanks for this patch! I think naming it "iperf" is fine, even though
the binary and manual is called iperf3. If we need iperf2 later it can
be packaged as "iperf@2".

I'm not sure about the home page: the manual and github page both list
http://software.es.net/iperf/ as the home. What is the relation between
iperf.fr and this project? Should we not go with the official source?

Other than that I'd like to make the following modifications. This can
be done before pushing, no need to send an updated patch:

* Change synopsis to "TCP, UDP and SCTP bandwidth measurement tool".
* Update license to match what's in the LICENSE file.
* Fix minor typos in the description (bandwith->bandwidth).
* Change commit message to match our current convention.
* Download the tarball from http://downloads.es.net/pub/iperf/

Are you okay with these changes (including the home page)?

Thanks again, and welcome! :)



Re: [PATCH] gnu: Add whois.

2016-10-18 Thread Marius Bakke
ng0  writes:

>> * The Debian package is built with HAVE_ICONV=1, should we set that too?
>
> I can send an updated patch with libiconv in the inputs. This is when
> you use a libc which does not provide a (usable) iconv, which is why
> Gentoo provides the option to build it with this too. As we are
> _currently_ only providing options to do one libc globally this is not
> so inmportant. I will even build uclibc-ng (I am working on that) with
> an outside iconv because reportedly their iconv is in bad shape.
>
> So with this information, should I send a new patch which adds libiconv
> and the build option?

Since we only support glibc at the moment, I don't think adding a
package for libiconv first is necessary. On the other hand, if it can
cause problems on other libc's, it's nice to use an external one.

IMO adding libiconv as input is something that can be done later, when
there is an actual need for it. I guess there are more packages that
will require it. But I don't really mind either way :)

>> Additionally it installs locales, but looks for /usr/share/locale at
>> runtime. Fixing this would probably require upstream help, I don't want
>> to hardcode either "/run/current-system/locale" or ~/.guix-profile. The
>> current version probably works on foreign distros, if nothing else.
>
> If you know how to fix it, try to bring it to upstream or include a
> patch / substitute phase at our end?

I tried patching whois.c to use the glibc default in the call to
bindtextdomain(3), instead of the LOCALEDIR build option. That almost
worked: it searches the system locales, but also expect to find the
translation files there. I'll see if I can cook up a fix for upstream,
but don't think this should hold back the package.



Re: [PATCH] gnu: Add whois.

2016-10-18 Thread Marius Bakke
ng0  writes:

> * gnu/packages/networking.scm (whois): New variable.

Thanks! This works for me. I have a couple of remarks that can be added
before committing if you agree, no need to send an updated patch.

* The source headers seems to indicate that this is GPL2+.
* The only reference to this program on the home page is a link to
  GitHub, do you think we should use that as home-page?
* Gettext only seems used for building locales and is not referenced at
  runtime, perhaps it should be a native-input?
* The Debian package is built with HAVE_ICONV=1, should we set that too?

Additionally it installs locales, but looks for /usr/share/locale at
runtime. Fixing this would probably require upstream help, I don't want
to hardcode either "/run/current-system/locale" or ~/.guix-profile. The
current version probably works on foreign distros, if nothing else.

Are these changes sensible?



Re: [PATCH] gnu: Add vim-full.

2016-10-17 Thread Marius Bakke
ng0 <n...@we.make.ritual.n0.is> writes:

> Hi,
>
> thanks for reviewing.
>
> Marius Bakke <mba...@fastmail.com> writes:
>
>> ng0 <n...@we.make.ritual.n0.is> writes:
>>
>>> * gnu/packages/vim.scm (vim-full): New variable.
>>> * gnu/packages/patches/vim-8.0.0003.patch: New file.
>>> * gnu/packages/patches/vim-8.0.0004.patch: New file.
>>> * gnu/packages/patches/vim-8.0.0005.patch: New file.
>>> * gnu/local.mk (dist_patch_DATA): Add patches.
>>> ---
>>>  gnu/local.mk|  3 ++
>>>  gnu/packages/patches/vim-8.0.0003.patch | 87 
>>> +
>>>  gnu/packages/patches/vim-8.0.0004.patch | 60 +++
>>>  gnu/packages/patches/vim-8.0.0005.patch | 45 +
>>>  gnu/packages/vim.scm| 81 ++
>>>  5 files changed, 276 insertions(+)
>>>  create mode 100644 gnu/packages/patches/vim-8.0.0003.patch
>>>  create mode 100644 gnu/packages/patches/vim-8.0.0004.patch
>>>  create mode 100644 gnu/packages/patches/vim-8.0.0005.patch
>>
>> [...]
>>
>>> +
>>> +(define-public vim-full
>>> +  (package
>>> +(inherit vim)
>>> +(name "vim-full")
>>> +(version (package-version vim))
>>> +(source
>>> + (origin
>>> +   (method url-fetch)
>>> +   (uri (string-append "ftp://ftp.vim.org/pub/vim/unix/vim-;
>>> +   version ".tar.bz2"))
>>> +   (sha256
>>> +(base32
>>> + "1s34rf8089klsbdx5l0iw7vjymir0kzfrx8wb30s31wygnq29axc"))
>>> +   ;; Patches need to be applied sequentially. 8.0 is the release of
>>> +   ;; vim version 8.0.0002 so we start at 8.0.0003
>>> +   (patches (search-patches "vim-8.0.0003.patch"
>>> +"vim-8.0.0004.patch"
>>> +"vim-8.0.0005.patch"
>>
>> Shouldn't these patches be applied on the base vim package? Then
>> "vim-full" can just inherit the source from there. I also think
>> "version" should be adjusted to match the patch level.
>
> No (for explanation see the other emails I've sent in the earlier
> thread).
> I agree on the version, I will update that.

Upstream recommends using the Github releases [0] for 8.0 which are at
8.0.0042 already. Do you think it makes sense to switch to that source
for both packages? Then we might avoid carrying the patches entirely.

0: https://github.com/vim/vim/releases



Re: [PATCH 2/4] gnu: notmuch: Enable tests.

2016-10-17 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Mon, Oct 17, 2016 at 05:55:04PM +0100, Marius Bakke wrote:
>> * gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch: New file.
>> * gnu/local.mk (dist_patch_DATA): Register it.
>> * gnu/packages/mail.scm (notmuch)[arguments]: Add verbose make flags.
>>   Add phase 'patch-notmuch-lib.el' to fix hard-coded /bin/sh.
>>   Add 'prepare-test-environment' phase to patch test shebangs and set
>>   environment.
>> [native-inputs]: Change from 'emacs-minimal' to 'emacs-no-x'. Add dtach,
>>   gnupg, man, perl and which.
>
> A true nit-pick, but all those lines should start at column 0 rather
> than being indented.

Noted.

>
>> +  (patches
>> +   ;; This is included in the next release.
>> +   ;; https://notmuchmail.org/pipermail/notmuch/2016/023309.html
>> +   (search-patches 
>> "notmuch-emacs-25-compatibility-fix.patch"
>
> Please mention the use of this patch in the commit changelog.

Oops, thanks!

>
>> +   ;; The following are required for tests only.
>> +   ("which" ,which)
>> +   ("dtach" ,dtach)
>> +   ("gnupg" ,gnupg)
>> +   ("man" ,man-db)
>> +   ("perl" ,perl)))
>
> Can you check if these inputs are referenced by the output? Ideally
> not...
>
> $ guix gc --references $(./pre-inst-env guix build notmuch)

Good point, I did not verify this until now. They are not referenced by
the output.

>
>> diff --git a/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch 
>> b/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch
>> new file mode 100644
>> index 000..456b345
>> --- /dev/null
>> +++ b/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch
>> @@ -0,0 +1,43 @@
>> +From f575a346df09c82691bb9e7c462836d982fe31f7 Mon Sep 17 00:00:00 2001
>> +From: David Bremner <da...@tethera.net>
>> +Date: Sun, 9 Oct 2016 19:30:44 -0300
>> +Subject: [PATCH] emacs/show: force notmuch-show-buttonise-links to act on
>> + lines
>
> If possible, please add a hyperlink to the source of the patch. Ideally,
> to a Git commit in a web-based Git repo interface.
>
> Not knowing Emacs Lisp, I can't comment on the patch itself.

The bug was exposed by enabling tests against emacs 25 and will be
included in the next release. See this thread:

https://notmuchmail.org/pipermail/notmuch/2016/023227.html

I will add a gitweb link to the patch header.



Re: [PATCH 1/4] gnu: notmuch: Update to 0.23.

2016-10-17 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Mon, Oct 17, 2016 at 05:55:03PM +0100, Marius Bakke wrote:
>> * gnu/packages/mail.scm (notmuch, python-notmuch): Update to 0.23.
>> [home-page]: Use https URL.
>
> LGTM. Is it possible to use (package-version notmuch) as
> python-notmuch's version?

That worked fine, thanks.



Re: [PATCH 3/4] gnu: xapian: Use 'modify-phases'.

2016-10-17 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Mon, Oct 17, 2016 at 05:55:05PM +0100, Marius Bakke wrote:
>> * gnu/packages/search.scm (xapian)[arguments]: Use 'modify-phases'.
>
>> + `(#:phases
>> +   (modify-phases %standard-phases
>> + (add-after 'unpack 'patch-remotetcp-harness
>> +   (lambda _
>> + (substitute* "tests/harness/backendmanager_remotetcp.cc"
>> +   (("/bin/sh") (which "bash"
>
> Please change it to use (which "sh") instead. Bash changes its behavior
> based on whether it is called as `bash` or `sh` (see Invocation in
> bash(1)).

I'm aware, but decided to remove it in the subsequent patch since it was
"buggy" anyway, and is not needed when remote TCP tests are disabled.

It was left to avoid justifying the fix when changing to modify-phases.
The phase also does not end on a #t.

But I agree, might as well just fix it and leave it even if the tests
don't use it.



Re: [PATCH] gnu: Add vim-full.

2016-10-17 Thread Marius Bakke
ng0  writes:

> * gnu/packages/vim.scm (vim-full): New variable.
> * gnu/packages/patches/vim-8.0.0003.patch: New file.
> * gnu/packages/patches/vim-8.0.0004.patch: New file.
> * gnu/packages/patches/vim-8.0.0005.patch: New file.
> * gnu/local.mk (dist_patch_DATA): Add patches.
> ---
>  gnu/local.mk|  3 ++
>  gnu/packages/patches/vim-8.0.0003.patch | 87 
> +
>  gnu/packages/patches/vim-8.0.0004.patch | 60 +++
>  gnu/packages/patches/vim-8.0.0005.patch | 45 +
>  gnu/packages/vim.scm| 81 ++
>  5 files changed, 276 insertions(+)
>  create mode 100644 gnu/packages/patches/vim-8.0.0003.patch
>  create mode 100644 gnu/packages/patches/vim-8.0.0004.patch
>  create mode 100644 gnu/packages/patches/vim-8.0.0005.patch

[...]

> +
> +(define-public vim-full
> +  (package
> +(inherit vim)
> +(name "vim-full")
> +(version (package-version vim))
> +(source
> + (origin
> +   (method url-fetch)
> +   (uri (string-append "ftp://ftp.vim.org/pub/vim/unix/vim-;
> +   version ".tar.bz2"))
> +   (sha256
> +(base32
> + "1s34rf8089klsbdx5l0iw7vjymir0kzfrx8wb30s31wygnq29axc"))
> +   ;; Patches need to be applied sequentially. 8.0 is the release of
> +   ;; vim version 8.0.0002 so we start at 8.0.0003
> +   (patches (search-patches "vim-8.0.0003.patch"
> +"vim-8.0.0004.patch"
> +"vim-8.0.0005.patch"

Shouldn't these patches be applied on the base vim package? Then
"vim-full" can just inherit the source from there. I also think
"version" should be adjusted to match the patch level.

Other than that this package works for me. Perhaps the description could
be updated to mention that this also includes the graphical "gvim" if
anyone is searching for that.

Could you separate this out to two patches, one that updates "vim" and
one that adds "vim-full"?

Thanks!



[PATCH 4/4] gnu: xapian: Update to 1.4.0.

2016-10-17 Thread Marius Bakke
* gnu/packages/search.scm (xapian): Update to 1.4.0.
[source]: Use https URL.
[home-page]: Use https URL.
[arguments]: Remove 'patch-remotetcp-harness' phase. Replace 'check'
phase with a list of custom test targets.
---
 gnu/packages/search.scm | 22 +++---
 1 file changed, 15 insertions(+), 7 deletions(-)

diff --git a/gnu/packages/search.scm b/gnu/packages/search.scm
index a43abde..5d7def5 100644
--- a/gnu/packages/search.scm
+++ b/gnu/packages/search.scm
@@ -35,30 +35,38 @@
 (define-public xapian
   (package
 (name "xapian")
-(version "1.2.21")
+(version "1.4.0")
 (source (origin
   (method url-fetch)
-  (uri (string-append "http://oligarchy.co.uk/xapian/; version
+  (uri (string-append "https://oligarchy.co.uk/xapian/; version
   "/xapian-core-" version ".tar.xz"))
   (sha256
-   (base32 
"0grd2s6gf8yzqwdaa50g57j9d81mxkrrpkyldm2shgyizdc8gx33"
+   (base32 
"0xv4da5rmqqzkkkzx2v3jwh5hz5zxhd2b7m8x30fk99a25blyn0h"
 (build-system gnu-build-system)
 (inputs `(("zlib" ,zlib)
   ("util-linux" ,util-linux)))
 (arguments
  `(#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'patch-remotetcp-harness
+ (replace 'check
+   ;; As of Xapian 1.3.3, the TCP server implementation uses
+   ;; getaddrinfo(). This does not work in the build environment,
+   ;; so exclude those tests. See HACKING for the list of targets.
(lambda _
- (substitute* "tests/harness/backendmanager_remotetcp.cc"
-   (("/bin/sh") (which "bash"
+ (zero? (system* "make"
+ "check-inmemory"
+ "check-remoteprog"
+ ;"check-remotetcp"
+ "check-multi"
+ "check-glass"
+ "check-chert")))
 (synopsis "Search Engine Library")
 (description
  "Xapian is a highly adaptable toolkit which allows developers to easily
 add advanced indexing and search facilities to their own applications.  It
 supports the Probabilistic Information Retrieval model and also supports a
 rich set of boolean query operators.")
-(home-page "http://xapian.org/;)
+(home-page "https://xapian.org/;)
 (license (list gpl2+ bsd-3 x11
 
 (define-public libtocc
-- 
2.10.1




[PATCH 3/4] gnu: xapian: Use 'modify-phases'.

2016-10-17 Thread Marius Bakke
* gnu/packages/search.scm (xapian)[arguments]: Use 'modify-phases'.
---
 gnu/packages/search.scm | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/gnu/packages/search.scm b/gnu/packages/search.scm
index 9eb4039..a43abde 100644
--- a/gnu/packages/search.scm
+++ b/gnu/packages/search.scm
@@ -46,12 +46,12 @@
 (inputs `(("zlib" ,zlib)
   ("util-linux" ,util-linux)))
 (arguments
- `(#:phases (alist-cons-after
- 'unpack 'patch-remotetcp-harness
- (lambda _
-   (substitute* "tests/harness/backendmanager_remotetcp.cc"
- (("/bin/sh") (which "bash"
- %standard-phases)))
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'patch-remotetcp-harness
+   (lambda _
+ (substitute* "tests/harness/backendmanager_remotetcp.cc"
+   (("/bin/sh") (which "bash"
 (synopsis "Search Engine Library")
 (description
  "Xapian is a highly adaptable toolkit which allows developers to easily
-- 
2.10.1




[PATCH 0/4] Notmuch and Xapian update.

2016-10-17 Thread Marius Bakke
This brings notmuch and xapian to the latest upstream releases.

Unfortunately some Xapian tests had to be excluded. If anyone knows
how to make getaddrinfo() work for 127.0.0.1 in the build chroot, I'm
all ears.

NB notmuch users: You may have to adjust 'notmuch-fcc-dirs' after this.
See release announcement:
https://notmuchmail.org/pipermail/notmuch/2016/023216.html

$ git diff --stat master
 gnu/local.mk  |  1 +
 gnu/packages/mail.scm | 42 
+-
 .../patches/notmuch-emacs-25-compatibility-fix.patch  | 43 
+++
 gnu/packages/search.scm   | 28 +--
 4 files changed, 95 insertions(+), 19 deletions(-)




[PATCH 2/4] gnu: notmuch: Enable tests.

2016-10-17 Thread Marius Bakke
* gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register it.
* gnu/packages/mail.scm (notmuch)[arguments]: Add verbose make flags.
  Add phase 'patch-notmuch-lib.el' to fix hard-coded /bin/sh.
  Add 'prepare-test-environment' phase to patch test shebangs and set
  environment.
[native-inputs]: Change from 'emacs-minimal' to 'emacs-no-x'. Add dtach,
  gnupg, man, perl and which.
---
 gnu/local.mk   |  1 +
 gnu/packages/mail.scm  | 36 +++---
 .../notmuch-emacs-25-compatibility-fix.patch   | 43 ++
 3 files changed, 74 insertions(+), 6 deletions(-)
 create mode 100644 
gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 9079b42..9d7e14b 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -728,6 +728,7 @@ dist_patch_DATA =   
\
   %D%/packages/patches/ninja-tests.patch   \
   %D%/packages/patches/ninja-zero-mtime.patch  \
   %D%/packages/patches/node-9077.patch \
+  %D%/packages/patches/notmuch-emacs-25-compatibility-fix.patch\
   %D%/packages/patches/nss-pkgconfig.patch \
   %D%/packages/patches/nvi-assume-preserve-path.patch  \
   %D%/packages/patches/nvi-dbpagesize-binpower.patch   \
diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index 1cb3ef4..6ab4035 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -72,7 +72,9 @@
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages flex)
   #:use-module (gnu packages gdb)
+  #:use-module (gnu packages man)
   #:use-module (gnu packages samba)
+  #:use-module (gnu packages screen)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages networking)
   #:use-module (gnu packages web)
@@ -501,12 +503,20 @@ invoking @command{notifymuch} from the post-new hook.")
   version ".tar.gz"))
   (sha256
(base32
-"1f51l34rdhjf8lvafrwybkxdsdwx8k9397m7qxd8rdg2irjmpry5"
+"1f51l34rdhjf8lvafrwybkxdsdwx8k9397m7qxd8rdg2irjmpry5"))
+  (patches
+   ;; This is included in the next release.
+   ;; https://notmuchmail.org/pipermail/notmuch/2016/023309.html
+   (search-patches "notmuch-emacs-25-compatibility-fix.patch"
 (build-system gnu-build-system)
 (arguments
- '(#:tests? #f ; FIXME: 723 tests; 187 fail and 100 are skipped
-   ; with perl input: 67 fail and 100 are skipped
+ '(#:make-flags (list "V=1") ; Verbose test output.
#:phases (modify-phases %standard-phases
+  (add-after 'unpack 'patch-notmuch-lib.el
+(lambda _
+  (substitute* "emacs/notmuch-lib.el"
+(("/bin/sh") (which "sh")))
+  #t))
   (replace 'configure
 (lambda* (#:key outputs #:allow-other-keys)
   (setenv "CC" "gcc")
@@ -514,14 +524,28 @@ invoking @command{notifymuch} from the post-new hook.")
 
   (let ((out (assoc-ref outputs "out")))
 (zero? (system* "./configure"
-(string-append "--prefix=" out)
+(string-append "--prefix=" out))
+  (add-before 'check 'prepare-test-environment
+(lambda _
+  (setenv "TEST_CC" "gcc")
+  ;; Patch various inline shell invocations.
+  (substitute* (find-files "test" "\\.sh$")
+(("/bin/sh") (which "sh")))
+  #t)
 (native-inputs
  `(("bash-completion" ,bash-completion)
-   ("emacs" ,emacs-minimal)
+   ("emacs" ,emacs-no-x) ; Minimal lacks libxml, needed for some tests.
("pkg-config" ,pkg-config)
("python" ,python-2)
("python-docutils" ,python2-docutils)
-   ("python-sphinx" ,python2-sphinx)))
+   ("python-sphinx" ,python2-sphinx)
+
+   ;; The following are required for tests only.
+   ("which" ,which)
+   ("dtach" ,dtach)
+   ("gnupg" ,gnupg)
+   ("man" ,man-db)
+   ("perl" ,perl)))
 (inputs
  `(("glib" ,glib)
("gmime" ,gmime)
diff --git a/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch 
b/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch
new file mode 100644
index 000..456b345
--- /dev/null
+++ b/gnu/packages/patches/notmuch-emacs-25-compatibility-fix.patch
@@ -0,0 +1,43 @@
+From f575a346df09c82691bb9e7c462836d982fe31f7 Mon Sep 17 00:00:00 2001
+From: David Bremner 
+Date: Sun, 9 Oct 2016 19:30:44 -0300
+Subject: [PATCH] emacs/show: force 

[PATCH 1/4] gnu: notmuch: Update to 0.23.

2016-10-17 Thread Marius Bakke
* gnu/packages/mail.scm (notmuch, python-notmuch): Update to 0.23.
[home-page]: Use https URL.
---
 gnu/packages/mail.scm | 12 ++--
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index 47c1549..1cb3ef4 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -494,18 +494,18 @@ invoking @command{notifymuch} from the post-new hook.")
 (define-public notmuch
   (package
 (name "notmuch")
-(version "0.22.1")
+(version "0.23")
 (source (origin
   (method url-fetch)
   (uri (string-append "https://notmuchmail.org/releases/notmuch-;
   version ".tar.gz"))
   (sha256
(base32
-"0jwpda3q023dn3sp41n8648951i7iagfv8zzpriv7hpkjivlafg7"
+"1f51l34rdhjf8lvafrwybkxdsdwx8k9397m7qxd8rdg2irjmpry5"
 (build-system gnu-build-system)
 (arguments
- '(#:tests? #f ; FIXME: 694 tests; 170 fail and 100 are skipped
-   ; with perl input: 50 fail and 100 are skipped
+ '(#:tests? #f ; FIXME: 723 tests; 187 fail and 100 are skipped
+   ; with perl input: 67 fail and 100 are skipped
#:phases (modify-phases %standard-phases
   (replace 'configure
 (lambda* (#:key outputs #:allow-other-keys)
@@ -528,7 +528,7 @@ invoking @command{notifymuch} from the post-new hook.")
("talloc" ,talloc)
("xapian" ,xapian)
("zlib" ,zlib)))
-(home-page "http://notmuchmail.org/;)
+(home-page "https://notmuchmail.org/;)
 (synopsis "Thread-based email index, search, and tagging")
 (description
  "Notmuch is a command-line based program for indexing, searching, read-
@@ -579,7 +579,7 @@ useful for email address completion.")
 (define-public python-notmuch
   (package
 (name "python-notmuch")
-(version "0.22.1")
+(version "0.23")
 ;; Notmuch python bindings are now unavailable on pypi.  The
 ;; bindings are distributed via the notmuch release tarball.
 (source (package-source notmuch))
-- 
2.10.1




Re: gnu: artanis: Remove implied $(DESTDIR) usage.

2016-10-17 Thread Marius Bakke
Adonay Felipe Nogueira  writes:

> Oh my! ... Sorry for being careless. I guess I was so happy to finally
> fix the problem upstream that I forgot to adapt our recipe accordingly.
>
> Thanks for testing. :)
>
> I have made the patch again, and also properly referenced the patch
> tickets from upstream.

Thanks! I made slight adjustments to the commit message and kept the
original (let* ((out ...))) to make it clearer what the patch does.

Pushed as 8a666bc5cb3c50b4b881290c7776c3f681a734bc !



Re: [PATCH 03/15] gnu: Add chez-web.

2016-10-16 Thread Marius Bakke
Federico Beffa  writes:

> From 828438eb009a557cd0be5f0e2a42eebb0d59257d Mon Sep 17 00:00:00 2001
> From: Federico Beffa 
> Date: Sun, 16 Oct 2016 15:59:49 +0200
> Subject: [PATCH 03/15] gnu: Add chez-web
>
> * gnu/packages/chez.scm (chez-web): New variable.
> ---
>  gnu/packages/chez.scm | 49 +
>  1 file changed, 49 insertions(+)
>
> diff --git a/gnu/packages/chez.scm b/gnu/packages/chez.scm
> index 68591da..d9f6f71 100644
> --- a/gnu/packages/chez.scm
> +++ b/gnu/packages/chez.scm
> @@ -22,6 +22,7 @@
>  #:select (gpl2+ lgpl2.0+ lgpl2.1+ asl2.0 bsd-3 expat))
>#:use-module (guix packages)
>#:use-module (guix download)
> +  #:use-module (guix git-download)
>#:use-module (guix utils)
>#:use-module (guix build-system gnu)
>#:use-module (gnu packages compression)
> @@ -222,3 +223,51 @@ and 32-bit PowerPC architectures.")
>  (description
>   "This package provides a collection of SRFI libraries for Chez Scheme.")
>  (license expat)))
> +
> +(define-public chez-web
> +  (package
> +(name "chez-web")
> +;; release 2.0 is different and doesn't work.

Can you expand on this comment? Why does the released version not work?

> +(version "2.0-1.5fd177f")
> +(source
> + (origin
> +   (method git-fetch)
> +   (uri (git-reference
> + (url "https://github.com/arcfide/ChezWEB.git;)
> + (commit "5fd177fe53f31f466bf88720d03c95a3711a8bea")))
> +   (file-name (string-append name "-" version "-checkout"))
> +   (sha256
> +(base32 "1dq25qygyncbfq4kwwqqgyyakfqjwhp5q23vrf3bff1p66nyfl3b"
> +(build-system gnu-build-system)
> +(native-inputs
> + `(("chez-scheme" ,chez-scheme)
> +   ("texlive" ,texlive)))
> +(arguments
> + `(#:make-flags (let ((out (assoc-ref %outputs "out")))
> +  (list (string-append "PREFIX=" out)
> +(string-append "DOCDIR=" out "/share/doc/"
> +   ,name "-" ,version)
> +(string-append "LIBDIR=" out "/lib/chezweb")
> +(string-append "TEXDIR=" out 
> "/share/texmf-local")))

You can use %output instead of (assoc-ref %outputs "out") here.

> +   #:tests? #f ; no tests
> +   #:phases
> +   (modify-phases %standard-phases
> + (replace 'configure
> +   (lambda* _
> + (copy-file "config.mk.template" "config.mk")
> + (substitute* "tangleit"
> +   (("\\./cheztangle\\.ss" all)
> +(string-append "chez-scheme --program " all)))
> + (substitute* "weaveit"
> +   (("mpost chezweb\\.mp")
> +"mpost --tex=tex chezweb.mp")
> +   (("\\./chezweave" all)
> +(string-append "chez-scheme --program " all)))
> + (substitute* "installit"
> +   (("-g \\$GROUP -o \\$OWNER") "")))
> +(home-page "https://github.com/arcfide/ChezWEB;)
> +(synopsis "Hygienic Literate Programming for Chez Scheme")
> +(description "ChezWEB is a system for doing Knuthian style WEB
> +programming in Scheme, and more particularly, it is implemented in
> +Chez Scheme.")

I think the description up to the first comma is enough, since chez
scheme is implied by the name.



Re: [PATCH 09/15] gnu: Add ghc-hmatrix.

2016-10-16 Thread Marius Bakke
Federico Beffa  writes:

> From 9cbbc66e111c5446f818ce1f9aa8f1bc52300bec Mon Sep 17 00:00:00 2001
> From: Federico Beffa 
> Date: Sun, 16 Oct 2016 16:25:26 +0200
> Subject: [PATCH 09/15] gnu: Add ghc-hmatrix.
>
> * gnu/packages/haskell.scm (ghc-hmatrix): New variable.
> ---
>  gnu/packages/haskell.scm | 33 -
>  1 file changed, 32 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm
> index 50b09ef..4203227 100644
> --- a/gnu/packages/haskell.scm
> +++ b/gnu/packages/haskell.scm
> @@ -1,5 +1,5 @@
>  ;;; GNU Guix --- Functional package management for GNU
> -;;; Copyright © 2015 Federico Beffa 
> +;;; Copyright © 2015, 2016 Federico Beffa 
>  ;;; Copyright © 2015 Siniša Biđin 
>  ;;; Copyright © 2015 Paul van der Walt 
>  ;;; Copyright © 2015 Eric Bavier 
> @@ -44,6 +44,7 @@
>#:use-module (gnu packages libffi)
>#:use-module (gnu packages libedit)
>#:use-module (gnu packages lua)
> +  #:use-module (gnu packages maths)
>#:use-module (gnu packages multiprecision)
>#:use-module (gnu packages ncurses)
>#:use-module (gnu packages python)
> @@ -7619,4 +7620,34 @@ Storable instance for Complex which is binary 
> compatible with C99, C++
>  and Fortran complex data types.")
>  (license license:bsd-3)))
>  
> +(define-public ghc-hmatrix
> +  (package
> +(name "ghc-hmatrix")
> +(version "0.17.0.2")
> +(source
> + (origin
> +   (method url-fetch)
> +   (uri (string-append
> + "http://hackage.haskell.org/package/hmatrix/hmatrix-;
> + version ".tar.gz"))
> +   (sha256
> +(base32 "1fgsrh2y9y971pzrd3767rg97bjr1ghpdvwmn1nn65s90rc9bv98"
> +(build-system haskell-build-system)
> +(inputs
> + `(("ghc-random" ,ghc-random)
> +   ("ghc-split" ,ghc-split)
> +   ("ghc-storable-complex" ,ghc-storable-complex)
> +   ("ghc-vector" ,ghc-vector)
> +   ;;("openblas" ,openblas)
> +   ("lapack" ,lapack)))
> +;;; Guix's OpenBLAS is built with the floag "NO_LAPACK=1" which
> +;;; disables inclusion of the LAPACK functions.
   ^^^
Only two semicolons here. Also s/floag/flag.

> +;;(arguments `(#:configure-flags '("--flags=openblas")))
> +(home-page "https://github.com/albertoruiz/hmatrix;)
> +(synopsis "Haskell numeric linear algebra library")
> +(description "The HMatrix package provices a Haskell library for
> +dealing with linear systems, matrix decompositions, and other
> +numerical computations based on BLAS and LAPACK.")
> +(license license:bsd-3)))
> +
>  ;;; haskell.scm ends here
> -- 
> 2.7.4



Re: gnu: artanis: Remove implied $(DESTDIR) usage.

2016-10-16 Thread Marius Bakke
Adonay Felipe Nogueira  writes:

> My first patch to Guix project, I hope this helps. :)

Welcome and thanks for this patch! :)

The current artanis package has a bug where the install location is set
to "$out/$out/share/guile/site/2.0". This patch fixes that by installing
to "$out/share/guile/site/2.0". I can load it from the Guile REPL now.

However, the same files are still present in
/gnu/store/...-artanis-0.1.2/gnu/store/...-artanis-0.1.2 as before. It
seems to be installed to both $out and $out/$out. Do you think you can
prevent this from happening as well?

Other than that I only have one remark:

[...]

> diff --git a/gnu/packages/patches/artanis-fix-Makefile.in.patch 
> b/gnu/packages/patches/artanis-fix-Makefile.in.patch
> new file mode 100644
> index 000..d2c19f1
> --- /dev/null
> +++ b/gnu/packages/patches/artanis-fix-Makefile.in.patch
> @@ -0,0 +1,69 @@
> +Applies until an Artanis release comes with patches #9130 and #9131
> +applied.

Please mention the upstream commit hash or bug report here, so that
the next person can easily tell whether this is still needed or not.

Can you send an updated patch?

Thanks!



Re: [PATCH] gnu: gd: Fix CVE-2016-8670.

2016-10-15 Thread Marius Bakke
Kei Kebreau  writes:

> This patch fixes the gd library's most recent published vulnerability on
> the oss-security list.

Looks like this was already applied by Leo in
e1376e25a755a7368d095b4eb2daf42be9e63b0d.



Re: [PATCH] gnu: Add python-whoosh.

2016-10-15 Thread Marius Bakke
Kei Kebreau  writes:

> Ricardo Wurmus  writes:
>
>> * gnu/packages/python.scm (python-whoosh, python2-whoosh): New variables.
>> ---
>>  gnu/packages/python.scm | 30 ++
>>  1 file changed, 30 insertions(+)
>>
>> diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
>> index 6207896..69c7d36 100644
>> --- a/gnu/packages/python.scm
>> +++ b/gnu/packages/python.scm
>> @@ -8823,6 +8823,36 @@ library.")
>>(native-inputs `(("python2-setuptools" ,python2-setuptools)
>> ,@(package-native-inputs responses))
>>  
>> +(define-public python-whoosh
>> +  (package
>> +(name "python-whoosh")
>> +(version "2.7.4")
>> +(source
>> + (origin
>> +   (method url-fetch)
>> +   (uri (pypi-uri "Whoosh" version))
>> +   (sha256
>> +(base32
>> + "10qsqdjpbc85fykc1vgcs8xwbgn4l2l52c8d83xf1q59pwyn79bw"
>> +(build-system python-build-system)
>> +(native-inputs
>> + `(("python-setuptools" ,python-setuptools)
>> +   ("python-pytest" ,python-pytest)))
>> +(home-page "http://bitbucket.org/mchaput/whoosh;)
>> +(synopsis "Full text indexing, search, and spell checking library")
>> +(description
>> + "Whoosh is a fast, pure-Python full text indexing, search, and spell
>> +checking library.")
>> +(license license:bsd-2)))
>> +
>> +(define-public python2-whoosh
>> +  (let ((whoosh (package-with-python2 (strip-python2-variant 
>> python-whoosh
>> +(package (inherit whoosh)
>> +  (propagated-inputs
>> +   `(("python2-backport-ssl-match-hostname"
>> +  ,python2-backport-ssl-match-hostname)
>> +  ,@(package-propagated-inputs whoosh))
>> +
>>  (define-public python-pathlib
>>(package
>>  (name "python-pathlib")
>
> Linting works fine, but outputs differ on each build. Is this a common
> problem with python packages?

Yes, it's a common problem with python packages. This should be largely
fixed by the new python build system however.

Wrt the patch, setuptools is not required for the python3 variant. But
since it will no longer be required for python2 either after the new
build system, I think it's okay to keep it for now, since it would
complicate the patch a lot.

LGTM.



Re: [PATCH]Add ati support to xorg configuration.

2016-10-06 Thread Marius Bakke
Dmitry Nikolaev  writes:

> Hi. Without this patch I couldn't run X on my Radeon card.

Thanks! This looks good to me, but please add a commit message that
follows our conventions. Check "git log --grep service" for examples.

> Dmitry Nikolaev
> From 25f8f50e1bd6efaee0008283ca1de8b1fe951d7e Mon Sep 17 00:00:00 2001
> From: 8p8c 
> Date: Thu, 6 Oct 2016 00:09:00 +0300
> Subject: [PATCH] Add Ati drivers to xorg configuration
>
> ---
>  gnu/services/xorg.scm | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm
> index d098d83..ccac677 100644
> --- a/gnu/services/xorg.scm
> +++ b/gnu/services/xorg.scm
> @@ -108,6 +108,7 @@ Section \"Files\"
>FontPath \"" font-adobe75dpi "/share/fonts/X11/75dpi\"
>ModulePath \"" xf86-video-vesa "/lib/xorg/modules/drivers\"
>ModulePath \"" xf86-video-fbdev "/lib/xorg/modules/drivers\"
> +  ModulePath \"" xf86-video-ati "/lib/xorg/modules/drivers\"
>ModulePath \"" xf86-video-modesetting "/lib/xorg/modules/drivers\"
>ModulePath \"" xf86-video-cirrus "/lib/xorg/modules/drivers\"
>ModulePath \"" xf86-video-intel "/lib/xorg/modules/drivers\"
> @@ -145,6 +146,7 @@ EndSection
>  (define %default-xorg-modules
>(list xf86-video-vesa
>  xf86-video-fbdev
> +xf86-video-ati
>  xf86-video-modesetting
>  xf86-video-cirrus
>  xf86-video-intel
> -- 
> 2.10.0



[PATCH] gnu: wpa-supplicant: Update to 2.6.

2016-10-06 Thread Marius Bakke

None of the patches applied, so I assume they are upstream.

Tested locally. Please push if it's good.

>From 28a85174650e5602364290f9b7d1259f4148bcf1 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 5 Oct 2016 04:08:46 +0100
Subject: [PATCH] gnu: wpa-supplicant: Update to 2.6.

* gnu/packages/admin.scm (wpa-supplicant-minimal)[source]: Update to
  2.6. Remove 'patches' field.
* gnu/packages/patches/wpa-supplicant-CVE-2015-5310.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2015-5314.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2015-5315.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2015-5316.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2016-4476.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt1.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt2.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt3.patch,
  gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt4.patch: Delete
  files.
* gnu/local.mk (dist_patch_DATA): Remove them.
---
 gnu/local.mk   |  9 ---
 gnu/packages/admin.scm | 14 +---
 .../patches/wpa-supplicant-CVE-2015-5310.patch | 32 -
 .../patches/wpa-supplicant-CVE-2015-5314.patch | 51 --
 .../patches/wpa-supplicant-CVE-2015-5315.patch | 54 --
 .../patches/wpa-supplicant-CVE-2015-5316.patch | 34 -
 .../patches/wpa-supplicant-CVE-2016-4476.patch | 82 --
 .../patches/wpa-supplicant-CVE-2016-4477-pt1.patch | 51 --
 .../patches/wpa-supplicant-CVE-2016-4477-pt2.patch | 82 --
 .../patches/wpa-supplicant-CVE-2016-4477-pt3.patch | 62 
 .../patches/wpa-supplicant-CVE-2016-4477-pt4.patch | 50 -
 11 files changed, 2 insertions(+), 519 deletions(-)
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2015-5310.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2015-5314.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2015-5315.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2015-5316.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2016-4476.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt1.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt2.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt3.patch
 delete mode 100644 gnu/packages/patches/wpa-supplicant-CVE-2016-4477-pt4.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 867946d..32da04a 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -888,15 +888,6 @@ dist_patch_DATA =		\
   %D%/packages/patches/wordnet-CVE-2008-2149.patch			\
   %D%/packages/patches/wordnet-CVE-2008-3908-pt1.patch			\
   %D%/packages/patches/wordnet-CVE-2008-3908-pt2.patch			\
-  %D%/packages/patches/wpa-supplicant-CVE-2015-5310.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2015-5314.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2015-5315.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2015-5316.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2016-4476.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2016-4477-pt1.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2016-4477-pt2.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2016-4477-pt3.patch	\
-  %D%/packages/patches/wpa-supplicant-CVE-2016-4477-pt4.patch	\
   %D%/packages/patches/xdotool-fix-makefile.patch   \
   %D%/packages/patches/xf86-video-ark-remove-mibstore.patch	\
   %D%/packages/patches/xf86-video-ast-remove-mibstore.patch	\
diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index cfb33c4..d9b08ef 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -862,7 +862,7 @@ commands and their arguments.")
 (define-public wpa-supplicant-minimal
   (package
 (name "wpa-supplicant-minimal")
-(version "2.5")
+(version "2.6")
 (source (origin
   (method url-fetch)
   (uri (string-append
@@ -871,17 +871,7 @@ commands and their arguments.")
 ".tar.gz"))
   (sha256
(base32
-"05mkp5bx1c3z7h5biddsv0p49gkrq9ksany3anp4wdiv92p5prfc"))
-  (patches
-   (search-patches "wpa-supplicant-CVE-2015-5310.patch"
-   "wpa-supplicant-CVE-2015-5314.patch"
-   "wpa-supplicant-CVE-2015-5315.patch"
-   "wpa-supplicant-CVE-2015-5316.patch"
-   "wpa-supplicant-CVE-2016-4476.patch"
-   "wpa-supplicant-CVE-2016-4477-pt1.patch"
-   "wpa-supplicant-CVE-2016-4477-pt2.patch"
-

Re: [PATCH 00/14] Change python-build-system (fixes bug 20765)

2016-10-02 Thread Marius Bakke


On 2 October 2016 19:01:38 BST, Leo Famulari  wrote:
>On Sun, Oct 02, 2016 at 07:31:01PM +0200, Hartmut Goebel wrote:
>> Am 02.10.2016 um 16:24 schrieb Ludovic Courtès:
>> >
>> >> Subject: [PATCH 2/2] guix: python-build-system: Import setuptools
>before
>> >>  calling `setup.py'.
>> >>
>> >> This is needed for packages using "distutils" instead of
>"setuptools"
>> >> since the former does not understand the
>> >> "--single-version-externally-managed" flag. Also export __file__
>since
>> >> it will be unset when setup.py is called from python "exec".
>> > Please move this explanation as a comment right above the
>newly-added
>> > code.
>> 
>> @marius: I already added this comment, see the fixups on my branch at
>> gitlab (which I'm going to clean up when we all agree on the result).
>
>Let us know when the two of you think the code is ready to be tested on
>Hydra, and I will set it up.

Just FYI: I will be offline for a couple of days while waiting for a newly 
ordered ARM chromebook (Asus C201).

If anyone wants to work on core/libreboot meanwhile that would be great ;-) 

I'll address the points raised Thursday or so. It makes sense to either apply 
these on core-updates or wait until it's merged before creating a 
channel/branch for Hydra IMO.

-- 
Marius



Re: [PATCH 00/14] Change python-build-system (fixes bug 20765)

2016-09-30 Thread Marius Bakke
Hartmut Goebel <h.goe...@crazy-compilers.com> writes:

> Am 28.09.2016 um 17:54 schrieb Marius Bakke:
>> Or push a branch somewhere?
>
> Branch is now available at 
> <https://gitlab.com/htgoebel/guix/tree/python-build-system>

Thanks a lot for doing this!

After adding a couple of patches I'm able to build many python packages.
Patch #2 mostly emulates NixOS "shim" setup.py[0], required for packages
using distutils instead of setuptools.

Some packages really don't like the new configure flags however (scons).
Perhaps we should have them as default, but if #:configure-flags is set,
let them be overridden?

Also some packages are missing a dependency on "python-py"[1].

Perhaps we can set up a Hydra channel to deal with the fallout?

Cheers,
Marius

0: 
https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/interpreters/python/run_setup.py

1: https://pypi.python.org/pypi/py/1.4.31

>From a12000dd320cebeb920a4f790fe9206a2b6bda41 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Thu, 29 Sep 2016 18:29:21 +0100
Subject: [PATCH 1/2] guix: python-build-system: fix configure flag append
 (followup to dba07a8d1)

---
 guix/build/python-build-system.scm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/guix/build/python-build-system.scm b/guix/build/python-build-system.scm
index 8d4d6d3..d07b83f 100644
--- a/guix/build/python-build-system.scm
+++ b/guix/build/python-build-system.scm
@@ -65,11 +65,11 @@
   #:allow-other-keys)
   "Install a given Python package."
   (let* ((out (assoc-ref outputs "out"))
- (params (append (list (string-append "--prefix=" out))
- "--single-version-externally-managed"
- "--root=/"
+ (params (append (list (string-append "--prefix=" out)
+   "--single-version-externally-managed"
+   "--root=/")
  configure-flags)))
-(call-setuppy "install" params)))
+(call-setuppy "install" params)))
 
 (define* (wrap #:key inputs outputs #:allow-other-keys)
   (define (list-of-files dir)
-- 
2.10.0

>From 84fa3e8be3d3d868ddb9278a96807086415b754d Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Thu, 29 Sep 2016 18:41:35 +0100
Subject: [PATCH 2/2] guix: python-build-system: Import setuptools before
 calling `setup.py'.

This is needed for packages using "distutils" instead of "setuptools"
since the former does not understand the
"--single-version-externally-managed" flag. Also export __file__ since
it will be unset when setup.py is called from python "exec".

* guix/build/python-build-system.scm (call-setuppy): extend
"python setup.py" call to import setuptools, export __file__, and
call setup.py from setuptools python environment.
---
 guix/build/python-build-system.scm | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/guix/build/python-build-system.scm b/guix/build/python-build-system.scm
index d07b83f..4362c48 100644
--- a/guix/build/python-build-system.scm
+++ b/guix/build/python-build-system.scm
@@ -42,7 +42,11 @@
   (begin
  (format #t "running \"python setup.py\" with command ~s and parameters ~s~%"
 command params)
- (zero? (apply system* "python" "setup.py" command params)))
+ (zero? (apply system* "python"
+   "-c" (string-append "import setuptools;"
+   "__file__='setup.py';"
+   "exec(open('setup.py').read())")
+   command params)))
   (error "no setup.py found")))
 
 (define* (build #:rest empty)
-- 
2.10.0



Re: [PATCH 00/14] Change python-build-system (fixes bug 20765)

2016-09-28 Thread Marius Bakke
Hartmut Goebel  writes:

> Hi, minor correction:
>
> Am 28.09.2016 um 15:58 schrieb Hartmut Goebel:
>> This series implements what I proposed in
>>   .
>>
>> A) For python2 include python2-setuptools as a native-input by default.
> I implemented :
> *
> A1) Change the Python 2 build to bootstrap pip*

Wow, amazing work! I am unable to apply these patches with "git am".
Any chance you can resend after "git format-patch"? For long patch
series, I tend to "git format-patch -n master --stdout > series.patch".

Or push a branch somewhere? It would probably be sensible to run this
through Hydra, but I'll try building (@ (gnu packages python)) on my
server.

Thanks!




Re: [PATCH 1/4] gnu: Add python-avro.

2016-09-26 Thread Marius Bakke
Hartmut Goebel <h.goe...@crazy-compilers.com> writes:

> Am 25.09.2016 um 23:17 schrieb Marius Bakke:
>> +;;; Avro uses a single source repository for all implementations. The 
>> individual
>> +;;; released versions often have missing or incomplete test data, so we 
>> define
>> +;;; the common source here for use in all avro packages.
>> +(define (avro-version) "1.8.1")
>> +(define (avro-source version)
>
> With "Avro uses a single source repository for all implementations " you
> mean for both Python 2 and Python 3? Well, this is the common case :-)
> Any other packages do have this and we never use a separate definition
> for source or version. Please have a look at e.g. python-graphql-relay
> (picked as example at random).

This is a rather special case. I've updated the comment to make it more
clear. The Avro repository contains one folder for each language
implementation, and py2 and py3 are developed separately:

https://www-eu.apache.org/dist/avro/avro-1.8.1/

The source in this case contains all those subfolders. I'm only building
the two different Python implementations for now, but expect the other
interfaces to be able to use the same source when packaged.

There are release tarballs for the subdirectories, but at least the py3
version was missing tests, which was also the case on PyPi:

https://pypi.python.org/pypi/avro
https://pypi.python.org/pypi/avro-python3

> Am 25.09.2016 um 23:17 schrieb Marius Bakke:
>> + `(#:configure-flags '("--single-version-externally-managed" "--root=/")
>
> Same here, please add a comment,
>
> BTW: What should --root=/ be goof for? AFAIK this is the default?!

When using --single-version-externally-managed without --root, the
install phase fails with:

error: You must specify --record or --root when building system packages

As to why it is needed, there is another side effect in
python-build-system that is not mentioned in the bug report, but the
same fix works. When not specified, "bin" inputs may end up in the "bin"
output of the package! E.g. for pbcommand, $out/bin contains
"jsonschema" from the python-jsonschema package, whereas
sphinx-bootstrap-theme has "easy_install" in $out/bin and
sphinx-argparse/bin contains various executables from python-sphinx.

I've updated the patch series addressing these and your other comments.

Thanks for the feedback!

>From 9bb2dac10478efc420a97ac70892be0fe0356080 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sun, 25 Sep 2016 20:23:39 +0100
Subject: [PATCH 1/4] gnu: Add python-avro.

* gnu/packages/serialization.scm (avro-version): New variable (private).
(avro-source): New variable (private).
(python-avro, python2-avro): New variables.
---
 gnu/packages/serialization.scm | 50 ++
 1 file changed, 50 insertions(+)

diff --git a/gnu/packages/serialization.scm b/gnu/packages/serialization.scm
index 4a3278f..e80f5fe 100644
--- a/gnu/packages/serialization.scm
+++ b/gnu/packages/serialization.scm
@@ -25,6 +25,7 @@
   #:use-module (guix download)
   #:use-module (guix build-system cmake)
   #:use-module (guix build-system gnu)
+  #:use-module (guix build-system python)
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages boost)
@@ -200,3 +201,52 @@ it a convenient format to store user input files.")
  "Cap'n Proto is a very fast data interchange format and capability-based
 RPC system.  Think JSON, except binary.  Or think Protocol Buffers, except faster.")
 (license license:expat)))
+
+;;; Avro uses a single source repository for all language implementations. The
+;;; individual released versions some times have missing or incomplete test data,
+;;; so we use the full source tarball for all Avro packages.
+(define (avro-version) "1.8.1")
+(define (avro-source version)
+  (origin
+(method url-fetch)
+(uri (string-append "mirror://apache/avro/avro-" version
+"/avro-src-" version ".tar.gz"))
+(sha256 (base32 "0bplj4qmh7d6p987qd6a13g59awrc5cbx25n5brcrwq8yjik21av"))
+(modules '((guix build utils)))
+(snippet
+ '(begin
+;; Drop bundled dependencies.
+(delete-file-recursively "lang/py/lib/simplejson")
+#t
+
+(define-public python-avro
+  (package
+(name "python-avro")
+(version (avro-version))
+(source (avro-source version))
+(build-system python-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'enter-source
+   (lambda _ (chdir "lang/py3") #t)
+(propagated-inputs
+ `(("python-simplejson" ,python-simplejson)))
+(home-page "https://avro.apa

Re: [PATCH 2/3] gnu: Add python-pyxb.

2016-09-26 Thread Marius Bakke
Ben Woodcroft <b.woodcr...@uq.edu.au> writes:

> On 24/09/16 13:15, Marius Bakke wrote:
>> Ben Woodcroft <b.woodcr...@uq.edu.au> writes:
>>
>>>> Htslib is propagated because it
>>>> is included by the installed samtools and bcftools headers; at least one
>>>> of pysams dependencies failed to build when it was a regular input.
>>> Ah, I see. Can this be avoided with patchelf?
>> I don't think so. The htslib headers need to be propagated for anything
>> that uses header files from pysam, since they contain contain code such
>> as "include ". Perhaps you can update the comment to make
>> it more clear?
>>
>> Patchelf is probably what made that work when htslib was bundled.
> Ah, ok I see, so the problem is that python-plastid requires the .h 
> files during build. Given that this is the only package that has an 
> issue, and perhaps pysam doesn't intend to provide these .h files as 
> part of it's "interface", I think it might be best to simply put htslib 
> as an input to python-plastid.

I'm not sure, we would have to do this with every package that uses
the pysam cython interface. This particular issue is described in the
manual:

https://www.gnu.org/software/guix/manual/html_node/package-Reference.html

The propagated-inputs section says "For example this is necessary when a
C/C++ library needs headers of another library to compile, or when a
pkg-config file refers to another one via its Requires field.".

So I think it's a pretty common propagation scenario. See e.g. 618089f9
for a less convoluted case (C++ library that propagates zlib headers).

Perhaps a "propagated-build-inputs" functionality would be useful, so
that libraries are only propagated at build time and not to the profile.

If we don't do propagation, at least add a comment to python-plastid
explaining that htslib is there to avoid propagating from pysam, since
the plastid code contains no direct references to htslib.

Your other changes LGTM.

Thanks!
Marius



[PATCH 2/4] gnu: Add python-sphinx-bootstrap-theme.

2016-09-25 Thread Marius Bakke
* gnu/packages/python.scm (python-sphinx-bootstrap-theme,
  python2-sphinx-bootstrap-theme): New variables.
---
 gnu/packages/python.scm | 28 
 1 file changed, 28 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 688a5d4..4b8caea 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -10939,3 +10939,31 @@ with an associated set of resolve methods that know 
how to fetch data.")
 provide extendible implementations of common aspects of a cloud so that you can
 focus on building massively scalable web applications.")
 (license license:expat)))
+
+(define-public python-sphinx-bootstrap-theme
+  (package
+(name "python-sphinx-bootstrap-theme")
+(version "0.4.12")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "sphinx-bootstrap-theme" version))
+  (sha256
+   (base32
+"0wmm292rpfzxaib7zf2j6kdl1dl2xzx303hx8sx8qsdy0pkmrk65"
+(build-system python-build-system)
+(arguments
+ `(#:tests? #f ; No tests.
+   #:configure-flags '("--single-version-externally-managed" "--root=/")))
+(home-page 
"https://ryan-roemer.github.io/sphinx-bootstrap-theme/README.html;)
+(synopsis "Bootstrap theme for Sphinx")
+(description "Sphinx theme that integrates the Bootstrap CSS / JavaScript
+framework with various layout options, hierarchical menu navigation, and
+mobile-friendly responsive design.")
+(license license:expat)
+(properties `((python2-variant . ,(delay 
python2-sphinx-bootstrap-theme))
+
+(define-public python2-sphinx-bootstrap-theme
+  (package (inherit (package-with-python2 (strip-python2-variant
+   python-sphinx-bootstrap-theme)))
+   (native-inputs
+`(("python2-setuptools" ,python2-setuptools)
-- 
2.10.0




[PATCH 4/4] gnu: Add python2-pbcommand.

2016-09-25 Thread Marius Bakke
* gnu/packages/bioinformatics.scm (python2-pbcommand): New variable.
---
 gnu/packages/bioinformatics.scm | 50 +
 1 file changed, 50 insertions(+)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 1bf91a9..9343cc6 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -3373,6 +3373,56 @@ interrupted by stop codons.  OrfM finds and prints these 
ORFs.")
 (home-page "https://github.com/wwood/OrfM;)
 (license license:lgpl3+)))
 
+(define-public python2-pbcommand
+  ;; Upstream does not tag git releases and PyPi is out of date.
+  ;; See https://github.com/PacificBiosciences/pbcommand/issues/116
+  (let ((revision "1")
+(commit "e83a3443a1cd42b4da0d210201d711ede789917f"))
+(package
+  (name "python2-pbcommand")
+  (version (string-append "0.4.11-" revision "." (string-take commit 7)))
+  (source (origin
+(method git-fetch)
+(uri (git-reference
+  (url 
"https://github.com/PacificBiosciences/pbcommand.git;)
+  (commit commit)))
+(file-name (string-append name "-" version "-checkout"))
+(sha256
+ (base32
+  "1kwg84f23l7ik65qy7cxa6g5nipc2y23mppigd4j3vlzam18v52h"
+  (build-system python-build-system)
+  (arguments
+   `(#:python ,python-2 ; Python-2 only.
+ #:configure-flags '("--single-version-externally-managed" "--root=/")
+ #:phases
+ (modify-phases %standard-phases
+   (add-after 'unpack 'substitute-/bin/bash
+ (lambda _
+   ;; Fully qualify /bin/bash for running external commands.
+   (substitute* "pbcommand/engine/runner.py"
+ (("/bin/bash") (which "bash")))
+   #t))
+   (replace 'check
+ (lambda _ (zero? (system* "nosetests" "-v")))
+  (native-inputs
+   `(("python-nose" ,python2-nose)
+ ("python-sphinx-bootstrap-theme" ,python2-sphinx-bootstrap-theme)
+ ("python-sphinx-argparse" ,python2-sphinx-argparse)
+ ("python-tox" ,python2-tox)
+ ("python-setuptools" ,python2-setuptools)))
+  (propagated-inputs
+   `(("python-functools32" ,python2-functools32)
+ ("python-jsonschema" ,python2-jsonschema)
+ ("python-numpy" ,python2-numpy "out")
+ ("python-avro" ,python2-avro)
+ ("python-requests" ,python2-requests)
+ ("python-iso8601" ,python2-iso8601)))
+  (home-page "https://github.com/PacificBiosciences/pbcommand;)
+  (synopsis "PacBio common models and CLI tool contract interface")
+  (description "PacBio library for common utils, models, and tools
+to interface with pbsmrtpipe workflow engine.")
+  (license license:bsd-3
+
 (define-public python2-pbcore
   (package
 (name "python2-pbcore")
-- 
2.10.0




[PATCH 1/4] gnu: Add python-avro.

2016-09-25 Thread Marius Bakke
* gnu/packages/serialization.scm (avro-version): New variable (private).
(avro-source): New variable (private).
(python-avro, python2-avro): New variables.
---
 gnu/packages/serialization.scm | 50 ++
 1 file changed, 50 insertions(+)

diff --git a/gnu/packages/serialization.scm b/gnu/packages/serialization.scm
index 4a3278f..c97778a 100644
--- a/gnu/packages/serialization.scm
+++ b/gnu/packages/serialization.scm
@@ -25,6 +25,7 @@
   #:use-module (guix download)
   #:use-module (guix build-system cmake)
   #:use-module (guix build-system gnu)
+  #:use-module (guix build-system python)
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages boost)
@@ -200,3 +201,52 @@ it a convenient format to store user input files.")
  "Cap'n Proto is a very fast data interchange format and capability-based
 RPC system.  Think JSON, except binary.  Or think Protocol Buffers, except 
faster.")
 (license license:expat)))
+
+;;; Avro uses a single source repository for all implementations. The 
individual
+;;; released versions often have missing or incomplete test data, so we define
+;;; the common source here for use in all avro packages.
+(define (avro-version) "1.8.1")
+(define (avro-source version)
+  (origin
+(method url-fetch)
+(uri (string-append "mirror://apache/avro/avro-" version
+"/avro-src-" version ".tar.gz"))
+(sha256 (base32 "0bplj4qmh7d6p987qd6a13g59awrc5cbx25n5brcrwq8yjik21av"))
+(modules '((guix build utils)))
+(snippet
+ '(begin
+;; Delete unneeded bundled dependencies here.
+(delete-file-recursively "lang/py/lib/simplejson")
+#t
+
+(define-public python-avro
+  (package
+(name "python-avro")
+(version (avro-version))
+(source (avro-source version))
+(build-system python-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'enter-source
+   (lambda _ (chdir "lang/py3") #t)
+(propagated-inputs
+ `(("python-simplejson" ,python-simplejson)))
+(home-page "https://avro.apache.org/;)
+(synopsis "Python implementation of the Avro data serialization system")
+(description
+ "Avro is a data serialization system and RPC framework with rich data
+structures.  This package provides the python version.")
+(license license:asl2.0)
+(properties `((python2-variant . ,(delay python2-avro))
+
+(define-public python2-avro
+  (let ((base (package-with-python2 (strip-python2-variant python-avro
+(package (inherit base)
+ (arguments
+  `(#:tests? #f ; Requires Apache Ivy.
+#:python ,python-2 ; Needed when overriding inherited args.
+#:phases
+(modify-phases %standard-phases
+  (add-after 'unpack 'enter-source
+(lambda _ (chdir "lang/py") #t
-- 
2.10.0




[PATCH 3/4] gnu: Add python-sphinx-argparse.

2016-09-25 Thread Marius Bakke
* gnu/packages/python.scm (python-sphinx-argparse,
  python2-sphinx-argparse): New variables.
---
 gnu/packages/python.scm | 45 +
 1 file changed, 45 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 4b8caea..bb28363 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -10967,3 +10967,48 @@ mobile-friendly responsive design.")
python-sphinx-bootstrap-theme)))
(native-inputs
 `(("python2-setuptools" ,python2-setuptools)
+
+(define-public python-sphinx-argparse
+  (package
+(name "python-sphinx-argparse")
+(version "0.1.15")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "sphinx-argparse" version))
+  (sha256
+   (base32
+"14wdxq379xxnhw0kgf8z6jqdi0rd4k5y20jllyar9mxwwjblayvq"
+(build-system python-build-system)
+(arguments
+ `(#:configure-flags '("--single-version-externally-managed" "--root=/")
+   #:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'adjust-tests
+   ;; Two tests compare the output of "py.test --help" and fail
+   ;; when it gets ".py.test-real" back, so we substitute it here.
+   (lambda _
+ (substitute* "test/test_parser.py"
+   (("py.test") ".py.test-real"))
+ #t))
+ (delete 'check)
+ (add-after 'install 'check
+   (lambda _ (zero? (system* "py.test" "-vv")))
+(native-inputs
+ `(("python-pytest" ,python-pytest)))
+(propagated-inputs
+ `(("python-sphinx" ,python-sphinx)
+   ("python-docutils" ,python-docutils)))
+(home-page "https://github.com/ribozz/sphinx-argparse;)
+(synopsis "Sphinx extension to document argparse commands")
+(description "Sphinx extension that automatically documents @code{argparse}
+commands and options.")
+(license license:expat)
+(properties `((python2-variant . ,(delay python2-sphinx-argparse))
+
+(define-public python2-sphinx-argparse
+  (let ((base (package-with-python2 (strip-python2-variant
+ python-sphinx-argparse
+(package (inherit base)
+ (native-inputs
+  `(("python2-setuptools" ,python2-setuptools)
+,@(package-native-inputs base))
-- 
2.10.0




Re: Zipped Python .egg-files

2016-09-25 Thread Marius Bakke
Hartmut Goebel  writes:

> Hi,
>
> I just packaged a Python package and found was generating a zipped
> .egg-file - which is not that bad, since this saved space.
>
> But: This zip-file does include recent time-stamps.
>
> I assume this is wrong, isn't it? Can somebody more skilled than me
> please implement something like "strip-jar-timestamps"
> (ant-build-system) for .egg-files?! Thanks. Or should I file a
> bug-report for this?

There is a related bug for this:
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765

You can search for that URL in python.scm to find workarounds.

I find myself adding the "--single-version-externally-managed" flag more
often than not and am willing to try changing python-build-system to use
pip, as discussed in that bug. But won't have time until a few weeks
from now, at least.

Thanks,
Marius



Re: [PATCH 2/3] gnu: Add python-pyxb.

2016-09-23 Thread Marius Bakke
Ben Woodcroft  writes:

>> Htslib is propagated because it
>> is included by the installed samtools and bcftools headers; at least one
>> of pysams dependencies failed to build when it was a regular input.
> Ah, I see. Can this be avoided with patchelf?

I don't think so. The htslib headers need to be propagated for anything
that uses header files from pysam, since they contain contain code such
as "include ". Perhaps you can update the comment to make
it more clear?

Patchelf is probably what made that work when htslib was bundled.

Cheers,
Marius



Re: [PATCH 2/3] gnu: Add python-pyxb.

2016-09-23 Thread Marius Bakke
Marius Bakke <mba...@fastmail.com> writes:

> Ben Woodcroft <b.woodcr...@uq.edu.au> writes:
>
>>>
>>>> Also, I notice that pysam bundles htslib, bcftools and samtools C code.
>>>> Hopefully it should be straightforward enough to remove htslib as there
>>>> are install instructions, I'm not sure about the other two. This
>>>> shouldn't block the patch here, but would you mind taking a look?
>>>> http://pysam.readthedocs.io/en/latest/installation.html#installation
>>> I had a go at this, and also enabled tests since I was reading the build
>>> system anyway. Samtools and bcftools does not seem possible to un-bundle
>>> at this time, but htslib was straightforward.
>> OK. I don't think it needs to be propagated though, right? Also, would 
>> you mind separating the change to modify-phases syntax and unbundling of 
>> htslib into two patches please? Other than that this whole series LGTM.
>
> Modify-phases is now a separate patch. Htslib is propagated because it
> is included by the installed samtools and bcftools headers; at least one
> of pysams dependencies failed to build when it was a regular input.
>
> I added some comments and other cosmetic changes. Updated patch below.

Oops, found a spelling error in the previous patch. Fixed.

>From eaa38fb4174997f6282ff7d278a6aa4153b75bcf Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 16 Sep 2016 18:05:15 +0100
Subject: [PATCH 1/7] gnu: python-pysam: Update to 0.9.1.4.

* gnu/packages/bioinformatics.scm (python-pysam, python2-pysam): Update
to 0.9.1.4.
---
 gnu/packages/bioinformatics.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 1bf91a9..6e83461 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -1290,13 +1290,13 @@ multiple sequence alignments.")
 (define-public python-pysam
   (package
 (name "python-pysam")
-(version "0.8.4")
+(version "0.9.1.4")
 (source (origin
   (method url-fetch)
   (uri (pypi-uri "pysam" version))
   (sha256
(base32
-"1slx5mb94mzm5qzk52q270sab0sar95j67w1g1k452nz3s9j7krh"
+"1i1djacqbr88y7w18b4aa78zxnsyr4sz7yqdq2spi7gs0y6pzvjn"
 (build-system python-build-system)
 (arguments
  `(#:tests? #f ; tests are excluded in the manifest
-- 
2.10.0


>From 5431b05fe66398f5c44a1f0a81e1e90663550ac1 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:33:28 +0100
Subject: [PATCH 2/7] gnu: Add python-pyxb.

* gnu/packages/xml.scm (python-pyxb, python2-pyxb): New variables.
---
 gnu/packages/xml.scm | 25 +
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm
index 7befad5..cd3426b 100644
--- a/gnu/packages/xml.scm
+++ b/gnu/packages/xml.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <jann...@gnu.org>
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -729,6 +730,30 @@ different Unicode encodings which happen automatically during
 parsing/saving.")
 (license license:expat)))
 
+(define-public python-pyxb
+  (package
+(name "python-pyxb")
+(version "1.2.5")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "PyXB" version))
+  (sha256
+   (base32
+"0rzzwibfqa28gxgcxx4cybx1qcg0g6fand06ykj3gz7z5kp653sf"
+(build-system python-build-system)
+(home-page "http://pyxb.sourceforge.net/;)
+(synopsis "Python XML Schema Bindings")
+(description
+ "PyXB (\"pixbee\") is a pure Python package that generates Python source
+code for classes that correspond to data structures defined by XMLSchema.")
+(license (list license:asl2.0; Most files.
+   license:expat ; pyxb/utils/six.py
+   license:gpl2  ; bundled jquery in doc is dual MIT/GPL2
+   license:psfl  ; pyxb/utils/activestate.py
+
+(define-public python2-pyxb
+  (package-with-python2 python-pyxb))
+
 (define-public xmlto
   (package
 (name "xmlto")
-- 
2.10.0


>From 923fc43d8c665d1a2795ea2c221003e54544a06b Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:42:56 +0100
Subject: [PATCH 3/7] gnu: python2-pbcore: Update to 1.2.10.

* gnu/packages/bioinformatics.scm (python2-pbcore): Update

Re: [PATCH 2/3] gnu: Add python-pyxb.

2016-09-23 Thread Marius Bakke
Ben Woodcroft <b.woodcr...@uq.edu.au> writes:

>>
>>> Also, I notice that pysam bundles htslib, bcftools and samtools C code.
>>> Hopefully it should be straightforward enough to remove htslib as there
>>> are install instructions, I'm not sure about the other two. This
>>> shouldn't block the patch here, but would you mind taking a look?
>>> http://pysam.readthedocs.io/en/latest/installation.html#installation
>> I had a go at this, and also enabled tests since I was reading the build
>> system anyway. Samtools and bcftools does not seem possible to un-bundle
>> at this time, but htslib was straightforward.
> OK. I don't think it needs to be propagated though, right? Also, would 
> you mind separating the change to modify-phases syntax and unbundling of 
> htslib into two patches please? Other than that this whole series LGTM.

Modify-phases is now a separate patch. Htslib is propagated because it
is included by the installed samtools and bcftools headers; at least one
of pysams dependencies failed to build when it was a regular input.

I added some comments and other cosmetic changes. Updated patch below.

Cheers!

>From eaa38fb4174997f6282ff7d278a6aa4153b75bcf Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 16 Sep 2016 18:05:15 +0100
Subject: [PATCH 1/7] gnu: python-pysam: Update to 0.9.1.4.

* gnu/packages/bioinformatics.scm (python-pysam, python2-pysam): Update
to 0.9.1.4.
---
 gnu/packages/bioinformatics.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 1bf91a9..6e83461 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -1290,13 +1290,13 @@ multiple sequence alignments.")
 (define-public python-pysam
   (package
 (name "python-pysam")
-(version "0.8.4")
+(version "0.9.1.4")
 (source (origin
   (method url-fetch)
   (uri (pypi-uri "pysam" version))
   (sha256
(base32
-"1slx5mb94mzm5qzk52q270sab0sar95j67w1g1k452nz3s9j7krh"
+"1i1djacqbr88y7w18b4aa78zxnsyr4sz7yqdq2spi7gs0y6pzvjn"
 (build-system python-build-system)
 (arguments
  `(#:tests? #f ; tests are excluded in the manifest
-- 
2.10.0


>From 5431b05fe66398f5c44a1f0a81e1e90663550ac1 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:33:28 +0100
Subject: [PATCH 2/7] gnu: Add python-pyxb.

* gnu/packages/xml.scm (python-pyxb, python2-pyxb): New variables.
---
 gnu/packages/xml.scm | 25 +
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm
index 7befad5..cd3426b 100644
--- a/gnu/packages/xml.scm
+++ b/gnu/packages/xml.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <jann...@gnu.org>
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -729,6 +730,30 @@ different Unicode encodings which happen automatically during
 parsing/saving.")
 (license license:expat)))
 
+(define-public python-pyxb
+  (package
+(name "python-pyxb")
+(version "1.2.5")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "PyXB" version))
+  (sha256
+   (base32
+"0rzzwibfqa28gxgcxx4cybx1qcg0g6fand06ykj3gz7z5kp653sf"
+(build-system python-build-system)
+(home-page "http://pyxb.sourceforge.net/;)
+(synopsis "Python XML Schema Bindings")
+(description
+ "PyXB (\"pixbee\") is a pure Python package that generates Python source
+code for classes that correspond to data structures defined by XMLSchema.")
+(license (list license:asl2.0; Most files.
+   license:expat ; pyxb/utils/six.py
+   license:gpl2  ; bundled jquery in doc is dual MIT/GPL2
+       license:psfl  ; pyxb/utils/activestate.py
+
+(define-public python2-pyxb
+  (package-with-python2 python-pyxb))
+
 (define-public xmlto
   (package
 (name "xmlto")
-- 
2.10.0


>From 923fc43d8c665d1a2795ea2c221003e54544a06b Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:42:56 +0100
Subject: [PATCH 3/7] gnu: python2-pbcore: Update to 1.2.10.

* gnu/packages/bioinformatics.scm (python2-pbcore): Update to 1.2.10.
[propagated-inputs]: New field. Add python2-pyxb.
---
 gnu/packages/bioinformatics.scm | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/

Re: [PATCH] gnu: boost: Update to 1.61.0.

2016-09-22 Thread Marius Bakke
Andreas Enge  writes:

> On Wed, Sep 21, 2016 at 06:11:31PM +0200, Andreas Enge wrote:
>> boost has quite a few dependencies, as Ricardo already pointed out, and in my
>> experience tends to be a bit fragile. So maybe the best option would be to
>> create a boost-update branch and have it built on hydra to see whether there
>> are problems. It not, one could then cherry-pick the commit to master.
>
> I replied before reading all the messages in that thread. Of course if Eric
> has tried the commit locally and tested that nothing breaks, this could be
> pushed to master directly.

Should this not be pushed to core-updates? `guix refresh -l` reports:

Building the following 190 packages would ensure 395 dependent packages
are rebuilt: [...]

That will take a while on Hydra, and in the mean time anyone trying to
install any dependent (or sub-dependent) package will have to compile
them locally.

Unless there is a security issue, isn't this exactly what core-updates
is for? Is `guix refresh recursive`? Many of the sub-depentents seem
like they have other dependents, affecting more than 10% of the tree.

~marius



Re: [PATCH 2/3] gnu: Add python-pyxb.

2016-09-22 Thread Marius Bakke
Ben Woodcroft <b.woodcr...@uq.edu.au> writes:

>> Subject: [PATCH 1/3] gnu: python-pysam: Update to 0.9.1.4.
> I'm not sure whether this is a product of the upgrade or not, but I 
> notice this in the build log. I think it is harmless though, WDYT?
>
> starting phase `validate-runpath'
> validating RUNPATH of 10 binaries in 
> "/gnu/store/bpiq3lm6b1kpf54i1vj2dl09ff293wic-python-pysam-0.9.1.4/lib"...
> /gnu/store/bpiq3lm6b1kpf54i1vj2dl09ff293wic-python-pysam-0.9.1.4/lib/python3.4/site-packages/pysam-0.9.1.4-py3.4-linux-x86_64.egg/pysam/libchtslib.cpython-34m.so:
>  
> warning: RUNPATH contains bogus entries: ("pysam" "." 
> "build/lib.linux-x86_64-3.4/pysam")

I don't see this in the previous version, so it is a regression.
However, it should be mostly harmless. Readelf reports (when compiled
with external htslib, see below):

 0x001d (RUNPATH)Library runpath: 
[/gnu/store/m4gc2wx4q9if1vrhgclpspdil7rqsn21-python-3.4.3/lib:/gnu/store/ba22myqvxccwmmjwwq665rc43hanycxy-htslib-1.3.1/lib:build/lib.linux-x86_64-3.4/pysam:$ORIGIN:/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib:/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib:/gnu/store/xl19qrfzga52vrvp4ncccwjlnrjqwj95-ncurses-6.0/lib:/gnu/store/5992iq1v7arqa14ym3di58n4la0893nv-zlib-1.2.8/lib:/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/../../..]

Compared to the runpath of the same file currently in Guix:

 0x001d (RUNPATH)Library runpath: 
[/gnu/store/m4gc2wx4q9if1vrhgclpspdil7rqsn21-python-3.4.3/lib:/gnu/store/m9vxvhdj691bq1f85lpflvnhcvrdilih-glibc-2.23/lib:/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib:/gnu/store/xl19qrfzga52vrvp4ncccwjlnrjqwj95-ncurses-6.0/lib:/gnu/store/5992iq1v7arqa14ym3di58n4la0893nv-zlib-1.2.8/lib:/gnu/store/9nifwk709wajpyfwa0jzaa3p6mf10vxs-gcc-4.9.3-lib/lib/gcc/x86_64-unknown-linux-gnu/4.9.3/../../..]

If a folder named "$CWD/build/lib.linux-x86_64-3.4/pysam exists, it
could potentially allow for code injection, which is troubling.

I opened an issue on their tracker, but don't think it's worth holding
the patch: https://github.com/pysam-developers/pysam/issues/347

>
> Also, I notice that pysam bundles htslib, bcftools and samtools C code. 
> Hopefully it should be straightforward enough to remove htslib as there 
> are install instructions, I'm not sure about the other two. This 
> shouldn't block the patch here, but would you mind taking a look?
> http://pysam.readthedocs.io/en/latest/installation.html#installation

I had a go at this, and also enabled tests since I was reading the build
system anyway. Samtools and bcftools does not seem possible to un-bundle
at this time, but htslib was straightforward.

Enabling tests required packaging bcftools as well. I've attached the
full patch series below. The first three commits are unchanged.

Thanks!

>From 0a6220a664ecf3aa967211db5bf9e9b9e539220d Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 16 Sep 2016 18:05:15 +0100
Subject: [PATCH 1/6] gnu: python-pysam: Update to 0.9.1.4.

* gnu/packages/bioinformatics.scm (python-pysam, python2-pysam): Update
to 0.9.1.4.
---
 gnu/packages/bioinformatics.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 7a27e0b..47b884e 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -1290,13 +1290,13 @@ multiple sequence alignments.")
 (define-public python-pysam
   (package
 (name "python-pysam")
-(version "0.8.4")
+(version "0.9.1.4")
 (source (origin
   (method url-fetch)
   (uri (pypi-uri "pysam" version))
   (sha256
(base32
-"1slx5mb94mzm5qzk52q270sab0sar95j67w1g1k452nz3s9j7krh"
+"1i1djacqbr88y7w18b4aa78zxnsyr4sz7yqdq2spi7gs0y6pzvjn"
 (build-system python-build-system)
 (arguments
  `(#:tests? #f ; tests are excluded in the manifest
-- 
2.10.0

>From 6a8ddd17d7f11e0687217c8649a452a1a56c596c Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:33:28 +0100
Subject: [PATCH 2/6] gnu: Add python-pyxb.

* gnu/packages/xml.scm (python-pyxb, python2-pyxb): New variables.
---
 gnu/packages/xml.scm | 25 +
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm
index 7befad5..cd3426b 100644
--- a/gnu/packages/xml.scm
+++ b/gnu/packages/xml.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <jann...@gnu.org>
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
+;;; Copyright © 2016 Mari

Re: [PATCH 2/3] gnu: Add python-pyxb.

2016-09-21 Thread Marius Bakke
Ben Woodcroft <b.woodcr...@uq.edu.au> writes:

> Hi again,
>
>
> On 20/09/16 16:34, Ben Woodcroft wrote:
>> Oops, forgot to cc the list.
>>
>>
>> On 20/09/16 16:02, Ben Woodcroft wrote:
>>> Hi Marius,
>>>
>>> Thanks for the patches.
>>>
>>> On 17/09/16 20:10, Marius Bakke wrote:
>>>> [..]
>>>> + (add-after 'unpack 'fix-tests
>>>> +   (lambda _
>>>> + ;; See https://github.com/pabigot/pyxb/issues/26 ...
>>>> + (delete-file "tests/trac/test-trac-0091.py")
>>>
>>> The fix for that test failing seems straightforward enough, might be 
>>> better to include as a patch so those tests are run.
>>> https://github.com/pabigot/pyxb/commit/d4bdd5a1c712cd70f96264ae13b55d015cbf3335
>>>  
>>>
> Actually, 1.2.5 just got released which has both of these fixes. Can you 
> send an updated patch please?

Hi Ben,

Thanks for the review. Updated patches attached.

>From 0a6220a664ecf3aa967211db5bf9e9b9e539220d Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 16 Sep 2016 18:05:15 +0100
Subject: [PATCH 1/3] gnu: python-pysam: Update to 0.9.1.4.

* gnu/packages/bioinformatics.scm (python-pysam, python2-pysam): Update
to 0.9.1.4.
---
 gnu/packages/bioinformatics.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 7a27e0b..47b884e 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -1290,13 +1290,13 @@ multiple sequence alignments.")
 (define-public python-pysam
   (package
 (name "python-pysam")
-(version "0.8.4")
+(version "0.9.1.4")
 (source (origin
   (method url-fetch)
   (uri (pypi-uri "pysam" version))
   (sha256
(base32
-"1slx5mb94mzm5qzk52q270sab0sar95j67w1g1k452nz3s9j7krh"))))
+        "1i1djacqbr88y7w18b4aa78zxnsyr4sz7yqdq2spi7gs0y6pzvjn"
 (build-system python-build-system)
 (arguments
  `(#:tests? #f ; tests are excluded in the manifest
-- 
2.10.0

>From 6a8ddd17d7f11e0687217c8649a452a1a56c596c Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:33:28 +0100
Subject: [PATCH 2/3] gnu: Add python-pyxb.

* gnu/packages/xml.scm (python-pyxb, python2-pyxb): New variables.
---
 gnu/packages/xml.scm | 25 +
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm
index 7befad5..cd3426b 100644
--- a/gnu/packages/xml.scm
+++ b/gnu/packages/xml.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <jann...@gnu.org>
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -729,6 +730,30 @@ different Unicode encodings which happen automatically during
 parsing/saving.")
 (license license:expat)))
 
+(define-public python-pyxb
+  (package
+(name "python-pyxb")
+(version "1.2.5")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "PyXB" version))
+  (sha256
+   (base32
+"0rzzwibfqa28gxgcxx4cybx1qcg0g6fand06ykj3gz7z5kp653sf"
+(build-system python-build-system)
+(home-page "http://pyxb.sourceforge.net/;)
+(synopsis "Python XML Schema Bindings")
+(description
+ "PyXB (\"pixbee\") is a pure Python package that generates Python source
+code for classes that correspond to data structures defined by XMLSchema.")
+(license (list license:asl2.0; Most files.
+   license:expat ; pyxb/utils/six.py
+   license:gpl2  ; bundled jquery in doc is dual MIT/GPL2
+   license:psfl  ; pyxb/utils/activestate.py
+
+(define-public python2-pyxb
+  (package-with-python2 python-pyxb))
+
 (define-public xmlto
   (package
 (name "xmlto")
-- 
2.10.0

>From 396cbcbfda24ce5cd1caecedf01407bf6a1f70a1 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 17 Sep 2016 10:42:56 +0100
Subject: [PATCH 3/3] gnu: python2-pbcore: Update to 1.2.10.

* gnu/packages/bioinformatics.scm (python2-pbcore): Update to 1.2.10.
[propagated-inputs]: New field. Add python2-pyxb.
---
 gnu/packages/bioinformatics.scm | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 47b884e..a598351 100644
--- a/gnu/p

[PATCH 2/3] gnu: Add python-pyxb.

2016-09-17 Thread Marius Bakke
* gnu/packages/xml.scm (python-pyxb, python2-pyxb): New variables.
---
 gnu/packages/xml.scm | 37 +
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/xml.scm b/gnu/packages/xml.scm
index 7befad5..793cd2f 100644
--- a/gnu/packages/xml.scm
+++ b/gnu/packages/xml.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <jann...@gnu.org>
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -729,6 +730,42 @@ different Unicode encodings which happen automatically 
during
 parsing/saving.")
 (license license:expat)))
 
+(define-public python-pyxb
+  (package
+(name "python-pyxb")
+(version "1.2.4")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "PyXB" version))
+  (sha256
+   (base32
+"0sgs184mq218li5qqi906hm55zkpqbiyinv9wk6qgqgx813rskq2"
+(build-system python-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'fix-tests
+   (lambda _
+ ;; See https://github.com/pabigot/pyxb/issues/26 ...
+ (delete-file "tests/trac/test-trac-0091.py")
+ ;; ...and https://github.com/pabigot/pyxb/pull/58 .
+ (substitute* "tests/utils/test-utility.py"
+   (("__NoExt_re = re.compile.*$")
+"__NoExt_re = re.compile('(^|\\%s)[^\\.]+$' % os.sep)\n"))
+ #t)
+(home-page "http://pyxb.sourceforge.net/;)
+(synopsis "Python XML Schema Bindings")
+(description
+ "PyXB (\"pixbee\") is a pure Python package that generates Python source
+code for classes that correspond to data structures defined by XMLSchema.")
+(license (list license:asl2.0; Most files.
+   license:expat ; pyxb/utils/six.py
+   license:gpl2  ; bundled jquery in doc is dual MIT/GPL2
+   license:psfl  ; pyxb/utils/activestate.py
+
+(define-public python2-pyxb
+  (package-with-python2 python-pyxb))
+
 (define-public xmlto
   (package
 (name "xmlto")
-- 
2.10.0




[PATCH 3/3] gnu: python2-pbcore: Update to 1.2.10.

2016-09-17 Thread Marius Bakke
* gnu/packages/bioinformatics.scm (python2-pbcore): Update to 1.2.10.
[propagated-inputs]: New field. Add python2-pyxb.
---
 gnu/packages/bioinformatics.scm | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index cfd098c..3d38042 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -3353,13 +3353,13 @@ interrupted by stop codons.  OrfM finds and prints 
these ORFs.")
 (define-public python2-pbcore
   (package
 (name "python2-pbcore")
-(version "1.2.8")
+(version "1.2.10")
 (source (origin
   (method url-fetch)
   (uri (pypi-uri "pbcore" version))
   (sha256
(base32
-"02pfn5raa3zf739672bg0dkx7z3j2c4nx7vmpfjqy5b12jrqpymk"
+"1kjmv891d6qbpp4shhhvkl02ff4q5xlpnls2513sm2cjcrs52f1i"
 (build-system python-build-system)
 (arguments `(#:python ,python-2)) ; pbcore requires Python 2.7
 (inputs
@@ -3372,6 +3372,8 @@ interrupted by stop codons.  OrfM finds and prints these 
ORFs.")
("python-nose" ,python2-nose)
("python-setuptools" ,python2-setuptools)
("python-sphinx" ,python2-sphinx)))
+(propagated-inputs
+ `(("python-pyxb" ,python2-pyxb)))
 (home-page "http://pacificbiosciences.github.io/pbcore/;)
 (synopsis "Library for reading and writing PacBio data files")
 (description
-- 
2.10.0




[PATCH 1/3] gnu: python-pysam: Update to 0.9.1.4.

2016-09-17 Thread Marius Bakke
* gnu/packages/bioinformatics.scm (python-pysam, python2-pysam): Update
to 0.9.1.4.
---
 gnu/packages/bioinformatics.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index 39a420a..cfd098c 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -1269,13 +1269,13 @@ multiple sequence alignments.")
 (define-public python-pysam
   (package
 (name "python-pysam")
-(version "0.8.4")
+(version "0.9.1.4")
 (source (origin
   (method url-fetch)
   (uri (pypi-uri "pysam" version))
   (sha256
(base32
-"1slx5mb94mzm5qzk52q270sab0sar95j67w1g1k452nz3s9j7krh"
+"1i1djacqbr88y7w18b4aa78zxnsyr4sz7yqdq2spi7gs0y6pzvjn"
 (build-system python-build-system)
 (arguments
  `(#:tests? #f ; tests are excluded in the manifest
-- 
2.10.0




[PATCH 0/3] gnu: python2-pbcore: Update to 1.2.10.

2016-09-17 Thread Marius Bakke
These patches are necessary to update pbcore to the latest release.
I've verified that all dependents of pysam and pbcore builds fine.

This is part of an effort to package the PacBio GenomicConsensus tools.




Re: [PATCH 1/3] gnu: Add python-pytest-pep8.

2016-09-14 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Sun, Sep 11, 2016 at 03:07:35PM +0100, Marius Bakke wrote:
>> * gnu/packages/python.scm (python-pytest-pep8, python2-pytest-pep8): New
>>   variables.
>
> Overall LGTM...
>
>> +(description "Pytest plugin for efficiently checking PEP8 compliance")
>
> I think we can drop "efficiently". I can do that before committing if
> you agree; no need to send an updated patch.

Thanks! Please do that for both the pep8 and flakes pytest plugins.



Re: [PATCH] gnu: Add mcelog.

2016-09-14 Thread Marius Bakke
Tobias Geerinckx-Rice <m...@tobias.gr> writes:

> Marius,
>
> On 14/09/16 17:19, Marius Bakke wrote:
>> Another thing, I think the snippet should be moved to a phase, as AFAIK
>> origin snippets should be reserved for removing unwanted files, or for
>> reproducibility.
>
> Not if we use your suggested snapshot tarball, which rightly lack a .git
> directory. There is no way for the build system to divine the version
> number at build time with ‘git describe’.
>
> Unpatched mcelog, manually built from ‘guix download’ed sources, would
> report its version as ‘unknown’. With this snippet, it just works.

Yes, I was mostly echoing Leos sentiment from this post:

https://lists.gnu.org/archive/html/guix-devel/2016-08/msg00937.html

I don't think reporting "unknown" as a version is a critical bug, but
don't have any strong opinions either way. It seems like the manual
could use some clarification on its use, though.

Cheers,
Marius



Re: [PATCH] gnu: Add mcelog.

2016-09-14 Thread Marius Bakke
Danny Milosavljevic  writes:

> DESTDIR is a feature which lets you install into a tempdir. The idea
> is that you install it all there and then atomically replace the
> ORIGINAL version at the non-DESTDIR location.

Oops, I meant DOCDIR! Sorry for the confusion!

>> >> +(home-page "http://mcelog.org/;)  
>> > Nit-pick: the trailing slash is unnecessary :)  
>
> If you don't include the trailing slash it will require an additional
> round-trip to the server in order to add it via a (302) redirect.

That's a very good point, although all HTTP clients I've used add it
automatically. But, explicit is better than implicit and all that.

Now I'll have to start doing it too :)

Thanks!
Marius



Re: [PATCH] gnu: Add mcelog.

2016-09-14 Thread Marius Bakke
Tobias Geerinckx-Rice <m...@tobias.gr> writes:

> On 14/09/16 15:45, Marius Bakke wrote:
>> It's not visible in the cgit interface, but it actually seems to 
>> support normal snapshot downloads: 
>> https://git.kernel.org/cgit/utils/cpu/mce/mcelog.git/snapshot/v141.tar.gz
>
> I did not know that. Thanks for the tip! It still requires a snippet,
> unfortunately.

Another thing, I think the snippet should be moved to a phase, as AFAIK
origin snippets should be reserved for removing unwanted files, or for
reproducibility. But, I may be wrong here.

>>> +(home-page "http://mcelog.org/;)
>> Nit-pick: the trailing slash is unnecessary :)
>
> Oh, I know, I just have a thing for proper root paths in URIs.
>
> I'm seeing someone about that.

This made me chuckle. Perhaps I should see someone about saving that
precious byte, too :)

Also, is DESTDIR supposed to be /share, shouldn't it be $out/share?
I think I'd define destdir as a variable, and use that also for the
etcprefix instead of using a make variable.

Thanks!
Marius



Re: [PATCH] gnu: Add mcelog.

2016-09-14 Thread Marius Bakke
Tobias Geerinckx-Rice  writes:

> * gnu/packages/linux.scm (mcelog): New variable.

Thanks!

> ---
>  gnu/packages/linux.scm | 41 +
>  1 file changed, 41 insertions(+)
>
> diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
> index 3ec6514..fc4faa4 100644
> --- a/gnu/packages/linux.scm
> +++ b/gnu/packages/linux.scm
> @@ -74,6 +74,7 @@
>#:use-module (guix build-system python)
>#:use-module (guix build-system trivial)
>#:use-module (guix download)
> +  #:use-module (guix git-download)
>#:use-module ((guix licenses) #:prefix license:)
>#:use-module (guix packages)
>#:use-module (guix utils)
> @@ -2939,3 +2940,43 @@ the default @code{nsswitch} and the experimental 
> @code{umich_ldap}.")
>   "Tools for loading and managing Linux kernel modules, such as 
> `modprobe',
>  `insmod', `lsmod', and more.")
>  (license license:gpl2+)))
> +
> +(define-public mcelog
> +  (package
> +(name "mcelog")
> +(version "141")
> +(source
> + (let ((commit (string-append "v" version)))
> +   (origin
> + (method git-fetch)
> + (uri (git-reference
> +   (url 
> "https://git.kernel.org/pub/scm/utils/cpu/mce/mcelog.git;)
> +   (commit commit)))

It's not visible in the cgit interface, but it actually seems to support
normal snapshot downloads:
https://git.kernel.org/cgit/utils/cpu/mce/mcelog.git/snapshot/v141.tar.gz

> + (sha256
> +  (base32
> +   "0iqvqiwf3aawmgjcyg2rj427m8nvfbfnmmfv0606nhr59l14h5jr"))
> + (file-name (string-append name "-" version))
> + (modules '((guix build utils)))
> + (snippet
> +  ;; Hard-code version to avoid a git (and .git/) build dependency.
> +  `(substitute* "Makefile"
> + (("\"unknown\"") (string-append "\"" ,commit "\"")))
> +(build-system gnu-build-system)
> +(arguments
> + `(#:phases (modify-phases %standard-phases
> +  (delete 'configure))  ; no configure script
> +#:make-flags (list "CC=gcc"
> +   (string-append "DESTDIR="
> +  (assoc-ref %outputs "out"))
> +   "prefix="
> +   "DOCDIR=/share/doc/mcelog"
> +   "etcprefix=$(DOCDIR)/examples")
> +#:tests? #f))   ; tests must be run as root

Does all tests have to run as root? Also, could you reverse the order of
the arguments to match other package definitions?

> +(home-page "http://mcelog.org/;)

Nit-pick: the trailing slash is unnecessary :)

> +(synopsis "Machine check monitor for x86 Linux systems")

If this is x86-only, perhaps we should set (supported-systems)?

> +(description
> + "The mcelog daemon is required by the Linux kernel to log memory, I/O,
> +  CPU, and other hardware errors on x86 systems.  It can also perform
> +  user-defined tasks, such as bringing bad pages off-line, when
> +  configurable error thresholds are exceeded.")
> +(license license:gpl2)))

The rest LGTM.



[PATCH 1/3] gnu: Add python-pytest-pep8.

2016-09-11 Thread Marius Bakke
* gnu/packages/python.scm (python-pytest-pep8, python2-pytest-pep8): New
  variables.
---
 gnu/packages/python.scm | 33 +
 1 file changed, 33 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 8b9273c..21eda38 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -10327,3 +10327,36 @@ Python to manipulate OpenDocument 1.2 files.")
  (native-inputs
   `(("python2-setuptools" ,python2-setuptools)
 ,@(package-native-inputs base))
+
+(define-public python-pytest-pep8
+  (package
+(name "python-pytest-pep8")
+(version "1.0.6")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "pytest-pep8" version))
+  (sha256
+   (base32
+"06032agzhw1i9d9qlhfblnl3dw5hcyxhagn7b120zhrszbjzfbh3"
+(build-system python-build-system)
+(arguments
+ `(#:tests? #f ; Fails with recent pytest and pep8. See upstream issues #8 
and #12.
+   ;; Prevent creation of the egg. This works around
+   ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
+   #:configure-flags '("--single-version-externally-managed" "--root=/")))
+(native-inputs
+ `(("python-pytest" ,python-pytest)))
+(propagated-inputs
+ `(("python-pep8" ,python-pep8)))
+(home-page "https://bitbucket.org/pytest-dev/pytest-pep8;)
+(synopsis "Py.test plugin to check PEP8 requirements")
+(description "Pytest plugin for efficiently checking PEP8 compliance")
+(license license:expat)
+(properties `((python2-variant . ,(delay python2-pytest-pep8))
+
+(define-public python2-pytest-pep8
+  (let ((base (package-with-python2 (strip-python2-variant 
python-pytest-pep8
+(package (inherit base)
+ (native-inputs
+  `(("python2-setuptools" ,python2-setuptools)
+,@(package-native-inputs base))
-- 
2.9.3




[PATCH 3/3] gnu: Add python-natsort.

2016-09-11 Thread Marius Bakke
* gnu/packages/python.scm (python-natsort, python2-natsort): New variables.
---
 gnu/packages/python.scm | 49 +
 1 file changed, 49 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index bd70cb6..f8e25d4 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -10402,3 +10402,52 @@ with pyflakes.")
  (native-inputs
   `(("python2-setuptools" ,python2-setuptools)
 ,@(package-native-inputs base))
+
+(define-public python-natsort
+  (package
+(name "python-natsort")
+(version "5.0.1")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "natsort" version))
+  (sha256
+   (base32
+"1abld5p4a6n5zjnyw5mi2pv37gqalcybv2brjr2y6l9l2p8v9mja"
+(build-system python-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-before 'check 'set-cachedir
+   ;; Tests require write access to $HOME by default
+   (lambda _ (setenv "PYTHON_EGG_CACHE" "/tmp") #t)
+(native-inputs
+ `(("python-hypothesis" ,python-hypothesis)
+   ("python-pytest-cache" ,python-pytest-cache)
+   ("python-pytest-cov" ,python-pytest-cov)
+   ("python-pytest-flakes" ,python-pytest-flakes)
+   ("python-pytest-pep8" ,python-pytest-pep8)))
+(propagated-inputs ; TODO: Add python-fastnumbers.
+ `(("python-pyicu" ,python-pyicu)))
+(home-page "https://github.com/SethMMorton/natsort;)
+(synopsis "Natural sorting for python and shell")
+(description
+ "Natsort lets you apply natural sorting on lists instead of
+lexicographical.  If you use the built-in @code{sorted} method in python
+on a list such as @code{['a20', 'a9', 'a1', 'a4', 'a10']}, it would be
+returned as @code{['a1', 'a10', 'a20', 'a4', 'a9']}.  Natsort provides a
+function @code{natsorted} that identifies numbers and sorts them separately
+from strings.  It can also sort version numbers, real numbers, mixed types
+and more, and comes with a shell command @command{natsort} that exposes this
+functionality in the command line.")
+(license license:expat)
+(properties `((python2-variant . ,(delay python2-natsort))
+
+(define-public python2-natsort
+  (let ((base (package-with-python2 (strip-python2-variant python-natsort
+(package (inherit base)
+ (native-inputs
+  `(("python2-setuptools" ,python2-setuptools)
+("python2-pathlib" ,python2-pathlib)
+("python2-mock" ,python2-mock)
+("python2-enum34" ,python2-enum34)
+,@(package-native-inputs base))
-- 
2.9.3




[PATCH 2/3] gnu: Add python-pytest-flakes.

2016-09-11 Thread Marius Bakke
* gnu/packages/python.scm (python-pytest-flakes, python2-pytest-flakes):
  New variables.
---
 gnu/packages/python.scm | 42 ++
 1 file changed, 42 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 21eda38..bd70cb6 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -10360,3 +10360,45 @@ Python to manipulate OpenDocument 1.2 files.")
  (native-inputs
   `(("python2-setuptools" ,python2-setuptools)
 ,@(package-native-inputs base))
+
+(define-public python-pytest-flakes
+  (package
+(name "python-pytest-flakes")
+(version "1.0.1")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "pytest-flakes" version))
+  (sha256
+   (base32
+"0flag3n33kbhyjrhzmq990rvg4yb8hhhl0i48q9hw0ll89jp28lw"
+(build-system python-build-system)
+(arguments
+ `(;; Prevent creation of the egg. This works around
+   ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=20765 .
+   #:configure-flags '("--single-version-externally-managed" "--root=/")
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'check)
+ (add-after 'install 'check
+   (lambda _ ; It's easier to run tests after install.
+ (zero? (system* "py.test" "-vv")))
+(native-inputs
+ `(("python-coverage" ,python-coverage)
+   ("python-pytest" ,python-pytest)
+   ("python-pytest-cache" ,python-pytest-cache)
+   ("python-pytest-pep8" ,python-pytest-pep8)))
+(propagated-inputs
+ `(("python-pyflakes" ,python-pyflakes)))
+(home-page "https://github.com/fschulze/pytest-flakes;)
+(synopsis "Py.test plugin to check source code with pyflakes")
+(description "Pytest plugin for efficiently checking python source
+with pyflakes.")
+(license license:expat)
+(properties `((python2-variant . ,(delay python2-pytest-flakes))
+
+(define-public python2-pytest-flakes
+  (let ((base (package-with-python2 (strip-python2-variant 
python-pytest-flakes
+(package (inherit base)
+ (native-inputs
+  `(("python2-setuptools" ,python2-setuptools)
+,@(package-native-inputs base))
-- 
2.9.3




Re: [PATCH] gnu: Add python-cachecontrol.

2016-09-10 Thread Marius Bakke
Ben Woodcroft  writes:

> Hi Marius, thanks for the patch.
>
> I added a 'python2-variant' line and pushed as 'b30565b'.

*facepalm* thanks. Here I was wondering why my next patches didn't build
for python2. You may want to do the same for "python-freezegun" above.

Btw, it seems you missed a couple of parenthesis in the commit:

-(properties `((python2-variant . ,(delay python2-cachecontrol)))
+(properties `((python2-variant . ,(delay python2-cachecontrol))

> The thing is, the list has already seen this package before, in this 
> thread where I tried packaging scikit-bio (I suspect you are trying to 
> do the same):
> https://lists.gnu.org/archive/html/guix-devel/2016-04/msg01012.html

I am indeed sending these to prepare for scikit-bio. Natsort coming up.
There have been a few dependency updates as well, since that thread.

I'll take a look at your branch to see if it contains anything I might
have missed. The remaining dependencies are pretty much ready to go.

Cheers!
Marius



Re: [PATCH] gnu: Add dlib.

2016-09-10 Thread Marius Bakke
Marius Bakke <mba...@fastmail.com> writes:

> Leo Famulari <l...@famulari.name> writes:
>
>> Changing the subject, you could disable the tests per-architecture. Look
>> for uses of current-target-system and current-system for usage examples.
>> But this is not absolutely required, IMO.
>
> This latest patch series now disables tests on a per-arch basis.
>
> There may be others on MIPS failing after the timeout, but extending the
> list should be obvious.

Here are the patches again, with the "failing-tests" variable renamed to
"disabled-tests". Let me know if I can provide anything else. Thanks!

>From 331d291cabcb5d17d0284414cae1f2ac5c32736a Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 23 Aug 2016 21:17:14 +0100
Subject: [PATCH 1/3] gnu: dlib: Remove unused fftw from inputs.

* gnu/packages/machine-learning.scm (dlib)[inputs]: Remove fftw.
  (define-module): Don't include algebra.scm.
---
 gnu/packages/machine-learning.scm | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 4332045..7669702 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -28,7 +28,6 @@
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system r)
   #:use-module (gnu packages)
-  #:use-module (gnu packages algebra)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages compression)
@@ -515,8 +514,7 @@ single hidden layer, and for multinomial log-linear models.")
 (native-inputs
  `(("pkg-config" ,pkg-config)))
 (inputs
- `(("fftw" ,fftw)
-   ("giflib" ,giflib)
+ `(("giflib" ,giflib)
;("lapack" ,lapack) XXX lapack here causes test failures in some setups.
("libjpeg" ,libjpeg)
("libpng" ,libpng)
-- 
2.9.3

>From 5c78ac7002cd92a2bfd8efa0f9902288dffe6a89 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 27 Aug 2016 17:23:58 +0100
Subject: [PATCH 2/3] gnu: dlib: Do not build dlib twice for tests.

* gnu/packages/machine-learning.scm (dlib)[arguments]: Use makefile
  instead of cmake in check phase to prevent full rebuild.
---
 gnu/packages/machine-learning.scm | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 7669702..e94ffdd 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -502,11 +502,10 @@ single hidden layer, and for multinomial log-linear models.")
  (replace 'check
(lambda _
  ;; No test target, so we build and run the unit tests here.
- (let ((test-dir (string-append "../dlib-" ,version "/dlib/test/build")))
-   (mkdir-p test-dir)
+ (let ((test-dir (string-append "../dlib-" ,version "/dlib/test")))
(with-directory-excursion test-dir
- (and (zero? (system* "cmake" ".."))
-  (zero? (system* "cmake" "--build" "." "--config" "Release"))
+ (setenv "CXXFLAGS" "-std=gnu++11")
+ (and (zero? (system* "make" "-j" (number->string (parallel-job-count
   (zero? (system* "./dtest" "--runall")))
  (add-after 'install 'delete-static-library
(lambda* (#:key outputs #:allow-other-keys)
-- 
2.9.3

>From 268d1085beb3195f38e4d96e0bfee55e456d3093 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 9 Sep 2016 01:51:23 +0100
Subject: [PATCH 3/3] gnu: dlib: Disable failing tests.

* gnu/packages/machine-learning.scm (dlib)[arguments]: Add phase to
  disable tests that are known not to work in the current release.
  [inputs]: Add lapack.
---
 gnu/packages/machine-learning.scm | 25 -
 1 file changed, 24 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index e94ffdd..b663b4f 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -499,6 +499,29 @@ single hidden layer, and for multinomial log-linear models.")
  (substitute* "dlib/config.h"
(("^//#define DLIB_DISABLE_ASSERTS") "#define DLIB_DISABLE_ASSERTS"))
  #t))
+ (add-after 'disable-asserts 'disable-failing-tests
+   (lambda _
+ ;; One test times out on MIPS, so we need to disable it.
+ ;; The rest is known to fail on non-x86_64 platforms in the current release.

[PATCH] gnu: Add python-cachecontrol.

2016-09-10 Thread Marius Bakke
>From e924847f7f1b226b7abe2dcf176d83b9ae2852d5 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 10 Sep 2016 11:19:37 +0100
Subject: [PATCH] gnu: Add python-cachecontrol.

* gnu/packages/python.scm (python-cachecontrol, python2-cachecontrol):
  New variables.
---
 gnu/packages/python.scm | 48 
 1 file changed, 48 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 33674fa..f965dc7 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -10278,3 +10278,51 @@ Python to manipulate OpenDocument 1.2 files.")
 
 (define-public python2-odfpy
   (package-with-python2 python-odfpy))
+
+(define-public python-cachecontrol
+  (package
+(name "python-cachecontrol")
+(version "0.11.6")
+(source
+ (origin
+   (method url-fetch)
+   ;; Pypi does not have tests.
+   (uri (string-append
+ "https://github.com/ionrock/cachecontrol/archive/v;
+ version ".tar.gz"))
+   (file-name (string-append name "-" version ".tar.gz"))
+   (sha256
+(base32
+ "0yj60d0f69a2l8p7y86k4zhzzm6rnxpq74sfl240pry9l0lfw2vw"
+(build-system python-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (replace 'check
+   (lambda _
+ ;; Drop test that requires internet access.
+ (delete-file "tests/test_regressions.py")
+ (setenv "PYTHONPATH"
+ (string-append (getcwd) "/build/lib:"
+(getenv "PYTHONPATH")))
+ (zero? (system* "py.test" "-vv")))
+(native-inputs
+ `(("python-pytest" ,python-pytest)
+   ("python-redis" ,python-redis)
+   ("python-webtest" ,python-webtest)
+   ("python-mock" ,python-mock)))
+(propagated-inputs
+ `(("python-requests" ,python-requests)
+   ("python-lockfile" ,python-lockfile)))
+(home-page "https://github.com/ionrock/cachecontrol;)
+(synopsis "The httplib2 caching algorithms for use with requests")
+(description "CacheControl is a port of the caching algorithms in
+@code{httplib2} for use with @code{requests} session objects.")
+(license license:asl2.0)))
+
+(define-public python2-cachecontrol
+  (let ((base (package-with-python2 (strip-python2-variant python-cachecontrol
+(package (inherit base)
+ (native-inputs
+  `(("python2-setuptools" ,python2-setuptools)
+,@(package-native-inputs base))
-- 
2.9.3




Re: [PATCH] gnu: Add schismtracker.

2016-09-10 Thread Marius Bakke
Kei Kebreau  writes:

> For those who love making tracks, X11 or not!
>
> If someone could look over this (and build it, please!), that would be
> nice. :-)

Thanks for this package! See comments below.

> From 91dbcb5c61de4b4b45f85b3bad8cf9e713c564b0 Mon Sep 17 00:00:00 2001
> From: Kei Kebreau 
> Date: Fri, 9 Sep 2016 18:16:12 -0400
> Subject: [PATCH] gnu: Add schismtracker.
>
> * gnu/packages/music.scm (schismtracker): New variable.
> ---
>  gnu/packages/music.scm | 40 
>  1 file changed, 40 insertions(+)
>
> diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
> index 88743aa..7c11771 100644
> --- a/gnu/packages/music.scm
> +++ b/gnu/packages/music.scm
> @@ -1638,6 +1638,46 @@ for improved Amiga ProTracker 2/3 compatibility.")
>  ;; 'src/milkyplay' is under Modified BSD, the rest is under GPL3 or 
> later.
>  (license (list license:bsd-3 license:gpl3+
>  
> +(define-public schismtracker
> +  (package
> +(name "schismtracker")
> +(version "20160521")
> +(source (origin
> +  (method url-fetch)
> +  (uri (string-append
> +"https://github.com/; name "/" name "/archive/"
> +version ".tar.gz"))
> +  (file-name (string-append name "-" version ".tar.gz"))
> +  (sha256
> +   (base32
> +"0c6r24wm3rldm4j8cskl9xnixj3rwi3lnrhckw5gv43wpy6h4jcz"
> +(build-system gnu-build-system)
> +(arguments
> + `(#:phases
> +   (modify-phases %standard-phases
> + (add-after 'unpack 'autoconf
> +   (lambda _ (zero? (system* "autoreconf" "-vfi"
> + (add-before 'configure 'link-libm
> +   (lambda _ (setenv "LIBS" "-lm"))

I believe this should end with a #t, as the return value of setenv is
unspecified.

> +(native-inputs
> + `(("autoconf" ,autoconf)
> +   ("automake" ,automake)))
> +(inputs
> + `(("alsa-lib" ,alsa-lib) ; for asound dependency
> +   ("libx11" ,libx11)
> +   ("libxext" ,libxext)
> +   ("python" ,python-2)

Python is only used for building some documentation, so it can be moved
to native-inputs. Is there any reason for using python-2?

> +   ("sdl" ,sdl)))
> +(home-page "http://schismtracker.org;)
> +(synopsis "Impulse Tracker clone")

I think this should be more generic. The tagline from github works
pretty well: "Oldschool sample-based music composition tool".

The rest LGTM. But! The package records build time in version.c. I
managed to make it reproducible by adding a phase like this:

  (add-before 'build 'make-reproducible
(lambda _
  ;; Remove use of __DATE__ and __TIME__ for reproducibility.
  (substitute* "schism/version.c"
(("Schism Tracker built %s %s.*$")
 (string-append "Schism Tracker version " ,version "\");")))
  #t))

Please add that substitution somewhere. Can you send an updated patch?

Thanks!
Marius

> +(description
> + "Schism Tracker is a reimplementation of Impulse Tracker, a program 
> used to
> +create high quality music without the requirements of specialized, expensive
> +equipment, and with a unique \"finger feel\" that is difficult to replicate 
> in
> +part.  The player is based on a highly modified version of the ModPlug 
> engine,
> +with a number of bugfixes and changes to improve IT playback.")
> +(license license:gpl2+)))
> +
>  (define-public moc
>(package
>  (name "moc")
> -- 
> 2.10.0



Re: How to use "every"?

2016-09-09 Thread Marius Bakke
Danny Milosavljevic  writes:

> Hi,
>
> how do I use "every" in a guix package declaration?
>
> When I add #:modules (sfri sfri-1) I get a message that guix-build is
> undefined (?).

I think when setting #:modules, you also have to specify the
"expected" ones, i.e. it will override the defaults rather than append.

So argument would be:

#:modules ((srfi srfi-1)
   (guix build gnu-build-system)
   (guix build utils))

But I am pretty new to Guile and Guix, so take it with a grain of salt.

HTH!
Marius



Re: [PATCH] gnu: Add seqtk.

2016-09-09 Thread Marius Bakke
Marius Bakke <mba...@fastmail.com> writes:

> The program seems to bundle {khash,kseq}.h from htslib. Could you try
> replacing them with the files directly from htslib? There are quite a
> few examples of doing this already in bioinformatics.scm.

The released version bundles a few unnecessary header files as well,
that are removed in git. I think you can remove all ".h" files in an
origin snippet and substitute references to khash.h and kseq.h before
building.

Cheers,
Marius



Re: [PATCH] gnu: Add seqtk.

2016-09-09 Thread Marius Bakke
Ben Woodcroft  writes:

> Well, despite the lightness of my touch, it seems the licensing is in now in
> order.  I've updated the package, here's an updated patch.  Better?

I don't think this was intended to be a commit message? :)

The program seems to bundle {khash,kseq}.h from htslib. Could you try
replacing them with the files directly from htslib? There are quite a
few examples of doing this already in bioinformatics.scm.

I also think the original description from github is better:
"Toolkit for processing sequences in FASTA/Q formats".

Other than that LGTM.

Thanks!
Marius



Re: [PATCH] gnu: Add dlib.

2016-09-09 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> Changing the subject, you could disable the tests per-architecture. Look
> for uses of current-target-system and current-system for usage examples.
> But this is not absolutely required, IMO.

This latest patch series now disables tests on a per-arch basis.

There may be others on MIPS failing after the timeout, but extending the
list should be obvious.

Thanks for your patience!

>From 331d291cabcb5d17d0284414cae1f2ac5c32736a Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 23 Aug 2016 21:17:14 +0100
Subject: [PATCH 1/3] gnu: dlib: Remove unused fftw from inputs.

* gnu/packages/machine-learning.scm (dlib)[inputs]: Remove fftw.
  (define-module): Don't include algebra.scm.
---
 gnu/packages/machine-learning.scm | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 4332045..7669702 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -28,7 +28,6 @@
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system r)
   #:use-module (gnu packages)
-  #:use-module (gnu packages algebra)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages compression)
@@ -515,8 +514,7 @@ single hidden layer, and for multinomial log-linear models.")
 (native-inputs
  `(("pkg-config" ,pkg-config)))
 (inputs
- `(("fftw" ,fftw)
-   ("giflib" ,giflib)
+ `(("giflib" ,giflib)
;("lapack" ,lapack) XXX lapack here causes test failures in some setups.
("libjpeg" ,libjpeg)
("libpng" ,libpng)
-- 
2.9.3


>From 5c78ac7002cd92a2bfd8efa0f9902288dffe6a89 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 27 Aug 2016 17:23:58 +0100
Subject: [PATCH 2/3] gnu: dlib: Do not build dlib twice for tests.

* gnu/packages/machine-learning.scm (dlib)[arguments]: Use makefile
  instead of cmake in check phase to prevent full rebuild.
---
 gnu/packages/machine-learning.scm | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 7669702..e94ffdd 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -502,11 +502,10 @@ single hidden layer, and for multinomial log-linear models.")
  (replace 'check
(lambda _
  ;; No test target, so we build and run the unit tests here.
- (let ((test-dir (string-append "../dlib-" ,version "/dlib/test/build")))
-   (mkdir-p test-dir)
+ (let ((test-dir (string-append "../dlib-" ,version "/dlib/test")))
(with-directory-excursion test-dir
- (and (zero? (system* "cmake" ".."))
-  (zero? (system* "cmake" "--build" "." "--config" "Release"))
+ (setenv "CXXFLAGS" "-std=gnu++11")
+ (and (zero? (system* "make" "-j" (number->string (parallel-job-count
       (zero? (system* "./dtest" "--runall")))
  (add-after 'install 'delete-static-library
(lambda* (#:key outputs #:allow-other-keys)
-- 
2.9.3


>From dd8e87ecfb1f475bd0f88338f233883d02e649af Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 9 Sep 2016 01:51:23 +0100
Subject: [PATCH 3/3] gnu: dlib: Disable failing tests.

* gnu/packages/machine-learning.scm (dlib)[arguments]: Add phase to
  disable tests that are known not to work in the current release.
  [inputs]: Add lapack.
---
 gnu/packages/machine-learning.scm | 25 -
 1 file changed, 24 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index e94ffdd..dd260c9 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -499,6 +499,29 @@ single hidden layer, and for multinomial log-linear models.")
  (substitute* "dlib/config.h"
(("^//#define DLIB_DISABLE_ASSERTS") "#define DLIB_DISABLE_ASSERTS"))
  #t))
+ (add-after 'disable-asserts 'disable-failing-tests
+   (lambda _
+ ;; One test times out on MIPS, so we need to disable it.
+ ;; The rest is known to fail on non-x86_64 platforms in the current release.
+ ;; Some have been fixed in git; this list should be readjusted next update.
+ (let* ((system ,(or (%current-target-system)
+

Re: [PATCH] gnu: Add threadingbuildingblocks.

2016-09-08 Thread Marius Bakke
ng0  writes:

> +(arguments
> + `(;; XXX: make 'check' is run with 'make all', however the 'all' phase 
> takes
> +   ;; 30+ minutes on a AMD FX-4300 Quad-Core Processor buildmachine.
> +   #:tests? #f

30 minutes isn't bad, we have packages that takes longer. As long as it
prints something to the console, it won't time out on slow machines
either (but they will hopefully get substitutes from Hydra!).

The #:test-target seems to be 'test', by the way.

> +(inputs
> + `(("python" ,python)))

Does it reference python at runtime, or is it only used for building?
You can check for references with `guix gc -R /gnu/store/`.

> Thanks, that's what I had at first. What about the product name, what is
> it described as? Should I refer to debians description? I remember we
> don't include © and ® in synopsis and description, but company name +
> product works?

I think I would phrase it as: "Threading Building Blocks (Intel TBB) is
a C++ library for writing parallel programs that take full advantage of
multicore performance."

~marius



Re: [PATCH] gnu: Add mash.

2016-09-08 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Thu, Sep 01, 2016 at 11:00:39AM +0100, Marius Bakke wrote:
>> I had these in inputs initially and was surprised to see no references.
>> Both seems to be compiled into the final program[0]: when running "mash
>> info" on an invalid file (the provided data/refseq.msh), a generic
>> capnproto exception is thrown (src/capnp/serialize.c++:159).
>
> I wonder, does using native-inputs work when building mash for another
> architecture?

That's interesting, the package indeed fails to build on i686.

Sketch.cpp:(.text+0xdf): undefined reference to `memcpy@GLIBC_2.2.5'

I don't understand why, the symbol versions should be the same, no?

Are there any clever linker flags we can throw at it, or is setting
supported-systems acceptable?

>> That raises another question: should the htslib and capnproto licenses
>> be listed too, since they are part of the binary output?
>
> Good question, I'm not sure. I'd guess "yes", along with a code comment
> explaining what's going on.

I've attached a patch below, with license comments and amd64 only.

>> I'm not a bioinformatician (just a mere sysadmin for such), but have
>> been going through the tutorial and things appear to work fine.
>
> Ah, bioinformatics software... all bets are off ;)

You haven't seen anything yet! This is the nice part of my queue ;)

Thanks!
Marius

>From 9e8102ed2d5bf9334e5311f2ac917aed2f451361 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 30 Aug 2016 18:49:21 +0100
Subject: [PATCH] gnu: Add mash.

* gnu/packages/bioinformatics.scm (mash): New variable.
---
 gnu/packages/bioinformatics.scm | 57 +
 1 file changed, 57 insertions(+)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index f34acd1..decca6c 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -76,6 +76,7 @@
   #:use-module (gnu packages python)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages ruby)
+  #:use-module (gnu packages serialization)
   #:use-module (gnu packages statistics)
   #:use-module (gnu packages tbb)
   #:use-module (gnu packages tex)
@@ -3046,6 +3047,62 @@ sequences).")
   "http://mafft.cbrc.jp/alignment/software/license.txt;
   "BSD-3 with different formatting"
 
+(define-public mash
+  (package
+(name "mash")
+(version "1.1.1")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/marbl/mash/archive/v;
+version ".tar.gz"))
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"08znbvqq5xknfhmpp3wcj574zvi4p7i8zifi67c9qw9a6ikp42fj"))
+  (modules '((guix build utils)))
+  (snippet
+   ;; Delete bundled kseq.
+   ;; TODO: Also delete bundled murmurhash and open bloom filter.
+   '(delete-file "src/mash/kseq.h"
+(build-system gnu-build-system)
+(arguments
+ `(#:tests? #f ; No tests.
+   #:configure-flags
+   (list
+(string-append "--with-capnp=" (assoc-ref %build-inputs "capnproto"))
+(string-append "--with-gsl=" (assoc-ref %build-inputs "gsl")))
+   #:make-flags (list "CC=gcc")
+   #:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'fix-includes
+   (lambda _
+ (substitute* '("src/mash/Sketch.cpp" "src/mash/CommandFind.cpp")
+   (("^#include \"kseq\\.h\"")
+"#include \"htslib/kseq.h\""))
+ #t))
+ (add-before 'configure 'autoconf
+   (lambda _ (zero? (system* "autoconf")))
+(native-inputs
+ `(("autoconf" ,autoconf)
+   ;; Capnproto and htslib are statically embedded in the final
+   ;; application. Therefore we also list their licenses, below.
+   ("capnproto" ,capnproto)
+   ("htslib" ,htslib)))
+(inputs
+ `(("gsl" ,gsl)
+   ("zlib" ,zlib)))
+(supported-systems '("x86_64-linux"))
+(home-page "https://mash.readthedocs.io;)
+(synopsis "Fast genome and metagenome distance estimation using MinHash")
+(description "Mash is a fast sequence distance estimator that uses the
+MinHash algorithm and is designed to work with genomes and metagenomes in the
+form of assemblies or reads.")
+(license (list license:bsd-3  ; Mash
+   license:expat  ; HTSlib and capnproto
+   license:public-domain  ; MurmurHash 3
+   license:cpl1.0 ; Open Bloom Filter
+
 (define-public metabat
   (package
 (name "metabat")
-- 
2.9.3



Re: [PATCH]: opensmtpd, opensmtpd-extras, libasr.

2016-09-08 Thread Marius Bakke
ng0  writes:

> From 30c8260a039d4c8d7cddbfd92341afa65577d680 Mon Sep 17 00:00:00 2001
> From: ng0 
> Date: Tue, 6 Sep 2016 17:10:18 +
> Subject: [PATCH 1/3] gnu: Add libasr.
>
> * gnu/packages/web.scm (libasr): New variable.

Nice!

> ---
>  gnu/packages/web.scm | 33 +
>  1 file changed, 33 insertions(+)

>From reading the description below, should this not go in dns.scm?

> diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
> index 70bfd9e..59ae049 100644
> --- a/gnu/packages/web.scm
> +++ b/gnu/packages/web.scm
> @@ -61,6 +61,7 @@
>#:use-module (gnu packages gnome)
>#:use-module (gnu packages gperf)
>#:use-module (gnu packages gtk)
> +  #:use-module (gnu packages groff)
>#:use-module (gnu packages icu4c)
>#:use-module (gnu packages image)
>#:use-module (gnu packages lua)
> @@ -3609,3 +3610,35 @@ tools they trust (e.g. wget).")
>  rendering engine entirely written from scratch.  It is small and capable of
>  handling many of the web standards in use today.")
>  (license l:gpl2+)))
> +
> +(define-public libasr
> +  (package
> +(name "libasr")
> +(version "201602131606")
> +(source
> + (origin
> +   (method url-fetch)
> +   (uri (string-append "https://www.opensmtpd.org/archives/;
> +   name "-" version ".tar.gz"))
> +   (sha256
> +(base32
> + "18kdmbjsxrfai16d66qslp48b1zf7gr8him2jj5dcqgbsl44ls75"
> +(build-system gnu-build-system)
> +(native-inputs
> + `(("autoconf" ,autoconf)
> +   ("automake" ,automake)
> +   ("pkg-config" ,pkg-config)
> +   ("groff" ,groff)))
> +(home-page "https://www.opensmtpd.org;)
> +(synopsis "Asynchronous resolver library by the OpenBSD project")
> +(description
> + "libasr is a free, simple and portable asynchronous resolver library.
> +It allows to run dns queries and perform hostname resolutions in a fully
^^^
Please capitalize.

> +asynchronous fashion.  The implementation is thread-less, fork-less, and
> +does not make use of signals or other 'tricks' that might get in the
> +developer's way.")

The second sentence may be left off, IMO.

> +(license (list l:isc
> +   l:bsd-2 ; last part of getrrsetbyname_async.c
> +   l:bsd-3
> +   (l:non-copyleft "file://COPYING") ; includes.h

This should probably be "file://LICENSE".

> +   l:openssl

Why is OpenSSL listed? Grepping for 'openssl' returns no results.

The rest of this patch LGTM. I won't comment on the other two as I don't
know enough about how paths and user accounts is usually handled.

Cheers,
Marius



Re: [PATCH 1/1] gnu: Add acme-client.

2016-09-03 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Sat, Sep 03, 2016 at 11:32:20AM +0100, Marius Bakke wrote:
>> Many distros prefix OpenBSD projects with ambigous names with
>> "openbsd-". E.g. "openbsd-netcat", "openbsd-ntpd" etc. We don't appear
>> to have that problem yet, but I think this could be a good precedent.
>
> Is "openbsd-ntpd" the same thing as OpenNTPD? [0]
>
> As for openbsd-netcat, this was discussed on guix-devel recently, and we
> learned that OpenBSD does not provide a portable release of their netcat
> client. I don't think it would be appropriate for us to re-package
> Debian's unmaintained port of this software. [1]
>
> I looked at `apt-cache search openbsd`, which searches my Debian package
> cache for packages related to OpenBSD. I *think* that there isn't
> anything packaged with an "openbsd-" name that OpenBSD offers a portable
> release of, but I'm not sure about openbsd-inetd.
>
> On the other hand, they explicitly provide portable releases of things
> like OpenNTPD, OpenSSH, LibreSSL, and now acme-client.

You are right, of course. I could have sworn there were more. And I even
use OpenNTPD on many systems..

The other acme-client projects seems to be mostly library
implementations with a CLI frontend and are likely to end up as
"ruby-acme-client" or similar in the tree. So "acme-client" should be
perfectly fine. If anything we'll get to have a new bikeshedding round
if another popular client with the same name comes around. :)

~marius



Re: [PATCH] gnu: Add libicns

2016-09-03 Thread Marius Bakke
Brendan Tildesley <brendan.tildes...@openmailbox.org> writes:

> On 2016-09-03 22:38, Marius Bakke wrote:
>> Marius Bakke <mba...@fastmail.com> writes:
>>
>>> Additionally this package bundles "m4" even if it doesn't use it. Can
>>> you remove it with a "origin" snippet? See e.g. "xcb-util-xrm" for how
>>> that's done.
>> My mistake, it does appear to use those files, and it's not actually m4.
>> I think using the generated libtool is probably OK.
>>
>> Alternatively it can be re-generated by adding a phase that invokes
>> "autoreconf -vif". I'm not actually sure if this is desired, so just
>> leave it for now.
>>
>> Thank you,
>> Marius
>
> Ah, well that lost me a bit of time.

Sorry about that! Now it re-generates libtool and friends, so it doesn't
hurt, at least. I only have a couple of remarks, and then someone with
commit access can take a final glance.

> From b04ad5e40ac5befe30832ffbcf3b4283b4ae1d63 Mon Sep 17 00:00:00 2001
> From: Brendan Tildesley <brendan.tildes...@openmailbox.org>
> Date: Sat, 3 Sep 2016 05:53:56 +1000
> Subject: [PATCH] gnu: Add libicns.
>
> * gnu/packages/image.scm (libicns): New variable.
> ---
>  gnu/packages/image.scm | 40 
>  1 file changed, 40 insertions(+)
>
> diff --git a/gnu/packages/image.scm b/gnu/packages/image.scm
> index 4fdc4ae..1b21306 100644
> --- a/gnu/packages/image.scm
> +++ b/gnu/packages/image.scm
> @@ -48,6 +48,7 @@
>#:use-module (guix download)
>#:use-module (guix build-system gnu)
>#:use-module (guix build-system cmake)
> +  #:use-module (guix utils)

I don't think this is required.

>#:use-module (srfi srfi-1))
>  
>  (define-public libpng
> @@ -147,6 +148,45 @@ maximum quality factor.")
> (license license:gpl2+)
> (home-page "http://www.kokkonen.net/tjko/projects.html#jpegoptim;)))
>  
> +(define-public libicns
> +  (package
> +(name "libicns")
> +(version "0.8.1")
> +(source (origin
> + (method url-fetch)
> + (uri (string-append
> +   "mirror://sourceforge/icns/libicns-" version ".tar.gz"))
> + (sha256 (base32
> +  
> "1hjm8lwap7bjyyxsyi94fh5817xzqhk4kb5y0b7mb6675xw10prk"
> +(build-system gnu-build-system)
> +(inputs
> + `(("libpng" ,libpng-1.2)

It built fine with the latest libpng, is there a specific reason to use
this version?

> +   ("jasper" ,jasper)))
> +(native-inputs
> + `(("autoconf" ,autoconf)
> +   ("automake" ,automake)
> +   ("libtool" ,libtool)))
> +(arguments
> + ;; no tests
> + `(#:tests? #f

Typically we add the "no tests" remark at the end of the line, i.e.
`(#:tests? #f ; No tests.

> +   #:phases
> +   (modify-phases %standard-phases
> + (add-before 'configure 'autoconf

I would call this phase "autoreconf", since autoconf is another tool.

> +   (lambda _
> + (zero? (system* "autoreconf" "-vfi")))
> +(home-page "http://icns.sourceforge.net/;)
> +(synopsis "Library for handling Mac OS icns resource files")
> +(description
> + "Libicns is a library for the manipulation of Mac OS IconFamily resource
> +type files (ICNS).  @command{icns2png} and @command{png2icns} are provided to
> +convert between PNG and ICNS. @command{icns2png} will extract image files 
> from
> +ICNS files under names like \"Foo_48x48x32.png\" useful for installing for 
> use
> +with .desktop files.  Additionally, @Command{icontainer2png} is provided for
  ^^^
 This probably should not be capitalized.

> +extracting icontainer icon files.")
> +(license (list license:lgpl2.1+ ; libicns
> +   license:lgpl2.0+ ; src/apidocs.*
> +   license:gpl2+; icns2png, png2icns, icontainer2png

The rest of the patch looks good to me.

Thanks again!
Marius



Re: [PATCH 1/1] gnu: Add acme-client.

2016-09-03 Thread Marius Bakke
Andreas Enge  writes:

> On Fri, Sep 02, 2016 at 02:50:28PM -0400, Leo Famulari wrote:
>> On Fri, Sep 02, 2016 at 08:01:55PM +0200, Hartmut Goebel wrote:
>> > Am 02.09.2016 um 16:49 schrieb Leo Famulari:
>> > > +(name "acme-client")
>> > I strongly suggest using a different name, as this is *one* of many
>> > implementations and it is not the "official" one.
>> Suggestions?
>
> Is there other reasonably widely used software with this name? Our package
> guidelines say to use the upstream name.

I don't know about widely used, but searching "acme-client" on github
shows four projects with this name, neither of which is this package.

Many distros prefix OpenBSD projects with ambigous names with
"openbsd-". E.g. "openbsd-netcat", "openbsd-ntpd" etc. We don't appear
to have that problem yet, but I think this could be a good precedent.

-marius



Re: [PATCH] gnu: Add libicns

2016-09-03 Thread Marius Bakke
Brendan Tildesley  writes:

> From 64ca4155a754a93b26a1002185950f49469197f3 Mon Sep 17 00:00:00 2001
> From: Brendan Tildesley 
> Date: Sat, 3 Sep 2016 05:53:56 +1000
> Subject: [PATCH] gnu: Add libicns
>
> * gnu/packages/image.scm (libicns): New variable

Thanks! Nit-pick: we end commit messages and descriptions with a ".",
but this can be fixed by the committer.
  
> +(define-public libicns
> +  (package
> +(name "libicns")
> +(version "0.8.1")
> +(source (origin
> + (method url-fetch)
> + (uri (string-append
> +   "https://sourceforge.net/projects/icns/files/libicns-;

Could you change this to the mirror://sourceforge system?

> +   version ".tar.gz/download"))
> + (file-name (string-append "libicns-" version ".tar.gz"))

Changing file-name is only necessary if it doesn't already use a
"package-version.ext" style name, which this appears to do. `guix lint`
will tell whether this is needed.

> + (sha256 (base32
> +  
> "1hjm8lwap7bjyyxsyi94fh5817xzqhk4kb5y0b7mb6675xw10prk"
> +(build-system gnu-build-system)
> +(arguments
> + ;; no tests
> + '(#:tests? #f))
> +(inputs `(("libpng" ,libpng)
> +  ("jasper" ,jasper)))

We typically add the inputs on a new line, but I have no strong opinions
on this.

> +(home-page "http://icns.sourceforge.net/;)
> +(synopsis "Library for handling Mac OS icns resource files")
> +(description
> + "libicns is a library for the manipulation of Mac OS IconFamily resource
> +type files (ICNS).  icns2png and png2icns are provided to convert between PNG

When describing command-line tools, it looks prettier in generated
documentation by using `@command(icns2png)`, but this is not always the
case or necessary.

> +and ICNS. icns2png will extract image files from ICNS files under names like
> +\"Foo_48x48x32.png\" useful for installing for use with .desktop files.")
> +(license (list license:lgpl2.1+  ; libicns
> +   license:gpl2+ ; icns2png, png2icns, icontainer2png

A couple of files are "lgpl2+" as well.

Additionally this package bundles "m4" even if it doesn't use it. Can
you remove it with a "origin" snippet? See e.g. "xcb-util-xrm" for how
that's done.

The rest looks fine to me. Can you send an updated patch?

Thanks!
Marius



Re: [PATCH v2] gnu: Add python-odfpy.

2016-09-02 Thread Marius Bakke
Alex Kost <alez...@gmail.com> writes:

> Marius Bakke (2016-09-01 18:41 +0300) wrote:
>
>> From f1bccf9bf26088107b6fec31eece30676d5a362f Mon Sep 17 00:00:00 2001
>> From: Marius Bakke <mba...@fastmail.com>
>> Date: Wed, 17 Aug 2016 17:45:24 +0100
>> Subject: [PATCH] gnu: Add python-odfpy.
>>
>> * gnu/packages/python.scm (python-odfpy, python2-odfpy): New variables.
> [...]
>> +(arguments
>> + `(#:phases
>> +   (modify-phases %standard-phases
>> + (replace 'check
>> +   ;; The test runner invokes python2 and python3 for test*.py.
>> +   ;; To avoid having both in inputs, we replicate it here.
>> +   (lambda _
>> + (for-each (lambda (test-file)
>
> 'every' procedure should be used here instead: 'for-each' is for side
> effects only, its returned value is unspecified; and with 'every', the
> check phase will fail if any of the tests fails.

Thanks Alex, that's really useful to know.

I've updated the patch.

>From 99216a79ddd817ce7be9da451c0a1b5d9ef73f46 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 17 Aug 2016 17:45:24 +0100
Subject: [PATCH] gnu: Add python-odfpy.

* gnu/packages/python.scm (python-odfpy, python2-odfpy): New variables.
---
 gnu/packages/python.scm | 37 +
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 8b52548..33674fa 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -26,6 +26,7 @@
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapient...@openmailbox.org>
 ;;; Copyright © 2016 David Craven <da...@craven.ch>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -10241,3 +10242,39 @@ time by mocking the datetime module.")
   (native-inputs
`(("python2-setuptools" ,python2-setuptools)
  ,@(package-native-inputs base))
+
+(define-public python-odfpy
+  (package
+(name "python-odfpy")
+(version "1.3.3")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "odfpy" version))
+  (sha256
+   (base32
+"1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"
+(arguments
+ `(#:modules ((srfi srfi-1)
+  (guix build python-build-system)
+  (guix build utils))
+   #:phases
+   (modify-phases %standard-phases
+ (replace 'check
+   ;; The test runner invokes python2 and python3 for test*.py.
+   ;; To avoid having both in inputs, we replicate it here.
+   (lambda _
+ (every (lambda (test-file)
+  (zero? (system* "python" test-file)))
+(find-files "tests" "^test.*\\.py$")))
+(build-system python-build-system)
+(home-page "https://github.com/eea/odfpy;)
+(synopsis "Python API and tools to manipulate OpenDocument files")
+(description "Collection of libraries and utility programs written in
+Python to manipulate OpenDocument 1.2 files.")
+(license
+ ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
+ ;; number of files with other licenses.
+ (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0
+
+(define-public python2-odfpy
+  (package-with-python2 python-odfpy))
-- 
2.9.3



[PATCH v2] gnu: Add python-odfpy.

2016-09-01 Thread Marius Bakke
>From f1bccf9bf26088107b6fec31eece30676d5a362f Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 17 Aug 2016 17:45:24 +0100
Subject: [PATCH] gnu: Add python-odfpy.

* gnu/packages/python.scm (python-odfpy, python2-odfpy): New variables.
---
 gnu/packages/python.scm | 34 ++
 1 file changed, 34 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 09fe627..f5c7498 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -26,6 +26,7 @@
 ;;; Copyright © 2016 ng0 <n...@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Dylan Jeffers <sapientech@sapient...@openmailbox.org>
 ;;; Copyright © 2016 David Craven <da...@craven.ch>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -10264,3 +10265,36 @@ time by mocking the datetime module.")
   (native-inputs
`(("python2-setuptools" ,python2-setuptools)
  ,@(package-native-inputs base))
+
+(define-public python-odfpy
+  (package
+(name "python-odfpy")
+(version "1.3.3")
+(source (origin
+  (method url-fetch)
+  (uri (pypi-uri "odfpy" version))
+  (sha256
+   (base32
+"1a6ms0w9zfhhkqhvrnynwwbxrivw6hgjc0s5k7j06npc7rq0blxw"
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (replace 'check
+   ;; The test runner invokes python2 and python3 for test*.py.
+   ;; To avoid having both in inputs, we replicate it here.
+   (lambda _
+ (for-each (lambda (test-file)
+ (zero? (system* "python" test-file)))
+   (find-files "tests" "^test.*\\.py$")))
+(build-system python-build-system)
+(home-page "https://github.com/eea/odfpy;)
+(synopsis "Python API and tools to manipulate OpenDocument files")
+(description "Collection of libraries and utility programs written in
+Python to manipulate OpenDocument 1.2 files.")
+(license
+ ;; The software is mainly dual GPL2+ and ASL2.0, but includes a
+ ;; number of files with different licenses.
+ (list license:gpl2+ license:asl2.0 license:lgpl2.1+ license:cc-by-sa3.0
+
+(define-public python2-odfpy
+  (package-with-python2 python-odfpy))
-- 
2.9.3




Re: [PATCH] gnu: Add mash.

2016-09-01 Thread Marius Bakke

Leo Famulari  writes:

>> + (add-after 'unpack 'fix-includes
>> +   (lambda _
>> + (substitute* '("src/mash/Sketch.cpp" 
>> "src/mash/CommandFind.cpp")
>> +   (("^#include \"kseq\\.h\"")
>> +"#include \"htslib/kseq.h\""))
>> + #t))
>> + (add-before 'configure 'autoconf
>> +   (lambda _ (zero? (system* "autoconf")))
>> +(native-inputs
>> + `(("autoconf" ,autoconf)
>> +   ("capnproto" ,capnproto)
>> +   ("htslib" ,htslib)))
>
> Does it only need to use capnproto and htslib while building? Okay if
> so.

I had these in inputs initially and was surprised to see no references.
Both seems to be compiled into the final program[0]: when running "mash
info" on an invalid file (the provided data/refseq.msh), a generic
capnproto exception is thrown (src/capnp/serialize.c++:159).

That raises another question: should the htslib and capnproto licenses
be listed too, since they are part of the binary output?

I'm not a bioinformatician (just a mere sysadmin for such), but have
been going through the tutorial and things appear to work fine.

0: https://github.com/marbl/Mash/blob/master/Makefile.in#L38



Re: [PATCH] gnu: rofi: Update to 1.2.0.

2016-08-31 Thread Marius Bakke

> Done and done! New patches attached.

Oops, forgot to refresh my local branch. Here are the actual new
patches.

>From e1606ba7814ff218a5670aab22b57686b71f2922 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 15:37:18 +0100
Subject: [PATCH 1/2] gnu: Add xcb-util-xrm.

* gnu/packages/xdisorg.scm (xcb-util-xrm): New variable.
---
 gnu/packages/xdisorg.scm | 41 +
 1 file changed, 41 insertions(+)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index cc83a04..06ed052 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2016 Efraim Flashner <efr...@flashner.co.il>
 ;;; Copyright © 2016 Leo Famulari <l...@famulari.name>
 ;;; Copyright © 2016 Alex Kost <alez...@gmail.com>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -49,6 +50,7 @@
   #:use-module (gnu packages gl)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages gnome)
+  #:use-module (gnu packages m4)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages python)
@@ -1021,3 +1023,42 @@ The taskbar includes transparency and color settings for the font, icons,
 border, and background.  It also supports multihead setups, customized mouse
 actions, a built-in clock, a battery monitor and a system tray.")
 (license license:gpl2)))
+
+(define-public xcb-util-xrm
+  (package
+(name "xcb-util-xrm")
+(version "1.0")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/Airblader/xcb-util-xrm/releases;
+"/download/v" version "/xcb-util-xrm-" version ".tar.bz2"))
+  (sha256
+   (base32
+"1h5vxwpd37dqfw9yj1l4zd9c5dj30r3g0szgysr6kd7xrqgaq04l"))
+  (modules '((guix build utils)))
+  (snippet
+   ;; Drop bundled m4.
+   '(delete-file-recursively "m4"
+(build-system gnu-build-system)
+(native-inputs
+ `(("pkg-config" ,pkg-config)
+   ("m4" ,m4)
+   ("libx11" ,libx11))) ; for tests
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util" ,xcb-util)))
+(home-page "https://github.com/Airblader/xcb-util-xrm;)
+(synopsis "XCB utility functions for the X resource manager")
+(description
+ "The XCB util module provides a number of libraries which sit on
+top of libxcb, the core X protocol library, and some of the extension
+libraries.  These experimental libraries provide convenience functions
+and interfaces which make the raw X protocol more usable.  Some of the
+libraries also provide client-side code which is not strictly part of
+the X protocol but which has traditionally been provided by Xlib.
+
+XCB util-xrm module provides the following libraries:
+
+- xrm: utility functions for the X resource manager.")
+(license license:x11)))
-- 
2.9.3

>From cb5d1f27388ab748afa96b86cc146545192f1b79 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 15:45:06 +0100
Subject: [PATCH 2/2] gnu: rofi: Update to 1.2.0.

* gnu/packages/xdisorg.scm (rofi): Update to 1.2.0.
  [inputs]: Drop libx11 and add xcb-util-xrm.
---
 gnu/packages/xdisorg.scm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 06ed052..323ff11 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -940,7 +940,7 @@ connectivity of the X server running on a particular @code{DISPLAY}.")
 (define-public rofi
   (package
 (name "rofi")
-(version "1.1.0")
+(version "1.2.0")
 (source (origin
   (method url-fetch)
   (uri (string-append "https://github.com/DaveDavenport/rofi/;
@@ -948,17 +948,17 @@ connectivity of the X server running on a particular @code{DISPLAY}.")
   version "/rofi-" version ".tar.xz"))
   (sha256
(base32
-"1l8vl0mh7i0b1ycifqpg6392f5i4qxlv003m126skfk6fnlfq8hn"
+"0xxx0xpxhrhlhi2axq9867zqrhwqavc1qrr833k1xr0pvm5m0aqc"
 (build-system gnu-build-system)
 (inputs
- `(("libx11" ,libx11)
-   ("pango" ,pango)
+ `(("pango" ,pango)
("cairo" ,cairo)
("glib" ,glib)
("startup-notification" ,startup-notification)
("libxkbcommon" ,libxkbcommon)
("libxcb" ,libxcb)
("xcb-util" ,xcb-util)
+   ("xcb-util-xrm" ,xcb-util-xrm)
("xcb-util-wm" ,xcb-util-wm)))
 (native-inputs
  `(("pkg-config" ,pkg-config)))
-- 
2.9.3



Re: [PATCH] gnu: rofi: Update to 1.2.0.

2016-08-31 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

>> * gnu/packages/xdisorg.scm (xcb-util-xrm): New variable.
>
> This actually bundles m4, even if it doesn't use it. Can you delete that
> 'm4' directory in an origin snippet? There's an example in the calibre
> package definition.

Good catch!

>> +  (uri (string-append
>> +
>> "https://github.com/Airblader/xcb-util-xrm/releases/download;
>
> Also this line a bit too long :)

Done and done! New patches attached.

>From 002e487185df0f6c5ad38c297ee77c9d1150841a Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 15:37:18 +0100
Subject: [PATCH 1/2] gnu: Add xcb-util-xrm.

* gnu/packages/xdisorg.scm (xcb-util-xrm): New variable.
---
 gnu/packages/xdisorg.scm | 37 +
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index cc83a04..b2cdde8 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2016 Efraim Flashner <efr...@flashner.co.il>
 ;;; Copyright © 2016 Leo Famulari <l...@famulari.name>
 ;;; Copyright © 2016 Alex Kost <alez...@gmail.com>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -49,6 +50,7 @@
   #:use-module (gnu packages gl)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages gnome)
+  #:use-module (gnu packages m4)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages python)
@@ -1021,3 +1023,38 @@ The taskbar includes transparency and color settings for the font, icons,
 border, and background.  It also supports multihead setups, customized mouse
 actions, a built-in clock, a battery monitor and a system tray.")
 (license license:gpl2)))
+
+(define-public xcb-util-xrm
+  (package
+(name "xcb-util-xrm")
+(version "1.0")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/Airblader/xcb-util-xrm/releases/download;
+"/v" version "/xcb-util-xrm-" version ".tar.bz2"))
+  (sha256
+   (base32
+"1h5vxwpd37dqfw9yj1l4zd9c5dj30r3g0szgysr6kd7xrqgaq04l"
+(build-system gnu-build-system)
+(native-inputs
+ `(("pkg-config" ,pkg-config)
+   ("m4" ,m4)
+   ("libx11" ,libx11))) ; for tests
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util" ,xcb-util)))
+(home-page "https://github.com/Airblader/xcb-util-xrm;)
+(synopsis "XCB utility functions for the X resource manager")
+(description
+ "The XCB util module provides a number of libraries which sit on
+top of libxcb, the core X protocol library, and some of the extension
+libraries.  These experimental libraries provide convenience functions
+and interfaces which make the raw X protocol more usable.  Some of the
+libraries also provide client-side code which is not strictly part of
+the X protocol but which has traditionally been provided by Xlib.
+
+XCB util-xrm module provides the following libraries:
+
+- xrm: utility functions for the X resource manager.")
+(license license:x11)))
-- 
2.9.3

>From 2daec13c728424a3e3b7695b30f873da47c22172 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 15:45:06 +0100
Subject: [PATCH 2/2] gnu: rofi: Update to 1.2.0.

* gnu/packages/xdisorg.scm (rofi): Update to 1.2.0.
  [inputs]: Drop libx11 and add xcb-util-xrm.
---
 gnu/packages/xdisorg.scm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index b2cdde8..b294a79 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -940,7 +940,7 @@ connectivity of the X server running on a particular @code{DISPLAY}.")
 (define-public rofi
   (package
 (name "rofi")
-(version "1.1.0")
+(version "1.2.0")
 (source (origin
   (method url-fetch)
   (uri (string-append "https://github.com/DaveDavenport/rofi/;
@@ -948,17 +948,17 @@ connectivity of the X server running on a particular @code{DISPLAY}.")
   version "/rofi-" version ".tar.xz"))
   (sha256
(base32
-"1l8vl0mh7i0b1ycifqpg6392f5i4qxlv003m126skfk6fnlfq8hn"
+"0xxx0xpxhrhlhi2axq9867zqrhwqavc1qrr833k1xr0pvm5m0aqc"
 (build-system gnu-build-system)
 (inputs
- `(("libx11" ,libx11)
-   ("pango" ,pango)
+ `(("pango" ,pango)
("cairo" ,cairo)
("glib" ,glib)
("startup-notification" ,startup-notification)
("libxkbcommon" ,libxkbcommon)
("libxcb" ,libxcb)
("xcb-util" ,xcb-util)
+   ("xcb-util-xrm" ,xcb-util-xrm)
("xcb-util-wm" ,xcb-util-wm)))
 (native-inputs
  `(("pkg-config" ,pkg-config)))
-- 
2.9.3



[PATCH] gnu: rofi: Update to 1.2.0.

2016-08-31 Thread Marius Bakke
Greetings Guix,

I am the maintainer of this package in NixOS and figured I could update
it here as well, since it was non-trivial.

The libx11 dependency is dropped in favour of a new xcb-util-xrm module.
I added the latter to xdisorg since it's not listed on xcb.fd.o proper,
but followed the convention of the other xcb-util-* libraries.

Disclaimer: untested, apart from building with rounds=2.

>From 002e487185df0f6c5ad38c297ee77c9d1150841a Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 15:37:18 +0100
Subject: [PATCH 1/2] gnu: Add xcb-util-xrm.

* gnu/packages/xdisorg.scm (xcb-util-xrm): New variable.
---
 gnu/packages/xdisorg.scm | 37 +
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index cc83a04..b2cdde8 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -14,6 +14,7 @@
 ;;; Copyright © 2016 Efraim Flashner <efr...@flashner.co.il>
 ;;; Copyright © 2016 Leo Famulari <l...@famulari.name>
 ;;; Copyright © 2016 Alex Kost <alez...@gmail.com>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -49,6 +50,7 @@
   #:use-module (gnu packages gl)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages gnome)
+  #:use-module (gnu packages m4)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages python)
@@ -1021,3 +1023,38 @@ The taskbar includes transparency and color settings for the font, icons,
 border, and background.  It also supports multihead setups, customized mouse
 actions, a built-in clock, a battery monitor and a system tray.")
 (license license:gpl2)))
+
+(define-public xcb-util-xrm
+  (package
+(name "xcb-util-xrm")
+(version "1.0")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/Airblader/xcb-util-xrm/releases/download;
+"/v" version "/xcb-util-xrm-" version ".tar.bz2"))
+  (sha256
+   (base32
+"1h5vxwpd37dqfw9yj1l4zd9c5dj30r3g0szgysr6kd7xrqgaq04l"
+(build-system gnu-build-system)
+(native-inputs
+ `(("pkg-config" ,pkg-config)
+   ("m4" ,m4)
+   ("libx11" ,libx11))) ; for tests
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util" ,xcb-util)))
+(home-page "https://github.com/Airblader/xcb-util-xrm;)
+(synopsis "XCB utility functions for the X resource manager")
+(description
+ "The XCB util module provides a number of libraries which sit on
+top of libxcb, the core X protocol library, and some of the extension
+libraries.  These experimental libraries provide convenience functions
+and interfaces which make the raw X protocol more usable.  Some of the
+libraries also provide client-side code which is not strictly part of
+the X protocol but which has traditionally been provided by Xlib.
+
+XCB util-xrm module provides the following libraries:
+
+- xrm: utility functions for the X resource manager.")
+(license license:x11)))
-- 
2.9.3

>From 2daec13c728424a3e3b7695b30f873da47c22172 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 15:45:06 +0100
Subject: [PATCH 2/2] gnu: rofi: Update to 1.2.0.

* gnu/packages/xdisorg.scm (rofi): Update to 1.2.0.
  [inputs]: Drop libx11 and add xcb-util-xrm.
---
 gnu/packages/xdisorg.scm | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index b2cdde8..b294a79 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -940,7 +940,7 @@ connectivity of the X server running on a particular @code{DISPLAY}.")
 (define-public rofi
   (package
 (name "rofi")
-(version "1.1.0")
+(version "1.2.0")
 (source (origin
   (method url-fetch)
   (uri (string-append "https://github.com/DaveDavenport/rofi/;
@@ -948,17 +948,17 @@ connectivity of the X server running on a particular @code{DISPLAY}.")
   version "/rofi-" version ".tar.xz"))
   (sha256
(base32
-"1l8vl0mh7i0b1ycifqpg6392f5i4qxlv003m126skfk6fnlfq8hn"
+"0xxx0xpxhrhlhi2axq9867zqrhwqavc1qrr833k1xr0pvm5m0aqc"
 (build-system gnu-build-system)
 (inputs
- `(("libx11" ,libx11)
-   ("pango" ,pango)
+ `(("pango" ,pango)
("cairo" ,cairo)
("glib" ,glib)
("startup-notification" ,startup-notification)
("libxkbcommon" ,libxkbcommon)
("libxcb" ,libxcb)
("xcb-util" ,xcb-util)
+   ("xcb-util-xrm" ,xcb-util-xrm)
("xcb-util-wm" ,xcb-util-wm)))
 (native-inputs
  `(("pkg-config" ,pkg-config)))
-- 
2.9.3



Re: [PATCH] gnu: slim: Move to display-managers.scm.

2016-08-31 Thread Marius Bakke
David Craven  writes:

> Are you packaging lightdm? I started packaging lightdm before sddm.
> But then I realized that it doesn't support (and probably never will)
> wayland sessions. Looks to me like another we are ubuntu and we are
> doing our own thing kind of project... ;-)

No immediate plans to package lightdm, but I'm sure it will get in
eventually. It offers some nice features such as light-locker and
multiple sessions, but I could not get either working properly..

Perhaps when I finally make the jump to GuixSD :)

~marius



[PATCH] gnu: slim: Move to display-managers.scm.

2016-08-31 Thread Marius Bakke
Hi,

This change is to make room for SDDM and other display managers such as
lightdm.

I did not add a copyright line as I consider "git mv" a trivial
operation.

>From a7e59cb154bd11e7ca04f68753982b21bef22b10 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Wed, 31 Aug 2016 14:07:15 +0100
Subject: [PATCH] gnu: slim: Move to display-managers.scm.

* gnu/packages/display-managers.scm: New file.
* gnu/packages/slim.scm: Delete file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Adjust accordingly.
* gnu/services/xorg.scm: Likewise.
---
 gnu/local.mk| 2 +-
 gnu/packages/{slim.scm => display-managers.scm} | 2 +-
 gnu/services/xorg.scm   | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)
 rename gnu/packages/{slim.scm => display-managers.scm} (98%)

diff --git a/gnu/local.mk b/gnu/local.mk
index 5ec47fc..bc34e4a 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -96,6 +96,7 @@ GNU_SYSTEM_MODULES =\
   %D%/packages/dictionaries.scm			\
   %D%/packages/dillo.scm			\
   %D%/packages/disk.scm\
+  %D%/packages/display-managers.scm		\
   %D%/packages/djvu.scm\
   %D%/packages/dns.scm\
   %D%/packages/docbook.scm			\
@@ -320,7 +321,6 @@ GNU_SYSTEM_MODULES =\
   %D%/packages/skarnet.scm			\
   %D%/packages/skribilo.scm			\
   %D%/packages/slang.scm			\
-  %D%/packages/slim.scm\
   %D%/packages/smalltalk.scm			\
   %D%/packages/speech.scm			\
   %D%/packages/spice.scm			\
diff --git a/gnu/packages/slim.scm b/gnu/packages/display-managers.scm
similarity index 98%
rename from gnu/packages/slim.scm
rename to gnu/packages/display-managers.scm
index 2328a1a..579b149 100644
--- a/gnu/packages/slim.scm
+++ b/gnu/packages/display-managers.scm
@@ -18,7 +18,7 @@
 ;;; You should have received a copy of the GNU General Public License
 ;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
 
-(define-module (gnu packages slim)
+(define-module (gnu packages display-managers)
   #:use-module ((guix licenses) #:prefix l:)
   #:use-module (guix packages)
   #:use-module (guix download)
diff --git a/gnu/services/xorg.scm b/gnu/services/xorg.scm
index 905c88f..4e311de 100644
--- a/gnu/services/xorg.scm
+++ b/gnu/services/xorg.scm
@@ -26,7 +26,7 @@
   #:use-module (gnu packages guile)
   #:use-module (gnu packages xorg)
   #:use-module (gnu packages gl)
-  #:use-module (gnu packages slim)
+  #:use-module (gnu packages display-managers)
   #:use-module (gnu packages gnustep)
   #:use-module (gnu packages admin)
   #:use-module (gnu packages bash)
-- 
2.9.3



Re: [PATCH] gnu: Add gzstream.

2016-08-31 Thread Marius Bakke
Eric Bavier <ericbav...@openmailbox.org> writes:

> Thanks for the patch!  Comments below:
>
> On Tue, 30 Aug 2016 19:17:14 +0100
> Marius Bakke <mba...@fastmail.com> wrote:
>
>> From 5e96b895c1ed77a6bfdcbe5c6dbd68220fd5a8dc Mon Sep 17 00:00:00 2001
>> From: Marius Bakke <m.ba...@warwick.ac.uk>
>> Date: Fri, 12 Aug 2016 02:29:51 +0100
>> Subject: [PATCH 1/1] gnu: Add gzstream.
>> 
>> * gnu/packages/compression.scm (gzstream): New variable.
>> ---
>> [...]
>> +(source (origin
>> +  (method url-fetch)
>> +  (uri
>> +   ;; No versioned URL, but last release was in 2003.
>> +   
>> "http://www.cs.unc.edu/Research/compgeom/gzstream/gzstream.tgz;)
>> +  (file-name (string-append name "-" version ".tar.gz"))
>> +  (sha256
>> +   (base32
>> +"00y19pqjsdj5zcrx4p9j56pl73vayfwnb7y2hvp423nx0cwv5b4r"
>
> There's a gzstream.o file in the tarball.  Could you remove it an origin
> snippet?
>
>> [...]
>> +(home-page "http://www.cs.unc.edu/Research/compgeom/gzstream/;)
>> +(synopsis "C++ library that provides the functionality of zlib in a C++ 
>> iostream")
>
> Maybe: "Compressed C++ iostream"
>
>> +(description "gzstream is a small library for providing zlib 
>> functionality in a C++
>> +iostream.  It is basically just a wrapper.")
>
> The second sentence may be left off, IMO.
>
>> +(license license:lgpl2.1)))
>     ^
> This should be lgpl2.1+ because of the "or later" in the file headers.
>
> Could you send an updated patch?

Hi Eric,

Thanks for the quick feedback! Correct on all accounts.

Updated patch below.

>From a8aae7f44289c75f67f2bea1046206f79acbdbdb Mon Sep 17 00:00:00 2001
From: Marius Bakke <m.ba...@warwick.ac.uk>
Date: Fri, 12 Aug 2016 02:29:51 +0100
Subject: [PATCH] gnu: Add gzstream.

* gnu/packages/compression.scm (gzstream): New variable.
---
 gnu/packages/compression.scm | 39 +++
 1 file changed, 39 insertions(+)

diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm
index c239d16..3f60c5b 100644
--- a/gnu/packages/compression.scm
+++ b/gnu/packages/compression.scm
@@ -12,6 +12,7 @@
 ;;; Copyright © 2016 Danny Milosavljevic <dan...@scratchpost.org>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
 ;;; Copyright © 2016 David Craven <da...@craven.ch>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -895,3 +896,41 @@ compared to the fastest mode of zlib, Snappy is an order of magnitude faster
 for most inputs, but the resulting compressed files are anywhere from 20% to
 100% bigger.")
 (license license:asl2.0)))
+
+(define-public gzstream
+  (package
+(name "gzstream")
+(version "1.5")
+(source (origin
+  (method url-fetch)
+  (uri
+   ;; No versioned URL, but last release was in 2003.
+   "http://www.cs.unc.edu/Research/compgeom/gzstream/gzstream.tgz;)
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"00y19pqjsdj5zcrx4p9j56pl73vayfwnb7y2hvp423nx0cwv5b4r"))
+  (modules '((guix build utils)))
+  (snippet
+   ;; Remove pre-compiled object.
+   '(delete-file "gzstream.o"
+(build-system gnu-build-system)
+(arguments
+ `(#:test-target "test"
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure)
+ (replace 'install
+   (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+(lib (string-append out "/lib"))
+(include (string-append out "/include")))
+   (install-file "libgzstream.a" lib)
+   (install-file "gzstream.h" include)
+   #t))
+(propagated-inputs `(("zlib" ,zlib)))
+(home-page "http://www.cs.unc.edu/Research/compgeom/gzstream/;)
+(synopsis "Compressed C++ iostream")
+(description "gzstream is a small library for providing zlib
+functionality in a C++ iostream.")
+(license license:lgpl2.1+)))
-- 
2.9.3



Re: [PATCH] gnu: Add praat

2016-08-30 Thread Marius Bakke
Brendan Tildesley  writes:

> This marks my first attempt at writing a package definition for Guix.
> Please assume it is broken since I still don't know what I'm doing, and
> forgive me if you need to school me on things written in the manual. If
> someone on GuixSD could test if it builds, load an audio file and see if
> it plays correctly, that would be a good test. When I compiled it on
> Parabola, it sets the wrong audio server by default so I had to change
> it in settings to ALSA via PortAudio in the GUI. I'm interested to see
> if it requires that on someone else's configuration too.

Hi Brendan,

Thanks for your contribution!

The patch was not recognized by my mail client, it's likely your mail
user agent changed the formatting.

I've fixed the patch indentation and commit message, and also added it
to local.mk, see updated patch below.

I don't have a Guix system with audio atm so someone else will have to
review it :)

Cheers,
Marius

>From b2194272655f6455e7a7ad7bdf78cb827f204f3d Mon Sep 17 00:00:00 2001
From: Brendan Tildesley 
Date: Wed, 31 Aug 2016 02:08:15 +1000
Subject: [PATCH 1/1] gnu: Add praat.

* gnu/packages/linguistics.scm: New file.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add it.
---
 gnu/local.mk |  1 +
 gnu/packages/linguistics.scm | 79 
 2 files changed, 80 insertions(+)
 create mode 100644 gnu/packages/linguistics.scm

diff --git a/gnu/local.mk b/gnu/local.mk
index d75ab54..c38bdef 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -211,6 +211,7 @@ GNU_SYSTEM_MODULES =\
   %D%/packages/libusb.scm			\
   %D%/packages/libunwind.scm			\
   %D%/packages/libupnp.scm			\
+  %D%/packages/linguistics.scm			\
   %D%/packages/links.scm			\
   %D%/packages/linux.scm			\
   %D%/packages/lirc.scm\
diff --git a/gnu/packages/linguistics.scm b/gnu/packages/linguistics.scm
new file mode 100644
index 000..6c4823c
--- /dev/null
+++ b/gnu/packages/linguistics.scm
@@ -0,0 +1,79 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2016 Brendan Tildesley 
+;;;
+;;; 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 linguistics)
+  #:use-module ((guix licenses) #:prefix license:)
+  #:use-module (guix packages)
+  #:use-module (guix build-system gnu)
+  #:use-module (guix utils)
+  #:use-module (guix download)
+  #:use-module (gnu packages)
+  #:use-module (gnu packages linux) ; for alsa-lib
+  #:use-module (gnu packages gtk)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages version-control)
+  #:use-module (gnu packages python)
+  #:use-module (gnu packages pulseaudio))
+
+(define-public praat
+  (package
+(name "praat")
+(version "6.0.19")
+(source
+ (origin
+   (method url-fetch)
+   (uri (string-append "https://github.com/praat/praat/archive/v;
+   version ".tar.gz"))
+   (file-name (string-append name "-" version ".tar.gz"))
+   (sha256
+(base32 "1fhzqzygx5h6xkjaxwgzvnby393q7c3lby0fq3bnhscfdhzkm0a0"
+(build-system gnu-build-system)
+(native-inputs
+ `(("pkg-config" ,pkg-config)))
+(inputs
+ `(("gtk" ,gtk+-2)
+   ("alsa-lib" ,alsa-lib)
+   ("pulseaudio" ,pulseaudio)
+   ("python" ,python))) ; optional scripts
+(arguments
+ `(#:tests? #f
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure)
+ (add-before 'build 'copy-makefile
+   ;; setup makefile for compiling on Linux as per README.md. There may
+   ;; be issues with this. The audio config may need to be changed in
+   ;; the GUI. If that is the case when tested on GuixSD, I'd like to
+   ;; figure out how to patch praat to work by default.
+   (lambda _
+ (copy-file "makefiles/makefile.defs.linux.pulse"
+"makefile.defs")
+ #t))
+ (replace 'install
+   (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+(target (string-append out "/bin")))
+   (mkdir-p target)
+   (install-file "praat" target))
+ #t)
+

[PATCH] gnu: Add gzstream.

2016-08-30 Thread Marius Bakke
>From 5e96b895c1ed77a6bfdcbe5c6dbd68220fd5a8dc Mon Sep 17 00:00:00 2001
From: Marius Bakke <m.ba...@warwick.ac.uk>
Date: Fri, 12 Aug 2016 02:29:51 +0100
Subject: [PATCH 1/1] gnu: Add gzstream.

* gnu/packages/compression.scm (gzstream): New variable.
---
 gnu/packages/compression.scm | 35 +++
 1 file changed, 35 insertions(+)

diff --git a/gnu/packages/compression.scm b/gnu/packages/compression.scm
index c239d16..b3b7f52 100644
--- a/gnu/packages/compression.scm
+++ b/gnu/packages/compression.scm
@@ -12,6 +12,7 @@
 ;;; Copyright © 2016 Danny Milosavljevic <dan...@scratchpost.org>
 ;;; Copyright © 2016 Tobias Geerinckx-Rice <m...@tobias.gr>
 ;;; Copyright © 2016 David Craven <da...@craven.ch>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -895,3 +896,37 @@ compared to the fastest mode of zlib, Snappy is an order of magnitude faster
 for most inputs, but the resulting compressed files are anywhere from 20% to
 100% bigger.")
 (license license:asl2.0)))
+
+(define-public gzstream
+  (package
+(name "gzstream")
+(version "1.5")
+(source (origin
+  (method url-fetch)
+  (uri
+   ;; No versioned URL, but last release was in 2003.
+   "http://www.cs.unc.edu/Research/compgeom/gzstream/gzstream.tgz;)
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"00y19pqjsdj5zcrx4p9j56pl73vayfwnb7y2hvp423nx0cwv5b4r"
+(build-system gnu-build-system)
+(arguments
+ `(#:test-target "test"
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure)
+ (replace 'install
+   (lambda* (#:key outputs #:allow-other-keys)
+ (let* ((out (assoc-ref outputs "out"))
+(lib (string-append out "/lib"))
+(include (string-append out "/include")))
+   (install-file "libgzstream.a" lib)
+   (install-file "gzstream.h" include)
+   #t))
+(propagated-inputs `(("zlib" ,zlib)))
+(home-page "http://www.cs.unc.edu/Research/compgeom/gzstream/;)
+(synopsis "C++ library that provides the functionality of zlib in a C++ iostream")
+(description "gzstream is a small library for providing zlib functionality in a C++
+iostream.  It is basically just a wrapper.")
+(license license:lgpl2.1)))
-- 
2.9.3




[PATCH] gnu: Add mash.

2016-08-30 Thread Marius Bakke
>From 2097408c8e94d10423d4a156caa5298d6dcb Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 30 Aug 2016 18:49:21 +0100
Subject: [PATCH 1/1] gnu: Add mash.

* gnu/packages/bioinformatics.scm (mash): New variable.
---
 gnu/packages/bioinformatics.scm | 53 +
 1 file changed, 53 insertions(+)

diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.scm
index ed20b56..9b96d37 100644
--- a/gnu/packages/bioinformatics.scm
+++ b/gnu/packages/bioinformatics.scm
@@ -76,6 +76,7 @@
   #:use-module (gnu packages python)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages ruby)
+  #:use-module (gnu packages serialization)
   #:use-module (gnu packages statistics)
   #:use-module (gnu packages tbb)
   #:use-module (gnu packages tex)
@@ -3046,6 +3047,58 @@ sequences).")
   "http://mafft.cbrc.jp/alignment/software/license.txt;
   "BSD-3 with different formatting"
 
+(define-public mash
+  (package
+(name "mash")
+(version "1.1.1")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://github.com/marbl/mash/archive/v;
+version ".tar.gz"))
+  (file-name (string-append name "-" version ".tar.gz"))
+  (sha256
+   (base32
+"08znbvqq5xknfhmpp3wcj574zvi4p7i8zifi67c9qw9a6ikp42fj"))
+  (modules '((guix build utils)))
+  (snippet
+   ;; Delete bundled kseq.
+   ;; TODO: Also delete bundled murmurhash and open bloom filter.
+   '(delete-file "src/mash/kseq.h"
+(build-system gnu-build-system)
+(arguments
+ `(#:tests? #f ; No tests.
+   #:configure-flags
+   (list
+(string-append "--with-capnp=" (assoc-ref %build-inputs "capnproto"))
+(string-append "--with-gsl=" (assoc-ref %build-inputs "gsl")))
+   #:make-flags (list "CC=gcc")
+   #:phases
+   (modify-phases %standard-phases
+ (add-after 'unpack 'fix-includes
+   (lambda _
+ (substitute* '("src/mash/Sketch.cpp" "src/mash/CommandFind.cpp")
+   (("^#include \"kseq\\.h\"")
+"#include \"htslib/kseq.h\""))
+ #t))
+ (add-before 'configure 'autoconf
+   (lambda _ (zero? (system* "autoconf")))
+(native-inputs
+ `(("autoconf" ,autoconf)
+   ("capnproto" ,capnproto)
+   ("htslib" ,htslib)))
+(inputs
+ `(("gsl" ,gsl)
+   ("zlib" ,zlib)))
+(home-page "https://mash.readthedocs.io;)
+(synopsis "Fast genome and metagenome distance estimation using MinHash")
+(description "Mash is a fast sequence distance estimator that uses the
+MinHash algorithm and is designed to work with genomes and metagenomes in the
+form of assemblies or reads.")
+;; Mash is distributed under 3-clause BSD, but includes software covered
+;; by other licenses.
+(license (list license:bsd-3 license:public-domain license:cpl1.0
+
 (define-public metabat
   (package
 (name "metabat")
-- 
2.9.3




Re: [PATCH] gnu: Add dlib.

2016-08-30 Thread Marius Bakke
Marius Bakke <mba...@fastmail.com> writes:

> Leo Famulari <l...@famulari.name> writes:
>
>> On Wed, Aug 24, 2016 at 11:26:28AM +0100, Marius Bakke wrote:
>>> There are a couple of things going on in this thread:
>>> 
>>> 1. Segfault on x86_64. This seems to have been resolved simply by
>>> updating OpenBLAS. At least, I'm no longer able to reproduce it even
>>> with LAPACK in inputs. So, that should fix the Hydra x86_64 build.
>>> Can the OpenBLAS update be cherry-picked to master?
>>
>> I'd say it depends on whether the OpenBLAS users are building
>> successfully on core-updates, but unfortunately core-updates is
>> currently failing early in the bootstrap process [0]. Can you take a
>> look at `guix refresh -l dlib` and pick some important looking
>> applications to test with the updated OpenBLAS?
>
> I'm currently building the following openblas dependents: `libreoffice
> bamm python-biom-format clipper shogun armadillo julia` and will try to
> test BLAS functionality in some of them.

Shogun failed to build in this run. I don't have time to investigate
further, so picking the OpenBLAS update is not very appealing.

Instead I opted to disable the test that fails with lapack (and without,
on Hydra), since it's one specific openblas operation that is not unique
to dlib. I think it's an acceptable tradeoff, to give users the full
dlib functionality, and have the segfault "sort itself" when
core-updates lands in master.

>>> 2. i686 test failures. Updating OpenBLAS fixed 1/5 errors. The remaining
>>> four are reproducible on 32-bit Ubuntu, so they do not seem Guix
>>> related. Upstream has been notified.
>>> 
>>> 3. ARM failures. I don't have ARM hardware to test on, but I'm guessing
>>> it's similar to i686 (i.e. not directly Guix related).
>>
>> Maybe dlib is 64-bit only? If that's the case, we can disable it on
>> those architectures.
>
> According to the developer[0], these targets should be supported.
>
> 0: https://github.com/davisking/dlib/issues/197
>
> We could disable tests (at least the failing ones) on these platforms
> until this issue is resolved. The mips64el target on Hydra times out
> after 3600 seconds on one of the tests, but seems fine up to that point.
> Some of these tests are fairly CPU heavy, so the timeout may be too low.

Below is a patch which disables these tests (and the above segfault) for
19.1, rather than backporting the patches from dlib master branch.

One note about the patch: I could not figure out how to pass the list of
tests as arguments to `substitute*`, so currently it calls `substitute*`
for each of them. Any tips to prevent this?

It also no longer builds the main application twice for tests.

>From fe3b7409d32bbfd5c263d1d8f080b160ac676b84 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 23 Aug 2016 21:17:14 +0100
Subject: [PATCH 1/2] gnu: dlib: Remove unused fftw from inputs.

* gnu/packages/machine-learning.scm (dlib)[inputs]: Remove fftw.
  (define-module): Don't include algebra.scm.
---
 gnu/packages/machine-learning.scm | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 4332045..7669702 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -28,7 +28,6 @@
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system r)
   #:use-module (gnu packages)
-  #:use-module (gnu packages algebra)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages compression)
@@ -515,8 +514,7 @@ single hidden layer, and for multinomial log-linear models.")
 (native-inputs
  `(("pkg-config" ,pkg-config)))
 (inputs
- `(("fftw" ,fftw)
-   ("giflib" ,giflib)
+ `(("giflib" ,giflib)
;("lapack" ,lapack) XXX lapack here causes test failures in some setups.
("libjpeg" ,libjpeg)
("libpng" ,libpng)
-- 
2.9.3

>From 121895b2d7915b1f1ef0430921418783019393d0 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Sat, 27 Aug 2016 17:23:58 +0100
Subject: [PATCH 2/2] gnu: dlib: Disable failing tests.

* gnu/packages/machine-learning.scm (dlib)[arguments]: Add
  'disable-failing-tests phase and prevent building dlib twice.
  [inputs]: Add lapack.
---
 gnu/packages/machine-learning.scm | 21 -
 1 file changed, 16 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 7669702..35f1514 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -499,14 +499,25 @@ single hidden

Re: [PATCH] gnu: Add ola

2016-08-26 Thread Marius Bakke

> 2 files changed, 4 insertions(+), 6 deletions(-)
> gnu/local.mk | 1 +
> gnu/packages/ola.scm | 9 +++--

Perhaps this could be added to something like automation.scm?
Or iot.scm?

> +(synopsis "Framework for controlling entertainment lighting equipment")
> +(description "The Open Lighting Architecture is a framework for lighting
> +control information.  It supports a range of protocols and over a dozen USB
> +devices.  It can run as a standalone service, which is useful for converting
> +signals between protocols, or alternatively using the OLA API, it can be used
> +as the backend for lighting control software.  OLA runs on many different
> +platforms including ARM, which makes it a perfect fit for low cost Ethernet 
> to
> +DMX gateways.")

Marius



Re: [PATCH] gnu: Add capnproto.

2016-08-25 Thread Marius Bakke
Alex Vong  writes:

>> PS. regarding the man page, I believe Debian mostly generated this
>> page from the capnp tool's help text. I'd accept a patch to
>> c++/src/kj/main.c++ which adds some code to generate man XML format
>> directly, so that we don't have to maintain the same text in multiple
>> places.
>
> I want to ask what is meant by man XML format? Do you mean to generate
> man page? As far as I know, there are at least 2 ways to generate a man
> page. One way is to use help2man, which is probably the Debian's
> approach. Another way is to write the man page in pod (perl's plain old
> documentation) and use pod2man to translate it into a man page. Would
> you accept any of these approaches?

I think Kenton is referring to the Debian manual, which is in XML
format:

https://github.com/thomaslee/capnproto-debian/blob/master/debian/capnp.1.xml

But you are right, it would be better to convert it to a standard format
and simply add a make target for it.

Cheers,
Marius



Re: [PATCH] gnu: Add capnproto.

2016-08-25 Thread Marius Bakke
Kenton Varda  writes:

> Hi, Cap'n Proto upstream author here. Noticed this thread in a Google
> search, thought I'd comment.
>
> To shed some light on the googletest situation:
>
> The googletest maintainers have deemed that googletest should never
> ever be system-installed, and have even disabled `make install` in
> their build. See:
>
> https://github.com/google/googletest/blob/master/googletest/Makefile.am#L300
>
> I don't really understand what they think they're solving here but it
> is what it is and this seems to make it hard to use googletest in a
> non-bundled way. It's possible I misunderstood, though.

Hi, thanks for dropping in!

>From reading the comments in the Makefile, apparently they are trying to
enforce something called the One-Definition Rule:

https://en.wikipedia.org/wiki/One_Definition_Rule

The way Guix (and actually most distro build systems) works makes it
impossible for another definition to "leak" into the build container, so
I don't understand either what they are trying to solve.

> FWIW, Cap'n Proto only uses googletest to build its tests. It does not
> install any artifacts that were influenced by googletest.
>
> In any case, this dependency will be gone once I find time to do the
> next release. Sorry for the trouble in the meantime.

No worries, can't blame you for bundling something clearly designed to
be bundled. It's usually easier to remove, though ;)

> PS. regarding the man page, I believe Debian mostly generated this
> page from the capnp tool's help text. I'd accept a patch to
> c++/src/kj/main.c++ which adds some code to generate man XML format
> directly, so that we don't have to maintain the same text in multiple
> places.

I'm guessing it's the issue I opened that sent you here :)
My C++ fu is not strong enough to embark on that journey, but maybe if
you mention it in the ticket someone may pick it up.

Thanks for the feedback!

Marius



Re: [PATCH] gnu: Add dlib.

2016-08-24 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Wed, Aug 24, 2016 at 11:26:28AM +0100, Marius Bakke wrote:
>> There are a couple of things going on in this thread:
>> 
>> 1. Segfault on x86_64. This seems to have been resolved simply by
>> updating OpenBLAS. At least, I'm no longer able to reproduce it even
>> with LAPACK in inputs. So, that should fix the Hydra x86_64 build.
>> Can the OpenBLAS update be cherry-picked to master?
>
> I'd say it depends on whether the OpenBLAS users are building
> successfully on core-updates, but unfortunately core-updates is
> currently failing early in the bootstrap process [0]. Can you take a
> look at `guix refresh -l dlib` and pick some important looking
> applications to test with the updated OpenBLAS?

I'm currently building the following openblas dependents: `libreoffice
bamm python-biom-format clipper shogun armadillo julia` and will try to
test BLAS functionality in some of them.

>> 2. i686 test failures. Updating OpenBLAS fixed 1/5 errors. The remaining
>> four are reproducible on 32-bit Ubuntu, so they do not seem Guix
>> related. Upstream has been notified.
>> 
>> 3. ARM failures. I don't have ARM hardware to test on, but I'm guessing
>> it's similar to i686 (i.e. not directly Guix related).
>
> Maybe dlib is 64-bit only? If that's the case, we can disable it on
> those architectures.

According to the developer[0], these targets should be supported.

0: https://github.com/davisking/dlib/issues/197

We could disable tests (at least the failing ones) on these platforms
until this issue is resolved. The mips64el target on Hydra times out
after 3600 seconds on one of the tests, but seems fine up to that point.
Some of these tests are fairly CPU heavy, so the timeout may be too low.

>> Adding "#:parallel-build? #f" had no effect on tests, indeed the check
>> phase does not seem to use the previously built dlib; it builds it again
>> without parallel-build. I will try reproducing the non-reproducibility
>> on some higher end hardware, hopefully this week.
>
> It's weird that it rebuilds the application again for the tests. Which
> build is actually installed in the case of success? Is it worth an
> upstream bug report?

We rely on cmake-build-system for everything but the check phase, which
doesn't have a "proper" check target. I'm no cmake expert, but we can
probably prevent re-build by not including the main application in
test/CmakeLists.txt and instead copy/link in our already-built version:

https://github.com/davisking/dlib/blob/master/dlib/test/CMakeLists.txt#L15

>> I've also found that FFTW is no longer used, apparently due to thread
>> safety issues. So I'd appreciate if the following patch can be added.
>> Apologies for not catching the missing reference earlier, I will be more
>> careful in the future (fftw was added in the last minute..).
>
> Can you hold this patch locally in your "dlib fixes" queue? It would
> trigger a rebuild of dlib on Hydra, but I don't see the point when we
> expect the build to fail near the end anyways.

Yep, hanging on to it for now.



Re: GuixSD 0.11.0 Install

2016-08-24 Thread Marius Bakke
David Craven  writes:

>> (device "my-root")
>
>> (device "my-boot")
>
> device should be a path to the device node and should look something
> like /dev/sda1 and /dev/sda2.
>
>> (title 'label)
>
>> (title 'label)
>
> remove these

(title 'label) instructs the boot routine to look for a partition or
device with filesystem label "my-root" or "my-boot" instead of a device
path. That works on my GuixSD at least:

  (file-systems (cons (file-system
(device "root")
(title 'label)
(mount-point "/")
(type "ext4"))
  %base-file-systems))



Re: [PATCH] gnu: Add dlib.

2016-08-24 Thread Marius Bakke
Marius Bakke <mba...@fastmail.com> writes:

>> Without OpenBLAS dlib will use an internal BLAS implementation. I'm
>> fairly certain that will at least fix the crash on x86_64, which was
>> a segfault in libopenblasp-r0.2.15.so when we had LAPACK in inputs, but
>> seems to consistently trigger on Hydra regardless.
>>
>> I got busy this weekend, but will try to reproduce the i686 errors this
>> week; and also check if the newer openblas in core-updates solves the
>> x86_64 segfault.
>>
>> Stay tuned...
>
> Short update: I can successfully reproduce the i686 test failures simply
> by `guix build --system=i686-linux` on x86_64. Removing OpenBLAS from
> inputs had no effect. Now to figure out what's going on..

There are a couple of things going on in this thread:

1. Segfault on x86_64. This seems to have been resolved simply by
updating OpenBLAS. At least, I'm no longer able to reproduce it even
with LAPACK in inputs. So, that should fix the Hydra x86_64 build.
Can the OpenBLAS update be cherry-picked to master?

2. i686 test failures. Updating OpenBLAS fixed 1/5 errors. The remaining
four are reproducible on 32-bit Ubuntu, so they do not seem Guix
related. Upstream has been notified.

3. ARM failures. I don't have ARM hardware to test on, but I'm guessing
it's similar to i686 (i.e. not directly Guix related).

Adding "#:parallel-build? #f" had no effect on tests, indeed the check
phase does not seem to use the previously built dlib; it builds it again
without parallel-build. I will try reproducing the non-reproducibility
on some higher end hardware, hopefully this week.

I've also found that FFTW is no longer used, apparently due to thread
safety issues. So I'd appreciate if the following patch can be added.
Apologies for not catching the missing reference earlier, I will be more
careful in the future (fftw was added in the last minute..).

>From 714f38b31996e014ed0cc56391e379e2241ee26e Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Tue, 23 Aug 2016 21:17:14 +0100
Subject: [PATCH] gnu: dlib: Remove unused fftw from inputs.

* gnu/packages/machine-learning.scm (dlib)[inputs]: Remove fftw.
  (define-module): Don't include algebra.scm.
---
 gnu/packages/machine-learning.scm | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 4332045..7669702 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -28,7 +28,6 @@
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system r)
   #:use-module (gnu packages)
-  #:use-module (gnu packages algebra)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages boost)
   #:use-module (gnu packages compression)
@@ -515,8 +514,7 @@ single hidden layer, and for multinomial log-linear models.")
 (native-inputs
  `(("pkg-config" ,pkg-config)))
 (inputs
- `(("fftw" ,fftw)
-   ("giflib" ,giflib)
+ `(("giflib" ,giflib)
;("lapack" ,lapack) XXX lapack here causes test failures in some setups.
("libjpeg" ,libjpeg)
("libpng" ,libpng)
-- 
2.9.3



Re: [PATCH] gnu: Add dlib.

2016-08-23 Thread Marius Bakke

> Without OpenBLAS dlib will use an internal BLAS implementation. I'm
> fairly certain that will at least fix the crash on x86_64, which was
> a segfault in libopenblasp-r0.2.15.so when we had LAPACK in inputs, but
> seems to consistently trigger on Hydra regardless.
>
> I got busy this weekend, but will try to reproduce the i686 errors this
> week; and also check if the newer openblas in core-updates solves the
> x86_64 segfault.
>
> Stay tuned...

Short update: I can successfully reproduce the i686 test failures simply
by `guix build --system=i686-linux` on x86_64. Removing OpenBLAS from
inputs had no effect. Now to figure out what's going on..

Marius



Re: [PATCH] gnu: Add capnproto.

2016-08-23 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Sat, Aug 20, 2016 at 01:22:30PM +0100, Marius Bakke wrote:
>> Subject: [PATCH] gnu: Add capnproto.
>> 
>> * gnu/packages/serialization.scm (capnproto): New variable.
>
> Thanks, pushed as 557d3328!

Cheers!

> By the way, I noticed some other distros include a man page for
> capnproto. Can you look into doing something similar for us?

Nice find! I guess we can pull the one from Debian. From capnp.1.xml:

  This manual page was written for the Debian system
(and may be used by others).

Not sure how to add it though, are there other packages with multiple
sources that can be used as reference?

Also, Gentoo apparently decouples gtest by two `sed` commands and
triggering `autoreconf`. I will try that too.

Thanks!
Marius



Re: [PATCH] gnu: Add dlib.

2016-08-22 Thread Marius Bakke
Ben Woodcroft <b.woodcr...@uq.edu.au> writes:

> On 21/08/16 16:17, Leo Famulari wrote:
>> On Fri, Aug 19, 2016 at 11:52:37AM +0100, Marius Bakke wrote:
>>> Leo Famulari <l...@famulari.name> writes:
>>>
>>>> I pushed the patch as 5f0ff6a9e. Hopefully dlib is still useful without
>>>> lapack. We should really figure out what the issue is and fix it :)
>>> I noticed this fails to build on Hydra. What's worse is that the i686,
>>> x86_64 and armhf targets fails at completely different things. armhf and
>>> i686 exits cleanly after failing 2 and 5 tests respectively, while the
>>> x86_64 target seems to get the segfault we saw with lapack in inputs.
>>>
>>> What should we do? I'd prefer to keep the package so it can easily be
>>> tested on various architectures, but can understand if it is reverted.
>>> Perhaps we can disable substitutes or tests, to stop bothering Hydra?
>>>
>>> I'll try reproducing it this weekend on various qemu configurations.
>> Let us know about the results of your tests. Then we can decide what to
>> do.
> Can this be fixed simply by using #parallel-build #f ? Doing so makes it 
> reproducible for me so arguably we should be doing that anyway, even if 
> it takes longer to build.

Any chance you can diff the outputs? If there is a race condition or
similar it may indeed fix some problems, but it would be nice to notify
upstream about it.

I opened an issue on their bug tracker, and the suggestion was to
disable BLAS: https://github.com/davisking/dlib/issues/197

Without OpenBLAS dlib will use an internal BLAS implementation. I'm
fairly certain that will at least fix the crash on x86_64, which was
a segfault in libopenblasp-r0.2.15.so when we had LAPACK in inputs, but
seems to consistently trigger on Hydra regardless.

I got busy this weekend, but will try to reproduce the i686 errors this
week; and also check if the newer openblas in core-updates solves the
x86_64 segfault.

Stay tuned...

-marius



Re: [PATCH] gnu: Add capnproto.

2016-08-20 Thread Marius Bakke
Leo Famulari <l...@famulari.name> writes:

> On Fri, Aug 19, 2016 at 06:06:24PM -0400, Leo Famulari wrote:
>> On Sun, Aug 14, 2016 at 07:16:22PM +0100, Marius Bakke wrote:
>> > Leo Famulari <l...@famulari.name> writes:
>> > 
>> > > On Sat, Aug 13, 2016 at 07:48:36PM +0100, Marius Bakke wrote:
>> > >> Note that it bundles googletest; I tried unbundling but it proved
>> > >> difficult. gtest will no longer be used from the 0.6 release so I did
>> > >> not think a comment was necessary.
>> > >
>> > > I am cc-ing Lukas with my reply, since he added our googletest package.
>> > > Maybe he has some insight.
>> > The problem is that their autotools system expects to build gtest as
>> > well, so there are references all over. See:
>> > https://github.com/sandstorm-io/capnproto/blob/release-0.5.3/c%2B%2B/Makefile.am
>> > and also configure.ac. It would have to be patched out, which seems
>> > excessive for a 4MB build dependency.
>> 
>> In my opinion, it's generally not about the size of the bundled
>> dependency. Rather, it's about the opacity of the dependency graph of
>> the application that does the bundling. The worst case would be
>> something like a bundled OpenSSL, for example.
>> 
>> In this case, Debian has accepted the bundled gtest [0], which makes me
>> wonder if my understanding of gtest is incorrect. Perhaps it is designed
>> to be bundled?

It comes bundled more often than not, but decoupling generally works out
of the box, as it's just linked to as with any library AFAICT:

https://github.com/google/googletest/blob/master/googletest/docs/Primer.md

If it was any other library, or if it wasn't dropped in current git, I
would have gone through the effort of purging it.

> In any case, since Debian accepted it, I'm willing to accept it as well,
> unless somebody objects.
>
> But the patch has gone stale due to other changes in serialization.scm.
> Marius, will you send an updated patch?

New patch below. Thanks!

>From 6e73e7c85a044d1da176534ed8ff046431afe617 Mon Sep 17 00:00:00 2001
From: Marius Bakke <mba...@fastmail.com>
Date: Fri, 12 Aug 2016 13:42:16 +0100
Subject: [PATCH] gnu: Add capnproto.

* gnu/packages/serialization.scm (capnproto): New variable.
---
 gnu/packages/serialization.scm | 30 ++
 1 file changed, 30 insertions(+)

diff --git a/gnu/packages/serialization.scm b/gnu/packages/serialization.scm
index c3ce5c5..4a3278f 100644
--- a/gnu/packages/serialization.scm
+++ b/gnu/packages/serialization.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2015 Ricardo Wurmus <rek...@elephly.net>
 ;;; Copyright © 2016 Lukas Gradl <lgr...@openmailbox.org>
 ;;; Copyright © 2016 David Craven <da...@craven.ch>
+;;; Copyright © 2016 Marius Bakke <mba...@fastmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -170,3 +171,32 @@ including serialization and deserialization to and from strings.  It can also
 preserve existing comment in unserialization/serialization steps, making
 it a convenient format to store user input files.")
 (license license:expat)))
+
+(define-public capnproto
+  (package
+(name "capnproto")
+(version "0.5.3")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"https://capnproto.org/capnproto-c++-;
+version ".tar.gz"))
+  (sha256
+   (base32
+"1yvaadhgakskqq5wpv53hd6fc3pp17mrdldw4i5cvgck4iwprcfd"
+(build-system gnu-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-before 'check 'do-not-require-/etc/services
+   (lambda _
+ ;; Workaround for test that tries to resolve port name from
+ ;; /etc/services, which is not present in build environment.
+ (substitute* "src/kj/async-io-test.c++" ((":http") ":80"))
+ #t)
+(home-page "https://capnproto.org;)
+(synopsis "Capability-based RPC and serialization system")
+(description
+ "Cap'n Proto is a very fast data interchange format and capability-based
+RPC system.  Think JSON, except binary.  Or think Protocol Buffers, except faster.")
+(license license:expat)))
-- 
2.9.2



<    5   6   7   8   9   10   11   >