Skip to content

Commit

Permalink
version 4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
cmatKhan committed Jun 23, 2023
1 parent 4adf06d commit 7a940f1
Show file tree
Hide file tree
Showing 138 changed files with 382,948 additions and 17 deletions.
23 changes: 6 additions & 17 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,21 +1,10 @@
MIT License
Copyright (c) 2009, Michael R. Brent, Ian Korf, and Paul Flicek
All rights reserved.

Copyright (c) 2023 Brent Lab
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "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 COPYRIGHT HOLDER OR CONTRIBUTORS 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
10 changes: 10 additions & 0 deletions LICENSE~
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Copyright (c) 2009, Michael R. Brent and David Lu
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "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 COPYRIGHT HOLDER OR CONTRIBUTORS 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
210 changes: 210 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,210 @@
###############################################################################
# Makefile for zoe
###############################################################################

###########
# LIBRARY #
###########

LIBRARY = lib/libzoe.a

OBJECTS = \
src/zTools.o\
src/zTBTree.o\
src/bntree/bntree.o\
src/bntree/cache.o\
src/bntree/celllistitem.o\
src/bntree/intlistitem.o\
src/bntree/node.o\
src/zAlignment.o\
src/zAlignmentScanner.o\
src/zAlnFeature.o\
src/zBNTreeModel.o\
src/zConseq.o\
src/zDistribution.o\
src/zDNA.o\
src/zDuration.o\
src/zEstseq.o\
src/zEstseqSearch.o\
src/zFastaFile.o\
src/zFeatureFactory.o\
src/zGTF.o\
src/zHardCoding.o\
src/zHMM.o\
src/zHMM_State.o\
src/zMath.o\
src/zMathTables.o\
src/zModel.o\
src/zPhasePref.o\
src/zProtein.o\
src/zScanner.o\
src/zSeedUtils.o\
src/zSequence.o\
src/zSfeature.o\
src/zStopSeq.o\
src/zTransition.o\
src/zTrellis.o\
src/zViterbi.o\
src/zPairTransition.o\
src/zPairTrellis.o\
src/zPairViterbi.o\

#################
# TEST PROGRAMS #
#################

LFLAGS = -L. -Llib -lzoe -lm

EXE12 = bin/iscan
SRC12 = src/iscan.c
OBJ12 = $(SRC12:.c=.o)

EXE13 = bin/zoe2gtf
SRC13 = src/zoe2gtf.c
OBJ13 = $(SRC13:.c=.o)

EXE15 = bin/pairagon
SRC15 = src/pairagon.c
OBJ15 = $(SRC15:.c=.o)

EXE16 = bin/pairagon2estgen
SRC16 = src/pairagon2estgen.c
OBJ16 = $(SRC16:.c=.o)

EXECUTABLES = $(EXE12) $(EXE13)
PAIRAGON_EXECUTABLES = $(EXE15) $(EXE16)

TABLE = src/zMathTables.c
TABLEGEN = src/zFloatwiseScoreAdd

########################
# Program Options #
########################

BUILD = 20060720RZ
VERSION = 3.5
PROGRAM = Twinscan
PAIRAGON_VERSION = 0.99
PAIRAGON_PROGRAM = Pairagon
GCC_FLAGS = "-W -Wall -Werror -ansi -pedantic -Wwrite-strings"
DIST_FLAGS = "-DBUILD=\\\"$(PROGRAM)\ version\ $(VERSION)\ build\ $(BUILD)\\\" -DNDEBUG -O2"
PAIRAGON_DIST_FLAGS = "-DBUILD=\\\"$(PAIRAGON_PROGRAM)\ version\ $(PAIRAGON_VERSION)\ build\ $(BUILD)\\\" -DNDEBUG -O2"

# In order to make the include file to contain header file dependencies,
# gcc needs a flag to construct this. In another funny SunOS stunt, this
# is entirely different in their cc.
INCLUDE_FLAGS = "-MM"

SPARC_INCLUDE_FLAGS= "-xM1"

ALPHA_FLAGS = "-c99 -msg_enable level5"

SPARC_FLAGS = "-O "

MACOSX_FLAGS = "-Wall -W -O2"
MACOSX_G5_FLAGS="-fast"
# You might have to use -mcpu=7450 if it is not a G5 processor!

############################
# End Program Options #
############################

################################################################################
# TARGETS
################################################################################


all: include $(LIBRARY) $(EXECUTABLES) symlinks

symlinks:
ln -s iscan bin/nscan || :
ln -s iscan bin/twinscan || :

$(LIBRARY): $(OBJECTS)
rm -f $(LIBRARY)
ar cr $(LIBRARY) $(OBJECTS)
ranlib $(LIBRARY)

include:
$(CC) $(INCLUDE_FLAGS) src/*.c > Makefile.include
src/get-glib-flags.sh >> Makefile.include

pairagon-exe: $(LIBRARY) $(PAIRAGON_EXECUTABLES)

clean:
rm -f src/*.o src/bntree/*.o $(LIBRARY) $(PAIRAGON_EXECUTABLES) $(EXECUTABLES) $(TABLE) $(TABLEGEN)
rm -f bin/twinscan bin/nscan

product:
make all CC="gcc" CFLAGS+=$(GCC_FLAGS) CFLAGS+=-march=i686 CFLAGS+=-DNDEBUG CFLAGS+=-O2 CFLAGS+=$(DIST_FLAGS)

gcc-distribution:
make all CC="gcc" CFLAGS+=$(GCC_FLAGS) CFLAGS+=-march=i686 CFLAGS+=-DNDEBUG CFLAGS+=-O2 CFLAGS+=$(DIST_FLAGS)

linux:
make all CC="gcc" CFLAGS+=$(GCC_FLAGS) CFLAGS+=-march=i686 CFLAGS+=-DNDEBUG CFLAGS+=-O2 CFLAGS+=$(DIST_FLAGS)

alpha:
make all CC="cc" CFLAGS+=$(ALPHA_FLAGS) CFLAGS+=$(DIST_FLAGS)

macosx:
make all CC="gcc" CFLAGS+=$(MACOSX_FLAGS) CFLAGS+=$(DIST_FLAGS)

macosxg5:
make all CC="gcc" CFLAGS+=$(MACOSX_FLAGS) CFLAGS+=$(MACOSX_G5_FLAGS) CFLAGS+=$(DIST_FLAGS)

sparc:
make all CC="cc" INCLUDE_FLAGS=$(SPARC_INCLUDE_FLAGS) CFLAGS+=$(SPARC_FLAGS) CFLAGS+=$(DIST_FLAGS)

pairagon-linux:
make pairagon-exe CC="gcc" CFLAGS+=$(GCC_FLAGS) CFLAGS+=$(PAIRAGON_DIST_FLAGS) $(GLIB_FLAGS)

pairagon-sparc:
make pairagon-exe CC="cc" CFLAGS+=$(SPARC_FLAGS) CFLAGS+=$(PAIRAGON_DIST_FLAGS)

pairagon-macosx:
make pairagon-exe CC="cc" CFLAGS+=$(MACOSX_FLAGS) CFLAGS+=$(PAIRAGON_DIST_FLAGS)

pairagon-distro:
make pairagon-exe CC="gcc" CFLAGS+=$(GCC_FLAGS) CFLAGS+=-march=i686 CFLAGS+=$(PAIRAGON_DIST_FLAGS)

.PHONY:include all pairagon-exe clean product gcc-distribution alpha macosx sparc pairagon-linux pairagon-sparc pairagon-macosx pairagon-distro

#######################
# Excecutable Section #
#######################

$(EXE12): $(OBJ12) $(LIBRARY)
$(CC) -o $(EXE12) $(CFLAGS) $(OBJ12) $(LFLAGS) $(GLIB_LFLAGS)

$(EXE13): $(OBJ13) $(LIBRARY)
$(CC) -o $(EXE13) $(CFLAGS) $(OBJ13) $(LFLAGS) $(GLIB_LFLAGS)

$(EXE15): $(OBJ15) $(LIBRARY)
$(CC) -o $(EXE15) $(CFLAGS) $(OBJ15) $(LFLAGS) $(GLIB_LFLAGS)

$(EXE16): $(OBJ16) $(LIBRARY)
$(CC) -o $(EXE16) $(CFLAGS) $(OBJ16) $(LFLAGS) $(GLIB_LFLAGS)

###################
# Inference Rules #
###################

.SUFFIXES : .c .o

.c.o:
$(CC) $(CFLAGS) -c -o $@ $<


#######################
# Source Dependencies #
#######################

$(TABLEGEN): src/zFloatwiseScoreAdd.c
$(CC) $(CFLAGS) -o $(TABLEGEN) src/zFloatwiseScoreAdd.c -lm

$(TABLE): $(TABLEGEN)
./$(TABLEGEN) > $(TABLE)

include Makefile.include

Loading

0 comments on commit 7a940f1

Please sign in to comment.