From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hartmut Goebel Subject: [PATCH 02/14] guix: build all Python packages with --single-version-externally-managed. Date: Wed, 28 Sep 2016 15:58:15 +0200 Message-ID: <1475071107-10765-3-git-send-email-h.goebel@crazy-compilers.com> References: <1475071107-10765-1-git-send-email-h.goebel@crazy-compilers.com> 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]:47748) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bpFNe-00021s-PE for guix-devel@gnu.org; Wed, 28 Sep 2016 09:58:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bpFNc-0006Fb-Nd for guix-devel@gnu.org; Wed, 28 Sep 2016 09:58:37 -0400 Received: from mail-out.m-online.net ([2001:a60:0:28:0:1:25:1]:43184) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bpFNc-0006FE-HG for guix-devel@gnu.org; Wed, 28 Sep 2016 09:58:36 -0400 Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 3skfSC5sWsz3hk7Z for ; Wed, 28 Sep 2016 15:58:34 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.68]) by mail.m-online.net (Postfix) with ESMTP id 3skfSB6bsRzvl3F for ; Wed, 28 Sep 2016 15:58:34 +0200 (CEST) Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.68]) (amavisd-new, port 10024) with ESMTP id 4WaaDI8LcNfX for ; Wed, 28 Sep 2016 15:58:32 +0200 (CEST) Received: from hermia.goebel-consult.de (ppp-188-174-146-208.dynamic.mnet-online.de [188.174.146.208]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPS for ; Wed, 28 Sep 2016 15:58:32 +0200 (CEST) Received: from lenashee.goebel-consult.de (lenashee.goebel-consult.de [192.168.110.2]) by hermia.goebel-consult.de (Postfix) with ESMTP id D2376605B7 for ; Wed, 28 Sep 2016 15:58:27 +0200 (CEST) In-Reply-To: <1475071107-10765-1-git-send-email-h.goebel@crazy-compilers.com> 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 This requires setuptools to be installed together with python, which is the case for Python 3 anyway and which we do for our build of Python 2 (see last commit). * guix/build/python-build-system.scm (install): Add "--single-version-externally-managed" and "--root=3D/" to params to be passed to call-setuppy. Remove thus needless manipulation of PYTHONPATH. --- guix/build/python-build-system.scm | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/guix/build/python-build-system.scm b/guix/build/python-build= -system.scm index 9109fb4..8d4d6d3 100644 --- a/guix/build/python-build-system.scm +++ b/guix/build/python-build-system.scm @@ -3,6 +3,7 @@ ;;; Copyright =C2=A9 2013 Andreas Enge ;;; Copyright =C2=A9 2013 Nikita Karetnikov ;;; Copyright =C2=A9 2015 Mark H Weaver +;;; Copyright =C2=A9 2016 Hartmut Goebel ;;; ;;; This file is part of GNU Guix. ;;; @@ -65,19 +66,9 @@ "Install a given Python package." (let* ((out (assoc-ref outputs "out")) (params (append (list (string-append "--prefix=3D" out)) - configure-flags)) - (python-version (get-python-version (assoc-ref inputs "python")= )) - (old-path (getenv "PYTHONPATH")) - (add-path (string-append out "/lib/python" python-version - "/site-packages/"))) - ;; create the module installation directory and add it to PYTHON= PATH - ;; to make setuptools happy - (mkdir-p add-path) - (setenv "PYTHONPATH" - (string-append (if old-path - (string-append old-path ":") - "") - add-path)) + "--single-version-externally-managed" + "--root=3D/" + configure-flags))) (call-setuppy "install" params))) =20 (define* (wrap #:key inputs outputs #:allow-other-keys) --=20 2.7.4