/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to Makefile

Tags: version-1.0.14-1
* Makefile (version): Changed to "1.0.14".
* NEWS (Version 1.0.14): New entry.
* debian/changelog (1.0.14-1): - '' -

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
#       -Wunreachable-code 
9
9
#DEBUG=-ggdb3
10
10
# For info about _FORTIFY_SOURCE, see
11
 
# <http://www.kernel.org/doc/man-pages/online/pages/man7/feature_test_macros.7.html>
12
 
# and <http://gcc.gnu.org/ml/gcc-patches/2004-09/msg02055.html>.
 
11
# <http://gcc.gnu.org/ml/gcc-patches/2004-09/msg02055.html>
13
12
FORTIFY=-D_FORTIFY_SOURCE=2 -fstack-protector-all -fPIC
14
13
LINK_FORTIFY_LD=-z relro -z now
15
14
LINK_FORTIFY=
56
55
LDFLAGS=$(COVERAGE) $(LINK_FORTIFY) $(foreach flag,$(LINK_FORTIFY_LD),-Xlinker $(flag))
57
56
 
58
57
# Commands to format a DocBook <refentry> document into a manual page
59
 
DOCBOOKTOMAN=$(strip cd $(dir $<); xsltproc --nonet --xinclude \
 
58
DOCBOOKTOMAN=cd $(dir $<); xsltproc --nonet --xinclude \
60
59
        --param man.charmap.use.subset          0 \
61
60
        --param make.year.ranges                1 \
62
61
        --param make.single.year.ranges         1 \
64
63
        --param man.authors.section.enabled     0 \
65
64
         /usr/share/xml/docbook/stylesheet/nwalsh/manpages/docbook.xsl \
66
65
        $(notdir $<); \
67
 
        $(MANPOST) $(notdir $@))
 
66
        $(MANPOST) $(notdir $@)
68
67
# DocBook-to-man post-processing to fix a '\n' escape bug
69
68
MANPOST=$(SED) --in-place --expression='s,\\\\en,\\en,g;s,\\n,\\en,g'
70
69
 
71
 
DOCBOOKTOHTML=$(strip xsltproc --nonet --xinclude \
 
70
DOCBOOKTOHTML=xsltproc --nonet --xinclude \
72
71
        --param make.year.ranges                1 \
73
72
        --param make.single.year.ranges         1 \
74
73
        --param man.output.quietly              1 \
76
75
        --param citerefentry.link               1 \
77
76
        --output $@ \
78
77
        /usr/share/xml/docbook/stylesheet/nwalsh/xhtml/docbook.xsl \
79
 
        $<; $(HTMLPOST) $@)
 
78
        $<; $(HTMLPOST) $@
80
79
# Fix citerefentry links
81
80
HTMLPOST=$(SED) --in-place \
82
81
        --expression='s/\(<a class="citerefentry" href="\)\("><span class="citerefentry"><span class="refentrytitle">\)\([^<]*\)\(<\/span>(\)\([^)]*\)\()<\/span><\/a>\)/\1\3.\5\2\3\4\5\6/g'
157
156
 
158
157
# Update all these files with version number $(version)
159
158
common.ent: Makefile
160
 
        $(strip $(SED) --in-place \
 
159
        $(SED) --in-place \
161
160
                --expression='s/^\(<!ENTITY version "\)[^"]*">$$/\1$(version)">/' \
162
 
                $@)
 
161
                $@
163
162
 
164
163
mandos: Makefile
165
 
        $(strip $(SED) --in-place \
 
164
        $(SED) --in-place \
166
165
                --expression='s/^\(version = "\)[^"]*"$$/\1$(version)"/' \
167
 
                $@)
 
166
                $@
168
167
 
169
168
mandos-keygen: Makefile
170
 
        $(strip $(SED) --in-place \
 
169
        $(SED) --in-place \
171
170
                --expression='s/^\(VERSION="\)[^"]*"$$/\1$(version)"/' \
172
 
                $@)
 
171
                $@
173
172
 
174
173
mandos-ctl: Makefile
175
 
        $(strip $(SED) --in-place \
 
174
        $(SED) --in-place \
176
175
                --expression='s/^\(version = "\)[^"]*"$$/\1$(version)"/' \
177
 
                $@)
 
176
                $@
178
177
 
179
178
mandos.lsm: Makefile
180
 
        $(strip $(SED) --in-place \
 
179
        $(SED) --in-place \
181
180
                --expression='s/^\(Version:\).*/\1\t$(version)/' \
182
 
                $@)
183
 
        $(strip $(SED) --in-place \
 
181
                $@
 
182
        $(SED) --in-place \
184
183
                --expression='s/^\(Entered-date:\).*/\1\t$(shell date --rfc-3339=date --reference=Makefile)/' \
185
 
                $@)
186
 
        $(strip $(SED) --in-place \
 
184
                $@
 
185
        $(SED) --in-place \
187
186
                --expression='s/\(mandos_\)[0-9.]\+\(\.orig\.tar\.gz\)/\1$(version)\2/' \
188
 
                $@)
 
187
                $@
189
188
 
190
 
plugins.d/mandos-client: plugins.d/mandos-client.c
191
 
        $(LINK.c) $(GNUTLS_LIBS) $(AVAHI_LIBS) $(GPGME_LIBS) $(strip\
192
 
                ) $(COMMON) $^ $(LOADLIBES) $(LDLIBS) -o $@
 
189
plugins.d/mandos-client: plugins.d/mandos-client.o
 
190
        $(LINK.o) $(GNUTLS_LIBS) $(AVAHI_LIBS) $(GPGME_LIBS) \
 
191
                $(COMMON) $^ $(LOADLIBES) $(LDLIBS) -o $@
193
192
 
194
193
.PHONY : all doc html clean distclean run-client run-server install \
195
194
        install-server install-client uninstall uninstall-server \