diff options
author | Petar Petrov <petar.petrov@student.oulu.fi> | 2013-12-14 10:02:36 +0700 |
---|---|---|
committer | Erik Hanson <erik@slackbuilds.org> | 2013-12-14 10:53:06 -0600 |
commit | 2ac64806386fede92fe5e789516808cd23316083 (patch) | |
tree | a35b764c1664bf82fb60362f059ec356139c4264 /academic | |
parent | ae708391b5e8ee2e022b7354dbcd96512d90397c (diff) | |
download | slackbuilds-2ac64806386fede92fe5e789516808cd23316083.tar.gz |
academic/vcftools: Added (A program designed for working with VCF).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'academic')
-rw-r--r-- | academic/vcftools/README | 18 | ||||
-rw-r--r-- | academic/vcftools/References | 10 | ||||
-rw-r--r-- | academic/vcftools/make.patch | 16 | ||||
-rw-r--r-- | academic/vcftools/slack-desc | 19 | ||||
-rw-r--r-- | academic/vcftools/use-dpkg-buildflags.patch | 40 | ||||
-rw-r--r-- | academic/vcftools/vcftools.SlackBuild | 104 | ||||
-rw-r--r-- | academic/vcftools/vcftools.info | 10 |
7 files changed, 217 insertions, 0 deletions
diff --git a/academic/vcftools/README b/academic/vcftools/README new file mode 100644 index 0000000000..de03f3235e --- /dev/null +++ b/academic/vcftools/README @@ -0,0 +1,18 @@ +VCFtools is a program package designed for working with VCF files, +such as those generated by the 1000 Genomes Project. The aim of +VCFtools is to provide methods for working with VCF files: validating, +merging, comparing and calculate some basic population genetic +statistics. + +VCFtools supports the VCF format v4.0. The vcf-validator, Perl API and +scripts now support also VCF format v4.2 and maintain backward +compatibility with older versions. + +If you make use of VCFtools in your research, the authors would +appreciate a citation of the following paper: + +The Variant Call Format and VCFtools, +Petr Danecek, Adam Auton, Goncalo Abecasis, Cornelis A. Albers, +Eric Banks, Mark A. DePristo, Robert Handsaker, Gerton Lunter, +Gabor Marth, Stephen T. Sherry, Gilean McVean, Richard Durbin +and 1000 Genomes Project Analysis Group, Bioinformatics, 2011 diff --git a/academic/vcftools/References b/academic/vcftools/References new file mode 100644 index 0000000000..03bd303faa --- /dev/null +++ b/academic/vcftools/References @@ -0,0 +1,10 @@ +If you make use of VCFtools in your research, the authors would +appreciate a citation of the following paper: + +The Variant Call Format and VCFtools, +Petr Danecek, Adam Auton, Goncalo Abecasis, Cornelis A. Albers, +Eric Banks, Mark A. DePristo, Robert Handsaker, Gerton Lunter, +Gabor Marth, Stephen T. Sherry, Gilean McVean, Richard Durbin +and 1000 Genomes Project Analysis Group, Bioinformatics, 2011 + +http://dx.doi.org/10.1093/bioinformatics/btr330 diff --git a/academic/vcftools/make.patch b/academic/vcftools/make.patch new file mode 100644 index 0000000000..f7cc48b93d --- /dev/null +++ b/academic/vcftools/make.patch @@ -0,0 +1,16 @@ +Description: do not use MAKEFLAGS +Author: Thorsten Alteholz <debian@alteholz.de> +Last-Update: 2011-07-03 +Index: vcftools-0.1.7/Makefile +=================================================================== +--- vcftools_0.1.7.org/Makefile 2011-07-04 15:22:33.000000000 +0200 ++++ vcftools_0.1.7/Makefile 2011-07-04 15:22:56.000000000 +0200 +@@ -22,7 +22,7 @@ + DIRS = cpp perl + install: + @mkdir -p $(BINDIR); mkdir -p $(MODDIR); \ +- for dir in $(DIRS); do cd $$dir && $(MAKE) $(MAKEFLAGS) && cd ..; done ++ for dir in $(DIRS); do cd $$dir && $(MAKE) && cd ..; done + + clean: + @for dir in $(DIRS); do cd $$dir && $(MAKE) clean && cd ..; done diff --git a/academic/vcftools/slack-desc b/academic/vcftools/slack-desc new file mode 100644 index 0000000000..a15655731f --- /dev/null +++ b/academic/vcftools/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +vcftools: vcftools (A program package designed for working with VCF files) +vcftools: +vcftools: VCFtools is a program package designed for working with VCF +vcftools: files such as those generated by the 1000 Genomes Project. +vcftools: The aim of VCFtools is to provide methods for working with +vcftools: VCF files: validating, merging, comparing and calculate some +vcftools: basic population genetic statistics. +vcftools: +vcftools: Home: http://vcftools.sourceforge.net/ +vcftools: References: /usr/doc/vcftools-0.1.11/References +vcftools: diff --git a/academic/vcftools/use-dpkg-buildflags.patch b/academic/vcftools/use-dpkg-buildflags.patch new file mode 100644 index 0000000000..3bd8521a3a --- /dev/null +++ b/academic/vcftools/use-dpkg-buildflags.patch @@ -0,0 +1,40 @@ +Author: Andreas Tille <tille@debian.org> +Date: Sat, 12 May 2012 09:31:58 +0200 +Description: Enable propagation of hardening flags + +Index: vcftools_0.1.11/cpp/Makefile +=================================================================== +--- vcftools_0.1.11.orig/cpp/Makefile 2013-06-13 16:40:54.000000000 +0200 ++++ vcftools_0.1.11/cpp/Makefile 2013-06-27 19:54:45.000000000 +0200 +@@ -12,9 +12,9 @@ + VCFTOOLS_PCA = 0 + endif + # Compiler flags +-CFLAGS = -O2 -m64 ++CFLAGS += -O2 + #CFLAGS = -Wall -O2 -pg -m64 +-CPPFLAGS = -O2 -D_FILE_OFFSET_BITS=64 ++CPPFLAGS += -O2 -D_FILE_OFFSET_BITS=64 + #CPPFLAGS = -O2 -Wall -pg -D_FILE_OFFSET_BITS=64 + # Included libraries (zlib) + LIB = -lz +@@ -38,7 +38,7 @@ + endif + + vcftools: $(OBJS) +- $(CPP) $(CPPFLAGS) $(OBJS) -o vcftools $(LIB) ++ $(CPP) $(CPPFLAGS) $(OBJS) $(LDFLAGS) -o vcftools $(LIB) + ifdef BINDIR + cp $(CURDIR)/$@ $(BINDIR)/$@ + endif +@@ -50,8 +50,8 @@ + -include $(OBJS:.o=.d) + + %.o: %.cpp +- $(CPP) -c $(CPPFLAGS) $*.cpp -o $*.o +- $(CPP) -MM $(CPPFLAGS) $*.cpp > $*.d ++ $(CPP) -c $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $*.cpp -o $*.o ++ $(CPP) -MM $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $*.cpp > $*.d + + # remove compilation products + clean: diff --git a/academic/vcftools/vcftools.SlackBuild b/academic/vcftools/vcftools.SlackBuild new file mode 100644 index 0000000000..506bba88d1 --- /dev/null +++ b/academic/vcftools/vcftools.SlackBuild @@ -0,0 +1,104 @@ +#!/bin/sh + +# Slackware build script for vcftools + +# Copyright 2013 Petar Petrov, petar.petrov@student.oulu.fi +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PRGNAM=vcftools +VERSION=${VERSION:-0.1.11} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf ${PRGNAM}_${VERSION} +tar xvf $CWD/${PRGNAM}_${VERSION}.tar.gz +cd ${PRGNAM}_${VERSION} +chown -R root:root . +find -L . \ + \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ + -o -perm 511 \) -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +# Thanks to Debian for the patches +patch -p1 -i $CWD/make.patch +patch -p1 -i $CWD/use-dpkg-buildflags.patch + +# Set the proper, architecture-specific path +sed -i "s:/lib/perl5/site_perl:/lib${LIBDIRSUFFIX}/perl5:g" Makefile + +# It seems that if you run just "make" as root, it will _install_ the +# executables and perl files before the package is even created... +CFLAGS="$SLKCFLAGS" \ +CPPFLAGS="$SLKCFLAGS" \ +PREFIX=$PKG/usr \ +make install + +# Copy examples +mkdir -p $PKG/usr/share/$PRGNAM +cp -a examples $PKG/usr/share/$PRGNAM + +find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a \ + README.txt perl/ChangeLog website/*.pdf \ + $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +cat $CWD/References > $PKG/usr/doc/$PRGNAM-$VERSION/References + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/academic/vcftools/vcftools.info b/academic/vcftools/vcftools.info new file mode 100644 index 0000000000..b754295189 --- /dev/null +++ b/academic/vcftools/vcftools.info @@ -0,0 +1,10 @@ +PRGNAM="vcftools" +VERSION="0.1.11" +HOMEPAGE="http://vcftools.sourceforge.net/" +DOWNLOAD="http://sourceforge.net/projects/vcftools/files/vcftools_0.1.11.tar.gz" +MD5SUM="ddb49e9fa2bfedae36b4dce163adfaa8" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="Petar Petrov" +EMAIL="petar.petrov@student.oulu.fi" |