From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id cHx0F9BcnWBuZwEAgWs5BA (envelope-from ) for ; Thu, 13 May 2021 19:07:28 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id GNIRE9BcnWC1DgAAbx9fmQ (envelope-from ) for ; Thu, 13 May 2021 17:07:28 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B186711F66 for ; Thu, 13 May 2021 19:07:27 +0200 (CEST) Received: from localhost ([::1]:57262 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lhEo2-0007EH-9g for larch@yhetil.org; Thu, 13 May 2021 13:07:26 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47704) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lhElk-0003eA-3E for guix-patches@gnu.org; Thu, 13 May 2021 13:05:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:60890) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lhEli-00077q-1v for guix-patches@gnu.org; Thu, 13 May 2021 13:05:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lhElh-0000H2-Si for guix-patches@gnu.org; Thu, 13 May 2021 13:05:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#47966] [PATCH] gnu: Add python-graph-tool. Resent-From: Marius Bakke Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 13 May 2021 17:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47966 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Alexandre Hannud Abdo , 47966@debbugs.gnu.org Received: via spool by 47966-submit@debbugs.gnu.org id=B47966.16209254791020 (code B ref 47966); Thu, 13 May 2021 17:05:01 +0000 Received: (at 47966) by debbugs.gnu.org; 13 May 2021 17:04:39 +0000 Received: from localhost ([127.0.0.1]:44203 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lhElK-0000GO-So for submit@debbugs.gnu.org; Thu, 13 May 2021 13:04:39 -0400 Received: from eggs.gnu.org ([209.51.188.92]:53906) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lhElH-0000G9-8P for 47966@debbugs.gnu.org; Thu, 13 May 2021 13:04:37 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]:50040) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lhElC-0006kU-29; Thu, 13 May 2021 13:04:30 -0400 Received: from host-37-191-231-185.lynet.no ([37.191.231.185]:42518 helo=localhost) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lhElB-0005uk-6m; Thu, 13 May 2021 13:04:29 -0400 From: Marius Bakke In-Reply-To: References: Date: Thu, 13 May 2021 19:04:25 +0200 Message-ID: <878s4iimzq.fsf@gnu.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1620925648; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post; bh=iq/vFa3eiM5rmbRljt9l0UwadVQxgfvFSg24Qeg9qy4=; b=W9O/sfTyuLJKFPX3Iys+alV9RAV4YbQ3cPHdr/iq9NpMMND0BXI7qgzLvaLbfJMzIB+IkG DzneBinydxF2NeXK0ufNhMbLKhHi+bLB+aFMV1ZOsVXue9r0BfOGprKeEgfRixEIcdLyV2 8H3kQxTv3ezO6F6Y1XuXjAloSAn77GrlROtDIdoOTNLLkt2W+yuO2GlX/pmO9qCx2gsIz5 O5dM3MwwT9Z9m/h+H3ZOlloTvxzWCO4ADa6BzBXoFEjVCBf/vxdv6D0IJvOUNBDcjLSgIA kg4MBzeudnSe5X2dV+iZhkmChiS0j3jeHMNGI8neguBD+leUoWbHhw4n0UErtw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1620925648; a=rsa-sha256; cv=none; b=m5t5174ukdRT4DnFd1l8C9WhQuIMxKhHj3YoWRfsl03s1n3sFTQY5YwEydXHQaZFPAp/Y+ ah+XN49qy1nd1drd+noo4so81PUanc10tK3YizZAXKXQ8yWXXWHE/CxMnVfDpIGbRNlqp5 +9scMWIzhqDOk2ydtUc1/BB1miHyTU8o9ET4ATLElGlaPvhqMDF5REA9oqfN8bmxDDXxkX lKafc7nD9rwAVSUI3UF2fo+qT+r4rIftOPUWq/7KICHwh3+TQ8s76UOCUaY3ES7GwX7QwH AaHBBuWf8AhK3Mk4fgokC1LrPvZBGsBjqyRTKkLCYOguPMKj2N33MeeK63nGJA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -5.05 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: B186711F66 X-Spam-Score: -5.05 X-Migadu-Scanner: scn0.migadu.com X-TUID: buSBta7AmcZN --=-=-= Content-Type: text/plain Hi Alexandre, Alexandre Hannud Abdo skriver: > * gnu/packages/graph.scm (python-graph-tool): New variable. Thanks for the patch. [...] > +(define-public python-graph-tool > + (package > + (name "python-graph-tool") > + (version "2.37") > + (source (origin > + (method url-fetch) > + (uri (string-append > + "https://downloads.skewed.de/graph-tool/graph-tool-" > + version > + ".tar.bz2")) > + (sha256 > + (base32 > + "0w2i4d4zyk051zkykcg0ksngspajznwmp523hbsx50xnxc6jliyz")))) > + (build-system gnu-build-system) > + ;; (arguments '(#:configure-flags '("--disable-openmp"))) This comment can probably be removed? > + (arguments > + `(#:configure-flags > + (list (string-append "--with-boost=" > + (assoc-ref %build-inputs "boost")) > + (string-append "--with-python-module-path=" > + (assoc-ref %outputs "out") > + "/lib/python" > + ((lambda (version) > + (substring version 0 (string-rindex version #\.))) > + ,(package-version > + (car (assoc-ref > + (package-propagated-inputs this-package) > + "python")))) > + "/site-packages/")))) That's clever. :-) (guix utils) has a handy (version-major+minor ...) procedure that can be accessed in the unquoted context. Thus the expression above can be simplified to: (string-append "--with-python-module-path=" (assoc-ref %outputs "out") "/lib/python" ,(version-major+minor (package-version (car (assoc-ref (package-propagated-inputs this-package) "python")))) "/site-packages/") > + (native-inputs `(("pkg-config" ,pkg-config) > + ("gcc-10" ,gcc-10) > + ("ncurses" ,ncurses))) The indentation here and below is unusual. :-) > + (inputs `(("boost" ,boost) > + ("expat" ,expat) > + ("gmp" ,gmp) > + ("cgal" ,cgal) > + ("sparsehash" ,sparsehash) > + ("gtk+" ,gtk+) > + ("cairomm" ,cairomm))) > + (propagated-inputs `(("python" ,python-wrapper) Python should be a regular input. It will be available in just about any context where this package is used, and propagating it can cause conflicts if users have custom variants in their profile/manifests/packages. > + ("python-scipy" ,python-scipy) > + ("python-numpy" ,python-numpy) > + ("python-pycairo" ,python-pycairo) > + ("python-matplotlib" ,python-matplotlib))) > + (synopsis "Efficient python module for analysis of graphs") Perhaps just 'Analyze graphs with Python' to avoid overlapping with the description which has more detail? > + (description "Graph-tool is an efficient Python module for > +manipulation and statistical analysis of graphs (a.k.a. networks). > +Contrary to most other Python modules with similar functionality, the > +core data structures and algorithms are implemented in C++, making > +extensive use of template metaprogramming, based heavily on the Boost > +Graph Library. This confers it a level of performance that is > +comparable (both in memory usage and computation time) to that of a > +pure C/C++ library.") > + (home-page "https://graph-tool.skewed.de/") > + (license license:lgpl3+))) Otherwise LGTM. Can you send an updated patch? TIA, Marius --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iIUEARYKAC0WIQRNTknu3zbaMQ2ddzTocYulkRQQdwUCYJ1cGQ8cbWFyaXVzQGdu dS5vcmcACgkQ6HGLpZEUEHed7AD/cTpxTCnZQFAtynxAsowWGTxI/pgdRFDZwlab TmWR0S0A/1XJEew7mZYu3H09xL92GvaJzUN+92JzNYzaJcoE6J0I =D5i/ -----END PGP SIGNATURE----- --=-=-=--