From patchwork Mon Oct 3 02:41:28 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Patterson X-Patchwork-Id: 16198 Received: (qmail 63238 invoked by uid 89); 3 Oct 2016 02:42:30 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Checked: by ClamAV 0.99.2 on sourceware.org X-Virus-Found: No X-Spam-SWARE-Status: No, score=-4.5 required=5.0 tests=BAYES_00, RP_MATCHES_RCVD, SPF_PASS autolearn=ham version=3.3.2 spammy=clisp, steel, Bank, bank X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00, RP_MATCHES_RCVD, SPF_PASS autolearn=ham version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on sourceware.org X-Spam-Level: X-HELO: lists.gnu.org Received: from lists.gnu.org (HELO lists.gnu.org) (208.118.235.17) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 03 Oct 2016 02:42:20 +0000 Received: from localhost ([::1]:33494 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bqtCs-00004q-Hd for patchwork@sourceware.org; Sun, 02 Oct 2016 22:42:18 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45313) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bqtCT-0008Cf-8D for guix-devel@gnu.org; Sun, 02 Oct 2016 22:41:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bqtCQ-0004s6-UU for guix-devel@gnu.org; Sun, 02 Oct 2016 22:41:52 -0400 Received: from mailservices.uwaterloo.ca ([129.97.128.141]:45338 helo=minos.uwaterloo.ca) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bqtCQ-0004ry-Nj for guix-devel@gnu.org; Sun, 02 Oct 2016 22:41:50 -0400 Received: from jalisou.gateway.2wire.net (bas1-jockvale05-3096537756.dsl.bell.ca [184.145.106.156]) (authenticated bits=0) by minos.uwaterloo.ca (8.14.4/8.14.4) with ESMTP id u932fgFf020024 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO); Sun, 2 Oct 2016 22:41:50 -0400 From: Andy Patterson To: guix-devel@gnu.org Subject: [PATCH v2 02/13] gnu: sbcl: Honour XDG_DATA_DIRS. Date: Sun, 2 Oct 2016 22:41:28 -0400 Message-Id: <20161003024139.19975-3-ajpatter@uwaterloo.ca> X-Mailer: git-send-email 2.10.0 In-Reply-To: <20161003024139.19975-1-ajpatter@uwaterloo.ca> References: <20160927041532.27097-1-ajpatter@uwaterloo.ca> <20161003024139.19975-1-ajpatter@uwaterloo.ca> X-UUID: 98ec4fbd-254c-4db2-917a-bb58ecb2e880 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 129.97.128.141 X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list 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+patchwork=sourceware.org@gnu.org Sender: "Guix-devel" * gnu/packages/lisp.scm (asdf-substitutions): New variable. (sbcl) [source]: Add snippet. [native-search-paths]: Add XDG_DATA_DIRS. --- gnu/packages/lisp.scm | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm index 439433a..1311a7d 100644 --- a/gnu/packages/lisp.scm +++ b/gnu/packages/lisp.scm @@ -47,6 +47,15 @@ #:use-module (ice-9 match) #:use-module (srfi srfi-1)) +(define (asdf-substitutions lisp) + `((("\\(,dir \"systems/\"\\)\\)") + (format #f + "(,dir \"~a-bundle-systems\"))) + + ,@(loop :for dir :in (xdg-data-dirs \"common-lisp/\") + :collect `(:directory (,dir \"systems\"))" + ,lisp)))) + (define-public gcl (package (name "gcl") @@ -226,7 +235,12 @@ an interpreter, a compiler, a debugger, and much more.") (uri (string-append "mirror://sourceforge/sbcl/sbcl/" version "/sbcl-" version "-source.tar.bz2")) (sha256 - (base32 "0fjdqnb2rsm2vi9794ywp27jr239ddvzc4xfr0dk49jd4v7p2kc5")))) + (base32 "0fjdqnb2rsm2vi9794ywp27jr239ddvzc4xfr0dk49jd4v7p2kc5")) + (modules '((guix build utils))) + (snippet + ;; Add sbcl-bundle-systems to the asdf registry + `(substitute* "contrib/asdf/asdf.lisp" + ,@(asdf-substitutions name))))) (build-system gnu-build-system) (outputs '("out" "doc")) ;; Bootstrap with CLISP. @@ -315,6 +329,10 @@ an interpreter, a compiler, a debugger, and much more.") #t)))) ;; No 'check' target, though "make.sh" (build phase) runs tests. #:tests? #f)) + (native-search-paths + (list (search-path-specification + (variable "XDG_DATA_DIRS") + (files '("share"))))) (home-page "http://www.sbcl.org/") (synopsis "Common Lisp implementation") (description "Steel Bank Common Lisp (SBCL) is a high performance Common