~ubuntu-branches/ubuntu/wily/dssp/wily

« back to all changes in this revision

Viewing changes to debian/patches/makefile

  • Committer: Package Import Robot
  • Author(s): Laszlo Kajan
  • Date: 2012-04-18 11:09:02 UTC
  • Revision ID: package-import@ubuntu.com-20120418110902-0tiui82qd364yvxh
Tags: 2.0.4-1
* Initial release. (Closes: #669259)
* Added description to dssp; added upstream (reference); parallel building
  now enabled; fixed spelling error in man page; added debug package;
  fixed debian/watch; added get-orig-source target to rules.
* Changed libboost build dependency to version >= 1.42.0.1 to allow
  building on stable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Description: assorted fixes
 
2
 [Maarten L. Hekkelman <m.hekkelman@cmbi.ru.nl>]
 
3
  * DEST_DIR patched to DESTDIR
 
4
 .
 
5
 [Laszlo Kajan <lkajan@rostlab.org>]
 
6
  * stripping is patched out so that it can be done by dh into a debug package
 
7
  * line echo suppression is removed
 
8
  * spelling errors in man page fixed
 
9
 .
 
10
 Upstream is aware of this patch.
 
11
Author: Maarten L. Hekkelman <m.hekkelman@cmbi.ru.nl>
 
12
Author: Laszlo Kajan <lkajan@rostlab.org>
 
13
--- a/makefile
 
14
+++ b/makefile
 
15
@@ -9,25 +9,21 @@
 
16
 # new one if it doesn't exist. In this make.config you can set site
 
17
 # specific variables like the Boost library location.
 
18
 
 
19
-firstTarget: mkdssp
 
20
-
 
21
-include make.config
 
22
+all: mkdssp
 
23
 
 
24
 VERSION                                = 2.0.4
 
25
 
 
26
-DEST_DIR                       ?= /usr/local/
 
27
-LIB_DIR                                = $(BOOST_LIB_DIR)
 
28
-INC_DIR                                = $(BOOST_INC_DIR)
 
29
-MAN_DIR                                = $(DEST_DIR)man/man1/
 
30
+BIN_DIR                                = $(DESTDIR)/usr/bin
 
31
+MAN_DIR                                = $(DESTDIR)/usr/share/man/man1
 
32
 
 
33
-BOOST_LIBS                     = thread regex filesystem program_options date_time iostreams math_c99 system
 
34
-LIBS                           = $(BOOST_LIBS:%=boost_%$(BOOST_LIB_SUFFIX)) z bz2
 
35
+BOOST_LIBS                     = thread filesystem program_options iostreams system
 
36
+LIBS                           = $(BOOST_LIBS:%=boost_%)
 
37
 
 
38
 DEFINES                                = USE_COMPRESSION LINUX VERSION='"$(VERSION)"'
 
39
-CC                                     = c++
 
40
+CXX                                    = g++
 
41
 
 
42
-CFLAGS                         = $(INC_DIR:%=-I%) -iquote src -g -Wall -Wno-multichar -pthread
 
43
-LDOPTS                         = $(LIB_DIR:%=-L%) $(LIBS:%=-l%) -g -pthread
 
44
+CFLAGS                         += -iquote src -g -Wall -Wno-multichar -pthread
 
45
+LDOPTS                         += $(LIBS:%=-l%) -g -pthread
 
46
 
 
47
 OBJ_DIR                                = obj
 
48
 
 
49
@@ -48,25 +44,21 @@
 
50
 OBJECTS = $(OBJ_DIR)/mkdssp.o $(OBJ_DIR)/dssp.o $(OBJ_DIR)/primitives-3d.o $(OBJ_DIR)/structure.o $(OBJ_DIR)/utils.o
 
51
 
 
52
 mkdssp: $(OBJECTS)
 
53
-       @ echo linking $@
 
54
-       @ $(CC) -static -o $@ $^ $(LDOPTS)
 
55
-       @ echo OK
 
56
-
 
57
-include $(OBJECTS:%.o=%.d)
 
58
-
 
59
-$(OBJECTS:.o=.d):
 
60
-
 
61
-$(OBJ_DIR)/%.o: %.cpp
 
62
-       @ if [ ! -d $(OBJ_DIR) ]; then mkdir $(OBJ_DIR); fi
 
63
-       @ echo compiling $@
 
64
-       @ $(CC) -MD -c -o $@ $< $(CFLAGS)
 
65
+       $(CXX) -o $@ $^ $(LDOPTS)
 
66
+
 
67
+$(OBJ_DIR):
 
68
+       mkdir -p $(OBJ_DIR)
 
69
+
 
70
+$(OBJ_DIR)/%.o: %.cpp | $(OBJ_DIR)
 
71
+       $(CXX) -MD -c -o $@ $< $(CFLAGS)
 
72
 
 
73
 clean:
 
74
        rm -rf $(OBJ_DIR)/* mkdssp
 
75
 
 
76
 install: mkdssp
 
77
-       sudo install -m 755 mkdssp $(DEST_DIR)bin/mkdssp
 
78
-       sudo install doc/mkdssp.1 $(MAN_DIR)mkdssp.1
 
79
+       install -d $(BIN_DIR) $(MAN_DIR)
 
80
+       install -m 755 mkdssp $(BIN_DIR)/mkdssp
 
81
+       install doc/mkdssp.1 $(MAN_DIR)/mkdssp.1
 
82
 
 
83
 dist: $(OBJECTS)
 
84
        @ rm -rf $(DIST_NAME)
 
85
@@ -81,11 +73,3 @@
 
86
        @ cp doc/mkdssp.1 $(DIST_NAME)/doc/mkdssp.1
 
87
        tar czf $(DIST_NAME).tgz $(DIST_NAME)
 
88
        cp $(DIST_NAME).tgz dssp_$(VERSION).orig.tar.gz
 
89
-
 
90
-make.config:
 
91
-       @echo "creating empty make.config file"
 
92
-       @echo "# Set local options for make here" > make.config
 
93
-       @echo "#BOOST_LIB_SUFFIX = -mt" >> make.config
 
94
-       @echo "#BOOST_LIB_DIR    = $(HOME)/projects/boost/lib" >> make.config
 
95
-       @echo "#BOOST_INC_DIR    = $(HOME)/projects/boost/include" >> make.config
 
96
-
 
97
--- a/doc/mkdssp.1
 
98
+++ b/doc/mkdssp.1
 
99
@@ -13,7 +13,7 @@
 
100
 Please note that \fImkdssp\fP \fBdoes not predict\fP secondary structure.
 
101
 .SH OPTIONS
 
102
 If you invoke \fImkdssp\fP with only one parameter, it will be
 
103
-interpreted as the PDB file to process and output will be send to
 
104
+interpreted as the PDB file to process and output will be sent to
 
105
 stdout. If a second parameter is specified this is interpreted as
 
106
 the name of the DSSP file to create. Both the input and the output
 
107
 file names may have either \.gz or \.bz2 as extension resulting in
 
108
@@ -159,7 +159,7 @@
 
109
 .SH TODO
 
110
 The code desperately needs an update. The first thing that needs
 
111
 implementing is the improved recognition of pi\-helices. A second
 
112
-improvement would be to use angle dependant H\-bond energy calculation.
 
113
+improvement would be to use angle dependent H\-bond energy calculation.
 
114
 .SH BUGS
 
115
 If you find any, please let me know.
 
116
 .SH AUTHOR