From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?UTF-8?B?QmrDtnJuIEjDtmZsaW5n?= Subject: Re: [PATCH] gnu: add proj4. Date: Mon, 16 Jan 2017 21:05:12 +0100 Message-ID: <20170116210512.6e519268@alma-ubu> References: <20170115232147.2ee240cc@alma-ubu> <20170115232402.17585716@alma-ubu> <20170116002121.1aec454e@scratchpost.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37008) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTDWq-0000x4-EV for guix-devel@gnu.org; Mon, 16 Jan 2017 15:05:21 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cTDWn-00034F-5t for guix-devel@gnu.org; Mon, 16 Jan 2017 15:05:20 -0500 Received: from m4s11.vlinux.de ([83.151.27.109]:36649) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cTDWm-000344-Sw for guix-devel@gnu.org; Mon, 16 Jan 2017 15:05:17 -0500 Received: from alma-ubu (pD9EA5345.dip0.t-ipconnect.de [217.234.83.69]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by m4s11.vlinux.de (Postfix) with ESMTPSA id 0B15F96A6 for ; Mon, 16 Jan 2017 19:58:23 +0000 (UTC) In-Reply-To: <20170116002121.1aec454e@scratchpost.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org On Mon, 16 Jan 2017 00:21:28 +0100 Danny Milosavljevic wrote: > Hi, >=20 > > * gnu/packages/geo.scm:139:13: proj4-4.9.3: invalid license field > >=20 > > But the documentation explicitly speaks about list values. What's > > wrong? =20 >=20 > You quoted the list. That means that all the symbols in it stay > symbols and are not resolved. Instead of substituting the actual > license license:asl2.0, it will literally put 'license:asl2.0 into > the list. >=20 > I'd just use something like (list license:a license:b) . It's a list of records, not of symbols, of cause! Thanks. >=20 > It would also be possible to use quasiquote but I'd not do that in > this case. It's too obtuse. `(,license:a ,license:b) >=20 > > * /home/bjoern/guix/gnu/packages/geo.scm:100:2: proj4-4.9.3: line > > 125 is way too long (102 characters) =20 >=20 > It's an URL in a comment - I'd be fine with it as-is and I wouldn't > break it anywhere. >=20 > > About the package name: The official name is "proj.4", so I left it > > as that. =20 >=20 > Seems reasonable. >=20 > > As variable name, I chose "proj4". Is that correct? =20 >=20 > Why not use the variable name "proj.4" too then? *scratches head* Because my Scheme-time is far too long ago, and I'm used to languages where "dot" in variable names is bad. Here is the new patch with the two corrections. Bj=C3=B6rn * gnu/packages/geo.scm (proj4): New variable. --- gnu/packages/geo.scm | 58 ++++++++++++++++++++++++++++++++++++++++++++++++= ++-- 1 file changed, 56 insertions(+), 2 deletions(-) diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm index 86828e717..0e63fe8c7 100644 --- a/gnu/packages/geo.scm +++ b/gnu/packages/geo.scm @@ -1,6 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright =C2=A9 2016 Leo Famulari ;;; Copyright =C2=A9 2016 Alex Griffin +;;; Copyright =C2=A9 2017 Bj=C3=B6rn H=C3=B6fling ;;; ;;; This file is part of GNU Guix. ;;; @@ -19,8 +20,9 @@ =20 (define-module (gnu packages geo) #:use-module (guix build-system glib-or-gtk) + #:use-module (guix build-system gnu) #:use-module (guix download) - #:use-module (guix licenses) + #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix utils) #:use-module (gnu packages glib) @@ -92,4 +94,56 @@ the OpenStreetMap project. It can provide directions for walking, bicycli= ng, and driving.") (home-page "https://wiki.gnome.org/Apps/Maps") - (license gpl2+))) + (license license:gpl2+))) + +(define-public proj.4 + (package + (name "proj.4") + (version "4.9.3") + (source (origin + (method url-fetch) + (uri (string-append "http://download.osgeo.org/proj/proj-" + version + ".tar.gz")) + (sha256 + (base32 + "1xw5f427xk9p2nbsj04j6m5zyjlyd66sbvl2bkg8hd1kx8pm9139")))) + (build-system gnu-build-system) + (arguments `(#:phases + (modify-phases %standard-phases + (add-after + 'unpack 'patch-test-shebangs + (lambda _ + (substitute* '("nad/test27" + "nad/test83" + "nad/testvarious" + "nad/testdatumfile" + "nad/testflaky" + "nad/testIGNF") + (("/bin/rm") (which "rm"))))) + ;; Precision problems on i686 and other platforms. See: + ;; https://web.archive.org/web/20151006134301/http://tr= ac.osgeo.org/proj/ticket/255 + ;; Disable failing test. + (add-after + 'patch-test-shebangs 'ignore-failing-tests + (lambda _ + (substitute* '("nad/Makefile.in") + (("\tPROJ_LIB.*" all) (string-append "#" all))))= )))) + (inputs + `(("glib" ,glib))) + (home-page "http://proj4.org/") + (synopsis "Cartographic Projections Library") + (description + "Proj.4 is a library for converting coordinates between cartographic = projections. +") + (license (list license:expat + ;; config.guess, config.sub + license:gpl3+ + ;; libtool + license:gpl2+ + ;; src/PJ_patterson.c + license:asl2.0 + ;; src/geodesic.c/h + license:x11 + ;; cmake/* + license:boost1.0)))) --=20 2.11.0