rpms/lagan/devel lagan.spec, NONE, 1.1 lagan12-chris.patch, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
Christian Iseli (c4chris)
fedora-extras-commits at redhat.com
Mon Jan 30 00:16:21 UTC 2006
Author: c4chris
Update of /cvs/extras/rpms/lagan/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv19321/devel
Modified Files:
.cvsignore sources
Added Files:
lagan.spec lagan12-chris.patch
Log Message:
auto-import lagan-1.21-1 on branch devel from lagan-1.21-1.src.rpm
--- NEW FILE lagan.spec ---
Name: lagan
Version: 1.21
Release: 1%{?dist}
Summary: Local, global, and multiple alignment of DNA sequences
Group: Applications/Engineering
License: GPL
URL: http://lagan.stanford.edu
Source0: http://lagan.stanford.edu/lagan_web/lagan12.tar.gz
Patch0: lagan12-chris.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#BuildRequires:
#Requires:
%description
LAGAN toolkit is a set of tools for local, global, and multiple alignment of
DNA sequences. Please visit http://lagan.stanford.edu for publications
describing LAGAN and its components.
The 4 main parts of LAGAN are:
1. CHAOS local alignment tool
2. LAGAN pairwise global alignment tool
3. MLAGAN multiple global alignment tool.
4. Shuffle-LAGAN pairwise glocal alignment
%prep
%setup -q -n lagan12
%patch0 -p1 -b .chris
sed -i 's/^CC .*$/CC = gcc $(RPM_OPT_FLAGS)/;
s/^CPP .*$/CPP = g++ $(RPM_OPT_FLAGS)/' Makefile
sed -i 's|getenv ("LAGAN_DIR")|"%_libdir/lagan"|g' *.c* utils/*.c*
sed -i 's|$ENV{LAGAN_DIR}|"%_libdir/lagan"|g' *.pl utils/*.pl
sed -i 's|$LAGAN_DIR|%_libdir/lagan|g' Readmes/README.shuffle
%build
make %{?_smp_mflags}
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/%_bindir $RPM_BUILD_ROOT/%_libdir/lagan/utils
install -m755 chaos ${RPM_BUILD_ROOT}%{_bindir}
install -m755 mlagan ${RPM_BUILD_ROOT}%{_bindir}
install -m755 lagan.pl ${RPM_BUILD_ROOT}%{_bindir}/lagan
install -m755 slagan.pl ${RPM_BUILD_ROOT}%{_bindir}/slagan
for f in anal_gloc.pl anchors glocal order rechaos.pl; do
install -m755 $f $RPM_BUILD_ROOT/%_libdir/lagan
done
for f in bin2bl bin2mf cextract cmerge2.pl contigorder cstat dotplot \
draft.pl fa2xfa getbounds getcontigpos getlength getoverlap Glue \
mextract.pl mf2bin.pl mpretty.pl mproject.pl mrunfile.pl mrunpairs.pl \
mrun.pl mviz.pl rc scorealign scorecontigs seqmerge; do
install -m755 utils/$f $RPM_BUILD_ROOT/%_libdir/lagan/utils
done
install -m644 *.txt $RPM_BUILD_ROOT/%_libdir/lagan
rm -f Readmes/*.chris
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc Readmes/* sample.*
%_bindir/chaos
%_bindir/lagan
%_bindir/mlagan
%_bindir/slagan
%_libdir/lagan/
%changelog
* Mon Jan 30 2006 Christian Iseli <Christian.Iseli at licr.org> 1.21-1
- Use _libdir instead of _libexecdir and kill all LAGAN_DIR refs.
* Thu Nov 17 2005 Christian Iseli <Christian.Iseli at licr.org> 1.21-0
- Create spec file.
lagan12-chris.patch:
--- NEW FILE lagan12-chris.patch ---
--- lagan12/utils/scorecontigs.c.chris 2003-09-22 19:06:56.000000000 +0200
+++ lagan12/utils/scorecontigs.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,4 +1,5 @@
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <assert.h>
@@ -234,6 +235,13 @@
return r;
}
+inline int getdata (rangelist **ranges, int *offs, int j, int i){
+ i -= offs[j];
+ if (i >= 0 && i < ranges[j]->seqlen)
+ return ranges[j]->score[i];
+ return 0;
+}
+
inline int match (rangelist **ranges, int numContigs, int i, int j, int *offs){
int k;
for (k = 0; k < numContigs; k++)
@@ -257,13 +265,6 @@
printf ("\n");
}
-inline int getdata (rangelist **ranges, int *offs, int j, int i){
- i -= offs[j];
- if (i >= 0 && i < ranges[j]->seqlen)
- return ranges[j]->score[i];
- return 0;
-}
-
void printRanges (rangelist **ranges, int numContigs, int seqLen, int *offs){
int i, j, start = 0, end;
int *score = (int *) malloc (sizeof (int) * numContigs);
--- lagan12/utils/getbounds.c.chris 2003-09-22 19:06:55.000000000 +0200
+++ lagan12/utils/getbounds.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,4 +1,5 @@
#include <stdio.h>
+#include <stdlib.h>
#include <assert.h>
#include <ctype.h>
#include <string.h>
--- lagan12/utils/mrunpairs.pl.chris 2003-09-22 19:06:56.000000000 +0200
+++ lagan12/utils/mrunpairs.pl 2006-01-30 01:05:25.000000000 +0100
@@ -5,7 +5,7 @@
# VISTA .plotfile defaults
-($lagandir = $ENV{LAGAN_DIR}) or die "LAGAN_DIR not set";
+$lagandir = $ENV{LAGAN_DIR};
$paregmin = 75;
$paregmax = 100;
@@ -87,11 +87,6 @@
@params[++$j] = "\"()\"";
}
-if ($lagandir eq "") {
- print ("Must specify environment variable LAGAN_DIR\n");
- exit(1);
-}
-
$mextstr = "$lagandir/mextract.pl $filename";
print "$mextstr\n";
if(!`$mextstr`) { print "\nMulti-FASTA extraction failure...\n"; exit(1); }
@@ -189,7 +184,7 @@
$mparams = "$mparams $s";
}
- $mlagan = "$lagandir/mlagan$mfiles$mparams > $outprefix.out";
+ $mlagan = "mlagan$mfiles$mparams > $outprefix.out";
print "\n$mlagan\n\n";
if(`$mlagan`) { print "\n\n"; exit(1); }
--- lagan12/utils/draft.pl.chris 2003-09-22 19:06:55.000000000 +0200
+++ lagan12/utils/draft.pl 2006-01-30 01:05:25.000000000 +0100
@@ -109,7 +109,7 @@
$skip1 = $skip2 = 0;
# make alignments
if (!$lazyflag || !(-e "$contigs[$i].mfa")){
- $execute = "perl $lagandir/lagan.pl $ARGV[0] $contigs[$i] -mfa $arglist -out $contigs[$i].mfa";
+ $execute = "lagan $ARGV[0] $contigs[$i] -mfa $arglist -out $contigs[$i].mfa";
$execute = $execute." -gap $anchgapstart $anchgapcont" if ($usebounds);
`$execute`;
$ex_val = $? >> 8;
@@ -128,7 +128,7 @@
}
if (!$lazyflag || !(-e "$contigs[$i].rc.mfa")){
- $execute = "perl $lagandir/lagan.pl $ARGV[0] $contigs[$i].rc -mfa $arglist -out $contigs[$i].rc.mfa";
+ $execute = "lagan $ARGV[0] $contigs[$i].rc -mfa $arglist -out $contigs[$i].rc.mfa";
$execute = $execute." -gap $anchgapstart $anchgapcont" if ($usebounds);
`$execute`;
$ex_val = $? >> 8;
--- lagan12/utils/mrunfile.pl.chris 2003-09-22 19:06:55.000000000 +0200
+++ lagan12/utils/mrunfile.pl 2006-01-30 01:05:25.000000000 +0100
@@ -8,7 +8,7 @@
exit(1);
}
-($lagandir = $ENV{LAGAN_DIR}) or die "LAGAN_DIR not set";
+$lagandir = $ENV{LAGAN_DIR};
$filename = $ARGV[0];
@@ -48,11 +48,6 @@
}
}
-if ($lagandir eq "") {
- print ("Must specify environment variable LAGAN_DIR\n");
- exit(1);
-}
-
if ($pairwise) {
$mexecs = "mrunpairs.pl";
} else {
--- lagan12/utils/getlength.c.chris 2003-09-22 19:06:55.000000000 +0200
+++ lagan12/utils/getlength.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,4 +1,5 @@
#include <stdio.h>
+#include <stdlib.h>
#include <ctype.h>
#include <string.h>
#include <assert.h>
--- lagan12/utils/mviz.pl.chris 2003-09-22 19:06:56.000000000 +0200
+++ lagan12/utils/mviz.pl 2006-01-30 01:05:25.000000000 +0100
@@ -4,7 +4,7 @@
# This script requires the environment variables:
# LAGAN_DIR and VISTA_DIR
-($lagandir = $ENV{LAGAN_DIR}) or die "LAGAN_DIR not set";
+$lagandir = $ENV{LAGAN_DIR};
$paregmin = 75;
$paregmax = 100;
@@ -57,11 +57,6 @@
$seqfile = @ARGV[0];
-if ($lagandir eq "") {
- print ("Must specify environment variable LAGAN_DIR\n");
- exit(1);
-}
-
for ($i=0; $i<@vparams; $i+=2) {
if (@vparams[$i] eq "--regmin") { $paregmin = @vparams[$i+1]; }
elsif (@vparams[$i] eq "--regmax") { $paregmax = @vparams[$i+1]; }
--- lagan12/utils/scorealign.c.chris 2003-09-22 19:06:56.000000000 +0200
+++ lagan12/utils/scorealign.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,5 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include <ctype.h>
#include <assert.h>
#include <math.h>
@@ -401,10 +402,6 @@
char *lagan_dir;
lagan_dir = getenv ("LAGAN_DIR");
- if (!lagan_dir){
- fprintf (stderr, "Error: $LAGAN_DIR not set.\n");
- exit (1);
- }
sprintf (line, "%s/%s", lagan_dir, filename);
fprintf (stderr, "%s\n", line);
--- lagan12/utils/seqmerge.c.chris 2003-09-22 19:06:56.000000000 +0200
+++ lagan12/utils/seqmerge.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,4 +1,5 @@
#include <stdio.h>
+#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <assert.h>
--- lagan12/utils/mrun.pl.chris 2003-09-22 19:06:56.000000000 +0200
+++ lagan12/utils/mrun.pl 2006-01-30 01:05:25.000000000 +0100
@@ -5,7 +5,7 @@
# VISTA .plotfile defaults
-($lagandir = $ENV{LAGAN_DIR}) or die "LAGAN_DIR not set";
+$lagandir = $ENV{LAGAN_DIR};
$paregmin = 75;
$paregmax = 100;
@@ -87,11 +87,6 @@
exit(1);
}
-if ($lagandir eq "") {
- print ("Must specify environment variable LAGAN_DIR\n");
- exit(1);
-}
-
$mextstr = "$lagandir/utils/mextract.pl $filename";
print "$mextstr\n";
if(!`$mextstr`) { print "\nMulti-FASTA extraction failure...\n"; exit(1); }
@@ -169,7 +164,7 @@
$mparams = "$mparams $s";
}
-$mlagan = "$lagandir/mlagan$mfiles$mparams > $prefix.out";
+$mlagan = "mlagan$mfiles$mparams > $prefix.out";
print STDERR "\n$mlagan\n\n";
if(`$mlagan`) { print "\n\n"; exit(1); }
--- lagan12/slagan.pl.chris 2003-10-20 13:29:56.000000000 +0200
+++ lagan12/slagan.pl 2006-01-30 01:05:25.000000000 +0100
@@ -84,7 +84,7 @@
chomp $seq1len;
chomp $seq2len;
-`$lagandir/chaos $seq1 $seq2 $chaos_fl > chaos.$$`;
+`chaos $seq1 $seq2 $chaos_fl > chaos.$$`;
if ($?) { exit(1); }
`$lagandir/glocal chaos.$$ $glocal_fl > out.$$`;
@regs = `$lagandir/anal_gloc.pl < out.$$`;
@@ -138,7 +138,7 @@
if ($extra2) {
`$lagandir/utils/fa2xfa $seq2 $startreg2 $endreg2 2 $rcf > seq2$k.$$.masked\n`;
}
- `$lagandir/lagan.pl seq1$k.$$ seq2$k.$$ $arglist $lagan_fl -mfa -out lagan.$k.$$\n`;
+ `lagan seq1$k.$$ seq2$k.$$ $arglist $lagan_fl -mfa -out lagan.$k.$$\n`;
$suff = "";
if ($outfile) {
$suff = " >> $outfile";
--- lagan12/mlagan.c.chris 2003-09-22 19:06:54.000000000 +0200
+++ lagan12/mlagan.c 2006-01-30 01:05:25.000000000 +0100
@@ -824,10 +824,6 @@
outfile = stdout;
lagan_dir = getenv ("LAGAN_DIR");
- if (!lagan_dir) {
- fprintf(stderr, "Environment variable LAGAN_DIR not set\n");
- exit(1);
- }
buildcache();
initLib();
--- lagan12/translate.c.chris 2003-09-22 19:06:54.000000000 +0200
+++ lagan12/translate.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,5 +1,6 @@
#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include "fchaos.h"
#include "translate.h"
#include "assert.h"
--- lagan12/lagan.pl.chris 2003-09-22 19:06:54.000000000 +0200
+++ lagan12/lagan.pl 2006-01-30 01:05:25.000000000 +0100
@@ -105,13 +105,13 @@
$rundraft = 1;
}
elsif ($ARGV[$i] =~ /-cons/){
- $draftparams = $draftparams." -cons $ARGV[$++i]";
+ $draftparams = $draftparams." -cons ".$ARGV[++$i];
}
elsif ($ARGV[$i] =~ /-draftskipfr/){
- $draftparams = $draftparams." -skipfr $ARGV[$++i]";
+ $draftparams = $draftparams." -skipfr ".$ARGV[++$i];
}
elsif ($ARGV[$i] =~ /-lazy/){
- $draftparams = $draftparams." -cons $ARGV[$++i]";
+ $draftparams = $draftparams." -cons ".$ARGV[++$i];
}
else {
@@ -233,7 +233,7 @@
# `$lagandir/utils/rm $infofilename` if ($binfile);
}
-`rm $secondName` if ($rcflag);
+`rm $secondName` if ($rcFlag);
`rm $$.*`;
if ($?) { exit(1); }
--- lagan12/Readmes/README.FIRST.chris 2003-11-10 11:30:28.000000000 +0100
+++ lagan12/Readmes/README.FIRST 2006-01-30 01:05:25.000000000 +0100
@@ -30,8 +30,7 @@
glocal as well as many tools in the utils directory.
You may also need to go into all the .pl file, and change the first line
-to call your perl interpreter. You must also specify an environment
-variable $LAGAN_DIR to point to the directory where you installed LAGAN.
+to call your perl interpreter.
Because LAGAN uses no system-dependent or implementation dependent
libraries it should compile on all platforms and ANSI C compilers.
--- lagan12/Readmes/README.shuffle.chris 2003-09-23 13:08:17.000000000 +0200
+++ lagan12/Readmes/README.shuffle 2006-01-30 01:05:25.000000000 +0100
@@ -13,14 +13,13 @@
If you received Shuffle-LAGAN as part of the LAGAN toolkit it is installed
automatically with the rest of the package. If you got it seperately, you
should merge the included files into the directories used by CHAOS and
-LAGAN (i.e. contents of the utils subdirectory should go into
-$LAGAN_DIR/utils). The code assumes $LAGAN_DIR has been set.
+LAGAN.
2. Running
Just give it two sequences and let it roll:
-#slagan.pl seq1.fa seq2.fa
+#slagan seq1.fa seq2.fa
3. Input
--- lagan12/Readmes/README.chaos.chris 2003-11-10 11:32:58.000000000 +0100
+++ lagan12/Readmes/README.chaos 2006-01-30 01:05:25.000000000 +0100
@@ -29,13 +29,7 @@
Because CHAOS uses no system-dependent or implementation dependent libraries
it should compile on all platforms and ANSI C compilers. If you have problems
-compiling the sources please e-mail the author. You will need to also set the
-environment variable LAGAN_DIR to the directory where you installed CHAOS. in
-c-shell this can be done by executing
-
-% setenv LAGAN_DIR `pwd`
-
-on the prompt. For other shells the command differs.
+compiling the sources please e-mail the author.
II Description
CHAOS is a heuristic local alignment tool optimized for non-coding
--- lagan12/Readmes/README.lagan.chris 2003-09-23 14:35:27.000000000 +0200
+++ lagan12/Readmes/README.lagan 2006-01-30 01:05:25.000000000 +0100
@@ -20,7 +20,7 @@
3. Doing global alignment in a limited area of thw NW matrix given the set of
anchors (order tool).
-lagan.pl is the main executable that calls the three steps.
+lagan is the main executable that calls the three steps.
II Usage
--- lagan12/rechaos.pl.chris 2003-09-22 19:06:54.000000000 +0200
+++ lagan12/rechaos.pl 2006-01-30 01:05:25.000000000 +0100
@@ -181,11 +181,11 @@
# print STDERR "-----------------\n";
# print STDERR `cat $$.anchs.pairs`;
# print STDERR "-----------------\n";
-# print STDERR "$lagandir/chaos $seq1 $seq2 -wl $wordlen -nd $degeneracy -co $cutoff $extraparams $gfc $chaosfl -pairs $$.anchs.pairs > $$.anchtemp";
+# print STDERR "chaos $seq1 $seq2 -wl $wordlen -nd $degeneracy -co $cutoff $extraparams $gfc $chaosfl -pairs $$.anchs.pairs > $$.anchtemp";
# PERFORM THE ALIGNMENTS USING CHAOS
- `$lagandir/chaos $seq1 $seq2 $extraparams -wl $wordlen -nd $degeneracy -co $cutoff $gfc $chaosfl -pairs $$.anchs.pairs > $$.anchtemp`;
+ `chaos $seq1 $seq2 $extraparams -wl $wordlen -nd $degeneracy -co $cutoff $gfc $chaosfl -pairs $$.anchs.pairs > $$.anchtemp`;
if ($?) { exit(1); }
# ADD IN BOUNDARIES
@@ -238,7 +238,6 @@
@b2new = 0;
@e1new = 0;
@e2new = 0;
- @scores = 0;
$app_str = "";
--- lagan12/global.c.chris 2003-09-22 19:06:54.000000000 +0200
+++ lagan12/global.c 2006-01-30 01:05:25.000000000 +0100
@@ -1,5 +1,6 @@
#include "global.h"
#include <stdlib.h>
+#include <stdio.h>
extern int indeces[256];
--- lagan12/glocal.c.chris 2006-01-30 01:05:40.000000000 +0100
+++ lagan12/glocal.c 2006-01-30 01:06:36.000000000 +0100
@@ -123,9 +123,9 @@
/* Put -infinity in cBound and dBound and rightCBound */
- cBound * c = createCBound ( LONG_MIN / 2, dummyownerLeft );
- dBound * d = createDBound ( LONG_MIN / 2, dummyownerLeft );
- dBound * rightC = createDBound ( LONG_MIN / 2, dummyownerRight );
+ cBound * c = createCBound ( INT_MIN / 2, dummyownerLeft );
+ dBound * d = createDBound ( INT_MIN / 2, dummyownerLeft );
+ dBound * rightC = createDBound ( INT_MIN / 2, dummyownerRight );
insertCBound ( cBoundTreeRoot[i], c, i );
insertDBound ( dBoundTreeRoot[i], d, i );
@@ -1680,7 +1680,7 @@
if ( ( cSucc != NULL ) &&
( cSucc->intpoint == NULL ) &&
- ( cSucc->column != LONG_MIN / 2 ) ){
+ ( cSucc->column != INT_MIN / 2 ) ){
point * intpt = createPoint ( ( cSucc->column - ( curpoint->y - curpoint->x ) ),
( cSucc->column ),
@@ -1848,7 +1848,7 @@
// Add intersection of d->diagonal and curpoint->column.
- if ( d->diagonal != LONG_MIN / 2 ){
+ if ( d->diagonal != INT_MIN / 2 ){
point * intpt = createPoint ( ( curpoint->y - d->diagonal ),
( curpoint->y ),
@@ -1905,7 +1905,7 @@
if ( ( dPred != NULL ) &&
( dPred->intpoint == NULL ) &&
- ( dPred->diagonal != LONG_MIN / 2 ) ){
+ ( dPred->diagonal != INT_MIN / 2 ) ){
point * intpt = createPoint ( ( curpoint->y - dPred->diagonal ),
( curpoint->y ),
@@ -2279,7 +2279,7 @@
if ( ( dPred != NULL ) &&
( dPred->intpoint == NULL ) &&
- ( dPred->diagonal != LONG_MIN / 2 ) ){
+ ( dPred->diagonal != INT_MIN / 2 ) ){
point * intpt = createPoint ( ( curpoint->y - dPred->diagonal ),
( curpoint->y ),
Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/lagan/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 30 Jan 2006 00:15:28 -0000 1.1
+++ .cvsignore 30 Jan 2006 00:16:20 -0000 1.2
@@ -0,0 +1 @@
+lagan12.tar.gz
Index: sources
===================================================================
RCS file: /cvs/extras/rpms/lagan/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 30 Jan 2006 00:15:28 -0000 1.1
+++ sources 30 Jan 2006 00:16:20 -0000 1.2
@@ -0,0 +1 @@
+e45c9287d04b31924115869588f1fb61 lagan12.tar.gz
More information about the fedora-extras-commits
mailing list