From mboxrd@z Thu Jan 1 00:00:00 1970 From: Efraim Flashner Subject: Re: [PATCH 0/3] add c-ares and aria2 Date: Thu, 5 Nov 2015 11:19:53 +0200 Message-ID: <20151105111953.19ef0e99@debian-netbook> References: <1446448523-27811-1-git-send-email-efraim@flashner.co.il> <87d1vryzn8.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/pWK3LWIQ8d1sHxK8PYVW=0M"; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58937) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZuGiF-0001tk-3s for guix-devel@gnu.org; Thu, 05 Nov 2015 04:20:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZuGiA-0003n0-Co for guix-devel@gnu.org; Thu, 05 Nov 2015 04:20:07 -0500 In-Reply-To: <87d1vryzn8.fsf@gnu.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-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Ludovic =?UTF-8?B?Q291cnTDqHM=?= Cc: guix-devel@gnu.org --Sig_/pWK3LWIQ8d1sHxK8PYVW=0M Content-Type: multipart/mixed; boundary="MP_/N_sV0kcEfBjxskYwAGqJDRh" --MP_/N_sV0kcEfBjxskYwAGqJDRh Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Tue, 03 Nov 2015 14:35:07 +0100 ludo@gnu.org (Ludovic Court=C3=A8s) wrote: > Efraim Flashner skribis: >=20 > > This patch has driven me crazy a bit. C-ares is a library for asynchron= ous DNS > > lookups, and aria2 is a cli program to download multiple files/torrents > > simultaneously, and also a git-annex dependency. C-ares builds without = any > > problems, but aria2 was a different story. The first problem is that th= e tests > > seem to need network connectivity, and it tries to access files outside= the > > build chroot. Disabling the tests was the easy part. =20 >=20 > It=E2=80=99s cheating! ;-) Could you investigate and see whether/how te= sts > could run in the build environment? A common problem wrt. networking in > host name lookups. In the build environment, only =E2=80=9Clocalhost=E2= =80=9D can be > found. >=20 > > The second problem was that pkg-config wouldn't find c-ares, so it > > kept on building without it. =20 >=20 > In that case, I would do this: >=20 > guix build -K aria2 > # =E2=80=A6 build fails > cd /tmp/nix-build*aria2* > source environment-variables > pkg-config c-ares --libs >=20 > (Replace =E2=80=9Cc-ares=E2=80=9D with the name corresponding to the actu= al .pc file > provided by c-ares.) >=20 > It might be that this command fails because of a missing dependency that > the .pc file requires. >=20 > Ludo=E2=80=99. In the end rebuilding c-ares with the release tarball and not the github tarball fixed the issues with aria2 not recognizing c-ares. I wasn't able to get anything more out of aria2, more than it not finding the locations and leaving me with with variables pointing to /path/to/dir and the like. --=20 Efraim Flashner =D7=90=D7=A4=D7=A8=D7=99=D7=9D = =D7=A4=D7=9C=D7=A9=D7=A0=D7=A8 GPG key =3D A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails sent or received unencrypted --MP_/N_sV0kcEfBjxskYwAGqJDRh Content-Type: text/x-patch Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename=0001-gnu-Add-c-ares.patch =46rom 1f601d7707623ff21da6567eec7f57bef133c3f5 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Thu, 29 Oct 2015 16:18:36 +0200 Subject: [PATCH 1/2] gnu: Add c-ares. * gnu/packages/aria2.scm: New file. * gnu-system.am (GNU_SYSTEM_MODULES): Add it. --- gnu-system.am | 1 + gnu/packages/aria2.scm | 49 ++++++++++++++++++++++++++++++++++++++++++++++= +++ 2 files changed, 50 insertions(+) create mode 100644 gnu/packages/aria2.scm diff --git a/gnu-system.am b/gnu-system.am index 946b77e..881ee35 100644 --- a/gnu-system.am +++ b/gnu-system.am @@ -35,6 +35,7 @@ GNU_SYSTEM_MODULES =3D \ gnu/packages/aidc.scm \ gnu/packages/apl.scm \ gnu/packages/apr.scm \ + gnu/packages/aria2.scm \ gnu/packages/asciidoc.scm \ gnu/packages/aspell.scm \ gnu/packages/attr.scm \ diff --git a/gnu/packages/aria2.scm b/gnu/packages/aria2.scm new file mode 100644 index 0000000..707a3ce --- /dev/null +++ b/gnu/packages/aria2.scm @@ -0,0 +1,49 @@ +;;; GNU Guix --- Functional package management for GNU +;;; Copyright =C2=A9 2015 Efraim Flashner +;;; +;;; This file is part of GNU Guix. +;;; +;;; GNU Guix is free software; you can redistribute it and/or modify it +;;; under the terms of the GNU General Public License as published by +;;; the Free Software Foundation; either version 3 of the License, or (at +;;; your option) any later version. +;;; +;;; GNU Guix is distributed in the hope that it will be useful, but +;;; WITHOUT ANY WARRANTY; without even the implied warranty of +;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;;; GNU General Public License for more details. +;;; +;;; You should have received a copy of the GNU General Public License +;;; along with GNU Guix. If not, see . + +(define-module (gnu packages aria2) + #:use-module ((guix licenses) #:prefix license:) + #:use-module (guix download) + #:use-module (guix packages) + #:use-module (guix build-system gnu) + #:use-module (gnu packages pkg-config)) + +(define-public c-ares + (package + (name "c-ares") + (version "1.10.0") + (source (origin + (method url-fetch) + (uri (string-append + "http://c-ares.haxx.se/download/" name "-" version + ".tar.gz")) + (sha256 + (base32 + "1nyka87yf2jfd0y6sspll0yxwb8zi7kyvajrdbjmh4axc5s1cw1x")))) + (build-system gnu-build-system) + (native-inputs + `(("pkg-config" ,pkg-config))) + (home-page "http://c-ares.haxx.se/") + (synopsis "C library for asynchronous DNS requests") + (description + "C-ares is a C library that performs DNS requests and name resolution +asynchronously. It is intended for applications which need to perform DNS +queries without blocking, or need to perform multiple DNS queries in paral= lel. +The primary examples of such applications are servers which communicate wi= th +multiple clients and programs with graphical user interfaces.") + (license (license:x11-style "http://c-ares.haxx.se/license.html")))) --=20 2.6.2 --MP_/N_sV0kcEfBjxskYwAGqJDRh Content-Type: text/x-patch Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename=0002-gnu-Add-aria2.patch =46rom ef12a054927c42442ba0806caabee75be0d6f88f Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 3 Nov 2015 22:05:47 +0200 Subject: [PATCH 2/2] gnu: Add aria2. * gnu/packages/aria2.scm (aria2): New variable. --- gnu/packages/aria2.scm | 44 +++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 43 insertions(+), 1 deletion(-) diff --git a/gnu/packages/aria2.scm b/gnu/packages/aria2.scm index 707a3ce..5a28a77 100644 --- a/gnu/packages/aria2.scm +++ b/gnu/packages/aria2.scm @@ -21,7 +21,14 @@ #:use-module (guix download) #:use-module (guix packages) #:use-module (guix build-system gnu) - #:use-module (gnu packages pkg-config)) + #:use-module (gnu packages compression) + #:use-module (gnu packages databases) + #:use-module (gnu packages nettle) + #:use-module (gnu packages tls) + #:use-module (gnu packages multiprecision) + #:use-module (gnu packages pkg-config) + #:use-module (gnu packages ssh) + #:use-module (gnu packages xml)) =20 (define-public c-ares (package @@ -47,3 +54,38 @@ queries without blocking, or need to perform multiple DN= S queries in parallel. The primary examples of such applications are servers which communicate wi= th multiple clients and programs with graphical user interfaces.") (license (license:x11-style "http://c-ares.haxx.se/license.html")))) + +(define-public aria2 + (package + (name "aria2") + (version "1.19.2") + (source (origin + (method url-fetch) + (uri (string-append "https://github.com/tatsuhiro-t/aria2/" + "releases/download/release-" version "/" + name "-" version ".tar.xz")) + (sha256 + (base32 + "0gnm1b7yp5q6fcajz1ln2f1rv64p6dv0nz9bcwpqrkcmsinlh19n")))) + (build-system gnu-build-system) + (arguments + `(#:configure-flags '("--enable-libaria2") + #:tests? #f)) ; tests require network connectivity + (native-inputs + `(("pkg-config", pkg-config))) + (inputs + `(("c-ares" ,c-ares) + ("gnutls" ,gnutls) + ("gmp" ,gmp) + ("libssh2" ,libssh2) + ("libxml2" ,libxml2) + ("nettle" ,nettle) + ("sqlite" ,sqlite) + ("zlib" ,zlib))) + (home-page "http://aria2.sourceforge.net/") + (synopsis "Utility for parallel downloading files") + (description + "Aria2 is a lightweight, multi-protocol & multi-source command-line +downloadu tility. It supports HTTP/HTTPS, FTP, SFTP, BitTorrent and Metal= ink. +Aria2 can be manipulated via built-in JSON-RPC and XML-RPC interfaces.") + (license license:gpl2+))) --=20 2.6.2 --MP_/N_sV0kcEfBjxskYwAGqJDRh-- --Sig_/pWK3LWIQ8d1sHxK8PYVW=0M Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAEBCgAGBQJWOx85AAoJEPTB05F+rO6TUxoP/0XI8XI1P6wrfEBKCAe5VDZR gp0R1K4kgbgFWxGNhgQ8AiVhYbh/jDodLFu3Plvgjqvo/JwdUsx4CjlTjUoG5wXO f4vZqtwXxUh8r9BcDu+sO2sKdekFF/zmHEk84EESwG/8H5a+fw1p6yD9hQELcL4N xsrZyVZs7W2wwWxQsJi3cEdLRfUtHBxfa08Ynhg5QRt3mix46I+Boba8oHcsdjSu 5/wjzMqLxSHlPz4xVQh2oz6nKp5qjUfvBoHBe9U0sftr3AiAmegDwY3bSL/GZSXE vXWDNkArmt6aXdej0KmB4GJsEAgIYVvZwLusEprR2ajkZHEo4WEmjoPOokRskURX AFvhjn3rFLAqk0LNcDOyKV6Bjw9VHaUrLASBoi/l6O0Va1Ge2QGgon2tX1pJDMLc +/YQfvhXo3iJ52046eT0S2ydH88JU5nm0ZvYKHIGQYCuujdq2v4fqHheKOcGUxCg APAbs/v8qXQsDlkryLUU3S2ez6mVcnPlDjkcitSggZEu+43jAz/M8chbYJiUtUUc /ItLg55OdYOKw6lhI74W/eCVM/w1m0JVS14vCfdJFniPMc9FxgvU/Mk4F0gr9YGx 2EjULhze+TkZXZkrjdIj18Y780tZjKqbLBgbISat00AIwcLTMmbMgZLiDD9Dy4hI TvKIvBHXlEBAtZD62m6R =CC2V -----END PGP SIGNATURE----- --Sig_/pWK3LWIQ8d1sHxK8PYVW=0M--