File: 20-Makefile.dpatch

package info (click to toggle)
readseq 1-7
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 332 kB
  • ctags: 294
  • sloc: ansic: 2,788; sh: 651; makefile: 75
file content (147 lines) | stat: -rw-r--r-- 4,802 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
#! /bin/sh /usr/share/dpatch/dpatch-run
## 20_Makefile.dpatch by  <tille@debian.org>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Enhanced Makefile

@DPATCH@

--- readseq-1/Makefile.orig	1992-12-30 01:00:00.000000000 +0100
+++ readseq-1/Makefile	2007-11-17 21:31:39.000000000 +0100
@@ -10,7 +10,7 @@
 #CC=cc  # SGI Irix
 #CC=vcc # some DEC Ultrix
 
-CFLAGS=
+CFLAGS= -g -O2
 #CFLAGS= -DSMALLCHECKSUM  # if you prefer to use a GCG-standard 13 bit checksum
 #    instead of a full 32 bit checksum. This may enhance compatibility w/ GCG software
 
@@ -29,63 +29,66 @@
 LIB2=-lncbiobj
 LIB3=-lncbicdr
 LIB4=-lvibrant
-INCPATH=$(NCBI)/include
-LIBPATH=$(NCBI)/lib
+LIB5=-lncbimmdb -lncbiid1 -lnetcli
+LIB6=-lncbiacc
+LIB7=-lncbitool
+INCPATH=/usr/include/ncbi
+#LIBPATH=$(NCBI)/lib
 NCFLAGS=$(CFLAGS) -DNCBI -I$(INCPATH)
-NLDFLAGS=-I$(INCPATH) -L$(LIBPATH)
-NLIBS=$(LIB1) $(LIB2) $(OTHERLIBS)
+NLDFLAGS=-I$(INCPATH) 
+NLIBS=$(LIB1) $(LIB2) $(LIB3) $(LIB6) $(LIB7) $(LIB5) $(OTHERLIBS)
+ARBFLAGS=-DARB
 
+all: build 
 
-all: build test
-
-build: $(SOURCES)
-	@echo "Compiling readseq..."
-	$(CC) $(CFLAGS) -o readseq readseq.c ureadseq.c
+#build: $(SOURCES)
+#	@echo "Compiling readseq..."
+#	$(CC) $(CFLAGS) -o readseq readseq.c ureadseq.c
 
 # if using NCBI, uncomment these lines in place of build: above
-#build: $(SOURCES)
-# @echo "Compiling readseq with NCBI toolkit support...";
-# $(CC) -o readseq $(NLDFLAGS) $(NCFLAGS) readseq.c ureadseq.c ureadasn.c $(NLIBS)
+build: $(SOURCES)
+	@echo "Compiling readseq with NCBI toolkit support and ARB patches";
+	$(CC) -o readseq $(NLDFLAGS) $(NCFLAGS) $(ARBFLAGS) readseq.c ureadseq.c ureadasn.c $(NLIBS)
 
-test: $(SOURCES) readseq
+test: 
 	@echo ""
 	@echo "Test for general read/write of all chars:"
-	./readseq -p alphabet.std -otest.alpha
+	readseq -p alphabet.std -otest.alpha
 	-diff test.alpha alphabet.std
 
 	@echo ""
 	@echo "Test for valid format conversions:"
-	./readseq -v -p -f=ig   nucleic.std -otest.ig
-	./readseq -v -p -f=gb   test.ig     -otest.gb
-	./readseq -v -p -f=nbrf test.gb     -otest.nbrf
-	./readseq -v -p -f=embl test.nbrf   -otest.embl
-	./readseq -v -p -f=gcg  test.embl   -otest.gcg
-	./readseq -v -p -f=strider test.gcg -otest.strider
-	./readseq -v -p -f=fitch test.strider -otest.fitch
-	./readseq -v -p -f=fasta test.fitch -otest.fasta
-	./readseq -v -p -f=pir  test.fasta  -otest.pir
-	./readseq -v -p -f=ig   test.pir    -otest.ig-b
+	readseq -v -p -f=ig   nucleic.std -otest.ig
+	readseq -v -p -f=gb   test.ig     -otest.gb
+	readseq -v -p -f=nbrf test.gb     -otest.nbrf
+	readseq -v -p -f=embl test.nbrf   -otest.embl
+	readseq -v -p -f=gcg  test.embl   -otest.gcg
+	readseq -v -p -f=strider test.gcg -otest.strider
+	readseq -v -p -f=fitch test.strider -otest.fitch
+	readseq -v -p -f=fasta test.fitch -otest.fasta
+	readseq -v -p -f=pir  test.fasta  -otest.pir
+	readseq -v -p -f=ig   test.pir    -otest.ig-b
 	-diff test.ig test.ig-b
 
 	@echo ""
 	@echo "Test for multiple-sequence format conversions:"
-	./readseq -p -f=ig    multi.std   -otest.m-ig
-	./readseq -p -f=gb    test.m-ig   -otest.m-gb
-	./readseq -p -f=nbrf  test.m-gb   -otest.m-nbrf
-	./readseq -p -f=embl  test.m-nbrf -otest.m-embl
-	./readseq -p -f=fasta test.m-embl -otest.m-fasta
-	./readseq -p -f=pir   test.m-fasta -otest.m-pir
-	./readseq -p -f=msf   test.m-pir  -otest.m-msf
-	./readseq -p -f=paup  test.m-msf  -otest.m-paup
-	./readseq -p -f=ig    test.m-paup -otest.m-ig-b
+	readseq -p -f=ig    multi.std   -otest.m-ig
+	readseq -p -f=gb    test.m-ig   -otest.m-gb
+	readseq -p -f=nbrf  test.m-gb   -otest.m-nbrf
+	readseq -p -f=embl  test.m-nbrf -otest.m-embl
+	readseq -p -f=fasta test.m-embl -otest.m-fasta
+	readseq -p -f=pir   test.m-fasta -otest.m-pir
+	readseq -p -f=msf   test.m-pir  -otest.m-msf
+	readseq -p -f=paup  test.m-msf  -otest.m-paup
+	readseq -p -f=ig    test.m-paup -otest.m-ig-b
 	-diff test.m-ig test.m-ig-b
 #
 # if using NCBI, uncomment these lines
-# @echo ""
-# @echo "Test of NCBI ASN.1 conversions:"
-# ./readseq -p -f=asn test.m-ig  -otest.m-asn
-# ./readseq -p -f=ig  test.m-asn -otest.m-ig-c
-# -diff test.m-ig test.m-ig-c
+	@echo ""
+	@echo "Test of NCBI ASN.1 conversions:"
+	readseq -p -f=asn test.m-ig  -otest.m-asn
+	readseq -p -f=ig  test.m-asn -otest.m-ig-c
+	-diff test.m-ig test.m-ig-c
 #
 	@echo ""
 	@echo "Expect differences in the header lines due to"
@@ -97,8 +100,13 @@
 	@echo "    make clean"
 
 
+install:
+	install readseq $(DESTDIR)/usr/bin
+	install *.std $(DESTDIR)/usr/share/doc/readseq/tests
+	install Makefile $(DESTDIR)/usr/share/doc/readseq/tests
+
 clean:
-	rm -f *.o core test.*
+	rm -f *.o core test.* readseq
 
 shar:
 	@echo "shell archiving files..."
@@ -109,3 +117,7 @@
 	shar -v readseqd > readseq.shar
 	rm -rf readseqd
 
+
+
+
+