diff --git a/.gitignore b/.gitignore index 5ec6a48..1cfff3b 100755 --- a/.gitignore +++ b/.gitignore @@ -32,3 +32,6 @@ blib/ /MYMETA.yml /MANIFEST !/MANIFEST +/t/_Inline/ +/t/sha1/ +/t/t/plasmids/ diff --git a/lib/panseq.pl b/bin/panseq old mode 100755 new mode 100644 similarity index 87% rename from lib/panseq.pl rename to bin/panseq index 401298d..96bf371 --- a/lib/panseq.pl +++ b/bin/panseq @@ -3,7 +3,7 @@ use strict; use warnings; use FindBin; -use lib "$FindBin::Bin"; +use lib "$FindBin::Bin/../lib/"; use Modules::Setup::Panseq; use Modules::Setup::Settings; use Log::Log4perl qw/:easy/; @@ -19,7 +19,7 @@ tie *STDERR, "Tie::Log4perl"; my $panseq = Modules::Setup::Panseq->new($settings); -Log::Log4perl->init("$FindBin::Bin/log4p.conf"); +Log::Log4perl->init("$FindBin::Bin/../lib/log4p.conf"); $panseq->run(); diff --git a/conda_recipe/build.sh b/conda_recipe/build.sh new file mode 100644 index 0000000..1859758 --- /dev/null +++ b/conda_recipe/build.sh @@ -0,0 +1,26 @@ +#!/bin/bash +# If it has Build.PL use that, otherwise use Makefile.PL +if [ -f Build.PL ]; then + perl Build.PL + sed -i.bak -e '1 s|^.*$|#!/usr/bin/env perl|' Build + ./Build installdeps + # Make sure this goes in site + ./Build install --installdirs site +elif [ -f Makefile.PL ]; then + # Make sure this goes in site + perl Makefile.PL INSTALLDIRS=site + make + make install +else + echo 'Unable to find Build.PL or Makefile.PL. You need to modify build.sh.' + exit 1 +fi + +export PERL5LIB="/opt/conda/lib/perl5/site_perl/5.22.0" +export PERL5LIB="/opt/conda/lib/perl5/site_perl/5.22.0/Modules" +export PERL5LIB="/opt/conda/lib/perl5/site_perl/5.22.0/x86_64-linux-thread-multi:$PERL5LIB" +# Add more build steps here, if they are necessary. + +# See +# http://docs.continuum.io/conda/build.html +# for a list of environment variables that are set during the build process. diff --git a/conda_recipe/meta.yaml b/conda_recipe/meta.yaml new file mode 100644 index 0000000..5bfcc7f --- /dev/null +++ b/conda_recipe/meta.yaml @@ -0,0 +1,28 @@ +package: + name: panseq + version: "3.1.1" + +source: + git_url: https://github.com/chadlaing/Panseq.git + +requirements: + build: + - libgcc + - perl-threaded + - perl-module-build + run: + - libgcc + - mummer + - muscle + - perl-threaded + - perl-module-build + - blast + - perl-archive-zip + - perl-bioperl + - perl-tie-log4perl + + +about: + home: https://github.com/chadlaing/Panseq + license: GNU GENERAL PUBLIC LICENSE + diff --git a/t/output.t b/t/output.t index a076fab..ad72b0f 100644 --- a/t/output.t +++ b/t/output.t @@ -365,7 +365,7 @@ sub _removeRun{ sub _runPanseq{ my $t=shift; - my $systemLine="perl $SCRIPT_LOCATION/../lib/panseq.pl $SCRIPT_LOCATION/$t.batch"; + my $systemLine="perl $SCRIPT_LOCATION/../bin/panseq $SCRIPT_LOCATION/$t.batch"; print "Systemline: $systemLine\n"; system($systemLine); }