[PATCH] gnu: Simplify LLVM build.

2015-08-16 Thread Andy Wingo
>From db066d194d3b8359eddd0149234bfad29c11542d Mon Sep 17 00:00:00 2001
From: Andy Wingo 
Date: Mon, 17 Aug 2015 08:26:07 +0200
Subject: [PATCH] gnu: Simplify LLVM build.

* gnu/packages/llvm.scm (llvm): Simplify build.
---
 gnu/packages/llvm.scm | 20 ++--
 1 file changed, 2 insertions(+), 18 deletions(-)

diff --git a/gnu/packages/llvm.scm b/gnu/packages/llvm.scm
index 9e06a64..2c96e9d 100644
--- a/gnu/packages/llvm.scm
+++ b/gnu/packages/llvm.scm
@@ -49,24 +49,8 @@
  `(("python" ,python-wrapper)
("perl"   ,perl)))
 (arguments
- `(#:phases (alist-cons-before
- 'build 'link-lib-for-build-exec
- (lambda* (#:key outputs #:allow-other-keys)
-   ;; This is a hacky fix that will allow binaries to run
-   ;; before being installed.  -DCMAKE_SKIP_BUILD_RPATH=FALSE
-   ;; seems to not help.  Nixpkgs does the same.
-   (let* ((out   (assoc-ref outputs "out"))
-  (out-lib   (string-append out "/lib"))
-  (build-lib (string-append (getcwd) "/lib")))
- (mkdir-p out)
- (symlink build-lib out-lib)))
- (alist-cons-after
-  'build 'cleanup-out
-  (lambda* (#:key outputs #:allow-other-keys)
-;; Cleanup the symlink that was created previously.  Let
-;; the install phase repopulate out.
-(delete-file-recursively (assoc-ref outputs "out")))
-  %standard-phases
+ `(#:configure-flags '("-DCMAKE_SKIP_BUILD_RPATH=FALSE"
+   "-DCMAKE_BUILD_WITH_INSTALL_RPATH=FALSE")))
 (home-page "http://www.llvm.org";)
 (synopsis "Optimizing compiler infrastructure")
 (description
-- 
2.4.3




Re: [PATCH] build: ruby: Rewrite build system to use gem archives.

2015-08-16 Thread Pjotr Prins
Made my day :)

On Sun, Aug 16, 2015 at 06:19:21PM -0400, Thompson, David wrote:
> Update:
> 
> On Tue, Jul 28, 2015 at 9:09 AM, David Thompson
>  wrote:
> 
> > One other caveat is that downloading gems from rubygems.org currently
> > *does not* work because the HTTP responses include an invalid
> > Content-Type header.  I added a temporary hack to do my development
> > work (not in this patch), and I'm currently waiting on a response from
> > the rubygems.org admins to see if they will fix the issue.  So, this
> > patch should not be applied until this is resolved.
> >
> > See: 
> > http://help.rubygems.org/discussions/problems/21223-invalid-content-type-header-when-downloading-gem-archive?unresolve=true
> 
> This issue has been fixed by the rubygems.org admins!  I would like to
> apply the below patch ASAP and get to work on 'guix import gem' if
> there are no objections.
> 
> The major change from the previous version of this patch is that I
> figured how to unpack the source gem, allow the package build script
> to make any necessary dynamic patches, and then install a repacked gem
> as opposed to the source gem.
> 
> - Dave

> From ee027442dd968734831eb372fcf502dcfaad7623 Mon Sep 17 00:00:00 2001
> From: David Thompson 
> Date: Sun, 26 Jul 2015 22:01:54 -0400
> Subject: [PATCH] build: ruby: Rewrite build system to use gem archives.
> 
> Co-Authored-By: Pjotr Prins 
> 
> * guix/build-system/ruby.scm (lower): Remove git dependency.
>   (rubygems-uri): New procedure.
> * guix/build/ruby-build-system (gitify, build): Delete.
>   (unpack): Use 'gem unpack' utility.
>   (check): Add docstring.
>   (install): Rebuild unpacked gem and install it.
>   (%standard-phases): Remove gitify and build phases.
> * gnu/packages/ruby.scm (ruby-hoe, ruby-rake-compiler, ruby-i18n,
>   ruby-rspec-support, ruby-rspec-core, ruby-diff-lcs-for-rspec,
>   ruby-rspec-expectations, ruby-rspec-mocks, ruby-rspec, bundler,
>   ruby-useragent, ruby-bacon, ruby-arel, ruby-connection-pool,
>   ruby-net-http-persistent, ruby-minitest, ruby-minitest-sprint,
>   ruby-minitest-bacon, ruby-daemons, ruby-git, ruby-slop,
>   ruby-multipart-post): Convert to new build system.
> ---
>  gnu/packages/ruby.scm| 222 
> +++
>  guix/build-system/ruby.scm   |  40 +++
>  guix/build/ruby-build-system.scm |  60 +++
>  3 files changed, 125 insertions(+), 197 deletions(-)
> 
> diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
> index a481365..196094c 100644
> --- a/gnu/packages/ruby.scm
> +++ b/gnu/packages/ruby.scm
> @@ -154,13 +154,11 @@ a focus on simplicity and productivity.")
>  (name "ruby-hoe")
>  (version "3.13.1")
>  (source (origin
> -  (method git-fetch)
> -  (uri (git-reference
> -(url "https://github.com/seattlerb/hoe.git";)
> -(commit "0c11836"))) ; no release tags :(
> +  (method url-fetch)
> +  (uri (rubygems-uri "hoe" version))
>(sha256
> (base32
> -"0i8dimf8kxcjgqj9x65bbi3l6hc9p9gbfbb1vmrz42764a4jjbz9"))) )
> +"1mac13krdrasn9819dd65xj27kklfy0xdbj3p6s2ij4vlcb46h8q"))) )
>  (build-system ruby-build-system)
>  (synopsis "Ruby project management helper")
>  (description
> @@ -178,22 +176,13 @@ announcement.")
>  (version "0.9.5")
>  (source (origin
>(method url-fetch)
> -  (uri (string-append
> -
> "https://github.com/rake-compiler/rake-compiler/archive/v";
> -version ".tar.gz"))
> -  (file-name (string-append name "-" version ".tar.gz"))
> +  (uri (rubygems-uri "rake-compiler" version))
>(sha256
> (base32
> -"07lk1vl0jqcaqwjjhmg0qshqwcxdyr5kscc9xxm13m03835xgpf3"
> +"1k8im2vzj849xdgjk6wafspkiwwapqwm738majchb4dnhnsk64cx"
>  (build-system ruby-build-system)
>  (arguments
> - '(#:tests? #f ; needs cucumber
> -   #:phases (modify-phases %standard-phases
> -  (add-before 'build 'remove-cucumber-rake-task
> -(lambda _
> -  ;; Remove cucumber test file because the
> -  ;; dependencies are not available right now.
> -  (delete-file "tasks/cucumber.rake"))
> + '(#:tests? #f)) ; needs cucumber
>  (synopsis "Building and packaging helper for Ruby native extensions")
>  (description "Rake-compiler provides a framework for building and
>  packaging native C and Java extensions in Ruby.")
> @@ -206,12 +195,10 @@ packaging native C and Java extensions in Ruby.")
>  (version "0.6.11")
>  (source (origin
>(method url-fetch)
> -  (uri (string-append 
> "https://github.com/svenfuchs/i18n/archive/v";
> -  version ".tar.gz"))
> -  (file-name (str

Re: [PATCH 6/7] gnu: Add libconfuse.

2015-08-16 Thread Eric Bavier
On Mon, 17 Aug 2015 05:05:36 +0200
Eric Dvorsak  wrote:

> * gnu/packages/i3.scm (libconfuse): New variable.
> ---
>  gnu/packages/i3.scm | 22 ++
>  1 file changed, 22 insertions(+)
> 
> diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
> index bcb4888..725fdb6 100644
> --- a/gnu/packages/i3.scm
> +++ b/gnu/packages/i3.scm
> @@ -39,6 +39,28 @@
>#:use-module (guix download)
>#:use-module (guix git-download))
>  
> +(define-public libconfuse
> +  (package
> +(name "libconfuse")
> +(version "2.7")
> +(source (origin
> +  (method url-fetch)
> +  (uri (string-append 
> "http://savannah.nongnu.org/download/confuse/";
> +  "confuse-" version ".tar.gz"))
> +  (sha256
> +   (base32
> +
> "0y47r2ashz44wvnxdb18ivpmj8nxhw3y9bf7v9w0g5byhgyp89g3"
> +(build-system gnu-build-system)
> +(home-page "http://www.nongnu.org/confuse/";)
> +(synopsis "Configuration file parser library")
> +(description "A configuration file parser library. It supports

"libconfuse is a configuration..."

Also, two spaces at the end of sentences.  'guix lint libconfuse'
should warn about this.

> +sections and (lists of) values (strings, integers, floats, booleans
> or +other sections), as well as some other features (such as
> +single/double-quoted strings, environment variable expansion,
> +functions and nested include statements).  It makes it very easy to
> +add configuration file capability to a program using a simple API. ")

"very easy" and "simple" seem too much like advertising.  Perhaps the
last sentence could be left out to keep the description more neutral.
WDYT?

Otherwise LGTM.

`~Eric




Re: [PATCH 5/7] gnu: Add i3-wm.

2015-08-16 Thread Eric Bavier
On Mon, 17 Aug 2015 05:05:35 +0200
Eric Dvorsak  wrote:

> * gnu/packages/i3.scm: New file.
> * gnu-system.am (GNU_SYSTEM_MODULES): Add it.
[...]
> +(define-public i3-wm
> +  (package
> +(name "i3-wm")
> +(version "4.10.3")
[...]
> +(description "i3 is a tiling window manager, completely written
> +from scratch.  The target platforms are GNU/Linux and BSD operating
> +systems, our code is Free and Open Source Software (FOSS) under the
> +BSD license.  i3 is primarily targeted at advanced users and
> +developers.")

You may remove the second sentence completely.  All programs in Guix
are free software.

`~Eric




Re: [PATCH 4/7] gnu: Add xcb-util-cursor.

2015-08-16 Thread Eric Bavier
On Mon, 17 Aug 2015 05:05:34 +0200
Eric Dvorsak  wrote:

> * gnu/packages/xorg.scm (xcb-util-cursor): New variable.
> ---
[...]
> +(license
> + (license:non-copyleft
> +  "file://COPYING"
> +  "See COPYING in the distribution."

Perhaps we should add a comment noting that the license is basically
the expat license with an added clause regarding advertising?  What do
others think?

`~Eric




Re: [PATCH 3/7] gnu: Add libev

2015-08-16 Thread Eric Bavier
On Mon, 17 Aug 2015 04:05:58 +0200
Eric Dvorsak  wrote:

> * gnu/packages/libevent.scm (libev): New variable.
> ---
>  gnu/packages/libevent.scm | 26 ++
>  1 file changed, 26 insertions(+)
> 
> diff --git a/gnu/packages/libevent.scm b/gnu/packages/libevent.scm
> index 88b13ec..efd8df0 100644
> --- a/gnu/packages/libevent.scm
> +++ b/gnu/packages/libevent.scm
> @@ -1,6 +1,7 @@
>  ;;; GNU Guix --- Functional package management for GNU
>  ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès 
>  ;;; Copyright © 2015 Mark H Weaver 
> +;;; Copyright © 2015 Eric Dvorsak 
>  ;;;
>  ;;; This file is part of GNU Guix.
>  ;;;
> @@ -61,6 +62,31 @@ then add or remove events dynamically without
> having to change the event loop.")
>  (license bsd-3)))
>  
> +(define-public libev
> +  (package
> +(name "libev")
[...]
> +(license
> + (non-copyleft
> +  "file://LICENSE"
> +  "See LICENSE in the distribution."

From what I can tell looking at the license, this should be "(list
bsd-2 gpl2+)" as it states: "If you do not delete the provisions above,
a recipient may use your version of this file under either the BSD or
the GPL."

`~Eric



Re: [PATCH 2/7] gnu: Add libyajl.

2015-08-16 Thread Eric Bavier
On Mon, 17 Aug 2015 04:05:57 +0200
Eric Dvorsak  wrote:

> * gnu/packages/web.scm (libyajl): New variable.
> ---
>  gnu/packages/web.scm | 19 +++
>  1 file changed, 19 insertions(+)
> 
> diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
> index 48bfbc7..07054c2 100644
> --- a/gnu/packages/web.scm
> +++ b/gnu/packages/web.scm
> @@ -6,6 +6,7 @@
>  ;;; Copyright © 2015 Ricardo Wurmus 
>  ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer
>  ;;; Copyright © 2015 Eric Bavier
>  +;;; Copyright © 2015 Eric Dvorsak
>  ;;;
>  ;;; This file is part of GNU Guix.
>  ;;;
> @@ -287,6 +288,24 @@ parse JSON formatted strings back into the C
> representation of JSON objects.") style API.")
>  (license l:expat)))
>  
> +(define-public libyajl
> +  (package
> +(name "libyajl")
> +(version "2.1.0")
> +(source (origin
> +  (method url-fetch)
> +  (uri (string-append "https://github.com/lloyd/yajl/archive/"; 
> version ".tar.gz"))

Wrap this line to 80 characters.

It would also be nice to provide a "file-name" field so that the tarball
is put in the store with a meaningful name, rather than just
"2.1.0.tar.gz".  E.g.:

  (file-name (string-append name "-" version ".tar.gz"))

See the aardict package for an example.

> +  (sha256
> +   (base32
> +
> "0nmcqpaiq4pv7dymyg3n3jsd57yhp5npxl26a1hzw3m3lmj37drz"
> +(build-system cmake-build-system)
> +(home-page "https://lloyd.github.io/yajl/";)
> +(synopsis "C library for parsing JSON")
> +(description "Yet Another JSON Library.  YAJL is a small
> +event-driven (SAX-style) JSON parser written in ANSI C, and a small
> +validating JSON generator.")
> +(license isc)))
> +
>  (define-public libwebsockets
>(package
>  (name "libwebsockets")

Otherwise looks good to me.

Thanks,
`~Eric



Re: [PATCH 1/7] gnu: Add Pod-Simple.

2015-08-16 Thread Eric Bavier
On Mon, 17 Aug 2015 04:05:56 +0200
Eric Dvorsak  wrote:

> * gnu/packages/perl.scm (perl-pod-simple): New variable.
> ---
>  gnu/packages/perl.scm | 21 +
>  1 file changed, 21 insertions(+)
> 
> diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm
> index d2e38cc..7318542 100644
> --- a/gnu/packages/perl.scm
> +++ b/gnu/packages/perl.scm
> @@ -3,6 +3,7 @@
>  ;;; Copyright © 2013 Andreas Enge 
>  ;;; Copyright © 2015 Ricardo Wurmus 
>  ;;; Copyright © 2015 Eric Bavier 
> +;;; Copyright © 2015 Eric Dvorsak 
>  ;;;
>  ;;; This file is part of GNU Guix.
>  ;;;
> @@ -3941,6 +3942,26 @@ directory specifications in a cross-platform
> manner.") for a given module is comprehensive.")
>  (license (package-license perl
>  
> +(define-public perl-pod-simple
> +  (package
> +(name "perl-pod-simple")
> +(version "3.30_1")

I think we should avoid using dev releases if we can.  Is there
anything preventing the use of the "3.30" release?

> +(source (origin
> +  (method url-fetch)
> +  (uri (string-append "http://search.cpan.org/CPAN/authors/id/M/";

Please use the "cpan" mirror: "mirror://cpan/authors/id/..."

> +  "MA/MARCGREEN/Pod-Simple-" version
> +  ".tar.gz"))
> +  (sha256
> +   (base32
> +
> "0yzy7mw2jriwcywmh38csjqrwxj207b2b7rlpvkdh1rq5828hary"
> +(build-system perl-build-system)
> +(home-page
> "http://search.cpan.org/~marcgreen/Pod-Simple/lib/Pod/Simple.pod";)

Could you use the "http://search.cpan.org/dist/Pod-Simple"; url
instead?  It prevents us from needing to update the home-page url if
ownership is ever transferred.

> +(synopsis "Parsing library for text in Pod format")
> +(description "Pod::Simple is a Perl library for parsing text in
> +the Pod (plain old documentation) markup language that is typically
> +used for writing documentation for Perl and for Perl modules.")
> +(license (package-license perl
> +
>  (define-public perl-posix-strftime-compiler
>(package
>  (name "perl-posix-strftime-compiler")

Thanks,
`~Eric



Re: [PATCH 2/2] gnu: Add American fuzzy lop.

2015-08-16 Thread Eric Bavier
On Sun, 16 Aug 2015 19:22:51 -0400
Mark H Weaver  wrote:

> ericbav...@openmailbox.org writes:
> 
> > From: Eric Bavier 
> >
> > * gnu/packages/debug.scm (american-fuzzy-lop): New variable.
> > ---
> >  gnu/packages/debug.scm | 96
> > +- 1 file changed,
> > 95 insertions(+), 1 deletion(-)
> >
> > diff --git a/gnu/packages/debug.scm b/gnu/packages/debug.scm
> > index ba80711..dba3091 100644
> > --- a/gnu/packages/debug.scm
> > +++ b/gnu/packages/debug.scm
> > @@ -27,7 +27,10 @@
> >#:use-module (gnu packages indent)
> >#:use-module (gnu packages llvm)
> >#:use-module (gnu packages perl)
> > -  #:use-module (gnu packages pretty-print))
> > +  #:use-module (gnu packages pretty-print)
> > +  #:use-module (gnu packages qemu)
> > +  #:use-module (ice-9 match)
> > +  #:use-module (srfi srfi-1))
> >  
> >  (define-public delta
> >(package
> > @@ -137,3 +140,94 @@ produces a much smaller C/C++ program that has
> > the same property.  It is intended for use by people who discover
> > and report bugs in compilers and other tools that process C/C++
> > code.") (license ncsa)))
> > +
> > +(define-public american-fuzzy-lop
> > +  (let ((machine (match (or (%current-target-system)
> > +(%current-system))
> > +   ("x86_64-linux"   "x86_64")
> > +   ("i686-linux" "i386")
> > +   ;; Prevent errors when querying this package on
> > unsupported
> > +   ;; platforms, e.g. when running "guix package
> > --search="
> > +   (_"UNSUPPORTED"
> > +(package
> > +  (name "american-fuzzy-lop")
> > +  (version "1.86b") ;It seems all releases have
> > the 'b' suffix
> > +  (source
> > +   (origin
> > + (method url-fetch)
> > + (uri (string-append
> > "http://lcamtuf.coredump.cx/afl/releases/";
> > + "afl-" version ".tgz"))
> > + (sha256
> > +  (base32
> > +
> > "1by9ncf6lgcyibzqwyla34jv64sd66mn8zhgjz2pcgsds51qwn0r"
> > +  (build-system gnu-build-system)
> > +  (inputs
> > +   `(("custom-qemu"
> > +  ;; The afl-qemu tool builds qemu 2.3.0 with a few
> > patches applied.
> > +  ,(package (inherit qemu-headless)
> > + (name "afl-qemu")
> > + (inputs
> > +  `(("afl-src" ,source)
> > +,@(package-inputs qemu-headless)))
> > + ;; afl only supports using a single afl-qemu-trace
> > executable, so
> > + ;; we only build qemu for the native target.
> > + (arguments
> > +  `(#:configure-flags
> > +(list (string-append "--target-list=" ,machine
> > "-linux-user"))
> > +,@(substitute-keyword-arguments (package-arguments
> > qemu-headless)
> > +((#:phases qemu-phases)
> > + `(modify-phases ,qemu-phases
> > +(add-after
> > + 'unpack 'apply-afl-patches
> > + (lambda* (#:key inputs #:allow-other-keys)
> > +   (let* ((afl-dir (string-append
> > "afl-" ,version))
> > +  (patch-dir
> > +   (string-append afl-dir
> > +
> > "/qemu_mode/patches")))
> > + (system* "tar" "xf" (assoc-ref inputs
> > "afl-src"))
> 
> Please check for an error here, with something like:
> 
>   (unless (zero? (system* ...))
> (error "tar failed to unpack afl-src"))
> 
> > + (copy-file (string-append patch-dir
> > +
> > "/afl-qemu-cpu-inl.h")
> > +"./afl-qemu-cpu-inl.h")
> > + (copy-file (string-append afl-dir
> > "/config.h")
> > +"./afl-config.h")
> > + (copy-file (string-append afl-dir
> > "/types.h")
> > +"./types.h")
> > + (substitute* "afl-qemu-cpu-inl.h"
> > +   (("\\.\\./\\.\\./config.h")
> > "afl-config.h"))
> > + (substitute* (string-append patch-dir
> > +
> > "/cpu-exec.diff")
> > +   (("\\.\\./patches/") ""))
> > + (for-each (lambda (patch-file)
> > + (system* "patch"
> > "--force" "-p1"
> > +  "--input"
> > patch-file))
> 
> Likewise, if these patches fail to apply, the failures will be
> ignored. Please change 'for-each' to 'every', and wrap (zero? ...)
> around the 'system*' call.
> 
> > +   (find-files patch-dir
> > +
> > ".*\\.diff"))
> 
> "\\.diff$"
> 
> > +  (arguments
> > +   `(#:make-flags (list (string-append "PREF

[PATCHES] Add i3

2015-08-16 Thread Eric Dvorsak
Hello,

Here is a set of patches that add the wonderfull tiling window manager
that is i3.

I am sorry for this second wave, it fixes things that broke after moving
the dependencies into the files that better suite their purpose. I also
made some formatting correction after Mark review on IRC.

Eric.



[PATCH 6/7] gnu: Add libconfuse.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/i3.scm (libconfuse): New variable.
---
 gnu/packages/i3.scm | 22 ++
 1 file changed, 22 insertions(+)

diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
index bcb4888..725fdb6 100644
--- a/gnu/packages/i3.scm
+++ b/gnu/packages/i3.scm
@@ -39,6 +39,28 @@
   #:use-module (guix download)
   #:use-module (guix git-download))
 
+(define-public libconfuse
+  (package
+(name "libconfuse")
+(version "2.7")
+(source (origin
+  (method url-fetch)
+  (uri (string-append 
"http://savannah.nongnu.org/download/confuse/";
+  "confuse-" version ".tar.gz"))
+  (sha256
+   (base32
+"0y47r2ashz44wvnxdb18ivpmj8nxhw3y9bf7v9w0g5byhgyp89g3"
+(build-system gnu-build-system)
+(home-page "http://www.nongnu.org/confuse/";)
+(synopsis "Configuration file parser library")
+(description "A configuration file parser library. It supports
+sections and (lists of) values (strings, integers, floats, booleans or
+other sections), as well as some other features (such as
+single/double-quoted strings, environment variable expansion,
+functions and nested include statements).  It makes it very easy to
+add configuration file capability to a program using a simple API. ")
+(license isc)))
+
 (define-public i3-wm
   (package
 (name "i3-wm")
-- 
2.4.3




[PATCH 7/7] gnu: Add i3status.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/i3.scm (i3status): New variable.
---
 gnu/packages/i3.scm | 38 ++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
index 725fdb6..a9a5640 100644
--- a/gnu/packages/i3.scm
+++ b/gnu/packages/i3.scm
@@ -61,6 +61,44 @@ functions and nested include statements).  It makes it very 
easy to
 add configuration file capability to a program using a simple API. ")
 (license isc)))
 
+(define-public i3status
+  (package
+(name "i3status")
+(version "2.9")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://i3wm.org/i3status/i3status-";
+  version ".tar.bz2"))
+  (sha256
+   (base32
+"1qwxbrga2fi5wf742hh9ajwa8b2kpzkjjnhjlz4wlpv21i80kss2"
+(build-system gnu-build-system)
+(arguments
+ `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure))
+   #:tests? #f)) ; no test suite
+(inputs
+ `(("openlibm" ,openlibm)
+   ("libconfuse" ,libconfuse)
+   ("libyajl" ,libyajl)
+   ("alsa-lib" ,alsa-lib)
+   ("wireless-tools" ,wireless-tools)
+   ("libcap" ,libcap)
+   ("asciidoc" ,asciidoc)))
+(home-page "http://i3wm.org/i3status/";)
+(synopsis "Generating a status bar for i3bar, dzen2, xmobar or
+similar programs")
+(description "i3status is a small program for generating a status
+bar for i3bar, dzen2, xmobar or similar programs.  It is designed to
+be very efficient by issuing a very small number of system calls, as
+one generally wants to update such a status line every second. This
+ensures that even under high load, your status bar is updated
+correctly.  Also, it saves a bit of energy by not hogging your CPU as
+much as spawning the corresponding amount of shell commands would.")
+(license bsd-3)))
+
 (define-public i3-wm
   (package
 (name "i3-wm")
-- 
2.4.3




[PATCH 3/7] gnu: Add libev

2015-08-16 Thread Eric Dvorsak
* gnu/packages/libevent.scm (libev): New variable.
---
 gnu/packages/libevent.scm | 26 ++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/libevent.scm b/gnu/packages/libevent.scm
index 88b13ec..efd8df0 100644
--- a/gnu/packages/libevent.scm
+++ b/gnu/packages/libevent.scm
@@ -1,6 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès 
 ;;; Copyright © 2015 Mark H Weaver 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -61,6 +62,31 @@ then add or remove events dynamically without having to 
change the event
 loop.")
 (license bsd-3)))
 
+(define-public libev
+  (package
+(name "libev")
+(version "4.20")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://dist.schmorp.de/libev/libev-";
+  version
+  ".tar.gz"))
+  (sha256
+   (base32
+"17j47pbkr65a18mfvy2861p5k7w4pxmdgiw723ryfqd9gx636w7q"
+(build-system gnu-build-system)
+(home-page "http://software.schmorp.de/pkg/libev.html";)
+(synopsis "An event loop that is loosely modelled after libevent")
+(description "A full-featured and high-performance event loop that
+is loosely modelled after libevent, but without its limitations and
+bugs.  It is used in GNU Virtual Private Ethernet, rxvt-unicode,
+auditd, the Deliantra MORPG Server and Client, and many other
+programs.")
+(license
+ (non-copyleft
+  "file://LICENSE"
+  "See LICENSE in the distribution."
+
 (define-public libuv
   (package
 (name "libuv")
-- 
2.4.3




[PATCH 5/7] gnu: Add i3-wm.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/i3.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
---
 gnu-system.am   |  1 +
 gnu/packages/i3.scm | 89 +
 2 files changed, 90 insertions(+)
 create mode 100644 gnu/packages/i3.scm

diff --git a/gnu-system.am b/gnu-system.am
index 9f46f7b..9686a7e 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -149,6 +149,7 @@ GNU_SYSTEM_MODULES =\
   gnu/packages/haskell.scm \
   gnu/packages/hugs.scm\
   gnu/packages/hurd.scm\
+  gnu/packages/i3.scm  \
   gnu/packages/ibus.scm\
   gnu/packages/icu4c.scm   \
   gnu/packages/idutils.scm \
diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
new file mode 100644
index 000..bcb4888
--- /dev/null
+++ b/gnu/packages/i3.scm
@@ -0,0 +1,89 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2015 Eric Dvorsak 
+;;;
+;;; 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 i3)
+  #:use-module (guix licenses)
+  #:use-module (guix packages)
+  #:use-module (gnu packages linux)
+  #:use-module (guix build-system gnu)
+  #:use-module (gnu packages base)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages perl)
+  #:use-module (gnu packages xorg)
+  #:use-module (gnu packages xdisorg)
+  #:use-module (gnu packages qt)
+  #:use-module (gnu packages asciidoc)
+  #:use-module (gnu packages xml)
+  #:use-module (gnu packages m4)
+  #:use-module (gnu packages docbook)
+  #:use-module (gnu packages pcre)
+  #:use-module (gnu packages gtk)
+  #:use-module (gnu packages libevent)
+  #:use-module (gnu packages maths)
+  #:use-module (gnu packages web)
+  #:use-module (guix download)
+  #:use-module (guix git-download))
+
+(define-public i3-wm
+  (package
+(name "i3-wm")
+(version "4.10.3")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://i3wm.org/downloads/i3-";
+  version ".tar.bz2"))
+  (sha256
+   (base32
+"1lq7h4w7m0hi31iva8g7yf1sc11ispnknxjdaj9agld4smxqb44j"
+(build-system gnu-build-system)
+(arguments
+ `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure))
+   #:tests? #f)) ; no test suite
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util" ,xcb-util)
+   ("xcb-util-cursor" ,xcb-util-cursor)
+   ("xcb-util-keysyms" ,xcb-util-keysyms)
+   ("xcb-util-wm" ,xcb-util-wm)
+   ("libxkbcommon" ,libxkbcommon)
+   ("libev" ,libev)
+   ("libyajl" ,libyajl)
+   ("asciidoc" ,asciidoc)
+   ("xmlto" ,xmlto)
+   ("perl-pod-simple" ,perl-pod-simple)
+   ("docbook-xml" ,docbook-xml)
+   ("libx11" ,libx11)
+   ("pcre" ,pcre)
+   ("startup-notification" ,startup-notification)
+   ("pango" ,pango)
+   ("cairo" ,cairo)))
+(native-inputs
+ `(("which" ,which)
+   ("perl" ,perl)
+   ("pkg-config" ,pkg-config)))
+(home-page "http://i3wm.org/";)
+(synopsis "Improved tiling window manager")
+(description "i3 is a tiling window manager, completely written
+from scratch.  The target platforms are GNU/Linux and BSD operating
+systems, our code is Free and Open Source Software (FOSS) under the
+BSD license.  i3 is primarily targeted at advanced users and
+developers.")
+(license bsd-3)))
-- 
2.4.3




[PATCH 4/7] gnu: Add xcb-util-cursor.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/xorg.scm (xcb-util-cursor): New variable.
---
 gnu/packages/xorg.scm | 29 +
 1 file changed, 29 insertions(+)

diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm
index a9ecc1e..dc90918 100644
--- a/gnu/packages/xorg.scm
+++ b/gnu/packages/xorg.scm
@@ -3,6 +3,7 @@
 ;;; Copyright © 2014, 2015 Mark H Weaver 
 ;;; Copyright © 2014 Eric Bavier 
 ;;; Copyright © 2015 Ludovic Courtès 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -2033,6 +2034,34 @@ legacy X clients.")
 (license license:x11)))
 
 
+(define-public xcb-util-cursor
+  (package
+(name "xcb-util-cursor")
+(version "0.1.2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://xcb.freedesktop.org/dist/";
+  "xcb-util-cursor-" version ".tar.gz"))
+  (sha256
+   (base32
+"0bm0mp99abdfb6v4v60hq3msvk67b2x9ml3kbx5y2g18xdhm3rdr"
+(build-system gnu-build-system)
+(native-inputs
+ `(("m4" ,m4)
+   ("pkg-config" ,pkg-config)))
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util-renderutil" ,xcb-util-renderutil)
+   ("xcb-util-image" ,xcb-util-image)))
+(home-page "http://cgit.freedesktop.org/xcb/util-cursor/";)
+(synopsis "Port of libxcursor")
+(description "Port of libxcursor.")
+(license
+ (license:non-copyleft
+  "file://COPYING"
+  "See COPYING in the distribution."
+
+
 (define-public xcb-proto
   (package
 (name "xcb-proto")
-- 
2.4.3




[PATCH 2/7] gnu: Add libyajl.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/web.scm (libyajl): New variable.
---
 gnu/packages/web.scm | 20 
 1 file changed, 20 insertions(+)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 48bfbc7..c1c461a 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -6,6 +6,7 @@
 ;;; Copyright © 2015 Ricardo Wurmus 
 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer 
 ;;; Copyright © 2015 Eric Bavier 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -287,6 +288,25 @@ parse JSON formatted strings back into the C 
representation of JSON objects.")
 style API.")
 (license l:expat)))
 
+(define-public libyajl
+  (package
+(name "libyajl")
+(version "2.1.0")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "https://github.com/lloyd/yajl/";
+  "archive/" version ".tar.gz"))
+  (sha256
+   (base32
+"0nmcqpaiq4pv7dymyg3n3jsd57yhp5npxl26a1hzw3m3lmj37drz"
+(build-system cmake-build-system)
+(home-page "https://lloyd.github.io/yajl/";)
+(synopsis "C library for parsing JSON")
+(description "Yet Another JSON Library.  YAJL is a small
+event-driven (SAX-style) JSON parser written in ANSI C, and a small
+validating JSON generator.")
+(license l:isc)))
+
 (define-public libwebsockets
   (package
 (name "libwebsockets")
-- 
2.4.3




[PATCH 1/7] gnu: Add Pod-Simple.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/perl.scm (perl-pod-simple): New variable.
---
 gnu/packages/perl.scm | 23 +++
 1 file changed, 23 insertions(+)

diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm
index d2e38cc..2e7df22 100644
--- a/gnu/packages/perl.scm
+++ b/gnu/packages/perl.scm
@@ -3,6 +3,7 @@
 ;;; Copyright © 2013 Andreas Enge 
 ;;; Copyright © 2015 Ricardo Wurmus 
 ;;; Copyright © 2015 Eric Bavier 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -3941,6 +3942,28 @@ directory specifications in a cross-platform manner.")
 for a given module is comprehensive.")
 (license (package-license perl
 
+(define-public perl-pod-simple
+  (package
+(name "perl-pod-simple")
+(version "3.30-1")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://search.cpan.org/CPAN/authors/id/M/";
+  "MA/MARCGREEN/Pod-Simple-"
+  (string-join (string-split version #\-) "_")
+  ".tar.gz"))
+  (sha256
+   (base32
+"0yzy7mw2jriwcywmh38csjqrwxj207b2b7rlpvkdh1rq5828hary"
+(build-system perl-build-system)
+(home-page
+ "http://search.cpan.org/~marcgreen/Pod-Simple/lib/Pod/Simple.pod";)
+(synopsis "Parsing library for text in Pod format")
+(description "Pod::Simple is a Perl library for parsing text in
+the Pod (plain old documentation) markup language that is typically
+used for writing documentation for Perl and for Perl modules.")
+(license (package-license perl
+
 (define-public perl-posix-strftime-compiler
   (package
 (name "perl-posix-strftime-compiler")
-- 
2.4.3




[PATCH 5/7] gnu: Add i3-wm.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/i3.scm: New file.
* gnu-system.am (GNU_SYSTEM_MODULES): Add it.
---
 gnu-system.am   |  1 +
 gnu/packages/i3.scm | 88 +
 2 files changed, 89 insertions(+)
 create mode 100644 gnu/packages/i3.scm

diff --git a/gnu-system.am b/gnu-system.am
index 9f46f7b..9686a7e 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -149,6 +149,7 @@ GNU_SYSTEM_MODULES =\
   gnu/packages/haskell.scm \
   gnu/packages/hugs.scm\
   gnu/packages/hurd.scm\
+  gnu/packages/i3.scm  \
   gnu/packages/ibus.scm\
   gnu/packages/icu4c.scm   \
   gnu/packages/idutils.scm \
diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
new file mode 100644
index 000..d324a10
--- /dev/null
+++ b/gnu/packages/i3.scm
@@ -0,0 +1,88 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2015 Eric Dvorsak 
+;;;
+;;; 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 i3)
+  #:use-module (guix licenses)
+  #:use-module (guix packages)
+  #:use-module (gnu packages linux)
+  #:use-module (guix build-system gnu)
+  #:use-module (gnu packages base)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages perl)
+  #:use-module (gnu packages xorg)
+  #:use-module (gnu packages xdisorg)
+  #:use-module (gnu packages qt)
+  #:use-module (gnu packages asciidoc)
+  #:use-module (gnu packages xml)
+  #:use-module (gnu packages m4)
+  #:use-module (gnu packages docbook)
+  #:use-module (gnu packages pcre)
+  #:use-module (gnu packages gtk)
+  #:use-module (gnu packages maths)
+  #:use-module (gnu packages web)
+  #:use-module (guix download)
+  #:use-module (guix git-download))
+
+(define-public i3-wm
+  (package
+(name "i3-wm")
+(version "4.10.3")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://i3wm.org/downloads/i3-";
+  version ".tar.bz2"))
+  (sha256
+   (base32
+"1lq7h4w7m0hi31iva8g7yf1sc11ispnknxjdaj9agld4smxqb44j"
+(build-system gnu-build-system)
+(arguments
+ `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure)
+ (delete 'check
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util" ,xcb-util)
+   ("xcb-util-cursor" ,xcb-util-cursor)
+   ("xcb-util-keysyms" ,xcb-util-keysyms)
+   ("xcb-util-wm" ,xcb-util-wm)
+   ("libxkbcommon" ,libxkbcommon)
+   ("libev" ,libev)
+   ("libyajl" ,libyajl)
+   ("asciidoc" ,asciidoc)
+   ("xmlto" ,xmlto)
+   ("perl-pod-simple" ,perl-pod-simple)
+   ("docbook-xml" ,docbook-xml)
+   ("libx11" ,libx11)
+   ("pcre" ,pcre)
+   ("startup-notification" ,startup-notification)
+   ("pango" ,pango)
+   ("cairo" ,cairo)))
+(native-inputs
+ `(("which" ,which)
+   ("perl" ,perl)
+   ("pkg-config" ,pkg-config)))
+(home-page "http://i3wm.org/";)
+(synopsis "Improved tiling window manager")
+(description "i3 is a tiling window manager, completely written
+from scratch.  The target platforms are GNU/Linux and BSD operating
+systems, our code is Free and Open Source Software (FOSS) under the
+BSD license.  i3 is primarily targeted at advanced users and
+developers.")
+(license bsd-3)))
-- 
2.4.3




[PATCH 1/7] gnu: Add Pod-Simple.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/perl.scm (perl-pod-simple): New variable.
---
 gnu/packages/perl.scm | 21 +
 1 file changed, 21 insertions(+)

diff --git a/gnu/packages/perl.scm b/gnu/packages/perl.scm
index d2e38cc..7318542 100644
--- a/gnu/packages/perl.scm
+++ b/gnu/packages/perl.scm
@@ -3,6 +3,7 @@
 ;;; Copyright © 2013 Andreas Enge 
 ;;; Copyright © 2015 Ricardo Wurmus 
 ;;; Copyright © 2015 Eric Bavier 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -3941,6 +3942,26 @@ directory specifications in a cross-platform manner.")
 for a given module is comprehensive.")
 (license (package-license perl
 
+(define-public perl-pod-simple
+  (package
+(name "perl-pod-simple")
+(version "3.30_1")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://search.cpan.org/CPAN/authors/id/M/";
+  "MA/MARCGREEN/Pod-Simple-" version
+  ".tar.gz"))
+  (sha256
+   (base32
+"0yzy7mw2jriwcywmh38csjqrwxj207b2b7rlpvkdh1rq5828hary"
+(build-system perl-build-system)
+(home-page 
"http://search.cpan.org/~marcgreen/Pod-Simple/lib/Pod/Simple.pod";)
+(synopsis "Parsing library for text in Pod format")
+(description "Pod::Simple is a Perl library for parsing text in
+the Pod (plain old documentation) markup language that is typically
+used for writing documentation for Perl and for Perl modules.")
+(license (package-license perl
+
 (define-public perl-posix-strftime-compiler
   (package
 (name "perl-posix-strftime-compiler")
-- 
2.4.3




[PATCH 4/7] gnu: Add xcb-util-cursor.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/xorg.scm (xcb-util-cursor): New variable.
---
 gnu/packages/xorg.scm | 28 
 1 file changed, 28 insertions(+)

diff --git a/gnu/packages/xorg.scm b/gnu/packages/xorg.scm
index a9ecc1e..00d7885 100644
--- a/gnu/packages/xorg.scm
+++ b/gnu/packages/xorg.scm
@@ -3,6 +3,7 @@
 ;;; Copyright © 2014, 2015 Mark H Weaver 
 ;;; Copyright © 2014 Eric Bavier 
 ;;; Copyright © 2015 Ludovic Courtès 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -2033,6 +2034,33 @@ legacy X clients.")
 (license license:x11)))
 
 
+(define-public xcb-util-cursor
+  (package
+(name "xcb-util-cursor")
+(version "0.1.2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append 
"http://xcb.freedesktop.org/dist/xcb-util-cursor-"; version ".tar.gz"))
+  (sha256
+   (base32
+"0bm0mp99abdfb6v4v60hq3msvk67b2x9ml3kbx5y2g18xdhm3rdr"
+(build-system gnu-build-system)
+(native-inputs
+ `(("m4" ,m4)
+   ("pkg-config" ,pkg-config)))
+(inputs
+ `(("libxcb" ,libxcb)
+   ("xcb-util-renderutil" ,xcb-util-renderutil)
+   ("xcb-util-image" ,xcb-util-image)))
+(home-page "http://cgit.freedesktop.org/xcb/util-cursor/";)
+(synopsis "Port of libxcursor")
+(description "Port of libxcursor.")
+(license
+ (non-copyleft
+  "file://COPYING"
+  "See COPYING in the distribution."
+
+
 (define-public xcb-proto
   (package
 (name "xcb-proto")
-- 
2.4.3




[PATCH 6/7] gnu: Add libconfuse.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/i3.scm (libconfuse): New variable.
---
 gnu/packages/i3.scm | 21 +
 1 file changed, 21 insertions(+)

diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
index d324a10..8895a28 100644
--- a/gnu/packages/i3.scm
+++ b/gnu/packages/i3.scm
@@ -38,6 +38,27 @@
   #:use-module (guix download)
   #:use-module (guix git-download))
 
+(define-public libconfuse
+  (package
+(name "libconfuse")
+(version "2.7")
+(source (origin
+  (method url-fetch)
+  (uri (string-append 
"http://savannah.nongnu.org/download/confuse/";
+  "confuse-" version ".tar.gz"))
+  (sha256
+   (base32 
"0y47r2ashz44wvnxdb18ivpmj8nxhw3y9bf7v9w0g5byhgyp89g3"
+(build-system gnu-build-system)
+(home-page "http://www.nongnu.org/confuse/";)
+(synopsis "Configuration file parser library")
+(description "A configuration file parser library. It supports
+sections and (lists of) values (strings, integers, floats, booleans or
+other sections), as well as some other features (such as
+single/double-quoted strings, environment variable expansion,
+functions and nested include statements).  It makes it very easy to
+add configuration file capability to a program using a simple API. ")
+(license isc)))
+
 (define-public i3-wm
   (package
 (name "i3-wm")
-- 
2.4.3




[PATCH 7/7] gnu: Add i3status.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/i3.scm (i3status): New variable.
---
 gnu/packages/i3.scm | 38 ++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/i3.scm b/gnu/packages/i3.scm
index 8895a28..23755fa 100644
--- a/gnu/packages/i3.scm
+++ b/gnu/packages/i3.scm
@@ -59,6 +59,44 @@ functions and nested include statements).  It makes it very 
easy to
 add configuration file capability to a program using a simple API. ")
 (license isc)))
 
+(define-public i3status
+  (package
+(name "i3status")
+(version "2.9")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://i3wm.org/i3status/i3status-";
+  version ".tar.bz2"))
+  (sha256
+   (base32
+"1qwxbrga2fi5wf742hh9ajwa8b2kpzkjjnhjlz4wlpv21i80kss2"
+(build-system gnu-build-system)
+(arguments
+ `(#:make-flags (list "CC=gcc" (string-append "PREFIX=" %output))
+   #:phases
+   (modify-phases %standard-phases
+ (delete 'configure)
+ (delete 'check
+(inputs
+ `(("openlibm" ,openlibm)
+   ("libconfuse" ,libconfuse)
+   ("libyajl" ,libyajl)
+   ("alsa-lib" ,alsa-lib)
+   ("wireless-tools" ,wireless-tools)
+   ("libcap" ,libcap)
+   ("asciidoc" ,asciidoc)))
+(home-page "http://i3wm.org/i3status/";)
+(synopsis "Generating a status bar for i3bar, dzen2, xmobar or
+similar programs")
+(description "i3status is a small program for generating a status
+bar for i3bar, dzen2, xmobar or similar programs.  It is designed to
+be very efficient by issuing a very small number of system calls, as
+one generally wants to update such a status line every second. This
+ensures that even under high load, your status bar is updated
+correctly.  Also, it saves a bit of energy by not hogging your CPU as
+much as spawning the corresponding amount of shell commands would.")
+(license bsd-3)))
+
 (define-public i3-wm
   (package
 (name "i3-wm")
-- 
2.4.3




[PATCH 2/7] gnu: Add libyajl.

2015-08-16 Thread Eric Dvorsak
* gnu/packages/web.scm (libyajl): New variable.
---
 gnu/packages/web.scm | 19 +++
 1 file changed, 19 insertions(+)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 48bfbc7..07054c2 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -6,6 +6,7 @@
 ;;; Copyright © 2015 Ricardo Wurmus 
 ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer 
 ;;; Copyright © 2015 Eric Bavier 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -287,6 +288,24 @@ parse JSON formatted strings back into the C 
representation of JSON objects.")
 style API.")
 (license l:expat)))
 
+(define-public libyajl
+  (package
+(name "libyajl")
+(version "2.1.0")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "https://github.com/lloyd/yajl/archive/"; 
version ".tar.gz"))
+  (sha256
+   (base32
+"0nmcqpaiq4pv7dymyg3n3jsd57yhp5npxl26a1hzw3m3lmj37drz"
+(build-system cmake-build-system)
+(home-page "https://lloyd.github.io/yajl/";)
+(synopsis "C library for parsing JSON")
+(description "Yet Another JSON Library.  YAJL is a small
+event-driven (SAX-style) JSON parser written in ANSI C, and a small
+validating JSON generator.")
+(license isc)))
+
 (define-public libwebsockets
   (package
 (name "libwebsockets")
-- 
2.4.3




[PATCH 3/7] gnu: Add libev

2015-08-16 Thread Eric Dvorsak
* gnu/packages/libevent.scm (libev): New variable.
---
 gnu/packages/libevent.scm | 26 ++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/libevent.scm b/gnu/packages/libevent.scm
index 88b13ec..efd8df0 100644
--- a/gnu/packages/libevent.scm
+++ b/gnu/packages/libevent.scm
@@ -1,6 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2013, 2014, 2015 Ludovic Courtès 
 ;;; Copyright © 2015 Mark H Weaver 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -61,6 +62,31 @@ then add or remove events dynamically without having to 
change the event
 loop.")
 (license bsd-3)))
 
+(define-public libev
+  (package
+(name "libev")
+(version "4.20")
+(source (origin
+  (method url-fetch)
+  (uri (string-append "http://dist.schmorp.de/libev/libev-";
+  version
+  ".tar.gz"))
+  (sha256
+   (base32
+"17j47pbkr65a18mfvy2861p5k7w4pxmdgiw723ryfqd9gx636w7q"
+(build-system gnu-build-system)
+(home-page "http://software.schmorp.de/pkg/libev.html";)
+(synopsis "An event loop that is loosely modelled after libevent")
+(description "A full-featured and high-performance event loop that
+is loosely modelled after libevent, but without its limitations and
+bugs.  It is used in GNU Virtual Private Ethernet, rxvt-unicode,
+auditd, the Deliantra MORPG Server and Client, and many other
+programs.")
+(license
+ (non-copyleft
+  "file://LICENSE"
+  "See LICENSE in the distribution."
+
 (define-public libuv
   (package
 (name "libuv")
-- 
2.4.3




[PATCHES] import: Add Ruby gem importer.

2015-08-16 Thread Thompson, David
Oops, I used the title of the first patch by accident.  The title of
the second patch is the important one!



[PATCH] gnu: Add ruby-arel.

2015-08-16 Thread David Thompson
Requires the new Ruby build system.

>From c6bdc405f2c1b79daa3058d73df966224f169293 Mon Sep 17 00:00:00 2001
From: David Thompson 
Date: Sun, 16 Aug 2015 21:58:12 -0400
Subject: [PATCH] gnu: Add ruby-arel.

* gnu/packages/ruby.scm (ruby-arel): New variable.
---
 gnu/packages/ruby.scm | 18 ++
 1 file changed, 18 insertions(+)

diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 196094c..e6f720c 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -610,3 +610,21 @@ options and parsing command line flags.")
 net/http library.")
 (home-page "https://github.com/nicksieger/multipart-post";)
 (license license:expat)))
+
+(define-public ruby-arel
+  (package
+(name "ruby-arel")
+(version "6.0.3")
+(source (origin
+  (method url-fetch)
+  (uri (rubygems-uri "arel" version))
+  (sha256
+   (base32
+"1a270mlajhrmpqbhxcqjqypnvgrq4pgixpv3w9gwp1wrrapnwrzk"
+(build-system ruby-build-system)
+(arguments '(#:tests? #f)) ; no tests
+(home-page "https://github.com/rails/arel";)
+(synopsis "SQL AST manager for Ruby")
+(description "Arel is a SQL AST manager for Ruby.  It simplifies the
+generation of complex SQL queries and is compatible with various RDBMSes.")
+(license license:expat)))
-- 
2.4.3


-- 
David Thompson
GPG Key: 0FF1D807


[PATCHES] import: pypi: Move generally useful procedures to utils module.

2015-08-16 Thread David Thompson
Building off of the new and improved Ruby build system, here are two
patches that add a handy RubyGems importer.

>From b60252c0c52f8ab4b096c00238acab9798ee64f4 Mon Sep 17 00:00:00 2001
From: David Thompson 
Date: Sun, 16 Aug 2015 21:09:19 -0400
Subject: [PATCH 1/2] import: pypi: Move generally useful procedures to utils
 module.

* guix/import/pypi.scm (make-pypi-sexp): Factorize license to symbol
  conversion code.
  (string->license, snake-case, guix-hash-url): Move from here...
* guix/import/utils.scm: ... to here.
  (license->symbol): New procedure.
---
 guix/import/pypi.scm  | 29 +
 guix/import/utils.scm | 43 ++-
 2 files changed, 43 insertions(+), 29 deletions(-)

diff --git a/guix/import/pypi.scm b/guix/import/pypi.scm
index 10d5bad..06d21fe 100644
--- a/guix/import/pypi.scm
+++ b/guix/import/pypi.scm
@@ -31,8 +31,6 @@
   #:use-module (guix utils)
   #:use-module (guix import utils)
   #:use-module (guix import json)
-  #:use-module (guix base32)
-  #:use-module (guix hash)
   #:use-module (guix packages)
   #:use-module (guix licenses)
   #:use-module (guix build-system python)
@@ -49,16 +47,6 @@ DELIMETER."
 ((elem . rest)
  (cons* elem delimiter (join rest delimiter)
 
-(define string->license
-  (match-lambda
-   ("GNU LGPL" lgpl2.0)
-   ("GPL" gpl3)
-   ((or "BSD" "BSD License") bsd-3)
-   ((or "MIT" "MIT license" "Expat license") expat)
-   ("Public domain" public-domain)
-   ("Apache License, Version 2.0" asl2.0)
-   (_ #f)))
-
 (define (pypi-fetch name)
   "Return an alist representation of the PyPI metadata for the package NAME,
 or #f on failure."
@@ -75,15 +63,6 @@ or #f on failure."
(assoc-ref* pypi-package "info" "name")
(assoc-ref* pypi-package "info" "version")
 
-(define (snake-case str)
-  "Return a downcased version of the string STR where underscores are replaced
-with dashes."
-  (string-join (string-split (string-downcase str) #\_) "-"))
-
-(define (guix-hash-url filename)
-  "Return the hash of FILENAME in nix-base32 format."
-  (bytevector->nix-base32-string  (file-sha256 filename)))
-
 (define (python->package-name name)
   "Given the NAME of a package on PyPI, return a Guix-compliant name for the
 package."
@@ -205,13 +184,7 @@ VERSION, SOURCE-URL, HOME-PAGE, SYNOPSIS, DESCRIPTION, and LICENSE."
  (home-page ,home-page)
  (synopsis ,synopsis)
  (description ,description)
- (license ,(assoc-ref `((,lgpl2.0 . lgpl2.0)
-(,gpl3 . gpl3)
-(,bsd-3 . bsd-3)
-(,expat . expat)
-(,public-domain . public-domain)
-(,asl2.0 . asl2.0))
-  license)))
+ (license ,(license->symbol license)))
 
 (define (pypi->guix-package package-name)
   "Fetch the metadata for PACKAGE-NAME from pypi.python.org, and return the
diff --git a/guix/import/utils.scm b/guix/import/utils.scm
index 969491d..0734fa1 100644
--- a/guix/import/utils.scm
+++ b/guix/import/utils.scm
@@ -21,6 +21,8 @@
   #:use-module (ice-9 regex)
   #:use-module (srfi srfi-1)
   #:use-module (guix hash)
+  #:use-module (guix base32)
+  #:use-module (guix licenses)
   #:use-module (guix utils)
   #:use-module ((guix build download) #:prefix build:)
   #:export (factorize-uri
@@ -29,7 +31,13 @@
 flatten
 assoc-ref*
 
-url-fetch))
+url-fetch
+guix-hash-url
+
+string->license
+license->symbol
+
+snake-case))
 
 (define (factorize-uri uri version)
   "Factorize URI, a package tarball URI as a string, such that any occurrences
@@ -95,3 +103,36 @@ recursively apply the procedure to the sub-list."
   "Save the contents of URL to FILE-NAME.  Return #f on failure."
   (parameterize ((current-output-port (current-error-port)))
 (build:url-fetch url file-name)))
+
+(define (guix-hash-url filename)
+  "Return the hash of FILENAME in nix-base32 format."
+  (bytevector->nix-base32-string (file-sha256 filename)))
+
+(define (string->license str)
+  "Convert the string STR into a license object."
+  (match str
+("GNU LGPL" lgpl2.0)
+("GPL" gpl3)
+((or "BSD" "BSD License") bsd-3)
+((or "MIT" "MIT license" "Expat license") expat)
+("Public domain" public-domain)
+((or "Apache License, Version 2.0" "Apache 2.0") asl2.0)
+(_ #f)))
+
+(define (license->symbol license)
+  "Convert license to a symbol representing the variable the object is bound
+to in the (guix licenses) module, or #f if there is no such known license."
+  ;; TODO: Traverse list public variables in (guix licenses) instead so we
+  ;; don't have to maintain a list manualy.
+  (assoc-ref `((,lgpl2.0 . lgpl2.0)
+   (,gpl3 . gpl3)
+   (,bsd-3 . bsd-3)
+  

Re: [PATCH 2/2] gnu: Add American fuzzy lop.

2015-08-16 Thread Mark H Weaver
ericbav...@openmailbox.org writes:

> From: Eric Bavier 
>
> * gnu/packages/debug.scm (american-fuzzy-lop): New variable.
> ---
>  gnu/packages/debug.scm | 96 
> +-
>  1 file changed, 95 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/debug.scm b/gnu/packages/debug.scm
> index ba80711..dba3091 100644
> --- a/gnu/packages/debug.scm
> +++ b/gnu/packages/debug.scm
> @@ -27,7 +27,10 @@
>#:use-module (gnu packages indent)
>#:use-module (gnu packages llvm)
>#:use-module (gnu packages perl)
> -  #:use-module (gnu packages pretty-print))
> +  #:use-module (gnu packages pretty-print)
> +  #:use-module (gnu packages qemu)
> +  #:use-module (ice-9 match)
> +  #:use-module (srfi srfi-1))
>  
>  (define-public delta
>(package
> @@ -137,3 +140,94 @@ produces a much smaller C/C++ program that has the same 
> property.  It is
>  intended for use by people who discover and report bugs in compilers and 
> other
>  tools that process C/C++ code.")
>  (license ncsa)))
> +
> +(define-public american-fuzzy-lop
> +  (let ((machine (match (or (%current-target-system)
> +(%current-system))
> +   ("x86_64-linux"   "x86_64")
> +   ("i686-linux" "i386")
> +   ;; Prevent errors when querying this package on 
> unsupported
> +   ;; platforms, e.g. when running "guix package --search="
> +   (_"UNSUPPORTED"
> +(package
> +  (name "american-fuzzy-lop")
> +  (version "1.86b") ;It seems all releases have the 'b' 
> suffix
> +  (source
> +   (origin
> + (method url-fetch)
> + (uri (string-append "http://lcamtuf.coredump.cx/afl/releases/";
> + "afl-" version ".tgz"))
> + (sha256
> +  (base32
> +   "1by9ncf6lgcyibzqwyla34jv64sd66mn8zhgjz2pcgsds51qwn0r"
> +  (build-system gnu-build-system)
> +  (inputs
> +   `(("custom-qemu"
> +  ;; The afl-qemu tool builds qemu 2.3.0 with a few patches applied.
> +  ,(package (inherit qemu-headless)
> + (name "afl-qemu")
> + (inputs
> +  `(("afl-src" ,source)
> +,@(package-inputs qemu-headless)))
> + ;; afl only supports using a single afl-qemu-trace executable, 
> so
> + ;; we only build qemu for the native target.
> + (arguments
> +  `(#:configure-flags
> +(list (string-append "--target-list=" ,machine 
> "-linux-user"))
> +,@(substitute-keyword-arguments (package-arguments 
> qemu-headless)
> +((#:phases qemu-phases)
> + `(modify-phases ,qemu-phases
> +(add-after
> + 'unpack 'apply-afl-patches
> + (lambda* (#:key inputs #:allow-other-keys)
> +   (let* ((afl-dir (string-append "afl-" ,version))
> +  (patch-dir
> +   (string-append afl-dir
> +  "/qemu_mode/patches")))
> + (system* "tar" "xf" (assoc-ref inputs 
> "afl-src"))

Please check for an error here, with something like:

  (unless (zero? (system* ...))
(error "tar failed to unpack afl-src"))

> + (copy-file (string-append patch-dir
> +   "/afl-qemu-cpu-inl.h")
> +"./afl-qemu-cpu-inl.h")
> + (copy-file (string-append afl-dir "/config.h")
> +"./afl-config.h")
> + (copy-file (string-append afl-dir "/types.h")
> +"./types.h")
> + (substitute* "afl-qemu-cpu-inl.h"
> +   (("\\.\\./\\.\\./config.h") "afl-config.h"))
> + (substitute* (string-append patch-dir
> + "/cpu-exec.diff")
> +   (("\\.\\./patches/") ""))
> + (for-each (lambda (patch-file)
> + (system* "patch" "--force" "-p1"
> +  "--input" patch-file))

Likewise, if these patches fail to apply, the failures will be ignored.
Please change 'for-each' to 'every', and wrap (zero? ...) around the
'system*' call.

> +   (find-files patch-dir
> +   ".*\\.diff"))

"\\.diff$"

> +  (arguments
> +   `(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs 
> "out"))
> +"CC=gcc")
> + #:phases (mod

[PATCH 1/2] gnu: Add font-ubuntu

2015-08-16 Thread Eric Dvorsak
* gnu/packages/fonts/scm (font-ubuntu): New variable.
---
 gnu/packages/fonts.scm | 53 ++
 1 file changed, 53 insertions(+)

diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm
index f72c542..f26a599 100644
--- a/gnu/packages/fonts.scm
+++ b/gnu/packages/fonts.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2014 Joshua Grant 
 ;;; Copyright © 2014 Alex Kost 
 ;;; Copyright © 2015 Sou Bunnbu 
+;;; Copyright © 2015 Eric Dvorsak 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -28,10 +29,62 @@
   #:use-module (guix build-system trivial)
   #:use-module (gnu packages base)
   #:use-module (gnu packages compression)
+  #:use-module (gnu packages zip)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages xorg)
   #:use-module (gnu packages pkg-config))
 
+(define-public font-ubuntu
+  (package
+(name "font-ubuntu")
+(version "0.80")
+(source (origin
+  (method url-fetch)
+  (uri (string-append 
"http://font.ubuntu.com/download/ubuntu-font-family-";
+  version ".zip"))
+  (sha256
+   (base32
+"0k4f548riq23gmw4zhn30qqkcpaj4g2ab5rbc3lflfxwkc4p0w8h"
+(build-system trivial-build-system)
+(arguments
+ `(#:modules ((guix build utils))
+   #:builder (begin
+   (use-modules (guix build utils)
+(srfi srfi-26))
+
+   (let ((PATH (string-append (assoc-ref %build-inputs
+ "unzip")
+  "/bin"))
+ (font-dir (string-append %output
+  "/share/fonts/truetype"))
+ (doc-dir  (string-append %output "/share/doc/"
+  ,name "-" ,version)))
+ (setenv "PATH" PATH)
+ (system* "unzip" (assoc-ref %build-inputs "source"))
+
+ (mkdir-p font-dir)
+ (mkdir-p doc-dir)
+ (chdir (string-append "ubuntu-font-family-" ,version))
+ (for-each (lambda (ttf)
+ (copy-file ttf
+(string-append font-dir "/" ttf)))
+   (find-files "." "\\.ttf$"))
+ (for-each (lambda (doc)
+ (copy-file doc
+(string-append doc-dir "/" doc)))
+   (find-files "." "\\.txt$"))
+(native-inputs `(("source" ,source)
+ ("unzip" ,unzip)))
+(home-page "http://font.ubuntu.com/";)
+(synopsis "The Ubuntu Font Family")
+(description "The Ubuntu Font Family is a unique, custom designed font
+that has a very distinctive look and feel.  This package provides the
+TrueType (TTF) files.")
+(license
+ (license:non-copyleft
+  "file://LICENCE.txt"
+  "See the LICENCE file in the distribution"
+
 (define-public font-dejavu
   (package
 (name "font-dejavu")
-- 
2.4.3




[PATCH 2/2] gnu: Add font-inconsolata

2015-08-16 Thread Eric Dvorsak
* gnu/packages/fonts.scm (font-inconsolata): New variable.
---
 gnu/packages/fonts.scm | 28 
 1 file changed, 28 insertions(+)

diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm
index f26a599..b0eac93 100644
--- a/gnu/packages/fonts.scm
+++ b/gnu/packages/fonts.scm
@@ -34,6 +34,34 @@
   #:use-module (gnu packages xorg)
   #:use-module (gnu packages pkg-config))
 
+(define-public font-incosolata
+  (package
+(name "font-inconsolata")
+(version "0.80")
+(source (origin
+  (method url-fetch)
+  (uri "http://www.levien.com/type/myfonts/Inconsolata.otf";)
+  (sha256
+   (base32
+"06js6znbcf7swn8y3b8ki416bz96ay7d3yvddqnvi88lqhbfcq8m"
+(build-system trivial-build-system)
+(arguments
+ `(#:modules ((guix build utils))
+   #:builder (begin
+   (use-modules (guix build utils))
+   (let ((font-dir (string-append %output
+  "/share/fonts/opentype"))
+ (source (assoc-ref %build-inputs "source")))
+ (mkdir-p font-dir)
+ (copy-file source
+(string-append font-dir "/" 
"inconsolata.otf"))
+(native-inputs `(("source" ,source)))
+(home-page "http://levien.com/type/myfonts/inconsolata.html";)
+(synopsis "Monospace font")
+(description "A monospace font, designed for code listings and the like,
+in print.  With attention to detail for high resolution rendering.")
+(license license:silofl1.1)))
+
 (define-public font-ubuntu
   (package
 (name "font-ubuntu")
-- 
2.4.3




Re: [PATCH] build: ruby: Rewrite build system to use gem archives.

2015-08-16 Thread Thompson, David
Update:

On Tue, Jul 28, 2015 at 9:09 AM, David Thompson
 wrote:

> One other caveat is that downloading gems from rubygems.org currently
> *does not* work because the HTTP responses include an invalid
> Content-Type header.  I added a temporary hack to do my development
> work (not in this patch), and I'm currently waiting on a response from
> the rubygems.org admins to see if they will fix the issue.  So, this
> patch should not be applied until this is resolved.
>
> See: 
> http://help.rubygems.org/discussions/problems/21223-invalid-content-type-header-when-downloading-gem-archive?unresolve=true

This issue has been fixed by the rubygems.org admins!  I would like to
apply the below patch ASAP and get to work on 'guix import gem' if
there are no objections.

The major change from the previous version of this patch is that I
figured how to unpack the source gem, allow the package build script
to make any necessary dynamic patches, and then install a repacked gem
as opposed to the source gem.

- Dave
From ee027442dd968734831eb372fcf502dcfaad7623 Mon Sep 17 00:00:00 2001
From: David Thompson 
Date: Sun, 26 Jul 2015 22:01:54 -0400
Subject: [PATCH] build: ruby: Rewrite build system to use gem archives.

Co-Authored-By: Pjotr Prins 

* guix/build-system/ruby.scm (lower): Remove git dependency.
  (rubygems-uri): New procedure.
* guix/build/ruby-build-system (gitify, build): Delete.
  (unpack): Use 'gem unpack' utility.
  (check): Add docstring.
  (install): Rebuild unpacked gem and install it.
  (%standard-phases): Remove gitify and build phases.
* gnu/packages/ruby.scm (ruby-hoe, ruby-rake-compiler, ruby-i18n,
  ruby-rspec-support, ruby-rspec-core, ruby-diff-lcs-for-rspec,
  ruby-rspec-expectations, ruby-rspec-mocks, ruby-rspec, bundler,
  ruby-useragent, ruby-bacon, ruby-arel, ruby-connection-pool,
  ruby-net-http-persistent, ruby-minitest, ruby-minitest-sprint,
  ruby-minitest-bacon, ruby-daemons, ruby-git, ruby-slop,
  ruby-multipart-post): Convert to new build system.
---
 gnu/packages/ruby.scm| 222 +++
 guix/build-system/ruby.scm   |  40 +++
 guix/build/ruby-build-system.scm |  60 +++
 3 files changed, 125 insertions(+), 197 deletions(-)

diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index a481365..196094c 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -154,13 +154,11 @@ a focus on simplicity and productivity.")
 (name "ruby-hoe")
 (version "3.13.1")
 (source (origin
-  (method git-fetch)
-  (uri (git-reference
-(url "https://github.com/seattlerb/hoe.git";)
-(commit "0c11836"))) ; no release tags :(
+  (method url-fetch)
+  (uri (rubygems-uri "hoe" version))
   (sha256
(base32
-"0i8dimf8kxcjgqj9x65bbi3l6hc9p9gbfbb1vmrz42764a4jjbz9"))) )
+"1mac13krdrasn9819dd65xj27kklfy0xdbj3p6s2ij4vlcb46h8q"))) )
 (build-system ruby-build-system)
 (synopsis "Ruby project management helper")
 (description
@@ -178,22 +176,13 @@ announcement.")
 (version "0.9.5")
 (source (origin
   (method url-fetch)
-  (uri (string-append
-"https://github.com/rake-compiler/rake-compiler/archive/v";
-version ".tar.gz"))
-  (file-name (string-append name "-" version ".tar.gz"))
+  (uri (rubygems-uri "rake-compiler" version))
   (sha256
(base32
-"07lk1vl0jqcaqwjjhmg0qshqwcxdyr5kscc9xxm13m03835xgpf3"
+"1k8im2vzj849xdgjk6wafspkiwwapqwm738majchb4dnhnsk64cx"
 (build-system ruby-build-system)
 (arguments
- '(#:tests? #f ; needs cucumber
-   #:phases (modify-phases %standard-phases
-  (add-before 'build 'remove-cucumber-rake-task
-(lambda _
-  ;; Remove cucumber test file because the
-  ;; dependencies are not available right now.
-  (delete-file "tasks/cucumber.rake"))
+ '(#:tests? #f)) ; needs cucumber
 (synopsis "Building and packaging helper for Ruby native extensions")
 (description "Rake-compiler provides a framework for building and
 packaging native C and Java extensions in Ruby.")
@@ -206,12 +195,10 @@ packaging native C and Java extensions in Ruby.")
 (version "0.6.11")
 (source (origin
   (method url-fetch)
-  (uri (string-append "https://github.com/svenfuchs/i18n/archive/v";
-  version ".tar.gz"))
-  (file-name (string-append name "-" version ".tar.gz"))
+  (uri (rubygems-uri "i18n" version))
   (sha256
(base32
-"1fdhnhh1p5g8vibv44d770z8nq208zrms3m2nswdvr54072y1m6k"
+"0fwjlgmgry2blf8zlxn9c555cf4a16p287l599kz5104ncjxlzdk"
 (build-s

Re: [PATCH] gnu: notmuch: Update to 0.20.2.

2015-08-16 Thread Thompson, David
On Sun, Aug 16, 2015 at 2:01 PM, Mark H Weaver  wrote:
> David Thompson  writes:
>
>> From 74d2db4f0ecbfc00473493e410a086f7c7c0bb10 Mon Sep 17 00:00:00 2001
>> From: David Thompson 
>> Date: Sat, 15 Aug 2015 22:23:59 -0400
>> Subject: [PATCH] gnu: notmuch: Update to 0.20.2.
>>
>> * gnu/packages/mail.scm (notmuch): Update to 0.20.2.  Add python-sphinx 
>> native
>>   input.  Rewrite phases using 'modify-phases' syntax.
>
> The commit log should probably mention that you enabled tests, but
> otherwise it looks good to me.

That was a typo, sorry.  I'm actually leaving the tests disabled.
Things are much improved since I first packaged notmuch, but there's
still annoying issues that I can't figure out.

Fixed and pushed.  Thanks.

- Dave



Re: [PATCH 1/2] gnu: qemu: Honor #:configure-flags argument.

2015-08-16 Thread Mark H Weaver
ericbav...@openmailbox.org writes:

> From: Eric Bavier 
>
> * gnu/packages/qemu.scm (qemu-headless)[arguments]: Honor #:configure-flags
>   arguments for configure phase.

Okay, please push.

Thanks,
  Mark



Re: [PATCH] gnu: notmuch: Update to 0.20.2.

2015-08-16 Thread Mark H Weaver
David Thompson  writes:

> From 74d2db4f0ecbfc00473493e410a086f7c7c0bb10 Mon Sep 17 00:00:00 2001
> From: David Thompson 
> Date: Sat, 15 Aug 2015 22:23:59 -0400
> Subject: [PATCH] gnu: notmuch: Update to 0.20.2.
>
> * gnu/packages/mail.scm (notmuch): Update to 0.20.2.  Add python-sphinx native
>   input.  Rewrite phases using 'modify-phases' syntax.

The commit log should probably mention that you enabled tests, but
otherwise it looks good to me.

 Thanks!
   Mark



Re: [PATCH 2/2] gnu: commencement: Add support for a native GNU/Hurd system.

2015-08-16 Thread Manolis Ragkousis
I forgot to add the part that points libpthread's makefile to the
libihash lib to link against.
Unless I do that, ld fails to find -lihash.

Updated patch.
From 690c42a18df0e4fff6145e0a9c4258ce5cefee7b Mon Sep 17 00:00:00 2001
From: Manolis Ragkousis 
Date: Fri, 14 Aug 2015 16:12:13 +0300
Subject: [PATCH] gnu: commencement: Add support for a native GNU/Hurd system.

* gnu/packages/commencement.scm (kernel-headers-boot0): New procedure.
  (flex-boot0, bison-boot0, gnumach-headers-boot0, mig-boot0,
  hurd-headers-boot0, hurd-minimal-boot0, hurd-kernel-headers-boot0): New variables.
  (glibc-final-with-bootstrap-bash)[propagated-inputs]: Replace with kernel-headers-boot0.
   [inputs]: Add "mig".
  (glibc-final)[arguments]: Replace with kernel-headers-boot0.
---
 gnu/packages/commencement.scm | 131 --
 1 file changed, 115 insertions(+), 16 deletions(-)

diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index d3f239f..ac12843 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -27,15 +27,18 @@
   #:use-module (gnu packages bash)
   #:use-module (gnu packages gcc)
   #:use-module (gnu packages m4)
+  #:use-module (gnu packages indent)
   #:use-module (gnu packages file)
   #:use-module (gnu packages gawk)
   #:use-module (gnu packages bison)
+  #:use-module (gnu packages flex)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages multiprecision)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages hurd)
   #:use-module (gnu packages texinfo)
   #:use-module (gnu packages pkg-config)
   #:use-module (guix packages)
@@ -46,7 +49,8 @@
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26)
   #:use-module (ice-9 vlist)
-  #:use-module (ice-9 match))
+  #:use-module (ice-9 match)
+  #:use-module (ice-9 regex))
 
 ;;; Commentary:
 ;;;
@@ -265,6 +269,43 @@
  (current-source-location)
  #:guile %bootstrap-guile)))
 
+(define flex-boot0
+  ;; This Flex is needed to build Mig.
+  (let* ((m4(package-with-bootstrap-guile
+ (package-with-explicit-inputs m4 %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile)))
+ (indent(package-with-bootstrap-guile
+ (package-with-explicit-inputs indent %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile)))
+ (flex (package (inherit flex)
+ (native-inputs `())
+ (propagated-inputs `(("m4" ,m4)))
+ (inputs '())
+ (arguments '(#:tests? #f)
+(package-with-bootstrap-guile
+ (package-with-explicit-inputs flex %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile
+
+(define bison-boot0
+  ;; This Bison is needed to build Mig so we need it early in the process. 
+  (let* ((m4(package-with-bootstrap-guile
+ (package-with-explicit-inputs m4 %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile)))
+ (bison (package (inherit bison)
+  (native-inputs `(("perl" ,perl-boot0)))
+  (propagated-inputs `(("m4" ,m4)))
+  (inputs '());remove Flex...
+  (arguments '(#:tests? #f
+   #:validate-runpath? #f)   ;... and thus disable tests
+(package-with-bootstrap-guile
+ (package-with-explicit-inputs bison %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile
+
 (define (linux-libre-headers-boot0)
   "Return Linux-Libre header files for the bootstrap environment."
   ;; Note: this is wrapped in a thunk to nicely handle circular dependencies
@@ -278,6 +319,58 @@
   `(("perl" ,perl-boot0)
 ,@%boot0-inputs)
 
+(define gnumach-headers-boot0
+  (package-with-bootstrap-guile
+   (package-with-explicit-inputs gnumach-headers
+ %boot0-inputs
+ (current-source-location)
+ #:guile %bootstrap-guile)))
+
+(define mig-boot0
+  (let ((mig (package (inherit mig)
+   (native-inputs `(("bison" ,bison-boot0)
+("flex" ,flex-boot0)))
+   (inputs '()
+(package-with-bootstrap-guile
+ (package-with-explicit-inputs mig %boot0-inputs
+  

[PATCH 1/2] gnu: qemu: Honor #:configure-flags argument.

2015-08-16 Thread ericbavier
From: Eric Bavier 

* gnu/packages/qemu.scm (qemu-headless)[arguments]: Honor #:configure-flags
  arguments for configure phase.
---
 gnu/packages/qemu.scm | 11 +++
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/gnu/packages/qemu.scm b/gnu/packages/qemu.scm
index af39427..6979655 100644
--- a/gnu/packages/qemu.scm
+++ b/gnu/packages/qemu.scm
@@ -74,7 +74,8 @@
 (arguments
  '(#:phases (alist-replace
  'configure
- (lambda* (#:key inputs outputs #:allow-other-keys)
+ (lambda* (#:key inputs outputs (configure-flags '())
+   #:allow-other-keys)
;; The `configure' script doesn't understand some of the
;; GNU options.  Thus, add a new phase that's compatible.
(let ((out (assoc-ref outputs "out")))
@@ -87,11 +88,13 @@
  ;; The binaries need to be linked against -lrt.
  (setenv "LDFLAGS" "-lrt")
  (zero?
-  (system* "./configure"
-   (string-append "--cc=" (which "gcc"))
+  (apply system*
+ `("./configure"
+   ,(string-append "--cc=" (which "gcc"))
"--disable-debug-info" ; save build space
"--enable-virtfs"  ; just to be sure
-   (string-append "--prefix=" out)
+   ,(string-append "--prefix=" out)
+   ,@configure-flags)
  (alist-cons-after
   'install 'install-info
   (lambda* (#:key inputs outputs #:allow-other-keys)
-- 
2.4.3




[PATCH 2/2] gnu: Add American fuzzy lop.

2015-08-16 Thread ericbavier
From: Eric Bavier 

* gnu/packages/debug.scm (american-fuzzy-lop): New variable.
---
 gnu/packages/debug.scm | 96 +-
 1 file changed, 95 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/debug.scm b/gnu/packages/debug.scm
index ba80711..dba3091 100644
--- a/gnu/packages/debug.scm
+++ b/gnu/packages/debug.scm
@@ -27,7 +27,10 @@
   #:use-module (gnu packages indent)
   #:use-module (gnu packages llvm)
   #:use-module (gnu packages perl)
-  #:use-module (gnu packages pretty-print))
+  #:use-module (gnu packages pretty-print)
+  #:use-module (gnu packages qemu)
+  #:use-module (ice-9 match)
+  #:use-module (srfi srfi-1))
 
 (define-public delta
   (package
@@ -137,3 +140,94 @@ produces a much smaller C/C++ program that has the same 
property.  It is
 intended for use by people who discover and report bugs in compilers and other
 tools that process C/C++ code.")
 (license ncsa)))
+
+(define-public american-fuzzy-lop
+  (let ((machine (match (or (%current-target-system)
+(%current-system))
+   ("x86_64-linux"   "x86_64")
+   ("i686-linux" "i386")
+   ;; Prevent errors when querying this package on unsupported
+   ;; platforms, e.g. when running "guix package --search="
+   (_"UNSUPPORTED"
+(package
+  (name "american-fuzzy-lop")
+  (version "1.86b") ;It seems all releases have the 'b' suffix
+  (source
+   (origin
+ (method url-fetch)
+ (uri (string-append "http://lcamtuf.coredump.cx/afl/releases/";
+ "afl-" version ".tgz"))
+ (sha256
+  (base32
+   "1by9ncf6lgcyibzqwyla34jv64sd66mn8zhgjz2pcgsds51qwn0r"
+  (build-system gnu-build-system)
+  (inputs
+   `(("custom-qemu"
+  ;; The afl-qemu tool builds qemu 2.3.0 with a few patches applied.
+  ,(package (inherit qemu-headless)
+ (name "afl-qemu")
+ (inputs
+  `(("afl-src" ,source)
+,@(package-inputs qemu-headless)))
+ ;; afl only supports using a single afl-qemu-trace executable, so
+ ;; we only build qemu for the native target.
+ (arguments
+  `(#:configure-flags
+(list (string-append "--target-list=" ,machine "-linux-user"))
+,@(substitute-keyword-arguments (package-arguments 
qemu-headless)
+((#:phases qemu-phases)
+ `(modify-phases ,qemu-phases
+(add-after
+ 'unpack 'apply-afl-patches
+ (lambda* (#:key inputs #:allow-other-keys)
+   (let* ((afl-dir (string-append "afl-" ,version))
+  (patch-dir
+   (string-append afl-dir
+  "/qemu_mode/patches")))
+ (system* "tar" "xf" (assoc-ref inputs "afl-src"))
+ (copy-file (string-append patch-dir
+   "/afl-qemu-cpu-inl.h")
+"./afl-qemu-cpu-inl.h")
+ (copy-file (string-append afl-dir "/config.h")
+"./afl-config.h")
+ (copy-file (string-append afl-dir "/types.h")
+"./types.h")
+ (substitute* "afl-qemu-cpu-inl.h"
+   (("\\.\\./\\.\\./config.h") "afl-config.h"))
+ (substitute* (string-append patch-dir
+ "/cpu-exec.diff")
+   (("\\.\\./patches/") ""))
+ (for-each (lambda (patch-file)
+ (system* "patch" "--force" "-p1"
+  "--input" patch-file))
+   (find-files patch-dir
+   ".*\\.diff"))
+  (arguments
+   `(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs 
"out"))
+"CC=gcc")
+ #:phases (modify-phases %standard-phases
+(delete 'configure)
+(add-after
+ ;; TODO: Build and install th afl-llvm tool.
+ 'install 'install-qemu
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+   (let ((qemu (assoc-ref inputs "custom-qemu"))
+ (out  (assoc-ref %outputs "out")))
+ (copy-file (string-append qemu "/bin/qemu-" ,machine)
+(string-appen

[PATCH 5/5] gnu: Add python-oslotest

2015-08-16 Thread Cyril Roelandt
* gnu/packages/openstack.scm (python-oslotest, python2-olsotest): New variables.
---
 gnu/packages/openstack.scm | 39 +++
 1 file changed, 39 insertions(+)

diff --git a/gnu/packages/openstack.scm b/gnu/packages/openstack.scm
index 1a7820a..f79dba0 100644
--- a/gnu/packages/openstack.scm
+++ b/gnu/packages/openstack.scm
@@ -138,3 +138,42 @@ tested on Python version 3.2, 2.7 and 2.6.")
 
 (define-public python2-pbr
   (package-with-python2 python-pbr))
+
+;; Packages from the Oslo library
+(define-public python-oslotest
+  (package
+(name "python-oslotest")
+(version "1.8.0")
+(source
+  (origin
+(method url-fetch)
+(uri (string-append
+   "https://pypi.python.org/packages/source/o/oslotest/oslotest-";
+   version
+   ".tar.gz"))
+(sha256
+  (base32
+"175dln2zxjvvh4b23f2hln6zwfy2v5f1blg7mxbwl4r3130zvs2k"
+(build-system python-build-system)
+(propagated-inputs
+  `(("python-fixtures" ,python-fixtures)
+("python-mock" ,python-mock)
+("python-six" ,python-six)))
+(inputs
+  `(("python-pbr" ,python-pbr)
+("python-mox3" ,python-mox3)
+("python-os-client-config" ,python-os-client-config)
+("python-setuptools" ,python-setuptools)
+("python-subunit" ,python-subunit)
+("python-testrepository" ,python-testrepository)
+("python-testscenarios" ,python-testscenarios)
+("python-testtools" ,python-testtools)))
+(home-page "http://launchpad.net/oslo";)
+(synopsis "Oslo test framework")
+(description
+  "The Oslo Test framework provides common fixtures, support for debugging,
+and better support for mocking results.")
+(license asl2.0)))
+
+(define-public python2-oslotest
+  (package-with-python2 python-oslotest))
-- 
2.1.4




[PATCH 1/5] gnu: add python-appdirs.

2015-08-16 Thread Cyril Roelandt
* gnu/packages/python.scm (python-appdirs, python2-appdirs): New variables.
---
 gnu/packages/python.scm | 29 +
 1 file changed, 29 insertions(+)

diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm
index 940efec..7f48b5b 100644
--- a/gnu/packages/python.scm
+++ b/gnu/packages/python.scm
@@ -4629,3 +4629,32 @@ term.js Javascript terminal emulator library.")
  ,python2-backport-ssl-match-hostname)
 ,@(alist-delete "python-tornado"
 (package-propagated-inputs terminado)))
+
+(define-public python-appdirs
+  (package
+(name "python-appdirs")
+(version "1.4.0")
+(source
+  (origin
+(method url-fetch)
+(uri (string-append
+   "https://pypi.python.org/packages/source/a/appdirs/appdirs-";
+   version
+   ".tar.gz"))
+(sha256
+  (base32
+"1iddva7v3fq0aqzsahkazxr7vpw28mqcrsy818z4wyiqnkplbhlg"
+(build-system python-build-system)
+(inputs
+  `(("python-setuptools" ,python-setuptools)))
+(home-page "http://github.com/ActiveState/appdirs";)
+(synopsis
+  "A small Python module for determining appropriate platform-specific
+dirs, e.g. a \"user data dir\".")
+(description
+  "This module provides an portable way of finding out where user data
+should be stored on various operating systems.")
+(license license:expat)))
+
+(define-public python2-appdirs
+  (package-with-python2 python-appdirs))
-- 
2.1.4




[PATCH 3/5] gnu: Add python-mox3.

2015-08-16 Thread Cyril Roelandt
* gnu/packages/openstack.scm (python-mox3, python2-mox3): New variables.
---
 gnu/packages/openstack.scm | 33 +
 1 file changed, 33 insertions(+)

diff --git a/gnu/packages/openstack.scm b/gnu/packages/openstack.scm
index 1598020..eb3c606 100644
--- a/gnu/packages/openstack.scm
+++ b/gnu/packages/openstack.scm
@@ -25,6 +25,39 @@
 #:select (asl2.0))
   #:use-module (guix packages))
 
+(define-public python-mox3
+  (package
+(name "python-mox3")
+(version "0.8.0")
+(source
+  (origin
+(method url-fetch)
+(uri (string-append
+   "https://pypi.python.org/packages/source/m/mox3/mox3-";
+   version
+   ".tar.gz"))
+(sha256
+  (base32
+"1dwj9lkifdqvrcympqa47bj55l0n0j9jhzv2gj03h0dpzg6mgfkj"
+(build-system python-build-system)
+(inputs
+  `(("python-fixtures" ,python-fixtures)
+("python-pbr" ,python-pbr)
+("python-setuptools" ,python-setuptools)
+("python-six" ,python-six)
+("python-testtools" ,python-testtools)))
+(home-page "http://www.openstack.org/";)
+(synopsis "Mock object framework for Python")
+(description
+  "Mox3 is an unofficial port of the Google mox framework
+(http://code.google.com/p/pymox/) to Python 3. It was meant to be as compatible
+with mox as possible, but small enhancements have been made. The library was
+tested on Python version 3.2, 2.7 and 2.6.")
+(license asl2.0)))
+
+(define-public python2-mox3
+  (package-with-python2 python-mox3))
+
 (define-public python-pbr
   (package
 (name "python-pbr")
-- 
2.1.4




[PATCH 0/5] Add oslotest.

2015-08-16 Thread Cyril Roelandt
This is a resubmission of a previous patch, broken down into 5 smaller patches.

Cyril Roelandt (5):
  gnu: add python-appdirs.
  gnu: Add python-pbr.
  gnu: Add python-mox3.
  gnu: Add python-os-client-config
  gnu: Add python-oslotest

 gnu-system.am  |   1 +
 gnu/packages/openstack.scm | 179 +
 gnu/packages/python.scm|  29 
 3 files changed, 209 insertions(+)
 create mode 100644 gnu/packages/openstack.scm

-- 
2.1.4




[PATCH 4/5] gnu: Add python-os-client-config

2015-08-16 Thread Cyril Roelandt
* gnu/packages/openstack.scm (python-os-client-config,
  python2-os-client-config): New variables.
---
 gnu/packages/openstack.scm | 39 +++
 1 file changed, 39 insertions(+)

diff --git a/gnu/packages/openstack.scm b/gnu/packages/openstack.scm
index eb3c606..1a7820a 100644
--- a/gnu/packages/openstack.scm
+++ b/gnu/packages/openstack.scm
@@ -55,6 +55,45 @@ with mox as possible, but small enhancements have been made. 
The library was
 tested on Python version 3.2, 2.7 and 2.6.")
 (license asl2.0)))
 
+(define-public python-os-client-config
+  (package
+(name "python-os-client-config")
+(version "1.4.0")
+(source
+  (origin
+(method url-fetch)
+(uri (string-append
+   
"https://pypi.python.org/packages/source/o/os-client-config/os-client-config-";
+   version
+   ".tar.gz"))
+(sha256
+  (base32
+"14png6ml3zbbilh8bihav24f8vig9lyijwynnjcvazdxxrzvwq9j"
+(build-system python-build-system)
+(arguments
+ `(#:tests? #f)) ;; Circular dependency with python-oslotest
+(inputs
+  `(("python-appdirs" ,python-appdirs)
+("python-fixtures" ,python-fixtures)
+("python-mimeparse" ,python-mimeparse)
+("python-pbr" ,python-pbr)
+("python-pyyaml" ,python-pyyaml)
+("python-testrepository" ,python-testrepository)
+("python-setuptools" ,python-setuptools)
+("python-testscenarios" ,python-testscenarios)
+("python-testtools" ,python-testtools)))
+(home-page "http://www.openstack.org/";)
+(synopsis
+  "OpenStack Client Configuration Library")
+(description
+  "The OpenStack Client Configuration Library is a library for collecting
+  client configuration for using an OpenStack cloud in a consistent and
+  comprehensive manner.")
+(license asl2.0)))
+
+(define-public python2-os-client-config
+  (package-with-python2 python-os-client-config))
+
 (define-public python2-mox3
   (package-with-python2 python-mox3))
 
-- 
2.1.4




[PATCH 2/5] gnu: Add python-pbr.

2015-08-16 Thread Cyril Roelandt
* gnu/packages/openstack.scm: New file.
* gnu-system.am: Add it.
---
 gnu-system.am  |  1 +
 gnu/packages/openstack.scm | 68 ++
 2 files changed, 69 insertions(+)
 create mode 100644 gnu/packages/openstack.scm

diff --git a/gnu-system.am b/gnu-system.am
index 9f46f7b..aa335e1 100644
--- a/gnu-system.am
+++ b/gnu-system.am
@@ -235,6 +235,7 @@ GNU_SYSTEM_MODULES =\
   gnu/packages/onc-rpc.scm \
   gnu/packages/openbox.scm \
   gnu/packages/openldap.scm\
+  gnu/packages/openstack.scm   \
   gnu/packages/orpheus.scm \
   gnu/packages/ots.scm \
   gnu/packages/package-management.scm  \
diff --git a/gnu/packages/openstack.scm b/gnu/packages/openstack.scm
new file mode 100644
index 000..1598020
--- /dev/null
+++ b/gnu/packages/openstack.scm
@@ -0,0 +1,68 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2015 Cyril Roelandt 
+;;;
+;;; 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 openstack)
+  #:use-module (gnu packages python)
+  #:use-module (gnu packages version-control)
+  #:use-module (guix build-system python)
+  #:use-module (guix download)
+  #:use-module ((guix licenses)
+#:select (asl2.0))
+  #:use-module (guix packages))
+
+(define-public python-pbr
+  (package
+(name "python-pbr")
+(version "1.2.0")
+(source
+  (origin
+(method url-fetch)
+(uri (string-append
+   "https://pypi.python.org/packages/source/p/pbr/pbr-";
+   version
+   ".tar.gz"))
+(sha256
+  (base32
+"1l2mls8wnwpkqj6hxsphq7xibbbsf40gg37wc30nj4r600zgqhqm"
+(build-system python-build-system)
+(arguments
+ `(#:tests? #f)) ;; Most tests seem to use the Internet.
+(propagated-inputs
+  `(("python-testrepository" ,python-testrepository)
+("git" ,git))) ;; pbr actually uses the "git" binary.
+(inputs
+  `(("python-fixtures" ,python-fixtures)
+("python-mimeparse" ,python-mimeparse)
+("python-mock" ,python-mock)
+("python-setuptools" ,python-setuptools)
+("python-six" ,python-six)
+("python-sphinx" ,python-sphinx)
+("python-testrepository" ,python-testrepository)
+("python-testresources" ,python-testresources)
+("python-testscenarios" ,python-testscenarios)
+("python-testtools" ,python-testtools)
+("python-virtualenv" ,python-virtualenv)))
+(home-page "https://launchpad.net/pbr";)
+(synopsis "Python Build Reasonableness")
+(description
+  "PBR is a library that injects some useful and sensible default behaviors
+  into your setuptools run.")
+(license asl2.0)))
+
+(define-public python2-pbr
+  (package-with-python2 python-pbr))
-- 
2.1.4




Running guix-daemon as an unprivileged user (Was: [PATCH] syscalls: setns: Skip binding if there is no such C function.)

2015-08-16 Thread 韋嘉誠
[Reposting with correct sender. Sorry, David.]

Great! I ran into this when trying to compile and run guix on a machine at
work, where I'm not root.

I was planning to run guix as a stow of steroids. But I'm still wondering
whether what I'm attempting is even intended to be possible? Of course, I
would lose the benefits of user separation, chroot, hydra (because I can't
write to /gnu) etc, but is guix even made to be able to downgrade to this
situation?


Running guix-daemon as an unprivileged user (Was: [PATCH] syscalls: setns: Skip binding if there is no such C function.)

2015-08-16 Thread 韋嘉誠
On 16-Aug-2015 2:19 pm, "David Thompson"  wrote:

Great! I ran into this when trying to compile and run guix on a machine at
work, where I'm not root.

I was planning to run guix as a stow of steroids. But I'm still wondering
whether what I'm attempting is even intended to be possible? Of course, I
would lose the benefits of user separation, chroot, hydra (because I can't
write to /gnu) etc, but is guix even made to be able to downgrade to this
situation?


[PATCH] syscalls: setns: Skip binding if there is no such C function.

2015-08-16 Thread David Thompson
>From 57faa1368cb96dd94cc32c18a0e6b63285ca8e1d Mon Sep 17 00:00:00 2001
From: David Thompson 
Date: Sun, 16 Aug 2015 08:08:34 -0400
Subject: [PATCH] syscalls: setns: Skip binding if there is no such C function.

On systems with a glibc prior to 2.14, the 'setns' function is not available.

Thanks to Eric Bavier for reporting the issue.

* guix/build/syscalls.scm (setns): Wrap with 'false-if-exception'.
---
 guix/build/syscalls.scm | 23 +--
 1 file changed, 13 insertions(+), 10 deletions(-)

diff --git a/guix/build/syscalls.scm b/guix/build/syscalls.scm
index 68f340c..fc801a5 100644
--- a/guix/build/syscalls.scm
+++ b/guix/build/syscalls.scm
@@ -328,19 +328,22 @@ are shared between the parent and child processes."
   (proc syscall-id flags %null-pointer
 
 (define setns
-  (let* ((ptr  (dynamic-func "setns" (dynamic-link)))
- (proc (pointer->procedure int ptr (list int int
-(lambda (fdes nstype)
-  "Reassociate the current process with the namespace specified by FDES, a
+  ;; Some systems may be using an old (pre-2.14) version of glibc where there
+  ;; is no 'setns' function available.
+  (false-if-exception
+   (let* ((ptr  (dynamic-func "setns" (dynamic-link)))
+  (proc (pointer->procedure int ptr (list int int
+ (lambda (fdes nstype)
+   "Reassociate the current process with the namespace specified by FDES, a
 file descriptor obtained by opening a /proc/PID/ns/* file.  NSTYPE specifies
 which type of namespace the current process may be reassociated with, or 0 if
 there is no such limitation."
-  (let ((ret (proc fdes nstype))
-(err (errno)))
-(unless (zero? ret)
-  (throw 'system-error "setns" "~d ~d: ~A"
- (list fdes nstype (strerror err))
- (list err)))
+   (let ((ret (proc fdes nstype))
+ (err (errno)))
+ (unless (zero? ret)
+   (throw 'system-error "setns" "~d ~d: ~A"
+  (list fdes nstype (strerror err))
+  (list err
 
 (define pivot-root
   (let* ((ptr  (dynamic-func "pivot_root" (dynamic-link)))
-- 
2.4.3




Re: [PATCH 2/2] gnu: commencement: Add support for a native GNU/Hurd system.

2015-08-16 Thread Manolis Ragkousis
Updated patch.
From f0d7050f2582e48c321b7a9158a2b7c83c521015 Mon Sep 17 00:00:00 2001
From: Manolis Ragkousis 
Date: Fri, 14 Aug 2015 16:12:13 +0300
Subject: [PATCH] gnu: commencement: Add support for a native GNU/Hurd system.

* gnu/packages/commencement.scm (kernel-headers-boot0): New procedure.
  (flex-boot0, bison-boot0, gnumach-headers-boot0, mig-boot0,
  hurd-headers-boot0, hurd-minimal-boot0, hurd-kernel-headers-boot0): New variables.
  (glibc-final-with-bootstrap-bash)[propagated-inputs]: Replace with kernel-headers-boot0.
   [inputs]: Add "mig".
  (glibc-final)[arguments]: Replace with kernel-headers-boot0.
---
 gnu/packages/commencement.scm | 122 --
 1 file changed, 106 insertions(+), 16 deletions(-)

diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index d3f239f..e9ef305 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -27,15 +27,18 @@
   #:use-module (gnu packages bash)
   #:use-module (gnu packages gcc)
   #:use-module (gnu packages m4)
+  #:use-module (gnu packages indent)
   #:use-module (gnu packages file)
   #:use-module (gnu packages gawk)
   #:use-module (gnu packages bison)
+  #:use-module (gnu packages flex)
   #:use-module (gnu packages guile)
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages multiprecision)
   #:use-module (gnu packages compression)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages hurd)
   #:use-module (gnu packages texinfo)
   #:use-module (gnu packages pkg-config)
   #:use-module (guix packages)
@@ -46,7 +49,8 @@
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26)
   #:use-module (ice-9 vlist)
-  #:use-module (ice-9 match))
+  #:use-module (ice-9 match)
+  #:use-module (ice-9 regex))
 
 ;;; Commentary:
 ;;;
@@ -265,6 +269,43 @@
  (current-source-location)
  #:guile %bootstrap-guile)))
 
+(define flex-boot0
+  ;; This Flex is needed to build Mig.
+  (let* ((m4(package-with-bootstrap-guile
+ (package-with-explicit-inputs m4 %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile)))
+ (indent(package-with-bootstrap-guile
+ (package-with-explicit-inputs indent %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile)))
+ (flex (package (inherit flex)
+ (native-inputs `())
+ (propagated-inputs `(("m4" ,m4)))
+ (inputs '())
+ (arguments '(#:tests? #f)
+(package-with-bootstrap-guile
+ (package-with-explicit-inputs flex %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile
+
+(define bison-boot0
+  ;; This Bison is needed to build Mig so we need it early in the process. 
+  (let* ((m4(package-with-bootstrap-guile
+ (package-with-explicit-inputs m4 %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile)))
+ (bison (package (inherit bison)
+  (native-inputs `(("perl" ,perl-boot0)))
+  (propagated-inputs `(("m4" ,m4)))
+  (inputs '());remove Flex...
+  (arguments '(#:tests? #f
+   #:validate-runpath? #f)   ;... and thus disable tests
+(package-with-bootstrap-guile
+ (package-with-explicit-inputs bison %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile
+
 (define (linux-libre-headers-boot0)
   "Return Linux-Libre header files for the bootstrap environment."
   ;; Note: this is wrapped in a thunk to nicely handle circular dependencies
@@ -278,6 +319,58 @@
   `(("perl" ,perl-boot0)
 ,@%boot0-inputs)
 
+(define gnumach-headers-boot0
+  (package-with-bootstrap-guile
+   (package-with-explicit-inputs gnumach-headers
+ %boot0-inputs
+ (current-source-location)
+ #:guile %bootstrap-guile)))
+
+(define mig-boot0
+  (let ((mig (package (inherit mig)
+   (native-inputs `(("bison" ,bison-boot0)
+("flex" ,flex-boot0)))
+   (inputs '()
+(package-with-bootstrap-guile
+ (package-with-explicit-inputs mig %boot0-inputs
+   (current-source-location)
+   #:guile %bootstrap-guile
+
+(define hurd-headers-boot0