From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ricardo Wurmus Subject: [PATCH] gnu: Add eigensoft. Date: Tue, 12 Jul 2016 15:29:19 +0200 Message-ID: <20160712132919.20938-1-ricardo.wurmus@mdc-berlin.de> 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]:54564) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bMxkp-0003R8-6M for guix-devel@gnu.org; Tue, 12 Jul 2016 09:29:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bMxkk-00044R-BT for guix-devel@gnu.org; Tue, 12 Jul 2016 09:29:38 -0400 Received: from venus.bbbm.mdc-berlin.de ([141.80.25.30]:58701) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bMxkj-00043v-Uf for guix-devel@gnu.org; Tue, 12 Jul 2016 09:29:34 -0400 Received: from localhost (localhost [127.0.0.1]) by venus.bbbm.mdc-berlin.de (Postfix) with ESMTP id 0E0C93806C8 for ; Tue, 12 Jul 2016 15:29:32 +0200 (CEST) Received: from venus.bbbm.mdc-berlin.de ([127.0.0.1]) by localhost (venus.bbbm.mdc-berlin.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2dXgzzcf3p5M for ; Tue, 12 Jul 2016 15:29:26 +0200 (CEST) Received: from HTCATWO.mdc-berlin.net (puck.citx.mdc-berlin.de [141.80.36.101]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by venus.bbbm.mdc-berlin.de (Postfix) with ESMTPS for ; Tue, 12 Jul 2016 15:29:26 +0200 (CEST) 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 * gnu/packages/bioinformatics.scm (eigensoft): New variable. --- gnu/packages/bioinformatics.scm | 72 +++++++++++++++++++++++++++++++++++= ++++++ 1 file changed, 72 insertions(+) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatic= s.scm index 7cffe26..7c95ec8 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -1691,6 +1691,78 @@ data and settings.") (license (license:non-copyleft "file://src/COPYING" "See src/COPYING in the distribution.= ")))) =20 +(define-public eigensoft + (let ((revision "1") + (commit "b14d1e202e21e532536ff8004f0419cd5e259dc7")) + (package + (name "eigensoft") + (version (string-append "6.1.2-" + revision "." + (string-take commit 9))) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/DReichLab/EIG.git") + (commit commit))) + (file-name (string-append "eigensoft-" commit "-checkout")) + (sha256 + (base32 + "0f5m6k2j5c16xc3xbywcs989xyc26ncy1zfzp9j9n55n9r4xcaiq")) + (modules '((guix build utils))) + ;; Remove pre-built binaries. + (snippet '(begin + (delete-file-recursively "bin") + (mkdir "bin") + #t)))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; There are no tests. + #:make-flags '("CC=3Dgcc") + #:phases + (modify-phases %standard-phases + ;; There is no configure phase, but the Makefile is in a + ;; sub-directory. + (replace 'configure + (lambda _ + (chdir "src") + ;; The link flags are incomplete. + (substitute* "Makefile" + (("-lgsl") "-lgsl -lm -llapack -llapacke -lpthread")) + #t)) + ;; The provided install target only copies executables to + ;; the "bin" directory in the build root. + (add-after 'install 'actually-install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin"))) + (mkdir-p bin) + (for-each (lambda (file) + (install-file file bin)) + (find-files "../bin" ".*")) + #t)))))) + (inputs + `(("gsl" ,gsl) + ("lapack" ,lapack) + ("lapack" ,lapack "lapacke") + ("openblas" ,openblas) + ("perl" ,perl) + ("gfortran" ,gfortran "lib"))) + (home-page "https://github.com/DReichLab/EIG") + (synopsis "Tools for population genetics") + (description "This package provides tools for population genetics = and +stratification correction. The EIGENSTRAT method uses principal compone= nts +analysis to explicitly model ancestry differences between cases and cont= rols +along continuous axes of variation; the resulting correction is specific= to a +candidate marker=E2=80=99s variation in frequency across ancestral popul= ations, +minimizing spurious associations while maximizing power to detect true +associations. The EIGENSOFT package has a built-in plotting script and +supports multiple file formats and quantitative phenotypes.") + ;; The license of the eigensoft tools is Expat, but since it's + ;; linking with the GNU Scientific Library (GSL) the effective + ;; license is the GPL. + (license license:gpl3+)))) + (define-public edirect (package (name "edirect") --=20 2.9.0