Re: Howto run guix.el correctly?

2014-11-22 Thread Alex Kost
Adam Pribyl (2014-11-22 01:28 +0300) wrote:

 I have folloed the instruction in
 http://www.gnu.org/software/guix/manual/guix.html#Emacs-Interface
 to get the emacs interface for guix, but there is something missing
 probably.

 Installation of emacs and geiser was OK, I changed the path to guix.el
 (there is no /usr/share/ in my guix installation, I had to find guix.el
 in the /gnu/store), after that I can start emacs and M-x guix-... but
 every action says Cannot open load file: no such file or directory
 geiser-mode.

 There should probably be also the geiser path in the emacs init file or
 something?

Apparently a directory with geiser is not in your `load-path' variable,
so (require 'geiser-mode) fails.

Did you install geiser with guix?  If so, you probably need to add
~/.guix-profile/share/emacs/site-lisp to `load-path'.

-- 
Alex



[PATCH] gnu: Add git-flow.

2014-11-22 Thread Eric Bavier
* gnu/packages/version-control.scm (git-flow, shflags): New variables.
---
 gnu/packages/version-control.scm |   95 +-
 1 file changed, 94 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index 931297c..3de11f0 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -4,6 +4,7 @@
 ;;; Copyright © 2013, 2014 Ludovic Courtès l...@gnu.org
 ;;; Copyright © 2013, 2014 Andreas Enge andr...@enge.fr
 ;;; Copyright © 2014 Mark H Weaver m...@netris.org
+;;; Copyright © 2014 Eric Bavier bav...@member.fsf.org
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -22,13 +23,18 @@
 
 (define-module (gnu packages version-control)
   #:use-module ((guix licenses)
-#:select (asl2.0 gpl1+ gpl2 gpl2+ gpl3+ x11-style))
+#:select (asl2.0 bsd-2
+  gpl1+ gpl2 gpl2+ gpl3+ lgpl2.1
+  x11-style))
   #:use-module (guix packages)
   #:use-module (guix download)
+  #:use-module (guix git-download)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system python)
+  #:use-module (guix build-system trivial)
   #:use-module (guix build utils)
   #:use-module (gnu packages apr)
+  #:use-module (gnu packages base)
   #:use-module (gnu packages bison)
   #:use-module (gnu packages cook)
   #:use-module (gnu packages curl)
@@ -204,6 +210,93 @@ everything from small to very large projects with speed 
and efficiency.)
(license gpl2)
(home-page http://git-scm.com/;)))
 
+(define-public shflags
+  (package
+(name shflags)
+(version 1.0.3)
+(source (origin
+  (method url-fetch)
+  (uri (string-append https://shflags.googlecode.com/files/;
+  shflags- version .tgz))
+  (sha256
+   (base32
+08laxhf1hifh3w4j0hri5ppcklaqz0mnkmbaz8j0wxih29vi8slm
+(build-system trivial-build-system)
+(native-inputs `((tar ,tar)
+ (gzip ,gzip)))
+(arguments
+ `(#:modules ((guix build utils))
+   #:builder (begin
+   (use-modules (guix build utils))
+   (let* ((source (assoc-ref %build-inputs source))
+  (tar(assoc-ref %build-inputs tar))
+  (gzip   (assoc-ref %build-inputs gzip))
+  (output (assoc-ref %outputs out))
+  (srcdir (string-append output /src)))
+ (begin
+   (setenv PATH (string-append gzip /bin))
+   (system* (string-append tar /bin/tar) xzf
+source)
+   (chdir ,(string-append name - version))
+   (mkdir-p srcdir)
+   (copy-file src/shflags
+  (string-append srcdir /shflags))
+   #t)
+(home-page https://code.google.com/p/shflags/;)
+(synopsis Command-line flags library for shell scripts)
+(description
+ Shell Flags (shFlags) is a library written to greatly simplify the
+handling of command-line flags in Bourne based Unix shell scripts (bash, dash,
+ksh, sh, zsh).  Most shell scripts use getopt for flags processing, but the
+different versions of getopt on various OSes make writing portable shell
+scripts difficult.  shFlags instead provides an API that doesn't change across
+shell and OS versions so the script writer can be confident that the script
+will work.)
+(license lgpl2.1)))
+
+(define-public git-flow
+  (package
+(name git-flow)
+;; This version has not be officially released yet, so we build it
+;; directly from the git repository.
+(version 0.4.2-pre)
+(source (origin
+  (method git-fetch)
+  (uri (git-reference
+(url https://github.com/nvie/gitflow/;)
+(commit 15aab26)))
+  (sha256
+   (base32
+01fs97q76fdfnvmrh2cyjhywcs3pykf1dg58sy0frflnsdzs6prx
+(build-system gnu-build-system)
+(inputs `((shflags ,shflags)))
+(arguments
+ '(#:tests? #f; no tests
+   #:make-flags (list (string-append prefix=
+ (assoc-ref %outputs out)))
+   #:phases (alist-cons-after
+ 'unpack 'reset-shFlags-link
+ (lambda* (#:key inputs #:allow-other-keys)
+   ;; The link points to a file in the shFlags submodule.
+   ;; Redirect it to point to our system shFlags.
+   (let ((shflags (assoc-ref inputs shflags)))
+ (begin
+   (delete-file gitflow-shFlags)
+   (symlink (string-append shflags /src/shflags)
+gitflow-shFlags
+ (alist-delete
+  

guix package: error: build failed: derivation has incorrect output

2014-11-22 Thread Bruno Félix Rezende Ribeiro
Running

  guix package -i windowmaker

gives me

  guix package: error: build failed: derivation
  `/gnu/store/pxyjsl5xv387kbx55lw97pjrlfzfxpcp-guile-bootstrap-2.0.drv'
  has incorrect output
  `/home/felix/gnu/store/ka1kwmxk2ffkjhfp84y4s192kximrxfz-guile-bootstrap-2.0',
  should be
  `/gnu/store/3pxvfkc3fca9cdpp5fqci8dy6r4s5cph-guile-bootstrap-2.0'

Any Idea why?


Context info:

I've configured Guix with the option
'--prefix=/home/felix/opt/guix.git' and installed it just to discover I
would like to have added '--with-store-dir=/home/felix/gnu/store'; then
I reinvoked configure from the previous VPATH build and then 'make'
only rebuilt 'guix/config.go' from 'guix/config.scm'.  After that I
installed Guix again.  I didn't run 'make clean' because this is an
Yeeloong and as such I'm trying to avoid the fatigue.

I've chowned 'guix-daemon' to 'root:root' and chomoded it to 'ug+s'.
Then, running 'guix package -i windowmaker' for the first time resulted
in

  guix package: error: build failed: Nix database directory
  `/home/felix/opt/guix.git/var/guix/db' is not writable: Permission
  denied

Facing that I chmoded '~felix/opt/guix.git/var/guix/db/' to 'o+w', and
all went fine to the error described on this mail's top.


-- 
 ,= ,-_-. =.  Bruno Félix Rezende Ribeiro (oitofelix) [0x28D618AF]
((_/)o o(\_)) There is no system but GNU;
 `-'(. .)`-'  GNU Linux-Libre is one of its official kernels;
 \_/  All software must be free as in freedom;



Re: Howto run guix.el correctly?

2014-11-22 Thread Ludovic Courtès
Alex Kost alez...@gmail.com skribis:

 Did you install geiser with guix?  If so, you probably need to add
 ~/.guix-profile/share/emacs/site-lisp to `load-path'.

Yes, and also something like:

  (setq-default geiser-guile-load-path (list geiser-scheme-dir))

We should find a way to make things work out of the box.

Ludo’.



Re: [PATCH 01/13] gnu: subversion: Propagate env variables to hooks.

2014-11-22 Thread Ludovic Courtès
Eric Bavier ericbav...@gmail.com skribis:

 On Fri, Nov 21, 2014 at 4:24 PM, Eric Bavier ericbav...@gmail.com wrote:


 Ludovic Courtès writes:

  Eric Bavier ericbav...@gmail.com skribis:
 
  * gnu/packages/patches/subversion-propagate-env-to-hooks.patch: New
 patch.
  * gnu-system.am (dist_patch_DATA): Add it.
  * gnu/packages/version-control.scm (subversion): Use it.
 
  [...]
 
  +++ b/gnu/packages/patches/subversion-propagate-env-to-hooks.patch
  @@ -0,0 +1,14 @@
  +* Hooks need to inherit environment variables such as PATH, otherwise
 simple
  +  things like `ls` might fail in a hook.
 
  That looks good, but I want to make sure we’re not changing something
  that was purposefully made this way.

 If the behavior is similar in 1.8.10, I'll get in contact with the
 developers.


 According to the subversion documentation, the desired behavior is to
 execute hooks in an empty environment for security reasons (see
 http://svnbook.red-bean.com/en/1.7/svn.reposadmin.create.html#svn.reposadmin.create.hooks
 ).

OK, so I think it’s important to stick to this behavior.

 So it looks like this is a small bug in libtool.  The wrapper scripts
 libtool generates for programs use `ls' to resolve symbolic links and is
 the only utility program invoked without an absolute file name (the only
 other utility being sed).  If such a wrapper script is executed with no
 PATH set, then we get ls: command not found errors.  I don't think it's
 unreasonable to expect libtool's wrappers to be able to execute in an empty
 environment.

I see.  So the patch is there “just” to allow tests to run, right?

Second, the problem should affect everyone, including FHS systems, no?
How do people work around it?

Thanks,
Ludo’.



Re: ‘strip’ phase

2014-11-22 Thread Ludovic Courtès
Mark H Weaver m...@netris.org skribis:

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

 Mark H Weaver m...@netris.org skribis:

 IMO, the best solution is to check for the presence of ELF headers
 ourselves.  We already have ELF code in Guile master.

 Yes, that sounds good.  Instead of relying on Guile’s ELF code, perhaps
 it would be enough to check for the presence of the ELF magic bytes?

 Agreed.  The test need not be perfect, because the worst that can happen
 is an _occasional_ warning from 'strip', which really will be harmless :)

Commit 50b87bd in ‘core-updates’ does that.

Thanks,
Ludo’.



core-updates is back

2014-11-22 Thread Ludovic Courtès
Hello!

‘core-updates’ is open again for updates to core packages (the implicit
inputs of ‘gnu-build-system’), their dependencies, or the (guix build …)
modules.

Things I’d like to see in this branch include:

  • Removing locales from ‘glibc’, and instead provide a separate
package to build them on-demand, and then using $LOCPATH.  This will
save a lot of space.

  • Maybe try using GCC 4.9.2 as the default compiler.

Other ideas welcome.

Ludo’.



Re: Howto run guix.el correctly?

2014-11-22 Thread Alex Kost
Ludovic Courtès (2014-11-22 13:52 +0300) wrote:

 Alex Kost alez...@gmail.com skribis:

 Did you install geiser with guix?  If so, you probably need to add
 ~/.guix-profile/share/emacs/site-lisp to `load-path'.

 Yes, and also something like:

   (setq-default geiser-guile-load-path (list geiser-scheme-dir))

Is it really needed?  Geiser should respect ‘geiser-scheme-dir’ by
default.

 We should find a way to make things work out of the box.

These lines may just be added to “guix-init.el.in”.

-- 
Alex



Re: [PATCH] gnu: Add Tiled

2014-11-22 Thread Andreas Enge
The problem should now be fixed in 5dee80d. I tried to enter something
in the file open dialog of tiled, and it worked.

Andreas




[PATCH] gnu: Add rtorrent and libtorrent.

2014-11-22 Thread Taylan Ulrich Bayırlı/Kammer

===File
/home/tub/media/src/guix/0001-gnu-Add-rtorrent-and-libtorrent.patch===
From 1ddb6d2e6ed7cbfc60c01fdd7d2c35559d735c28 Mon Sep 17 00:00:00 2001
From: Taylan Ulrich B taylanbayi...@gmail.com
Date: Sat, 22 Nov 2014 14:38:01 +0100
Subject: [PATCH] gnu: Add rtorrent and libtorrent.

* gnu/packages/bittorrent.scm (libtorrent, rtorrent): New variables.
---
 gnu/packages/bittorrent.scm | 67 -
 1 file changed, 66 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/bittorrent.scm b/gnu/packages/bittorrent.scm
index 8b43886..a4e2ad1 100644
--- a/gnu/packages/bittorrent.scm
+++ b/gnu/packages/bittorrent.scm
@@ -30,7 +30,12 @@
   #:use-module ((gnu packages compression)
 #:select (zlib))
   #:use-module (gnu packages glib)
-  #:use-module (gnu packages gtk))
+  #:use-module (gnu packages gtk)
+  #:use-module (gnu packages check)
+  #:use-module (gnu packages ncurses)
+  #:use-module (gnu packages curl)
+  #:use-module (gnu packages cyrus-sasl)
+  #:use-module (gnu packages gnupg))
 
 (define-public transmission
   (package
@@ -88,3 +93,63 @@ DHT, µTP, PEX and Magnet Links.)
 ;;
 ;; A few files files carry an MIT/X11 license header.
 (license l:gpl3+)))
+
+(define-public libtorrent
+  (package
+(name libtorrent)
+(version 0.13.4)
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+http://libtorrent.rakshasa.no/downloads/libtorrent-;
+version .tar.gz))
+  (sha256
+   (base32
+0ma910br5vxrfpm4f4w4942lpmhwvqjnnf9h8vpf52fw35qhjkkh
+(build-system gnu-build-system)
+(inputs `((pkg-config ,pkg-config)
+  (openssl ,openssl)
+  (zlib ,zlib)
+  ;; Add this when you enable tests:
+  ;; (cppunit ,cppunit)
+  ))
+(arguments
+ `(#:tests? #f)) ;FIXME: enable on the next release:
+ ;https://github.com/rakshasa/libtorrent/issues/59
+(synopsis BitTorrent library of rtorrent)
+(description
+ LibTorrent is a BitTorrent library used by and developed in parallel
+with the BitTorrent client rtorrent.  It is written in C++ with emphasis on
+speed and efficiency.)
+(home-page http://libtorrent.rakshasa.no/;)
+(license l:gpl2)))
+
+(define-public rtorrent
+  (package
+(name rtorrent)
+(version 0.9.4)
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+http://libtorrent.rakshasa.no/downloads/rtorrent-;
+version .tar.gz))
+  (sha256
+   (base32
+113yrrac75vqi4g8r6bgs0ggjllj9bkg9shv08vqzdhkwqg2q2mw
+(build-system gnu-build-system)
+(inputs `((pkg-config ,pkg-config)
+  (libtorrent ,libtorrent)
+  (ncurses ,ncurses)
+  (curl ,curl)
+  (cyrus-sasl ,cyrus-sasl)
+  (openssl ,openssl)
+  (zlib ,zlib)
+  (libgcrypt ,libgcrypt)
+  (cppunit ,cppunit)))
+(synopsis BitTorrent client with ncurses interface)
+(description
+ rTorrent is a BitTorrent client with an ncurses interface.  It supports
+full encryption, DHT, PEX, and Magnet Links.  It can also be controlled via
+XML-RPC over SCGI.)
+(home-page http://nmap.org/;)
+(license l:gpl2)))
-- 
2.1.2





Re: guix package: error: build failed: derivation has incorrect output

2014-11-22 Thread Ludovic Courtès
Bruno Félix Rezende Ribeiro oitofe...@gnu.org skribis:

 Running

   guix package -i windowmaker

 gives me

   guix package: error: build failed: derivation
   `/gnu/store/pxyjsl5xv387kbx55lw97pjrlfzfxpcp-guile-bootstrap-2.0.drv'
   has incorrect output
   
 `/home/felix/gnu/store/ka1kwmxk2ffkjhfp84y4s192kximrxfz-guile-bootstrap-2.0',
   should be
   `/gnu/store/3pxvfkc3fca9cdpp5fqci8dy6r4s5cph-guile-bootstrap-2.0'

 Any Idea why?


 Context info:

 I've configured Guix with the option
 '--prefix=/home/felix/opt/guix.git' and installed it just to discover I
 would like to have added '--with-store-dir=/home/felix/gnu/store'; then
 I reinvoked configure from the previous VPATH build and then 'make'
 only rebuilt 'guix/config.go' from 'guix/config.scm'.  After that I
 installed Guix again.  I didn't run 'make clean' because this is an
 Yeeloong and as such I'm trying to avoid the fatigue.

Apparently that broke the installation, where part of the tools still
expect /gnu/store while others expect /home/felix/gnu/store.  You can’t
avoid running ‘make clean’ after such a change.

However, note that using a store other than /gnu/store will prevent use
of substitutes, which may be problematic on a slow machine.

Ludo’.



Re: Installing Guix with VirtualBox

2014-11-22 Thread David Thompson
白熊 guix-devel_gnu@sumou.com writes:

 How did you configure network in the Virtualbox machine. 

 I have it set: Attached to NAT, Adapter type PCnet-FAST III (Am79C973)

 But then on:

 dhclient eth0

 it fails: 

 SIOCSIFADDR: No such device 
 eth0: unknown interface: No such device 
 eth0: unknown interface: No such device 

Check the output of 'ifconfig -a' to see what the device name is.  On my
machine, it was 'enp5s0', not 'eth0'.

Hope this helps.

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



Re: [PATCH 1/2] gnu: Add numpy

2014-11-22 Thread Federico Beffa
Sorry for taking this long to answer.

On Wed, Nov 19, 2014 at 10:04 AM, Ludovic Courtès l...@gnu.org wrote:
 IIUC, this patch can now be applied.  Please push it if there’s no
 blocker left.

In the mean time version 1.9.1 was released.  With this release I
noticed that the pdf documentation gets updated and therefore the hash
changes and breaks the package.  For this reason I think that, as you
suggested before, we should build the documentation locally.  As
mentioned before, this requires matplotlib and matplotlib requires
numpy.  So I will make a numpy package without documentation and use
it as input to matplotlib as you suggested.  I'm thinking of calling
this 'numpy-bootstrap' and of not exporting it (use 'define' instead
of 'define-public').  I now got matplotlib building and able to
generate its own documentation, but would like to add the pygtk
backend before supplying a patch for review.

Regards,
Fede



[PATCH 12/13] gnu: Add python2-pygtk.

2014-11-22 Thread Federico Beffa
 Eric Bavier ericbav...@gmail.com skribis:

 * gnu/packages/gtk.scm (python2-pygtk): New variable.


I notice that most python packages are defined for python 3 and then a
python2 package is generated with the procedure 'package-with-python2'.
Is pygtk problematic with python 3?  I would be interested in using it
with a package for matplotlib that I'm preparing.

Regards,
Fede



Re: [PATCH] gnu: Add rtorrent and libtorrent.

2014-11-22 Thread David Thompson
Taylan Ulrich Bayırlı/Kammer taylanbayi...@gmail.com writes:

 David Thompson dthomps...@worcester.edu writes:

 Please break this into 2 commits, one for each new package.

 rTorrent and its libTorrent kind of belong together, though I guess
 they're strictly speaking separate packages...

Yes, they belong together, but it's best to have small, focused
patches.

 +(home-page http://nmap.org/;)

 Should be http://libtorrent.rakshasa.no/;

 Whoops, too much copy  paste. :-)

 (I'm working on an nmap recipe too.)

I figured.  I've made that mistake, too.

 Here's the new patches.  By the way the first does not strictly need the
 #:use-module (gnu packages check) since cppunit is commented out for
 now, but I left it there; is that OK?

Might be best to move that line to the patch that adds rtorrent, for
cleanliness.

The new patches look good to me.  Let's see what Ludo thinks.  :)

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



[PATCH] gnu: atlas: Try to fix build on MIPS.

2014-11-22 Thread Federico Beffa
I would like to propose the attached patch to try to fix the MIPS
package.  I'm not sure if this really help, but I do not have a way to
test it locally.

Regards,
Fede
From 64235b3012ebf6ac337a8615dd91ae08beb95180 Mon Sep 17 00:00:00 2001
From: Federico Beffa be...@fbengineering.ch
Date: Sat, 22 Nov 2014 16:42:41 +0100
Subject: [PATCH] gnu: atlas: Try to fix build on MIPS.

* gnu/packages/maths.scm (atlas): Add MIPS specific configure flags.
---
 gnu/packages/maths.scm | 5 +
 1 file changed, 5 insertions(+)

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 1aa3757..6a8d56c 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -979,6 +979,11 @@ point numbers)
  ;; Disable parallel build as it gives errors: atlas_pthread.h is
  ;; needed to compile C files before it is generated.
  -Ss pmake make -j 1
+ ;; Probe is failing for MIPS.  We therefore define the system
+ ;; architecture explicitly by setting (-A) MACHINETYPE = 49
+ ;; 'MIPSR1xK' and (-V) ISA = 1 'none'.
+ ,,@(when (string-prefix? mips (%current-system))
+  (list -A 49 -V 1))
  ;; Generate shared libraries.
  --shared
  ;; Build a full LAPACK library.
-- 
1.8.4



Re: [PATCH 12/13] gnu: Add python2-pygtk.

2014-11-22 Thread Eric Bavier
On Sat, Nov 22, 2014 at 9:40 AM, Federico Beffa be...@ieee.org wrote:

  Eric Bavier ericbav...@gmail.com skribis:
 
  * gnu/packages/gtk.scm (python2-pygtk): New variable.
 

 I notice that most python packages are defined for python 3 and then a
 python2 package is generated with the procedure 'package-with-python2'.
 Is pygtk problematic with python 3?


It has been a while since I did the packaging work for this python2-pygtk,
and I seem to recall that there was some sort of difficulty with python3.


 I would be interested in using it
 with a package for matplotlib that I'm preparing.


I will take another look at it, being that it would be useful to you.

Thanks for asking,
`~Eric

-- 
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html


Re: Containers on Guix

2014-11-22 Thread Ian Denhardt
Quoting David Thompson (2014-11-19 21:34:49)
 I did some reading about how Docker creates containers and discovered
 that it uses systemd-nspawn[0] to do it.  Since Guix uses dmd, using
 systemd-nspawn isn't an option.  Does anyone have thoughts on how we
 might have similar functionality in the Guix distro?


I'm not so sure that docker actually needs systemd -- the docker
documentation has instructions for a number of systems that don't use
systemd. A quick scan suggests they're using lxc, at least on some
systems.
 
 Would an nspawn equivalent be appropriate for dmd?  Or a completely
 separate program?  This seems to be a Linux only feature, so if we added
 a container creation program, would it make it harder to support the
 Hurd?

I'm sure there are other things already packaged that don't really have
any hope of working on top of another kernel. This is going to be hard
to do portably, but I don't think it's worth worrying about too much
yet. Probably some work will have to happen upstream on the Hurd
project.


signature.asc
Description: signature


Re: core-updates is back

2014-11-22 Thread John Darrington
On Sat, Nov 22, 2014 at 01:01:05PM +0100, Ludovic Courtès wrote:
 Hello!
 
 ‘core-updates’ is open again for updates to core packages (the implicit
 inputs of ‘gnu-build-system’), their dependencies, or the (guix build …)
 modules.
 
 Things I’d like to see in this branch include:

 [...]
 
 Other ideas welcome.

There is some oddness in cross-pkg-config: It creates a symlink to the real 
pkg-config,
But does not do so for the pkg.m4 file.  
I think the symlink is wrong anyway, since in the build environment the symlink 
target 
will not exist.

Unfortunately, since almost everything depends on pkg-config this is hard to 
test.

J'


 
 

-- 
PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.



signature.asc
Description: Digital signature


Re: [PATCH 1/2] gnu: Add numpy

2014-11-22 Thread Ludovic Courtès
Federico Beffa be...@ieee.org skribis:

 In the mean time version 1.9.1 was released.  With this release I
 noticed that the pdf documentation gets updated and therefore the hash
 changes and breaks the package.

Oh, OK.

 For this reason I think that, as you suggested before, we should build
 the documentation locally.  As mentioned before, this requires
 matplotlib and matplotlib requires numpy.  So I will make a numpy
 package without documentation and use it as input to matplotlib as you
 suggested.  I'm thinking of calling this 'numpy-bootstrap' and of not
 exporting it (use 'define' instead of 'define-public').  I now got
 matplotlib building and able to generate its own documentation, but
 would like to add the pygtk backend before supplying a patch for
 review.

Sounds like a good plan.

Thanks,
Ludo’.



Re: [PATCH] gnu: Add rtorrent and libtorrent.

2014-11-22 Thread Ludovic Courtès
David Thompson dthomps...@worcester.edu skribis:

 The new patches look good to me.  Let's see what Ludo thinks.  :)

Yep, please push.

More reviewers is better, so thanks for handling this one!  :-)

Ludo’.



Re: [PATCH] gnu: atlas: Try to fix build on MIPS.

2014-11-22 Thread Ludovic Courtès
Federico Beffa be...@ieee.org skribis:

 I would like to propose the attached patch to try to fix the MIPS
 package.  I'm not sure if this really help, but I do not have a way to
 test it locally.

The change makes sense, so I think it’s OK to commit it and see what
happens.  Mark or some other MIPS user can always chime in anytime.

 From 64235b3012ebf6ac337a8615dd91ae08beb95180 Mon Sep 17 00:00:00 2001
 From: Federico Beffa be...@fbengineering.ch
 Date: Sat, 22 Nov 2014 16:42:41 +0100
 Subject: [PATCH] gnu: atlas: Try to fix build on MIPS.

 * gnu/packages/maths.scm (atlas): Add MIPS specific configure flags.

[...]

 + ;; Probe is failing for MIPS.  We therefore define the system
 + ;; architecture explicitly by setting (-A) MACHINETYPE = 49
 + ;; 'MIPSR1xK' and (-V) ISA = 1 'none'.
 + ,,@(when (string-prefix? mips (%current-system))
 +  (list -A 49 -V 1))

This should be an ‘if’:

  (if (string-prefix? ...)
  ...
  '())

You can check on Intel that this modification doesn’t change the result
of the ‘guix build atlas’.

OK to push afterwards.

Thank you,
Ludo’.



Re: Containers on Guix

2014-11-22 Thread Ludovic Courtès
Ian Denhardt i...@zenhack.net skribis:

 I'm sure there are other things already packaged that don't really have
 any hope of working on top of another kernel.

I think packages that are Linux-specific by design are all in (gnu
packages linux).

 This is going to be hard to do portably, but I don't think it's worth
 worrying about too much yet.

Yes, agreed.

 Probably some work will have to happen upstream on the Hurd project.

The Hurd supports fine-grain virtualization, so it wouldn’t be hard to
do (“sub-hurds” correspond to completely isolated containers, launching
a separate ‘proc’ server gives you a separate PID name space, etc.)

Thanks,
Ludo’.



Re: core-updates is back

2014-11-22 Thread Ludovic Courtès
John Darrington j...@darrington.wattle.id.au skribis:

 There is some oddness in cross-pkg-config: It creates a symlink to the real 
 pkg-config,
 But does not do so for the pkg.m4 file.  

Why would the missing pkg.m4 be a problem?  It’s only used when
bootstrapping Autoconf-based packages.

(And if it’s really needed, it’s easy to add that symlink.)

 I think the symlink is wrong anyway, since in the build environment the 
 symlink target 
 will not exist.

Of course it exists!

--8---cut here---start-8---
$ guix build 
/gnu/store/y634jqapqxs6ajzifx0shd8w7iaf9yrc-pkg-config-mips64el-linux-gnu-0.27.1.drv
The following file will be downloaded:
   
/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1
@ substituter-started 
/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1
 
/gnu/store/fkq63515pz3l8bdyi6qhchb9pida7pzp-guix-0.8.47739f5/libexec/guix/substitute-binary
found valid signature for 
'/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1',
 from 
'http://hydra.gnu.org/nar/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1'
downloading 
`/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1'
 (0.0 MiB installed)...
http://hydra.gnu.org/nar/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1
 0.2 KiB transferred@ substituter-succeeded 
/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1
/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1

$ ls -l 
/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1/bin/
total 4
lrwxrwxrwx 2 root root 76  1 janv.  1970 mips64el-linux-gnu-pkg-config - 
/gnu/store/s432k19icqqjchfp83klghv3p07q5hdd-pkg-config-0.27.1/bin/pkg-config

$ guix gc --references 
/gnu/store/9ycjrm4n6w4ar740vsxlacbd2x5s3khr-pkg-config-mips64el-linux-gnu-0.27.1
/gnu/store/s432k19icqqjchfp83klghv3p07q5hdd-pkg-config-0.27.1
--8---cut here---end---8---

Thanks,
Ludo’.



Re: Advice needed on gcc error

2014-11-22 Thread Saul Hazledine

Hello Ludo,

On 21/11/14 10:21, Ludovic Courtès wrote:

Could you post, say, the last 200 lines of its build log?  One way to
find it is to run:

   ls -lrt /var/log/guix/drvs/*/*gcc-4.8.3*

and then open the most recent one.



Thank you very much for your offer of help. I have the problem that I 
cannot login to the machine over ssh to get the log file. I have 
installed both openssh and lsh (using hydra) but I cannot find an ssh 
daemon.


I have also added (use-modules (gnu services ssh)) to /etc/config.scm 
and ran  'guix system reconfigure' but no ssh daemon is started.


I totally understand if you do not want to take up time trying to solve 
newbie errors. However, my hope is that these problems provide useful 
information for guix development.


Many thanks
Saul




Re: core-updates is back

2014-11-22 Thread John Darrington
On Sat, Nov 22, 2014 at 06:36:47PM +0100, Ludovic Courtès wrote:
 John Darrington j...@darrington.wattle.id.au skribis:
 
  There is some oddness in cross-pkg-config: It creates a symlink to the 
real pkg-config,
  But does not do so for the pkg.m4 file.  
 
 Why would the missing pkg.m4 be a problem?  It’s only used when
 bootstrapping Autoconf-based packages.

Right.  If you want to bootstrap an autoconf based package (for example, 
guix-devel from package-management.scm),
then it will fail.
 
 (And if it’s really needed, it’s easy to add that symlink.)
 
 
 Of course it exists!

I thought that whilst bulding things were in a chroot jail where only those 
things explicitly declared as inputs
actually existed.

J'
 

-- 
PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.



signature.asc
Description: Digital signature


Re: Gegl build failures

2014-11-22 Thread Ludovic Courtès
Andreas Enge andr...@enge.fr skribis:

 gegl, an input for gimp, fails its tests:
http://hydra.gnu.org/build/159641/nixlog/1/tail-reload

 We already have the following comments in the package:
   ;; This test program seems to crash on exit. Specifically, whilst
   ;; g_object_unreffing bufferA and bufferB - This seems to be a bug
   ;; in the destructor.  This is just a test program so will not have
   ;; any wider effect, although might be hiding another problem.
   ;; According to advice received on irc.gimp.org#gegl although 0.2.0
   ;; is the latest released version, any bug reports against it will
   ;; be ignored.  So we are on our own.
 before a line that removes one test. I would suggest to disable all tests.

That sounds reasonable, but since John did the initial investigation and
discussed with GEGL people, I’d like to know what he thinks.

Thanks,
Ludo’.



Re: Gegl build failures

2014-11-22 Thread John Darrington
On Sat, Nov 22, 2014 at 07:05:11PM +0100, Ludovic Court??s wrote:
 Andreas Enge andr...@enge.fr skribis:
 
  gegl, an input for gimp, fails its tests:
 http://hydra.gnu.org/build/159641/nixlog/1/tail-reload
 
  We already have the following comments in the package:
;; This test program seems to crash on exit. Specifically, 
whilst
;; g_object_unreffing bufferA and bufferB - This seems to be a 
bug
;; in the destructor.  This is just a test program so will not 
have
;; any wider effect, although might be hiding another problem.
;; According to advice received on irc.gimp.org#gegl although 
0.2.0
;; is the latest released version, any bug reports against it 
will
;; be ignored.  So we are on our own.
  before a line that removes one test. I would suggest to disable all 
tests.
 
 That sounds reasonable, but since John did the initial investigation and
 discussed with GEGL people, I???d like to know what he thinks.
 

Yeah, I can't think of a better idea at the moment.

J'

-- 
PGP Public key ID: 1024D/2DE827B3 
fingerprint = 8797 A26D 0854 2EAB 0285  A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.



signature.asc
Description: Digital signature


Re: Howto run guix.el correctly?

2014-11-22 Thread Alex Kost
Adam Pribyl (2014-11-22 01:28 +0300) wrote:

 I have folloed the instruction in
 http://www.gnu.org/software/guix/manual/guix.html#Emacs-Interface
 to get the emacs interface for guix, but there is something missing
 probably.

 Installation of emacs and geiser was OK, I changed the path to guix.el
 (there is no /usr/share/ in my guix installation, I had to find guix.el
 in the /gnu/store), after that I can start emacs and M-x guix-... but
 every action says Cannot open load file: no such file or directory
 geiser-mode.

If you mean you did (add-to-list 'load-path /gnu/store/...), then it's
definitely not right.

 There should probably be also the geiser path in the emacs init file or
 something?

I assume you use a Guix (or GNU or whatever it should be called)
system.  I must admit I have not tried it yet, and all I know about
setting guix.el there I learnt from a chat with davexunit on #guix
today.

So I think the following should be added to your emacs config:

- Add dirs with guix.el and geiser to load-path (I'm absolutely
  not sure about the correctness of the paths, so double check please):

  (add-to-list 'load-path /run/current-system/profile/share/emacs/site-lisp/)
  (add-to-list 'load-path ~/.guix-profile/share/emacs/site-lisp)

- Initial setup of geiser:

  (require 'geiser-install)

- Initial setup of guix:

  (require 'guix-init)

-- 
Alex



Re: core-updates is back

2014-11-22 Thread Ludovic Courtès
John Darrington j...@darrington.wattle.id.au skribis:

 On Sat, Nov 22, 2014 at 06:36:47PM +0100, Ludovic Courtès wrote:
  John Darrington j...@darrington.wattle.id.au skribis:
  
   There is some oddness in cross-pkg-config: It creates a symlink to the 
 real pkg-config,
   But does not do so for the pkg.m4 file.  
  
  Why would the missing pkg.m4 be a problem?  It’s only used when
  bootstrapping Autoconf-based packages.

 Right.  If you want to bootstrap an autoconf based package (for example, 
 guix-devel from package-management.scm),
 then it will fail.

Oh right, this one is a good example.  I’ll add the symlink.

  (And if it’s really needed, it’s easy to add that symlink.)
  
  
  Of course it exists!

 I thought that whilst bulding things were in a chroot jail where only those 
 things explicitly declared as inputs
 actually existed.

More precisely, the inputs *and* their run-time dependencies are
available.

For instance, if a package has Coreutils as an input, then its build
process gets both Coreutils and libc in its chroot (otherwise the
Coreutils programs would be unusable.)

Ludo’.



Re: Advice needed on gcc error

2014-11-22 Thread Ludovic Courtès
Saul Hazledine s...@alienscience.org.uk skribis:

 Thank you very much for your offer of help. I have the problem that I
 cannot login to the machine over ssh to get the log file. I have
 installed both openssh and lsh (using hydra) but I cannot find an ssh
 daemon.

 I have also added (use-modules (gnu services ssh)) to /etc/config.scm
 and ran  'guix system reconfigure' but no ssh daemon is started.

You need to add a call to ‘lsh-service’ in the ‘services’ field of the
configuration, similar to what is shown at
http://www.gnu.org/software/guix/manual/guix.html#Using-the-Configuration-System.

Also, ATM it is necessary to reboot after ‘reconfigure’ for new services
to be started (that limitation will be removed hopefully soon.)

 I totally understand if you do not want to take up time trying to
 solve newbie errors. However, my hope is that these problems provide
 useful information for guix development.

It’s definitely useful!

Thanks,
Ludo’.



Re: Advice needed on gcc error

2014-11-22 Thread Adam Pribyl

On Sat, 22 Nov 2014, Ludovic Courtès wrote:


Saul Hazledine s...@alienscience.org.uk skribis:


Thank you very much for your offer of help. I have the problem that I
cannot login to the machine over ssh to get the log file. I have
installed both openssh and lsh (using hydra) but I cannot find an ssh
daemon.

I have also added (use-modules (gnu services ssh)) to /etc/config.scm
and ran  'guix system reconfigure' but no ssh daemon is started.


You need to add a call to ‘lsh-service’ in the ‘services’ field of the
configuration, similar to what is shown at


http://www.gnu.org/software/guix/manual/guix.html#Using-the-Configuration-System.


Also, ATM it is necessary to reboot after ‘reconfigure’ for new services
to be started (that limitation will be removed hopefully soon.)


This is exactly the same thing I am triing to achieve. But the lsh-service
(ssh-daemon) has a dependency on the networking service, which I am not
able to provide - this is the reason why I did add also a
dhcp-client-service, but it seems to not work, as there is no network even
after reconfigure and reboot.

deco status dmd
Started: (nscd file-system-/dev/shm dmd host-name term-tty1 loopback
guix-daemon console-font-tty1 root-file-system user-unmount term-tty4
term-tty5 udev term-tty6 term-tty2 term-tty3 user-processes
console-font-tty4 console-font-tty5 console-font-tty6 console-font-tty2
console-font-tty3 file-system-/dev/pts syslogd)
Stopped: (ssh-daemon)

Obviously:
deco status networking
No service at all providing networking.


I totally understand if you do not want to take up time trying to
solve newbie errors. However, my hope is that these problems provide
useful information for guix development.


It’s definitely useful!

Thanks,
Ludo’.



Adam Pribyl


Re: Howto run guix.el correctly?

2014-11-22 Thread David Thompson
Adam Pribyl pri...@lowlevel.cz writes:

 (add-to-list 'load-path 
 /gnu/store/ysh4fvnxr0p8xrphcikivpafgvf6g18m-guix-0.8/share/emacs/site-lisp/)
 (add-to-list 'load-path ~/.guix-profile/share/emacs/site-lisp)
 (require 'geiser-install)
 (require 'guix-init)

 Reason for the /gnu/store path is, that guix.el is a part of guix and I 
 did not found it in any profile. I've added my profile path, where the 
 geiser is (as it is installed by this user), but the /run/current-system 
 has no share/emacs at all. I do not know why.

 While I got further, it is still somewhat confused as invoking 
 guix-all-available-packages results in 
 error in process sentinel: Text is read-only
 No prompt found!

I am experiencing the exact same issue.  If you check *Guix REPL*,
you'll see that compiling 'guix-main.scm' fails for some reason.  Not
sure why.  I gave up on it for now.

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



Re: [PATCH] gnu: Add rtorrent and libtorrent.

2014-11-22 Thread Taylan Ulrich Bayırlı/Kammer
Please use this patch for the rTorrent one; gcrypt was a redundant
dependency after all.

From 0cf93793fcdf4f7c8250cc02899a0caf68636df3 Mon Sep 17 00:00:00 2001
From: Taylan Ulrich B taylanbayi...@gmail.com
Date: Sat, 22 Nov 2014 15:57:26 +0100
Subject: [PATCH 2/2] gnu: Add rTorrent.

* gnu/packages/bittorrent.scm (rtorrent): New variable.
---
 gnu/packages/bittorrent.scm | 34 +-
 1 file changed, 33 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/bittorrent.scm b/gnu/packages/bittorrent.scm
index 022eb4e..067c2ac 100644
--- a/gnu/packages/bittorrent.scm
+++ b/gnu/packages/bittorrent.scm
@@ -31,7 +31,10 @@
 #:select (zlib))
   #:use-module (gnu packages glib)
   #:use-module (gnu packages gtk)
-  #:use-module (gnu packages check))
+  #:use-module (gnu packages check)
+  #:use-module (gnu packages ncurses)
+  #:use-module (gnu packages curl)
+  #:use-module (gnu packages cyrus-sasl))
 
 (define-public transmission
   (package
@@ -120,3 +123,32 @@ with the BitTorrent client rtorrent.  It is written in C++ with emphasis on
 speed and efficiency.)
 (home-page http://libtorrent.rakshasa.no/;)
 (license l:gpl2)))
+
+(define-public rtorrent
+  (package
+(name rtorrent)
+(version 0.9.4)
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+http://libtorrent.rakshasa.no/downloads/rtorrent-;
+version .tar.gz))
+  (sha256
+   (base32
+113yrrac75vqi4g8r6bgs0ggjllj9bkg9shv08vqzdhkwqg2q2mw
+(build-system gnu-build-system)
+(inputs `((libtorrent ,libtorrent)
+  (ncurses ,ncurses)
+  (curl ,curl)
+  (cyrus-sasl ,cyrus-sasl)
+  (openssl ,openssl)
+  (zlib ,zlib)))
+(native-inputs `((pkg-config ,pkg-config)
+ (cppunit ,cppunit)))
+(synopsis BitTorrent client with ncurses interface)
+(description
+ rTorrent is a BitTorrent client with an ncurses interface.  It supports
+full encryption, DHT, PEX, and Magnet Links.  It can also be controlled via
+XML-RPC over SCGI.)
+(home-page http://libtorrent.rakshasa.no/;)
+(license l:gpl2)))
-- 
2.1.2



Re: Advice needed on gcc error

2014-11-22 Thread Ludovic Courtès
Adam Pribyl pri...@lowlevel.cz skribis:

 This is exactly the same thing I am triing to achieve. But the lsh-service
 (ssh-daemon) has a dependency on the networking service, which I am not
 able to provide - this is the reason why I did add also a
 dhcp-client-service, but it seems to not work, as there is no network even
 after reconfigure and reboot.

 deco status dmd
 Started: (nscd file-system-/dev/shm dmd host-name term-tty1 loopback
 guix-daemon console-font-tty1 root-file-system user-unmount term-tty4
 term-tty5 udev term-tty6 term-tty2 term-tty3 user-processes
 console-font-tty4 console-font-tty5 console-font-tty6 console-font-tty2
 console-font-tty3 file-system-/dev/pts syslogd)
 Stopped: (ssh-daemon)

 Obviously:
 deco status networking
 No service at all providing networking.

Could you post your configuration?

I have something like this:

--8---cut here---start-8---
  (services (cons* (slim-service)

   (avahi-service)
   (dbus-service (list avahi))

   ;; [...]

   (lsh-service #:root-login? #t)
   (dhcp-client-service)

   %base-services))
--8---cut here---end---8---

and ‘deco status networking’ shows the actual service.

Thanks,
Ludo’.



Re: Howto run guix.el correctly?

2014-11-22 Thread Ludovic Courtès
David Thompson dthomps...@worcester.edu skribis:

 I am experiencing the exact same issue.  If you check *Guix REPL*,
 you'll see that compiling 'guix-main.scm' fails for some reason.  Not
 sure why.  I gave up on it for now.

Can you try ,bt and ,error in there?

Most likely, either Geiser’s or Guix’s Scheme modules are not in the
search path when the REPL is started.  I had to fiddle with
‘geiser-scheme-dir’ and ‘geiser-guile-load-path’.

Ludo’.



[PATCH 2/4] guix build: Add --max-jobs option (without handling code).

2014-11-22 Thread Deck Pickard
* doc/guix.texi: Mention in the docs.
* guix/scripts/build.scm: Extend (show-build-options-help) and
(%standard-build-options) functions.
---
doc/guix.texi | 5 +
guix/scripts/build.scm | 14 --
2 files changed, 17 insertions(+), 2 deletions(-)

diff --git a/doc/guix.texi b/doc/guix.texi
index 2a33cb5..02edee0 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -2676,6 +2676,11 @@ may be helpful when debugging setup issues with the
build daemon.
Allow the use of up to @var{n} CPU cores for the build. The special
value @code{0} means to use as many CPU cores as available.

+@item --max-jobs=@var{n}
+@itemx -M @var{n}
+Allow at most @var{n} build jobs. The special value @code{0} means to
+create as many jobs as the number of available CPU cores.
+
@end table

Behind the scenes, @command{guix build} is essentially an interface to
diff --git a/guix/scripts/build.scm b/guix/scripts/build.scm
index 7b7f419..d10b95b 100644
--- a/guix/scripts/build.scm
+++ b/guix/scripts/build.scm
@@ -119,7 +119,9 @@ options handled by
'set-build-options-from-command-line', and listed in
(display (_ 
--verbosity=LEVEL use the given verbosity LEVEL))
(display (_ 
- -c, --cores=N allow the use of up to N CPU cores for the build)))
+ -c, --cores=N allow the use of up to N CPU cores for the build))
+ (display (_ 
+ -M, --max-jobs=N allow at most N build jobs)))

(define (set-build-options-from-command-line store opts)
Given OPTS, an alist as returned by 'args-fold' given
@@ -192,7 +194,15 @@ options handled by
'set-build-options-from-command-line', and listed in
(let ((c (false-if-exception (string-number arg
(if c
(apply values (alist-cons 'cores c result) rest)
- (leave (_ ~a: not a number~%) arg)))
+ (leave (_ not a number: '~a' option argument: ~a~%)
+ name arg)
+ (option '(#\M max-jobs) #t #f
+ (lambda (opt name arg result . rest)
+ (let ((c (false-if-exception (string-number arg
+ (if c
+ (apply values (alist-cons 'max-jobs c result) rest)
+ (leave (_ not a number: '~a' option argument: ~a~%)
+ name arg)))

;;;
-- 
2.1.2


[PATCH 1/4] store: default to serial scheduler

2014-11-22 Thread Deck Pickard
* guix/store.scm (set-build-options): exchange default argument values
---
guix/store.scm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/guix/store.scm b/guix/store.scm
index bc4c641..571cc06 100644
--- a/guix/store.scm
+++ b/guix/store.scm
@@ -435,14 +435,14 @@ encoding conversion errors.
(define* (set-build-options server
#:key keep-failed? keep-going? fallback?
(verbosity 0)
- (max-build-jobs (current-processor-count))
+ (max-build-jobs 1)
timeout
(max-silent-time 3600)
(use-build-hook? #t)
(build-verbosity 0)
(log-type 0)
(print-build-trace #t)
- (build-cores 1)
+ (build-cores (current-processor-count))
(use-substitutes? #t)
(binary-caches '())) ; client untrusted cache URLs
;; Must be called after `open-connection'.
-- 
2.1.2


[PATCH 4/4] guix build: Try to handle --cores and --max-jobs in a sane way.

2014-11-22 Thread Deck Pickard
* guix/scripts/build.scm (set-build-options-from-command-line): use
make-schedule-sane to parse and set scheduling options.
---
guix/scripts/build.scm | 24 ++--
1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/guix/scripts/build.scm b/guix/scripts/build.scm
index d10b95b..31f17d2 100644
--- a/guix/scripts/build.scm
+++ b/guix/scripts/build.scm
@@ -20,6 +20,7 @@
(define-module (guix scripts build)
#:use-module (guix ui)
#:use-module (guix store)
+ #:use-module (guix schedule)
#:use-module (guix derivations)
#:use-module (guix packages)
#:use-module (guix utils)
@@ -127,16 +128,19 @@ options handled by
'set-build-options-from-command-line', and listed in
Given OPTS, an alist as returned by 'args-fold' given
'%standard-build-options', set the corresponding build options on STORE.
;; TODO: Add more options.
- (set-build-options store
- #:keep-failed? (assoc-ref opts 'keep-failed?)
- #:build-cores (or (assoc-ref opts 'cores) 0)
- #:fallback? (assoc-ref opts 'fallback?)
- #:use-substitutes? (assoc-ref opts 'substitutes?)
- #:use-build-hook? (assoc-ref opts 'build-hook?)
- #:max-silent-time (assoc-ref opts 'max-silent-time)
- #:timeout (assoc-ref opts 'timeout)
- #:print-build-trace (assoc-ref opts 'print-build-trace?)
- #:verbosity (assoc-ref opts 'verbosity)))
+ (let ((sched (make-schedule-sane #:max-cores (assoc-ref opts 'cores)
+ #:max-jobs (assoc-ref opts 'max-jobs
+ (set-build-options store
+ #:keep-failed? (assoc-ref opts 'keep-failed?)
+ #:build-cores (schedule-max-cores sched)
+ #:max-build-jobs (schedule-max-jobs sched)
+ #:fallback? (assoc-ref opts 'fallback?)
+ #:use-substitutes? (assoc-ref opts 'substitutes?)
+ #:use-build-hook? (assoc-ref opts 'build-hook?)
+ #:max-silent-time (assoc-ref opts 'max-silent-time)
+ #:timeout (assoc-ref opts 'timeout)
+ #:print-build-trace (assoc-ref opts 'print-build-trace?)
+ #:verbosity (assoc-ref opts 'verbosity

(define %standard-build-options
;; List of standard command-line options for tools that build something.
-- 
2.1.2


[PATCH 3/4] guix: Add schedule module.

2014-11-22 Thread Deck Pickard
* guix/schedule.scm: New file. To handle --cores and --max-jobs
options in 'guix build'.
* Makefile.am (MODULES): Add *this.
---
Makefile.am | 1 +
guix/schedule.scm | 102
++
2 files changed, 103 insertions(+)
create mode 100644 guix/schedule.scm

diff --git a/Makefile.am b/Makefile.am
index 5c4ce90..1806a05 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -56,6 +56,7 @@ MODULES = \
guix/ftp-client.scm \
guix/http-client.scm \
guix/gnupg.scm \
+ guix/schedule.scm \
guix/store.scm \
guix/svn-download.scm \
guix/ui.scm \
diff --git a/guix/schedule.scm b/guix/schedule.scm
new file mode 100644
index 000..26c7b6b
--- /dev/null
+++ b/guix/schedule.scm
@@ -0,0 +1,102 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2014 Nebulieu nebu@kipple
+;;;
+;;; 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 http://www.gnu.org/licenses/.
+
+(define-module (guix schedule)
+ #:use-module (guix records)
+ #:export (schedule?
+ schedule
+ schedule-name
+ schedule-max-cores
+ schedule-max-jobs
+ schedule-override-cores?
+ schedule-override-jobs?
+
+ make-schedule-sane))
+
+(define-record-type* schedule
+ schedule make-schedule
+ schedule?
+ (name schedule-name ; symbol
+ (default 'serial))
+ (max-cores schedule-max-cores ; non-negative integer
+ (default 0)) ; use all available horse-power
+ (max-jobs schedule-max-jobs ; non-negative integer
+ (default 1)) ; there can be only one
+ ;; unused, for now, rethink unified override
+ (override-cores? schedule-override-cores? ; boolean
+ (default #t))
+ (override-jobs? schedule-override-jobs? ; boolean
+ (default #t)))
+
+; will rather need one `make-schedule-with-name` and switch on 'symbol
+(define (make-schedule-serial)
+ (schedule))
+; redundant for now...
+
+; macro?
+(define (real-schedule symname cores jobs
+ override-c override-j)
+ (schedule
+ (name symname)
+ (max-cores cores)
+ (max-jobs jobs)
+ (override-cores? override-c)
+ (override-jobs? override-j)))
+
+; better name?
+(define (1 num)
+ (if ( num 1)
+ 1
+ num))
+
+;; TODO: increase number of jobs with spare cores??? perhaps in
real-schedule
+(define* (make-schedule-sane #:key max-cores max-jobs)
+ (let ((sym-name 'serial-sane)
+ ;; should overriding one override both (think: yes, e.g.
+ ;; setting cores to max with guix-daemon default [max-jobs = 0]
+ ;; will again lead to the N^2 phenomenon...
+ (override-cores (and max-cores #t))
+ (override-jobs (and max-jobs #t))
+ ;; scheduling needs be centralized (think: override always)
+ (max-threads (min (current-processor-count)
+ (total-processor-count
+ (let ((default-max-cores (1 (- max-threads 1)))
+ (default-max-jobs 1)
+ (validate (lambda (arg default)
+ (if (or (not arg)
+ (not (integer? arg)))
+ default
+ (or (and (= arg 0) max-threads)
+ (and ( arg 0) default)
+ arg)
+ ;; perhaps we shouldn't be so symmetrical?
+ (let ((cores (validate max-cores default-max-cores))
+ (jobs (validate max-jobs default-max-jobs)))
+ ;; cut-off
+ (let loop ((c (min cores max-threads))
+ (j (min jobs max-threads)))
+ (let ((threads (* c j)))
+ (if (= threads max-threads)
+ (real-schedule sym-name c j
+ override-cores override-jobs)
+ ;; maximize cores at the cost of jobs...
+ (let ((j- (1 (- j 1
+ (if (= (* c j-) max-threads)
+ (real-schedule sym-name c j-
+ override-cores override-jobs)
+ (loop (1 (- c 1)) j-))
-- 
2.1.2


[PATCH 0/4] Fix 'guix build' local overheating

2014-11-22 Thread Deck Pickard
Aka No, Laptot, no fry...

nebuli (4):
store: default to serial scheduler
guix build: Add --max-jobs option (without handling code).
guix: Add schedule module.
guix build: Try to handle --cores and --max-jobs in a sane way.

Makefile.am | 1 +
doc/guix.texi | 5 +++
guix/schedule.scm | 102 +
guix/scripts/build.scm | 38 --
guix/store.scm | 4 +-
5 files changed, 136 insertions(+), 14 deletions(-)
create mode 100644 guix/schedule.scm

-- 
2.1.2


Re: [PATCH] gnu: Add Tiled

2014-11-22 Thread iyzsong
Andreas Enge andr...@enge.fr writes:

 The problem should now be fixed in 5dee80d. I tried to enter something
 in the file open dialog of tiled, and it worked.
Great!

 Andreas



[PATCH] gnu: Add getmail

2014-11-22 Thread 宋文武
From b26fe8c0c4f6517cfacedc6cfd48441c4aaa28dd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= iyzs...@gmail.com
Date: Sun, 23 Nov 2014 13:07:42 +0800
Subject: [PATCH] gnu: Add getmail.

* gnu/packages/mail.scm (getmail): New variable.
---
 gnu/packages/mail.scm | 26 ++
 1 file changed, 26 insertions(+)

diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
index 46c2409..cb16663 100644
--- a/gnu/packages/mail.scm
+++ b/gnu/packages/mail.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2013, 2014 Ludovic Courtès l...@gnu.org
 ;;; Copyright © 2014 Mark H Weaver m...@netris.org
 ;;; Copyright © 2014 Ian Denhardt i...@zenhack.net
+;;; Copyright © 2014 Sou Bunnbu iyzs...@gmail.com
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -365,4 +366,29 @@ attachments, create new maildirs, and so on.)
 ing, and tagging large collections of email messages.)
 (license gpl3+)))
 
+(define-public getmail
+  (package
+(name getmail)
+(version 4.46.0)
+(source
+ (origin
+   (method url-fetch)
+   (uri (string-append http://pyropus.ca/software/getmail/old-versions/;
+   name - version .tar.gz))
+   (sha256
+(base32
+ 15rqmm25pq6ll8aaqh8h6pfdkpqs7y6yismb3h3w1bz8j292c8zl
+(build-system python-build-system)
+(arguments
+ `(#:tests? #f ; no tests
+   #:python ,python-2))
+(home-page http://pyropus.ca/software/getmail/;)
+(synopsis Mail retriever)
+(description
+ A flexible, extensible mail retrieval system with support for
+POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
+arbitrary message filtering, single-user and domain-mailboxes, and many other
+useful features.)
+(license gpl2)))
+
 ;;; mail.scm ends here
-- 
2.1.2




Re: [PATCH] gnu: Add getmail

2014-11-22 Thread 宋文武
宋文武 iyzs...@gmail.com writes:

 From b26fe8c0c4f6517cfacedc6cfd48441c4aaa28dd Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= iyzs...@gmail.com
 Date: Sun, 23 Nov 2014 13:07:42 +0800
 Subject: [PATCH] gnu: Add getmail.

 * gnu/packages/mail.scm (getmail): New variable.
 ---
  gnu/packages/mail.scm | 26 ++
  1 file changed, 26 insertions(+)

 diff --git a/gnu/packages/mail.scm b/gnu/packages/mail.scm
 index 46c2409..cb16663 100644
 --- a/gnu/packages/mail.scm
 +++ b/gnu/packages/mail.scm
 @@ -2,6 +2,7 @@
  ;;; Copyright © 2013, 2014 Ludovic Courtès l...@gnu.org
  ;;; Copyright © 2014 Mark H Weaver m...@netris.org
  ;;; Copyright © 2014 Ian Denhardt i...@zenhack.net
 +;;; Copyright © 2014 Sou Bunnbu iyzs...@gmail.com
  ;;;
  ;;; This file is part of GNU Guix.
  ;;;
 @@ -365,4 +366,29 @@ attachments, create new maildirs, and so on.)
  ing, and tagging large collections of email messages.)
  (license gpl3+)))
  
 +(define-public getmail
 +  (package
 +(name getmail)
 +(version 4.46.0)
 +(source
 + (origin
 +   (method url-fetch)
 +   (uri (string-append http://pyropus.ca/software/getmail/old-versions/;
 +   name - version .tar.gz))
 +   (sha256
 +(base32
 + 15rqmm25pq6ll8aaqh8h6pfdkpqs7y6yismb3h3w1bz8j292c8zl
 +(build-system python-build-system)
 +(arguments
 + `(#:tests? #f ; no tests
 +   #:python ,python-2))
 +(home-page http://pyropus.ca/software/getmail/;)
 +(synopsis Mail retriever)
 +(description
 + A flexible, extensible mail retrieval system with support for
 +POP3, IMAP4, SSL variants of both, maildirs, mboxrd files, external MDAs,
 +arbitrary message filtering, single-user and domain-mailboxes, and many other
 +useful features.)
 +(license gpl2)))
 +
Sorry for the trailing whitespace here.
  ;;; mail.scm ends here
 -- 
 2.1.2



Re: Howto run guix.el correctly?

2014-11-22 Thread Alex Kost
Ludovic Courtès (2014-11-23 01:17 +0300) wrote:

 David Thompson dthomps...@worcester.edu skribis:

 I am experiencing the exact same issue.  If you check *Guix REPL*,
 you'll see that compiling 'guix-main.scm' fails for some reason.  Not
 sure why.  I gave up on it for now.

 Can you try ,bt and ,error in there?

IIUC the REPL is dead, so what can be done is sending the full contents
of *Guix REPL* buffer here so we could look at it.

 Most likely, either Geiser’s or Guix’s Scheme modules are not in the
 search path when the REPL is started.  I had to fiddle with
 ‘geiser-scheme-dir’ and ‘geiser-guile-load-path’.

No need to fiddle with ‘geiser-scheme-dir’: it should be set properly if
you have ‘(require 'geiser-install)’ in your emacs config.

Also you made a commit for ‘geiser-guile-load-path’ (a1ca1b7) after the
release, so fiddling with this var will not take any effect.

David wrote on #guix that he has ~/.guile file with some additional
settings.  AFAICT it is loaded only if ‘geiser-guile-load-init-file-p’
was set to a non-nil value.

-- 
Alex