pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

kallisto: Test biology/kallisto with libaec in place of szip



Module Name:	pkgsrc-wip
Committed By:	Jason Bacon <bacon%NetBSD.org@localhost>
Pushed By:	outpaddling
Date:		Sat Apr 20 11:03:04 2019 -0500
Changeset:	c9ad614b7d3c62d7d1aed3d7effedeffd114f336

Modified Files:
	Makefile
Added Files:
	kallisto/DESCR
	kallisto/Makefile
	kallisto/PLIST
	kallisto/distinfo
	kallisto/files/kallisto-test
	kallisto/patches/patch-CMakeLists.txt
	kallisto/patches/patch-src_CMakeLists.txt

Log Message:
kallisto: Test biology/kallisto with libaec in place of szip

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=c9ad614b7d3c62d7d1aed3d7effedeffd114f336

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 Makefile                                  |  1 +
 kallisto/DESCR                            |  4 +++
 kallisto/Makefile                         | 38 ++++++++++++++++++++++++++
 kallisto/PLIST                            | 10 +++++++
 kallisto/distinfo                         |  8 ++++++
 kallisto/files/kallisto-test              | 45 +++++++++++++++++++++++++++++++
 kallisto/patches/patch-CMakeLists.txt     | 28 +++++++++++++++++++
 kallisto/patches/patch-src_CMakeLists.txt | 30 +++++++++++++++++++++
 8 files changed, 164 insertions(+)

diffs:
diff --git a/Makefile b/Makefile
index 69e5e2de9d..e0aebc6e59 100644
--- a/Makefile
+++ b/Makefile
@@ -1688,6 +1688,7 @@ SUBDIR+=	kacst-ttf
 SUBDIR+=	kactivitymanagerd
 SUBDIR+=	kahakai
 SUBDIR+=	kalarmcal
+SUBDIR+=	kallisto
 SUBDIR+=	kamera
 SUBDIR+=	kannel-gateway
 SUBDIR+=	kapacitor
diff --git a/kallisto/DESCR b/kallisto/DESCR
new file mode 100644
index 0000000000..de9c8d8c3d
--- /dev/null
+++ b/kallisto/DESCR
@@ -0,0 +1,4 @@
+Kallisto is a program for quantifying abundances of transcripts from RNA-Seq
+data, or more generally of target sequences using high-throughput sequencing
+reads. It is based on the novel idea of pseudoalignment for rapidly determining
+the compatibility of reads with targets, without the need for alignment.
diff --git a/kallisto/Makefile b/kallisto/Makefile
new file mode 100644
index 0000000000..e64f71cb55
--- /dev/null
+++ b/kallisto/Makefile
@@ -0,0 +1,38 @@
+# $NetBSD: Makefile,v 1.1 2018/12/21 19:00:56 bacon Exp $
+
+DISTNAME=	kallisto-${PV}
+CATEGORIES=	biology
+MASTER_SITES=	${MASTER_SITE_GITHUB:=pachterlab/}
+GITHUB_TAG=	v${PV}
+
+MAINTAINER=	bacon%NetBSD.org@localhost
+HOMEPAGE=	https://pachterlab.github.io/kallisto/
+COMMENT=	Quantify abundances of transcripts from RNA-Seq data
+LICENSE=	2-clause-bsd
+
+USE_LANGUAGES=	c c++
+USE_TOOLS+=	pax
+USE_CMAKE=	yes
+
+SUBST_CLASSES+=		test
+SUBST_STAGE.test=	post-build
+SUBST_FILES.test=	kallisto-test
+SUBST_SED.test=		-e 's|/usr/local/share/kallisto|${DATADIR}|g'
+
+PV=		0.45.0
+DATADIR=	${PREFIX}/share/kallisto
+
+INSTALLATION_DIRS=	bin ${DATADIR}
+
+post-extract:
+	${CP} ${FILESDIR}/kallisto-test ${WRKSRC}
+
+post-install:
+	${INSTALL_SCRIPT} ${WRKSRC}/kallisto-test ${DESTDIR}${PREFIX}/bin
+	cd ${WRKSRC} && pax -rw test ${DESTDIR}${DATADIR}
+
+.include "../../biology/htslib/buildlink3.mk"
+.include "../../devel/hdf5/buildlink3.mk"
+.include "../../wip/libaec/buildlink3.mk"
+.include "../../devel/zlib/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/kallisto/PLIST b/kallisto/PLIST
new file mode 100644
index 0000000000..7835b3fd81
--- /dev/null
+++ b/kallisto/PLIST
@@ -0,0 +1,10 @@
+@comment $NetBSD: PLIST,v 1.1 2018/12/21 19:00:56 bacon Exp $
+bin/kallisto
+bin/kallisto-test
+share/kallisto/test/README.md
+share/kallisto/test/Snakefile
+share/kallisto/test/chrom.txt
+share/kallisto/test/reads_1.fastq.gz
+share/kallisto/test/reads_2.fastq.gz
+share/kallisto/test/transcripts.fasta.gz
+share/kallisto/test/transcripts.gtf.gz
diff --git a/kallisto/distinfo b/kallisto/distinfo
new file mode 100644
index 0000000000..00932381cc
--- /dev/null
+++ b/kallisto/distinfo
@@ -0,0 +1,8 @@
+$NetBSD: distinfo,v 1.1 2018/12/21 19:00:56 bacon Exp $
+
+SHA1 (kallisto-0.45.0.tar.gz) = ab0890c5d675d678dbcf415a86512b4694b3a4a6
+RMD160 (kallisto-0.45.0.tar.gz) = f482f7525dde0bfc2425cf803812c1c7748c882e
+SHA512 (kallisto-0.45.0.tar.gz) = b120c36ccb4725b19307c3e90c7f9b73b87efc53f08d3f2c12fc2e4b7afc3c03c52ba07dff623c9c8ad5a7e89c1eeb907389ccf3e4440236e81a0611500639e2
+Size (kallisto-0.45.0.tar.gz) = 2250430 bytes
+SHA1 (patch-CMakeLists.txt) = 2817091347e35898fec0bab77e8d9cc5ca5fff3f
+SHA1 (patch-src_CMakeLists.txt) = 2ef72024591c5216fbf44fb7cdfa4a8330b0c81a
diff --git a/kallisto/files/kallisto-test b/kallisto/files/kallisto-test
new file mode 100644
index 0000000000..f0b7695224
--- /dev/null
+++ b/kallisto/files/kallisto-test
@@ -0,0 +1,45 @@
+#!/bin/sh
+
+##########################################################################
+#   Script description:
+#       Run standard kallisto test data
+#       
+#   History:
+#   Date        Name        Modification
+#   2016-03-21  J Bacon     Begin
+##########################################################################
+
+usage()
+{
+    printf "Usage: $0 test-directory\n"
+    exit 1
+}
+
+
+##########################################################################
+#   Main
+##########################################################################
+
+if [ $# != 1 ]; then
+    usage
+fi
+
+dir="$1"
+if [ -e "$dir" ]; then
+    printf "$dir already exists.  Remove it first or choose a different name.\n"
+    exit 1
+fi
+
+cp -iR /usr/local/share/kallisto/test/ "$dir"
+cd "$dir"
+kallisto index -i transcripts.idx transcripts.fasta.gz
+kallisto quant -i transcripts.idx -o output -b 100 reads_1.fastq.gz reads_2.fastq.gz
+ls -l output
+more output/abundance.tsv
+
+cat << EOM
+
+See https://pachterlab.github.io/kallisto/starting.html for instructions
+on interpreting the output above.
+
+EOM
diff --git a/kallisto/patches/patch-CMakeLists.txt b/kallisto/patches/patch-CMakeLists.txt
new file mode 100644
index 0000000000..0bd8d403ca
--- /dev/null
+++ b/kallisto/patches/patch-CMakeLists.txt
@@ -0,0 +1,28 @@
+$NetBSD: patch-CMakeLists.txt,v 1.1 2018/12/21 19:00:56 bacon Exp $
+
+# Unbundle htslib
+
+--- CMakeLists.txt.orig	2018-12-19 17:13:04.000000000 +0000
++++ CMakeLists.txt
+@@ -35,21 +35,6 @@ ELSE(LINK MATCHES shared)
+ ENDIF(LINK MATCHES static)
+ 
+ 
+-include(ExternalProject)
+-ExternalProject_Add(htslib
+-    PREFIX ${PROJECT_SOURCE_DIR}/ext/htslib
+-    SOURCE_DIR ${PROJECT_SOURCE_DIR}/ext/htslib
+-    BUILD_IN_SOURCE 1
+-    CONFIGURE_COMMAND autoheader && autoconf && ${PROJECT_SOURCE_DIR}/ext/htslib/configure 
+-        --prefix=${PREFIX} --disable-bz2 --disable-lzma --disable-libcurl
+-    BUILD_COMMAND make lib-static
+-    INSTALL_COMMAND ""
+-)
+-
+-include_directories(${htslib_PREFIX}/src/htslib)
+-
+-
+-
+ # add_compile_options(-Wdeprecated-register)
+ 
+ add_subdirectory(src)
diff --git a/kallisto/patches/patch-src_CMakeLists.txt b/kallisto/patches/patch-src_CMakeLists.txt
new file mode 100644
index 0000000000..bbc8df4a79
--- /dev/null
+++ b/kallisto/patches/patch-src_CMakeLists.txt
@@ -0,0 +1,30 @@
+$NetBSD: patch-src_CMakeLists.txt,v 1.1 2018/12/21 19:00:56 bacon Exp $
+
+# Unbundle htslib
+
+--- src/CMakeLists.txt.orig	2018-10-17 23:58:22 UTC
++++ src/CMakeLists.txt
+@@ -3,15 +3,13 @@ file(GLOB headers *.h *.hpp)
+ 
+ list(REMOVE_ITEM sources main.cpp)
+ 
+-include_directories(../ext/htslib)
+-
+ add_library(kallisto_core ${sources} ${headers})
+ target_include_directories(kallisto_core PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
+ 
+ add_executable(kallisto main.cpp)
+ 
+ find_package( Threads REQUIRED )
+-target_link_libraries(kallisto kallisto_core pthread ${CMAKE_CURRENT_SOURCE_DIR}/../ext/htslib/libhts.a)
++target_link_libraries(kallisto kallisto_core pthread hts)
+ 
+ if(LINK MATCHES static)
+     set(BUILD_SHARED_LIBS OFF)
+@@ -56,4 +54,4 @@ else()
+ endif(LINK MATCHES static)
+ 
+ 
+-install(TARGETS kallisto DESTINATION "${CMAKE_INSTALL_BINDIR}")
+\ No newline at end of file
++install(TARGETS kallisto DESTINATION "${CMAKE_INSTALL_BINDIR}")


Home | Main Index | Thread Index | Old Index