Re: Git-style aliases in Guix?

2017-02-26 Thread John Darrington
On Sun, Feb 26, 2017 at 10:15:10PM +0100, Mekeor Melire wrote:

 Concerning how to implement this alias feature within Guix, I'd first
 like to pose a much broader question. So, on GuixSD you have a
 configuration, written in Scheme, for your operating system. Couldn't we
 make Guix have a scheme-configuration file for itself, as well?
 

We do.  guix/config.scm

-- 
Avoid eavesdropping.  Send strong encrypted email.
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: Git-style aliases in Guix?

2017-02-26 Thread Mekeor Melire

I'd also like to have some Guix aliases. In Git, you can define aliases
like so:

 # define new alias
 $ git config --global alias.i init
 # use new alias
 $ git i

Personally, I'd prefer to type `guix p -i` for `guix package -i`.
Anyway.


Concerning how to implement this alias feature within Guix, I'd first
like to pose a much broader question. So, on GuixSD you have a
configuration, written in Scheme, for your operating system. Couldn't we
make Guix have a scheme-configuration file for itself, as well?


Alex Griffin  writes:

> I think it would be cool and useful if Guix had some kind of config file
> where users could define new commands or aliases, as in git. I'm sure
> many people here already have their own helper code to work witk Guix,
> whether that's in shell scripts, bashrc, guile, elisp, etc. And it would
> make it easier to experiment with changing the command line syntax
> without committing to any change too soon.
>
> I've attached my own Guix wrapper function to show some use cases, like:
>
> # New features
> * automatically invoke `./pre-inst-env` when ~/.config/guix/latest
> points to a git repo
> * `guix make` builds Guix in your git checkout directory
> * `guix clean` cleans out your Guix git checkout
> * `guix visit ` opens a package's homepage in a browser
> * `guix ls` lists the files in a Guix package (must be present or built
> on your machine)
>
> # Convenience Commands
> * `guix search` wraps `guix package -s` with a recutils template
> * `guix manifest` -> guix package --manifest=~/.config/guix/profile.scm
> * `guix reconfigure` -> sudo guix system reconfigure
> ~/.config/guix/system.scm
> * `guix repl` just invokes `./pre-inst-env guile`, but it should
> probably also load some Guix modules.
>
> # Simple Aliases
> * `guix add` or `guix install` -> guix package --install
> * `guix env` -> guix environment
> * `guix try` -> guix environment --ad-hoc
> * `guix profile` -> guix package
> * `guix show` or `guix info` -> guix package --show=
> * `guix remove` or `guix uninstall` -> guix package --remove
>
> What does everyone think? If you like the idea, what would the
> implementation/config file look like?


--



PHP on core-updates

2017-02-26 Thread Leo Famulari
Hi Julien,

Libgd is updated to 2.2.4 on the core-updates branch.

Can you take a look and decide what to do with gd-for-php on that
branch?



[PATCH 1/3] gnu: Add slib.

2017-02-26 Thread John Darrington
* gnu/packages/scheme.scm (slib): New variable.
---
 gnu/packages/scheme.scm | 42 --
 1 file changed, 40 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index af416c5..5134c24 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -6,6 +6,7 @@
 ;;; Copyright © 2016 Efraim Flashner 
 ;;; Copyright © 2016 Jan Nieuwenhuizen 
 ;;; Copyright © 2016, 2017 ng0 
+;;; Copyright © 2017 John Darrington 
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -25,8 +26,8 @@
 (define-module (gnu packages scheme)
   #:use-module (gnu packages)
   #:use-module ((guix licenses)
-#:select (gpl2+ lgpl2.0+ lgpl2.1+ asl2.0 bsd-3
-  cc-by-sa4.0))
+#:select (gpl2+ lgpl2.0+ lgpl2.1+ lgpl3+ asl2.0 bsd-3
+  cc-by-sa4.0 non-copyleft))
   #:use-module (guix packages)
   #:use-module (guix download)
   #:use-module (guix git-download)
@@ -57,6 +58,7 @@
   #:use-module (gnu packages xorg)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages gl)
+  #:use-module (gnu packages zip)
   #:use-module (ice-9 match))
 
 (define (mit-scheme-source-directory system version)
@@ -844,3 +846,39 @@ metalinguistic abstraction, recursion, interpreters, and 
modular programming.")
"String pattern-matching library for scheme48 based on the SRE
 regular-expression notation.")
   (license bsd-3
+
+(define-public slib
+  (package
+(name "slib")
+(version "3b5")
+(source (origin
+ (method url-fetch)
+ (uri (string-append 
"http://groups.csail.mit.edu/mac/ftpdir/scm/slib-; version ".zip"))
+ (sha256
+  (base32
+   "0q0p2d53p8qw2592yknzgy2y1p5a9k7ppjx0cfrbvk6242c4mdpq"
+(build-system gnu-build-system)
+(arguments
+ `(#:tests? #f ;; No check target
+   #:phases
+   (modify-phases %standard-phases
+ (add-after 'install 'remove-bin-share
+(lambda* (#:key inputs outputs #:allow-other-keys)
+  (zero? (system* "rm" "-r"
+  (string-append
+   (assoc-ref outputs "out") "/bin")
+ (replace 'configure
+  (lambda* (#:key inputs outputs #:allow-other-keys)
+(zero? (system* "./configure"
+(string-append "--prefix="
+   (assoc-ref outputs 
"out")
+(native-inputs `(("unzip" ,unzip)
+ ("texinfo" ,texinfo)))
+(home-page "http://people.csail.mit.edu/jaffer/SLIB/;)
+(synopsis "Compatibility and utility library for Scheme.")
+(description "SLIB is a portable Scheme library providing compatibility and
+utility functions for all standard Scheme implementations.")
+(license (non-copyleft
+  "http://people.csail.mit.edu/jaffer/SLIB_COPYING.txt;
+  "Or see COPYING in the distribution."
+
-- 
2.1.4




[PATCH 2/3] gnu: Add scm.

2017-02-26 Thread John Darrington
* gnu/packages/scheme.scm (scm): New variable.
---
 gnu/packages/scheme.scm | 61 +
 1 file changed, 61 insertions(+)

diff --git a/gnu/packages/scheme.scm b/gnu/packages/scheme.scm
index 5134c24..cd3fb5b 100644
--- a/gnu/packages/scheme.scm
+++ b/gnu/packages/scheme.scm
@@ -882,3 +882,64 @@ utility functions for all standard Scheme 
implementations.")
   "http://people.csail.mit.edu/jaffer/SLIB_COPYING.txt;
   "Or see COPYING in the distribution."
 
+(define-public scm
+  (package
+(name "scm")
+(version "5f2")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"http://groups.csail.mit.edu/mac/ftpdir/scm/scm-;
+version ".zip"))
+  (sha256
+   (base32
+"050ijb51jm1cij9g3r89zl9rawsrikhbb5y8zb7lspb7bsxq5w99"
+(build-system gnu-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (replace 'configure
+  (lambda* (#:key inputs outputs #:allow-other-keys)
+(zero? (system* "./configure"
+(string-append "--prefix="
+   (assoc-ref outputs 
"out"))
+ (add-before 'build 'pre-build
+ (lambda* (#:key inputs #:allow-other-keys)
+   (substitute* "Makefile"
+ (("ginstall-info") "install-info"
+ (replace 'build
+  (lambda* (#:key inputs outputs #:allow-other-keys)
+(setenv "SCHEME_LIBRARY_PATH"
+(string-append (assoc-ref inputs "slib")
+   "/lib/slib/"))
+(and
+ (zero? (system* "make" "scmlit" "CC=gcc"))
+ (zero? (system* "make" "all")
+ (add-after 'install 'post-install
+(lambda* (#:key inputs outputs #:allow-other-keys)
+  (let ((req
+ (string-append (assoc-ref outputs "out")
+"/lib/scm/require.scm")))
+(and
+ (delete-file req)
+ (format (open req (logior O_WRONLY O_CREAT))
+ "(define (library-vicinity) ~s)\n"
+ (string-append (assoc-ref inputs "slib")
+"/lib/slib/"))
+
+ ;; We must generate the slibcat file
+ (zero? (system*
+ (string-append
+  (assoc-ref outputs "out")
+  "/bin/scm")
+ "-br" "new-catalog")
+(inputs `(("slib" ,slib)))
+(native-inputs `(("unzip" ,unzip)
+ ("texinfo" ,texinfo)))
+(home-page "http://people.csail.mit.edu/jaffer/SCM;)
+(synopsis "Scheme implementation conforming to R5RS and IEEE P1178")
+(description "GNU SCM is an implementation of Scheme.  This
+implementation includes Hobbit, a Scheme-to-C compiler, which can
+generate C files whose binaries can be dynamically or statically
+linked with a SCM executable.")
+(license lgpl3+)))
-- 
2.1.4




[PATCH 3/3] gnu: Add jacal.

2017-02-26 Thread John Darrington
* gnu/packages/maths.scm (jacal): New variable.
* gnu/packages/patches/jacal.texi.patch: New file.
---
 gnu/packages/maths.scm| 50 +++
 gnu/packages/patches/jacal.texi.patch | 90 +++
 2 files changed, 140 insertions(+)
 create mode 100644 gnu/packages/patches/jacal.texi.patch

diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm
index 18536c4..df3ba40 100644
--- a/gnu/packages/maths.scm
+++ b/gnu/packages/maths.scm
@@ -83,6 +83,7 @@
   #:use-module (gnu packages python)
   #:use-module (gnu packages readline)
   #:use-module (gnu packages tbb)
+  #:use-module (gnu packages scheme)
   #:use-module (gnu packages shells)
   #:use-module (gnu packages tcl)
   #:use-module (gnu packages texinfo)
@@ -2956,3 +2957,52 @@ algorithm for LCS.  It is a fast program to compute the 
approximate
 Longest Commons Subsequence of a set of strings.")
   (home-page "https://github.com/gdv/Reduce-Expand-for-LCS;)
   (license license:gpl3+
+
+(define-public jacal
+  (package
+(name "jacal")
+(version "1c4")
+(source (origin
+  (method url-fetch)
+  (uri (string-append
+"http://groups.csail.mit.edu/mac/ftpdir/scm/jacal-;
+version ".zip"))
+  (sha256 (base32
+   "055zrn12a1dmy0dqkwrkq3fklbhg3yir6vn0lacp4mvbg8573a3q"))
+  (patches (search-patches "jacal.texi.patch"
+(build-system gnu-build-system)
+(arguments
+ `(#:phases
+   (modify-phases %standard-phases
+ (add-before 'build 'pre-build
+ ;; Don't use upstream's script - it really doesn't fit 
into
+ ;; Guix's functional paradigm.
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+   (substitute* "Makefile"
+ (("^install: install-script") "install: "
+ (add-after 'install 'post-install
+;; Instead, we provide our own simplified script.
+(lambda* (#:key inputs outputs #:allow-other-keys)
+  (let ((wrapper (string-append (assoc-ref outputs "out")
+"/bin/jacal")))
+(format (open wrapper (logior O_WRONLY O_CREAT))
+"#!~a\nexec ~a/bin/scm -ip1 -e '(slib:load 
\"~a/lib/jacal/math\") (math)' \"$@\"\n"
+(which  "bash")
+(assoc-ref inputs "scm")
+(assoc-ref outputs "out"))
+(chmod wrapper #o555
+ (replace 'configure
+  (lambda* (#:key inputs outputs #:allow-other-keys)
+(zero? (system* "./configure"
+(string-append "--prefix="
+   (assoc-ref outputs 
"out")
+(inputs `(("scm" ,scm)))
+(native-inputs `(("unzip" ,unzip)
+ ("texinfo" ,texinfo)))
+(synopsis "Symbolic mathematics system")
+(description "GNU JACAL is an interactive symbolic mathematics program 
based on
+Scheme.  It manipulate and simplify a range of mathematical expressions such
+as equations, scalars, vectors, and matrices.")
+(home-page "http://www.gnu.org/software/jacal;)
+(license license:gpl3+)))
+
diff --git a/gnu/packages/patches/jacal.texi.patch 
b/gnu/packages/patches/jacal.texi.patch
new file mode 100644
index 000..27c6d78
--- /dev/null
+++ b/gnu/packages/patches/jacal.texi.patch
@@ -0,0 +1,90 @@
+--- jacal/jacal.texi,orig  2017-02-23 20:35:55.303980444 +0100
 jacal/jacal.texi   2017-02-23 20:53:14.539024674 +0100
+@@ -343,7 +343,7 @@
+ 
+ With the standard input grammar, the precedence of @samp{-} as a prefix
+ behaves strangely.  @code{a^-b*c} becomes @code{a^(-b*c)} while
+-@code{@result{a^b*c} (a^b)*c}.
++@code{a^b*c @result{} (a^b)*c}.
+ 
+ Using @code{divide} to divide a polynomial by an integer does not work.
+ 
+@@ -675,8 +675,9 @@
+ e1: -
+ a
+ @end example
++@end deffn
+ 
+-@deffnx Command suchthat var exp
++@deffn Command suchthat var exp
+ 
+ If an expression rather than an equation is given to @code{suchthat}, it
+ is as though the equation @code{@var{exp}=0} was given.
+@@ -688,8 +689,9 @@
+ e2: -
+ a
+ @end example
++@end deffn
+ 
+-@deffnx Operator | var exp_or_eqn
++@deffn Operator | var exp_or_eqn
+ 
+ An alternative infix notation is also available for @code{suchthat}.
+ 
+@@ -857,8 +859,9 @@
+ 
+ Returns the degree of polynomial or equation @var{poly} in variable
+ @var{var}.
++@end deffn
+ 
+-@deffnx Operator degree poly
++@deffn Operator degree poly
+ 
+ Returns the total-degree, the degree of its highest degree monomial,
+ of polynomial or equation @var{poly}.
+@@ -1016,10 +1019,12 @@
+ Returns @var{poly1} reduced with respect to @var{poly2} 

[PATCH] services: dovecot: Fix unix_listeners and fifo_listeners path types.

2017-02-26 Thread Clément Lassieur
* gnu/services/mail.scm (unix-listener-configuration)[path]
  (fifo-listener-configuration)[path]: Change type from 'file-name' to 'string'.
* doc/guix.texi (Mail Services): Document it.
---
 doc/guix.texi | 8 
 gnu/services/mail.scm | 8 
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/doc/guix.texi b/doc/guix.texi
index be11096a4..979820300 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -10750,8 +10750,8 @@ Defaults to @samp{()}.
 
 Available @code{unix-listener-configuration} fields are:
 
-@deftypevr {@code{unix-listener-configuration} parameter} file-name path
-The file name on which to listen.
+@deftypevr {@code{unix-listener-configuration} parameter} string path
+The file name on which to listen.  This is also used as the section name.
 @end deftypevr
 
 @deftypevr {@code{unix-listener-configuration} parameter} string mode
@@ -10772,8 +10772,8 @@ Defaults to @samp{""}.
 
 Available @code{fifo-listener-configuration} fields are:
 
-@deftypevr {@code{fifo-listener-configuration} parameter} file-name path
-The file name on which to listen.
+@deftypevr {@code{fifo-listener-configuration} parameter} string path
+The file name on which to listen.  This is also used as the section name.
 @end deftypevr
 
 @deftypevr {@code{fifo-listener-configuration} parameter} string mode
diff --git a/gnu/services/mail.scm b/gnu/services/mail.scm
index 30b1672d3..31191a962 100644
--- a/gnu/services/mail.scm
+++ b/gnu/services/mail.scm
@@ -158,8 +158,8 @@
 
 (define-configuration unix-listener-configuration
   (path
-   (file-name (configuration-missing-field 'unix-listener 'path))
-   "The file name on which to listen.")
+   (string (configuration-missing-field 'unix-listener 'path))
+   "The file name on which to listen.  This is also used as the section name.")
   (mode
(string "0600")
"The access mode for the socket.")
@@ -177,8 +177,8 @@
 
 (define-configuration fifo-listener-configuration
   (path
-   (file-name (configuration-missing-field 'fifo-listener 'path))
-   "The file name on which to listen.")
+   (string (configuration-missing-field 'fifo-listener 'path))
+   "The file name on which to listen.  This is also used as the section name.")
   (mode
(string "0600")
"The access mode for the socket.")
-- 
2.12.0




Re: How to M-x debbugs-gnu with new guix-patches

2017-02-26 Thread Christopher Allan Webber
Pjotr Prins writes:

> I submitted my first patch on debbugs. It is a fairly trivial one for
> speedtest-cli which I need because I move around so much ;)
>
> More importantly I wrote some documentation:
>
>   
> https://github.com/pjotrp/guix-notes/blob/master/HACKING.org#making-a-patch-and-submit-to-the-guix-project
>
> Comments welcome (as usual).
>
> Pj.

This is really nice!  Maybe we should link to it from or put it on the
Guix website somewhere?



Re: [PATCH] gnu: icedtea-8: Build keystore without id-ecPublicKey certificates.

2017-02-26 Thread Roel Janssen

Carlo Zancanaro writes:

> On Fri, Feb 10 2017, Roel Janssen wrote
>> [ ... ]
>
> I was getting frustrated at not having certificates with java 8 (it's
> surprisingly annoying to have to use one environment with java 7 to
> download dependencies with maven, then a different environment with java
> 8 to actually run your program), so I downloaded and tried out your
> patch. It seems to work!

Thanks for picking up the patch!

> But then I wondered, could we just change the generate-keystore phase of
> the icedtea-6 package to log a failed certificate import without failing
> the build? Then we could move the permissions change there, too, which
> would give us a smaller patch that should accomplish a similar result
> (attached).

Great idea.  This is also a more durable solution for when certificates
change in nss-certs.

> From b1ed0d53a72f95fdc42fa3741ae16726782ad414 Mon Sep 17 00:00:00 2001
> From: Carlo Zancanaro 
> Date: Sun, 26 Feb 2017 11:34:44 +1100
> Subject: [PATCH] gnu: icedtea-6: Modify certificate import to not fail for
>  icedtea-8.
>
> * gnu/packages/java.scm (icedtea-6)[arguments]: Fix install-keystore phase to
>   not fail the build when attempting to import unsupported certificate
>   types (which occur with icedtea-8, which inherits from icedtea-6). Also
>   ensure that the keystore is able to be written to before copying it.
> ---
>  gnu/packages/java.scm | 14 ++
>  1 file changed, 10 insertions(+), 4 deletions(-)
>
> diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm
> index e7479e1b0..c7f9b9aad 100644
> --- a/gnu/packages/java.scm
> +++ b/gnu/packages/java.scm
> @@ -706,7 +706,7 @@ build process and its dependencies, whereas Make uses 
> Makefile format.")
> "-file" temp)))
>   (display "yes\n" port)
>   (when (not (zero? (status:exit-val (close-pipe port
> -   (error "failed to import" cert)))
> +   (format #t "failed to import ~a\n" cert)))
> (delete-file temp)))
>  
> ;; This is necessary because the certificate directory 
> contains
> @@ -719,6 +719,15 @@ build process and its dependencies, whereas Make uses 
> Makefile format.")
> "/lib/security"))
> (mkdir-p (string-append (assoc-ref outputs "jdk")
> "/jre/lib/security"))
> +
> +   ;; The cacerts files we are going to overwrite are chmod'ed as
> +   ;; read-only (444) in icedtea-8 (which derives from this
> +   ;; package).  We have to change this so we can overwrite them.
> +   (chmod (string-append (assoc-ref outputs "out")
> + "/lib/security/" keystore) #o644)
> +   (chmod (string-append (assoc-ref outputs "jdk")
> + "/jre/lib/security/" keystore) #o644)
> +
> (install-file keystore
>   (string-append (assoc-ref outputs "out")
>  "/lib/security"))

I checked to see if the keystore is actually chmod'ed back to #o444, and
it is!  So this looks fine to me as well.

> @@ -1023,9 +1032,6 @@ build process and its dependencies, whereas Make uses 
> Makefile format.")
>  (find-files "openjdk.src/jdk/src/solaris/native"
>  "\\.c|\\.h"))
> #t)))
> - ;; FIXME: This phase is needed but fails with this version of
> - ;; IcedTea.
> - (delete 'install-keystore)
>   (replace 'install
> (lambda* (#:key outputs #:allow-other-keys)
>   (let ((doc (string-append (assoc-ref outputs "doc")

I tried this patch and it works fine.

I think we should add ourselves to the copyright notice.
Other than that, I think this patch is good to be pushed.

Kind regards,
Roel Janssen



Re: [PATCH 1/1] gnu: fontconfig: Fix build failure caused by symbol conflict with glibc@2.25.

2017-02-26 Thread Marius Bakke
Leo Famulari  writes:

> * gnu/packages/patches/fontconfig-charwidth-symbol-conflict.patch: New file.
> * gnu/local.mk (dist_patch_DATA): Add it.
> * gnu/packages/fontutils.scm (fontconfig)[source]: Use it.

LGTM, thanks!

> ---
>  gnu/local.mk   |  1 +
>  gnu/packages/fontutils.scm |  1 +
>  .../fontconfig-charwidth-symbol-conflict.patch | 82 
> ++
>  3 files changed, 84 insertions(+)
>  create mode 100644 
> gnu/packages/patches/fontconfig-charwidth-symbol-conflict.patch
>
> diff --git a/gnu/local.mk b/gnu/local.mk
> index ec9332271..3623bbb49 100644
> --- a/gnu/local.mk
> +++ b/gnu/local.mk
> @@ -557,6 +557,7 @@ dist_patch_DATA = 
> \
>%D%/packages/patches/flint-ldconfig.patch  \
>%D%/packages/patches/fltk-shared-lib-defines.patch \
>%D%/packages/patches/fltk-xfont-on-demand.patch\
> +  %D%/packages/patches/fontconfig-charwidth-symbol-conflict.patch\
>%D%/packages/patches/fontforge-svg-modtime.patch   \
>%D%/packages/patches/freeimage-CVE-2015-0852.patch \
>%D%/packages/patches/freeimage-CVE-2016-5684.patch \
> diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm
> index fad0cb11a..ad15659f6 100644
> --- a/gnu/packages/fontutils.scm
> +++ b/gnu/packages/fontutils.scm
> @@ -229,6 +229,7 @@ fonts to/from the WOFF2 format.")
>  (uri (string-append
> 
> "https://www.freedesktop.org/software/fontconfig/release/fontconfig-;
> version ".tar.bz2"))
> +(patches (search-patches 
> "fontconfig-charwidth-symbol-conflict.patch"))
>  (sha256 (base32
>   
> "1wy7svvp7df6bjpg1m5vizb3ngd7rhb20vpclv3x3qa71khs6jdl"
> (build-system gnu-build-system)
> diff --git a/gnu/packages/patches/fontconfig-charwidth-symbol-conflict.patch 
> b/gnu/packages/patches/fontconfig-charwidth-symbol-conflict.patch
> new file mode 100644
> index 0..8ebe33bc6
> --- /dev/null
> +++ b/gnu/packages/patches/fontconfig-charwidth-symbol-conflict.patch
> @@ -0,0 +1,82 @@
> +The first patch is copied from the upstream source repository:
> +
> +https://cgit.freedesktop.org/fontconfig/commit/?id=1ab5258f7c2abfafcd63a760ca08bf93591912da
> +
> +The second patch is adapted from a message to from the OpenEmbedded mailing 
> list:
> +
> +http://lists.openembedded.org/pipermail/openembedded-core/2016-December/130213.html
> +
> +From 1ab5258f7c2abfafcd63a760ca08bf93591912da Mon Sep 17 00:00:00 2001
> +From: Khem Raj 
> +Date: Wed, 14 Dec 2016 16:11:05 -0800
> +Subject: Avoid conflicts with integer width macros from TS 18661-1:2014
> +
> +glibc 2.25+ has now defined these macros in 
> +https://sourceware.org/git/?p=glibc.git;a=commit;h=5b17fd0da62bf923cb61d1bb7b08cf2e1f1f9c1a
> +
> +Create an alias for FC_CHAR_WIDTH for ABI compatibility
> +
> +Signed-off-by: Khem Raj 
> +
> +diff --git a/fontconfig/fontconfig.h b/fontconfig/fontconfig.h
> +index 5c72b22..070a557 100644
> +--- a/fontconfig/fontconfig.h
>  b/fontconfig/fontconfig.h
> +@@ -128,7 +128,8 @@ typedef int  FcBool;
> + #define FC_USER_CACHE_FILE  ".fonts.cache-" FC_CACHE_VERSION
> + 
> + /* Adjust outline rasterizer */
> +-#define FC_CHAR_WIDTH   "charwidth" /* Int */
> ++#define FC_CHARWIDTH"charwidth" /* Int */
> ++#define FC_CHAR_WIDTH   FC_CHARWIDTH
> + #define FC_CHAR_HEIGHT  "charheight"/* Int */
> + #define FC_MATRIX   "matrix"/* FcMatrix */
> + 
> +diff --git a/src/fcobjs.h b/src/fcobjs.h
> +index 1fc4f65..d27864b 100644
> +--- a/src/fcobjs.h
>  b/src/fcobjs.h
> +@@ -51,7 +51,7 @@ FC_OBJECT (DPI,FcTypeDouble,   NULL)
> + FC_OBJECT (RGBA,FcTypeInteger,  NULL)
> + FC_OBJECT (SCALE,   FcTypeDouble,   NULL)
> + FC_OBJECT (MINSPACE,FcTypeBool, NULL)
> +-FC_OBJECT (CHAR_WIDTH,  FcTypeInteger,  NULL)
> ++FC_OBJECT (CHARWIDTH,   FcTypeInteger,  NULL)
> + FC_OBJECT (CHAR_HEIGHT, FcTypeInteger,  NULL)
> + FC_OBJECT (MATRIX,  FcTypeMatrix,   NULL)
> + FC_OBJECT (CHARSET, FcTypeCharSet,  FcCompareCharSet)
> +-- 
> +cgit v0.10.2
> +
> +From 20cddc824c6501c2082cac41b162c34cd5fcc530 Mon Sep 17 00:00:00 2001
> +From: Khem Raj 
> +Date: Sun, 11 Dec 2016 14:32:00 -0800
> +Subject: [PATCH] Avoid conflicts with integer width macros from TS
> + 18661-1:2014
> +
> +glibc 2.25+ has now defined these macros in 
> +https://sourceware.org/git/?p=glibc.git;a=commit;h=5b17fd0da62bf923cb61d1bb7b08cf2e1f1f9c1a
> +
> +Signed-off-by: Khem Raj 
> +---
> +Upstream-Status: Submitted
> +
> + fontconfig/fontconfig.h | 2 +-
> + src/fcobjs.h| 2 +-
> + src/fcobjshash.gperf| 2 +-
> + src/fcobjshash.h| 2 +-
> + 4 files changed, 4 

Re: core-updates: Fix cups-minimal build failure

2017-02-26 Thread Marius Bakke
Leo Famulari  writes:

> Do you have any suggestions about how to make this more concise?
> From 0191e8394eedd271494b5e1e8c8eb131176440a8 Mon Sep 17 00:00:00 2001
> From: Leo Famulari 
> Date: Sat, 25 Feb 2017 21:22:08 -0500
> Subject: [PATCH] gnu: cups-minimal: Fix build failure in reset-gzip-timestamps
>  phase.
>
> * gnu/packages/cups.scm (cups-minimal)[arguments]: Add 
> 'make-manpages-writable'
> phase.
> ---
>  gnu/packages/cups.scm | 17 +
>  1 file changed, 17 insertions(+)
>
> diff --git a/gnu/packages/cups.scm b/gnu/packages/cups.scm
> index 20621e32b..ebb979c62 100644
> --- a/gnu/packages/cups.scm
> +++ b/gnu/packages/cups.scm
> @@ -166,6 +166,23 @@ filters for the PDF-centric printing workflow introduced 
> by OpenPrinting.")
>   (substitute* "Makedefs.in"
> (("INITDIR.*=.*@INITDIR@") "INITDIR = @prefix@/@INITDIR@")
> (("/bin/sh") (which "sh")
> + ;; Make the compressed manpages writable so that the
> + ;; reset-gzip-timestamps phase does not error out.
> + (add-before 'reset-gzip-timestamps 'make-manpages-writable
> +   (lambda* (#:key outputs #:allow-other-keys)
> + (let* ((out (assoc-ref outputs "out"))
> +(man1 (string-append out "/share/man/man1"))
> +(man5 (string-append out "/share/man/man5"))
> +(man7 (string-append out "/share/man/man7"))
> +(man8 (string-append out "/share/man/man8")))
> +   (for-each (lambda (file) (chmod file #o666))
> + (find-files man1 "\\.gz"))
> +   (for-each (lambda (file) (chmod file #o666))
> + (find-files man5 "\\.gz"))
> +   (for-each (lambda (file) (chmod file #o666))
> + (find-files man7 "\\.gz"))
> +   (for-each (lambda (file) (chmod file #o666))
> + (find-files man8 "\\.gz")

Would it work to simply run this on all of "out/share/man", instead of
explicitly specifying the sections?

I would also use 0644 perms here, not that it matters though!

>   (add-before 'build 'patch-tests
> (lambda _
>   (substitute* "test/ippserver.c"
> -- 
> 2.11.1


signature.asc
Description: PGP signature


Re: core-updates: Fix eudev build failure

2017-02-26 Thread Marius Bakke
Leo Famulari  writes:

> The update is not necessary to fix the build failure, but we might as
> well update if we are rebuilding eudev anyways.

Thanks! These patches LGTM.

> From 65c2a3f8edb1d8ef9dd32889acf833e5561329fa Mon Sep 17 00:00:00 2001
> From: Leo Famulari 
> Date: Sat, 25 Feb 2017 21:45:44 -0500
> Subject: [PATCH 1/2] gnu: eudev: Update to 3.2.1.
>
> * gnu/packages/linux.scm (eudev): Update to 3.2.1.
> ---
>  gnu/packages/linux.scm | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
> index 03b7e295d..b3fd9d260 100644
> --- a/gnu/packages/linux.scm
> +++ b/gnu/packages/linux.scm
> @@ -1732,7 +1732,7 @@ from the module-init-tools project.")
>;; The post-systemd fork, maintained by Gentoo.
>(package
>  (name "eudev")
> -(version "3.2")
> +(version "3.2.1")
>  (source (origin
>(method url-fetch)
>(uri (string-append
> @@ -1740,7 +1740,7 @@ from the module-init-tools project.")
>  version ".tar.gz"))
>(sha256
> (base32
> -"099w62ncq78nxpxizf910mx18hc8x4qvzw3azjd00fir89wmyjnq"))
> +"06gyyl90n85x8i7lfhns514y1kg1ians13l467admyzy3kjxkqsp"))
>(patches (search-patches "eudev-rules-directory.patch"
>  (build-system gnu-build-system)
>  (native-inputs
> -- 
> 2.11.1
>
> From da6db68dae4bb2573ee75f304c7d61b5b88089e4 Mon Sep 17 00:00:00 2001
> From: Leo Famulari 
> Date: Sat, 25 Feb 2017 21:59:09 -0500
> Subject: [PATCH 2/2] gnu: eudev: Fix build failure caused by conflicting
>  function type declaration.
>
> * gnu/packages/patches/eudev-conflicting-declaration.patch: New file.
> * gnu/local.mk (dist_patch_DATA): Add it.
> * gnu/packages/linux.scm (eudev)[source]: Use it.
> ---
>  gnu/local.mk   |  1 +
>  gnu/packages/linux.scm |  3 ++-
>  .../patches/eudev-conflicting-declaration.patch| 31 
> ++
>  3 files changed, 34 insertions(+), 1 deletion(-)
>  create mode 100644 gnu/packages/patches/eudev-conflicting-declaration.patch
>
> diff --git a/gnu/local.mk b/gnu/local.mk
> index 3623bbb49..6f7bed9d1 100644
> --- a/gnu/local.mk
> +++ b/gnu/local.mk
> @@ -541,6 +541,7 @@ dist_patch_DATA = 
> \
>%D%/packages/patches/emacs-scheme-complete-scheme-r5rs-info.patch  \
>%D%/packages/patches/emacs-source-date-epoch.patch \
>%D%/packages/patches/eudev-rules-directory.patch   \
> +  %D%/packages/patches/eudev-conflicting-declaration.patch   \
>%D%/packages/patches/evilwm-lost-focus-bug.patch   \
>%D%/packages/patches/expat-CVE-2016-0718-fix-regression.patch  \
>%D%/packages/patches/fastcap-mulGlobal.patch   \
> diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm
> index b3fd9d260..fe72f98b7 100644
> --- a/gnu/packages/linux.scm
> +++ b/gnu/packages/linux.scm
> @@ -1741,7 +1741,8 @@ from the module-init-tools project.")
>(sha256
> (base32
>  "06gyyl90n85x8i7lfhns514y1kg1ians13l467admyzy3kjxkqsp"))
> -  (patches (search-patches "eudev-rules-directory.patch"
> +  (patches (search-patches "eudev-rules-directory.patch"
> +   
> "eudev-conflicting-declaration.patch"
>  (build-system gnu-build-system)
>  (native-inputs
>   `(("pkg-config" ,pkg-config)
> diff --git a/gnu/packages/patches/eudev-conflicting-declaration.patch 
> b/gnu/packages/patches/eudev-conflicting-declaration.patch
> new file mode 100644
> index 0..f5399e20d
> --- /dev/null
> +++ b/gnu/packages/patches/eudev-conflicting-declaration.patch
> @@ -0,0 +1,31 @@
> +Fix build failure due to conflicting declaration of
> +keyboard_lookup_key() in gperf-3.1:
> +
> +https://bugs.gentoo.org/show_bug.cgi?id=604864
> +
> +Patch copied from upstream source repository:
> +
> +https://github.com/gentoo/eudev/commit/5bab4d8de0dcbb8e2e7d4d5125b4aea1652a0d60
> +
> +From 5bab4d8de0dcbb8e2e7d4d5125b4aea1652a0d60 Mon Sep 17 00:00:00 2001
> +From: "Anthony G. Basile" 
> +Date: Thu, 5 Jan 2017 16:21:17 -0500
> +Subject: [PATCH] src/udev/udev-builtin-keyboard.c: fix build with gperf 3.1
> +
> +Signed-off-by: Anthony G. Basile 
> +---
> + src/udev/udev-builtin-keyboard.c | 1 -
> + 1 file changed, 1 deletion(-)
> +
> +diff --git a/src/udev/udev-builtin-keyboard.c 
> b/src/udev/udev-builtin-keyboard.c
> +index 73171c3..fad3520 100644
> +--- a/src/udev/udev-builtin-keyboard.c
>  b/src/udev/udev-builtin-keyboard.c
> +@@ -28,7 +28,6 @@
> + 
> + #include "udev.h"
> + 
> +-static const struct key *keyboard_lookup_key(const char *str, unsigned len);
> + #include "keyboard-keys-from-name.h"
> + #include 

Re: How to M-x debbugs-gnu with new guix-patches

2017-02-26 Thread Pjotr Prins
I submitted my first patch on debbugs. It is a fairly trivial one for
speedtest-cli which I need because I move around so much ;)

More importantly I wrote some documentation:

  
https://github.com/pjotrp/guix-notes/blob/master/HACKING.org#making-a-patch-and-submit-to-the-guix-project

Comments welcome (as usual).

Pj.




Re: Input needed: Plan for packaging scala

2017-02-26 Thread Ricardo Wurmus

Pjotr Prins  writes:

> On Sun, Feb 26, 2017 at 12:08:37AM +0100, Ricardo Wurmus wrote:
>> This is the primary reason why we only have a handful of Java packages
>> in Guix.  We don’t want to make an exception for Java and accept
>> pre-built binaries just to increase the number of packages.  (Luckily
>> for us, Java build artifacts are often quite portable, so there’s not as
>> much urgency to make it work with Guix as there is for applications
>> written in other languages.)
>
> You mean that users can easily deploy JVM packages (jars and wars) on
> top of on existing Guix JVM?

I don’t know about wars, but the jars we worked with at the MDC worked
just fine on top of the JVM provided by the icedtea packages.

> Why don't we accept these particular build tools as binary bootstraps
> for now?

The reason is that we cannot make one decision for all tools.  A big
chunk of the work is to figure out *which* of the dependencies can be
considered an “impossible” dependency.  Having a binary for Maven alone
wouldn’t be very helpful.  The primary purpose of Maven is to download
required binaries from a central site.  It doesn’t help us *build* any
packages from source.  When we provide Maven it has to be with a
maven-build-system that takes all Java inputs and arranges them in the
layout that a local Maven repository containing all these inputs would
have.  Maven on its own would not be very useful.

In fact, I’ve been packaging libraries that officially require Maven to
build them, but I used plain ant with the default build.xml the
ant-build-system generates.

> Guix is not exactly pure anyway - we bootstrap build binaries for
> pragmatic reasons.

And we try very hard to reduce the number of bootstrap binaries.  I
don’t think it would be a good idea to open the flood gates and accept
binaries for Java tools — because that’s not an exceptional case;
downloading binaries is in the fabric of the Java culture.

We need a few more libraries packaged the hard way, which would make the
next steps a lot easier.  My recommendation is to continue following the
bootstrap path of Maven and its dependencies and see where that leads
us.

> But, if no one is actively working on Maven, I suggest to use a jar
> for the time being.

I’ll get back to it soon.  It’s in my own interest to reduce the number
of unpushed patches I have on my machines :)

> Q: who here wants to work on this eyesore and challenge called Maven?
>So far Ricardo and Roel have worked on it and given up.

(Hartmut also worked on it and I’m still working on some of his
abandoned patches in a branch.)

I would be very happy to collaborate with others who are interested in
moving Java on Guix forward.

--
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net




Can (grub-configuration (device $DEV)) accept UUIDs?

2017-02-26 Thread dian_cecht
I am in the process of trying to get GuixSD installed on my desktop and
I've run into a minor issue. The documentation doesn't mention any
support for UUIDs for grub-configuration (I'm going by the webpage with
the install instead of the info files on the LiveUSB). Anyways, since
the boot drive is very likely to change between install and the first
LiveUSBless install, I'd rather use UUIDs. Can grub-configuration
support this? If it can, the docs need to be updated to support this
and if not, I'd hope someone could figure out a way to enable support
for this.




Re: Debbugs handling of Guix patches

2017-02-26 Thread Pjotr Prins
I think the web page for patches is rather good :) Especially that you
can sort by date and the 'Toggle all extra information' switch. Nice.
The emacs plugin, as usual, is amazing. I ought to try and submit a
patch again ;)

Pj.

On Sun, Feb 12, 2017 at 03:01:07PM +0100, Ludovic Courtès wrote:
> Glenn Morris  skribis:
> 
> > I see you got this sorted out, so I've now completed the debbugs part.
> > It may take an hour or so for the mailing list redirection to take effect.
> 
> It seems to be working now:
> 
>   https://debbugs.gnu.org/cgi/pkgreport.cgi?pkg=guix-patches
> 
> Thanks, Glenn!
> 
> Ludo'.
> 

-- 



Re: [PATCH 1/2] build: union: Add create-all-directory? parameter to union-build

2017-02-26 Thread 宋文武

"Huang, Ying"  writes:

Hi, sorry for my late reply.

> Danny Milosavljevic  writes:
>
>> Hi,
>>
>> yeah, I've looked at it and I see what you are trying to do.
>>
>> You modified 'union to replicate the directory tree and symlink only the 
>> non-directory files - in order to be able to add "fonts.dir" in those 
>> directories.
>>
>> The previous version symlinked entire directories, too, and you wouldn't 
>> have been able to add those "fonts.dir" files inside them later.
>>
>> Your fix seems kinda hacky - but I don't really see a downside.
>>
>> Thinking about it some more I think it looks good enough to me. I'd like a 
>> second opinion, though.
>>
>> Other than that, the name of the new flag "create-all-directory?" is weird. 
>> I'd like it to be something like "create-all-directories?".

>>
>> (The non-hacky solution would be to make 'union aware that there are
>> "fonts.dir" files to go in there, too. One could do that by adding
>> these as an input, too. I'm not sure whether that would be worth the
>> added complexity, though - especially since the fonts.dir generator
>> needs to have the finished union as input and not just single
>> directories one by one. Thoughts?)
>
> union will only be called with create-all-directory? != nil for packages
> have share/fonts directories.  And for these packages, we plan to remove
> the fonts.dir and fonts.scale files, so that we need to create all
> directories for them after all.  Is this good enough?
>

Yes, I thought so and it will work, but maybe it's better (non-hacky
way?) to make every font package install fonts.scale and fonts.dir files
into its own directory...

IIUC, to make them useful, we have to make the fonts directories
available to the running X server through xserver.conf (FontPath) or
adding them using 'xset +fp'.  And since either method is limited to a
single directory, so if we avoid the collision by putting each font
package under an unique path ($out/share/fonts/TYPE/FONT-NAME), then the
font-dir profile hook is not needed at all.

We can do this in the wanted (upcoming?) 'font-build-system'.