From mboxrd@z Thu Jan 1 00:00:00 1970 From: Federico Beffa Subject: [PATCH] gnu: Add clojure. Date: Wed, 24 Feb 2016 21:46:51 +0100 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45070) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aYgKj-00069G-HR for guix-devel@gnu.org; Wed, 24 Feb 2016 15:46:54 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aYgKi-0000EE-NR for guix-devel@gnu.org; Wed, 24 Feb 2016 15:46:53 -0500 Received: from mail-vk0-x233.google.com ([2607:f8b0:400c:c05::233]:33047) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aYgKi-0000E7-Hh for guix-devel@gnu.org; Wed, 24 Feb 2016 15:46:52 -0500 Received: by mail-vk0-x233.google.com with SMTP id k196so29246613vka.0 for ; Wed, 24 Feb 2016 12:46:51 -0800 (PST) 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: alexvong1995@gmail.com Cc: Guix-devel Alex Vong writes: > + #:phases > + (modify-phases %standard-phases > + (delete 'configure) > + (replace 'unpack > + (lambda _ > + (and (mkdir "clojure/") > + (zero? (system* "unzip" > + "-d" "clojure/" > + (assoc-ref %build-inputs "source"))) > + (chdir "clojure/")))) The return value of 'mkdir' and 'chdir' is unspecified. Therefore it should not be used. > + (add-after 'remove-jar 'unpack-submodule-sources > + (lambda* (#:key inputs #:allow-other-keys) > + (let ((unpack > + (lambda (src-name) > + (and (mkdir src-name) > + (with-directory-excursion src-name > + (zero? (system* "tar" > + "zxvf" > + (assoc-ref inputs src-name) > + "--strip-components=1")))))) > + (copy (lambda (src-name) > + (copy-recursively > + (string-append src-name "/src/main/clojure/") > + (string-append "clojure-" ,version "/src/clj/"))))) > + (every (lambda (src) > + (begin (unpack src) > + (copy src))) > + '("data-generators-src" "java-classpath-src" > + "test-check-src" "test-generative-src" > + "tools-namespace-src" "tools-reader-src"))))) Same. Regards, Fede