1 #################################################################
2 # Makefile for HMMER: Main project directory: installation, documentation
3 # CVS $Id: Makefile.in,v 1.1.1.1 2005/03/22 08:33:51 cmzmasek Exp $
5 # HMMER - Biological sequence analysis with profile HMMs
6 # Copyright (C) 1992-1999 Washington University School of Medicine
9 # This source code is distributed under the terms of the
10 # GNU General Public License. See the files COPYING and LICENSE
14 # On most Unices, you can build the package without modifying anything
15 # by just typing "./configure; make".
17 # You may want to modify the following make variables:
18 # BINDIR - where the executables will be installed by a 'make install'
19 # MANDIR - where the man pages will be installed by a 'make install'
20 # CC - which compiler to use
21 # CFLAGS - compiler flags to use
23 # where you want things installed
24 # Sort of uses GNU coding standards. ${prefix} might be /usr/local.
25 # ${exec_prefix} gives you some flexibility for installing architecture
26 # dependent files (e.g. the programs): an example ${exec_prefix} might be
30 exec_prefix = @exec_prefix@
34 # how to install the man pages;
35 # cp is generally fine, unless you preformat your pages.
40 # your compiler and compiler flags
46 ## You should not need to modify below this line.
47 ## Much of it is concerned with maintenance of the development version
48 ## and building the release (indeed, several commands will only work in
56 RELEASEDATE = "August 2001"
57 COPYRIGHT = "Copyright \(C\) 1992-2001 HHMI/Washington University School of Medicine"
58 LICENSE = "Freely distributed under the GNU General Public License \(GPL\)"
62 # The program lists below for HMMER and SQUID are not necessarily
63 # a complete manifest. They are the list of stable programs that the
64 # package will install. There must be a man page for each one of them
65 # in the appropriate places (documentation/man for HMMER, squid/Man
66 # for the SQUID library).
88 # all: Compile everything (except the testsuite),
89 # and stick the supported programs in binaries/
92 @if test -d binaries; then\
93 echo "You appear to already have a compiled HMMER distribution.";\
94 echo "You don't need to make.";\
96 echo "If I'm wrong, it's because I'm only looking to see if you have";\
97 echo "a 'binaries' directory; do 'make distclean' to revert HMMER";\
98 echo "to a pristine source distribution.";\
100 (cd squid; make CC="$(CC)" CFLAGS="$(CFLAGS)"; make module);\
101 (cd src; make CC="$(CC)" CFLAGS="$(CFLAGS)"; make module);\
103 for prog in $(PROGS) $(PVMPROGS); do\
104 mv src/$$prog binaries/;\
106 for prog in $(SQUIDPROGS); do\
107 mv squid/$$prog binaries/;\
112 # create the version.h file that will define stamps used by
113 # squidcore.c's Banner(), which is called by all executables to
114 # print a standard package/copyright/license banner;
115 # then puts copies of version.h in all directories that are
116 # going to need it -- HMMER src/ and any modules of mine that
117 # also produce installed executables (squid/)
120 echo "/* version.h -- automatically generated by a Makefile. DO NOT EDIT. */" > version.h
121 echo "#define PACKAGE \"$(PACKAGE)\"" >> version.h
122 echo "#define RELEASE \"$(RELEASE)\"" >> version.h
123 echo "#define RELEASEDATE \"$(RELEASEDATE)\"" >> version.h
124 echo "#define COPYRIGHT \"$(COPYRIGHT)\"" >> version.h
125 echo "#define LICENSE \"$(LICENSE)\"" >> version.h
129 # check: compiles and runs test suite in testsuite/
130 # These are public tests, distributed with the package.
132 check: squid/libsquid.a src/libhmmer.a
133 (cd testsuite; make CC="$(CC)" CFLAGS="$(CFLAGS)")
134 (cd testsuite; make check)
136 squid/libsquid.a: version.h
137 (cd squid; make CC="$(CC)" CFLAGS="$(CFLAGS)"; make module)
139 src/libhmmer.a: version.h
140 (cd src; make CC="$(CC)" CFLAGS="$(CFLAGS)"; make module)
143 # install: installs the binaries in BINDIR/
144 # installs man pages in MANDIR/man1/ (e.g. if MANSUFFIX is 1)
146 for file in $(PROGS) $(SQUIDPROGS) $(PVMPROGS); do\
147 cp binaries/$$file $(BINDIR)/;\
149 for file in hmmer $(PROGS) $(SQUIDPROGS); do\
150 $(INSTMAN) documentation/man/$$file.man $(MANDIR)/man$(MANSUFFIX)/$$file.$(MANSUFFIX);\
152 for file in $(SQUIDPROGS); do\
153 $(INSTMAN) squid/Man/$$file.man $(MANDIR)/man$(MANSUFFIX)/$$file.$(MANSUFFIX);\
156 # "make clean" removes almost everything except configuration files
159 -rm -f *.o *~ Makefile.bak core TAGS gmon.out
161 (cd squid; make clean)
162 (cd testsuite; make clean)
164 # "make distclean" leaves a pristine source distribution.
168 -rm config.cache config.log config.status
171 (cd src; make distclean)
172 (cd squid; make distclean)
173 (cd testsuite; make distclean)
176 # verify: consistency checks on the package
177 # These are private tests, not distributed with HMMER
179 @echo Checking options for consistency and documentation...
180 @for prog in $(PROGS) $(SQUIDPROGS); do\
181 ./checkoptions.pl $$prog;\
184 # doc: build the Userguide and on-line manual
189 # dist: build a new distribution directory in hmmer-$RELEASE
190 # Exports from the CVS repository.
191 # tags RCS files with $(RELCODE) for later reconstruction
192 # squid RCS files are tagged with hmmer$(RELCODE).
193 # Adds a license statement to each file that has a @ LICENSE @ line.
194 # Virtually identical to squid's make dist -- keep them in sync!
196 # Delete old versions of the same release
198 @if test -d ${BASENAME}-$(RELEASE); then rm -rf ${BASENAME}-$(RELEASE); fi
199 @if test -e ${BASENAME}-$(RELEASE).tar; then rm -f ${BASENAME}-$(RELEASE).tar; fi
200 @if test -e ${BASENAME}-$(RELEASE).tar.Z; then rm -f ${BASENAME}-$(RELEASE).tar.Z; fi
201 @if test -e ${BASENAME}-$(RELEASE).tar.gz; then rm -f ${BASENAME}-$(RELEASE).tar.gz; fi
203 # CVS tag and extract. -c: make sure we committed;
204 # -F: allow more than one "make dist" per rel
205 # prep: must have done "cvs commit", and CVSROOT must be set
206 # We also need the squid library, so tag and export it too.
208 cvs tag -F $(RELCODE)
209 cvs export -r $(RELCODE) -d ${BASENAME}-${RELEASE} ${BASENAME}
210 cvs rtag -F ${RELCODE} squid
211 (cd ${BASENAME}-${RELEASE}; cvs export -r ${RELCODE} -d squid squid)
213 # Make the configure scripts from configure.in
215 (cd ${BASENAME}-${RELEASE}; autoconf)
216 (cd ${BASENAME}-${RELEASE}/squid; autoconf)
218 # Include the appropriate license files and release notes
220 cp Licenses/LICENSE.$(LICENSETAG) ${BASENAME}-$(RELEASE)/LICENSE
221 cp Licenses/COPYING.$(LICENSETAG) ${BASENAME}-$(RELEASE)/COPYRIGHT
222 -cp Release-Notes/RELEASE-$(RELEASE) ${BASENAME}-$(RELEASE)/NOTES
224 # Attach license stamps on files that need 'em (replace LICENSE keyword)
225 # licenseadd.pl is basically harmless, so we can overannotate here by
226 # trying to licenseadd everything.
228 find ${BASENAME}-${RELEASE} -type f -exec licenseadd.pl Licenses/$(LICENSETAG) {} \;
230 # Compilation of the documentation.
231 # Documentation is not provided in source form.
233 (cd documentation/userguide; make clean)
234 (cd documentation/userguide; make pdf)
235 cp -f documentation/userguide/Userguide.pdf build/hmmer-$(RELEASE)/
237 # Remove CVS-controlled files/directories that don't belong in
240 -rm -rf ${BASENAME}-${RELEASE}/Bugs
241 -rm -rf ${BASENAME}-${RELEASE}/CHECKLIST
242 -rm -rf ${BASENAME}-${RELEASE}/Internal-Notes
243 -rm -rf ${BASENAME}-${RELEASE}/Licenses
244 -rm -rf ${BASENAME}-${RELEASE}/MAILING_LIST
245 -rm -rf ${BASENAME}-${RELEASE}/Release-Notes
246 -rm -rf ${BASENAME}-${RELEASE}/configure.in
247 -rm -rf ${BASENAME}-${RELEASE}/checkoptions.pl
248 -rm -rf ${BASENAME}-${RELEASE}/licenseadd.pl
249 -rm -rf ${BASENAME}-${RELEASE}/nodebuild
250 -rm -rf ${BASENAME}-${RELEASE}/rootbuild
251 -rm -rf ${BASENAME}-${RELEASE}/buildall
252 -rm -rf ${BASENAME}-${RELEASE}/documentation/userguide
253 -rm -rf ${BASENAME}-${RELEASE}/squid/Licenses
254 -rm -rf ${BASENAME}-${RELEASE}/squid/LOG
255 -rm -rf ${BASENAME}-${RELEASE}/squid/configure.in
259 tar cvf ${BASENAME}-${RELEASE}.tar ${BASENAME}-${RELEASE}
260 $(COMPRESS) ${BASENAME}-$(RELEASE).tar
263 # make ftpdist: install FTP distribution. Assumes a "make dist"
264 # has already succeeded. Doesn't do the symlink;
265 # doesn't install the on-line manual for the Web site.
268 cp -f $(READMES) $(FTPDIR)
269 cp -f build/hmmer-$(RELEASE)/COPYING $(FTPDIR)
270 cp -f build/hmmer-$(RELEASE)/LICENSETAG $(FTPDIR)
271 cp -f build/hmmer-$(RELEASE)/NOTES $(FTPDIR)
272 cp -f build/hmmer-$(RELEASE).tar.Z $(FTPDIR)
273 cp -f build/hmmer-$(RELEASE)-*.tar.Z $(FTPDIR)
274 cp -f Userguide/Userguide.ps $(FTPDIR)
275 cp -f Userguide/Userguide.pdf $(FTPDIR)
276 cp -f Userguide/hmmer-html.tar.Z $(FTPDIR)
279 # make stable: Set up the FTP site symlink to the current stable HMMER release.
282 ln -sf $(FTPDIR)/hmmer-$(RELEASE).tar.Z $(FTPDIR)/hmmer.tar.Z