1
# ======================================================================
2
# (c) Copyright 1996,1997,1998,1999,2000,2001,2004,2006 Whitehead
3
# Institute for Biomedical Research, Steve Rozen, and Helen Skaletsky
6
# Redistribution and use in source and binary forms, with or without
7
# modification, are permitted provided that the following conditions are
10
# * Redistributions of source code must retain the above copyright
11
# notice, this list of conditions and the following disclaimer.
12
# * Redistributions in binary form must reproduce the above
13
# copyright notice, this list of conditions and the following disclaimer
14
# in the documentation and/or other materials provided with the
16
# * Neither the names of the copyright holders nor contributors may
17
# be used to endorse or promote products derived from this software
18
# without specific prior written permission.
20
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24
# OWNERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31
# ======================================================================
33
# ======================================================================
36
# Steve Rozen and Helen J. Skaletsky (2000) Primer3 on the WWW for
37
# general users and for biologist programmers. In: Krawetz S, Misener S
38
# (eds) Bioinformatics Methods and Protocols: Methods in Molecular
39
# Biology. Humana Press, Totowa, NJ, pp 365-386. Source code available
40
# at http://fokker.wi.mit.edu/primer3/.
41
# ======================================================================
43
MAX_PRIMER_LENGTH = 36
48
WHITEHEAD_SPECIFIC_HACK = -include /usr/include/sys/types.h
49
CC_OPTS = -g -Wall -D__USE_FIXED_PROTOTYPES__ $(WHITEHEAD_SPECIFIC_HACK)
50
P_DEFINES = -DDPAL_MAX_ALIGN=$(MAX_PRIMER_LENGTH) -DMAX_PRIMER_LENGTH=$(MAX_PRIMER_LENGTH)
52
CFLAGS = $(CC_OPTS) $(O_OPTS)
55
# ======================================================================
56
# IMPORTANT: on MacOS X and some other Unix/Linux systems where
57
# static libraries are not routinely available, -static has to
61
PRIMER_EXE = primer3_core
63
PRIMER_OBJECTS=primer3_main.o\
70
EXES=$(PRIMER_EXE) ntdpal oligotm long_seq_tm_test
77
$(PRIMER_EXE): $(PRIMER_OBJECTS)
78
$(CC) $(LDFLAGS) -o $@ $(PRIMER_OBJECTS) $(LIBOPTS) $(LDLIBS)
80
# For use with the "testcenter" testing program (CenterLine Software
81
# Inc, http://www.centerline.com)
82
$(PRIMER_EXE).tc: $(PRIMER_OBJECTS) /usr/lib/debug/malloc.o
83
proof $(CC) $(CFLAGS) -o $@ $(PRIMER_OBJECTS) $(LIBOPTS) $(LDLIBS)
85
ntdpal: ntdpal_main.o dpal.o
86
$(CC) $(LDFLAGS) -o $@ ntdpal_main.o dpal.o
88
oligotm: oligotm_main.c oligotm.o
89
$(CC) $(CFLAGS) -o $@ oligotm_main.c oligotm.o $(LIBOPTS) $(LDLIBS)
91
long_seq_tm_test: long_seq_tm_test_main.c oligotm.o
92
$(CC) $(CFLAGS) -o $@ long_seq_tm_test_main.c oligotm.o $(LIBOPTS) $(LDLIBS)
94
boulder_input.o: boulder_input.c boulder_input.h primer3.h primer3_release.h dpal.h
95
$(CC) -c $(CFLAGS) $(P_DEFINES) -o $@ boulder_input.c
97
dpal.o: dpal.c dpal.h primer3_release.h
98
$(CC) -c $(CFLAGS) -o $@ dpal.c
100
dpal_primer.o: dpal.c dpal.h primer3_release.h
101
$(CC) -c $(CFLAGS) $(P_DEFINES) -o $@ dpal.c
103
format_output.o: format_output.c primer3_release.h format_output.h primer3.h dpal.h
104
$(CC) -c $(CFLAGS) $(P_DEFINES) -o $@ format_output.c
106
ntdpal_main.o: ntdpal_main.c dpal.h
107
$(CC) -c $(CC_OPTS) -o $@ ntdpal_main.c
108
# We use CC_OPTS above rather than CFLAGS because
109
# gcc 2.7.2 crashes while compiling ntdpal_main.c with -O2
111
oligotm_main.o: oligotm_main.c oligotm.h
112
$(CC) -c $(CFLAGS) -o $@ ntdpal_main.c
114
oligotm.o: oligotm.c oligotm.h primer3_release.h
116
primer3.o: primer3.c primer3.h primer3_release.h
117
$(CC) -c $(CFLAGS) $(P_DEFINES) primer3.c
119
primer3_main.o: primer3_main.c primer3.h primer3_release.h dpal.h oligotm.h format_output.h
120
$(CC) -c $(CFLAGS) $(P_DEFINES) primer3_main.c
122
primer_test: $(PRIMER_EXE)
123
cd ../test; primer_test.pl