top level:
[deliverable/binutils-gdb.git] / binutils / doc / Makefile.am
CommitLineData
c45021f2
NC
1## Process this file with automake to generate Makefile.in
2
3AUTOMAKE_OPTIONS = cygnus
4
5# What version of the manual you want; "all" includes everything
6CONFIG=all
7
8# Options to extract the man page from as.texinfo
9MANCONF = -Dman
10
38fc1cb1 11TEXI2POD = perl $(top_srcdir)/../etc/texi2pod.pl $(AM_MAKEINFOFLAGS)
c45021f2 12
c7c55b78
NC
13POD2MAN = pod2man --center="GNU Development Tools" \
14 --release="binutils-$(VERSION)" --section=1
c45021f2
NC
15
16# List of man pages generated from binutils.texi
17man_MANS = \
18 addr2line.1 \
19 ar.1 \
20 dlltool.1 \
21 nlmconv.1 \
22 nm.1 \
23 objcopy.1 \
24 objdump.1 \
25 ranlib.1 \
26 readelf.1 \
27 size.1 \
28 strings.1 \
29 strip.1 \
30 windres.1 \
31 $(DEMANGLER_NAME).1
32
33info_TEXINFOS = binutils.texi
42ecbf5e
DJ
34binutils_TEXINFOS = config.texi
35binutils_TEXI = $(srcdir)/binutils.texi
c45021f2 36
38fc1cb1 37AM_MAKEINFOFLAGS = -I "$(srcdir)" -I "$(top_srcdir)/../libiberty"
e10fad12 38TEXI2DVI = texi2dvi -I "$(srcdir)" -I "$(top_srcdir)/../libiberty"
38fc1cb1 39
42ecbf5e 40config.texi: $(srcdir)/../../bfd/configure $(binutils_TEXI)
c45021f2 41 rm -f config.texi
970c3dbc
DJ
42 eval `grep '^ *VERSION=' $(srcdir)/../../bfd/configure`; \
43 echo "@set VERSION $$VERSION" > $@
258ea6c8 44 echo "@set UPDATED `date '+%B %Y'`" >> config.texi
c45021f2 45
c45021f2 46# Man page generation from texinfo
f33e8c5b 47addr2line.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 48 touch $@
75aa6618 49 -$(TEXI2POD) $(MANCONF) -Daddr2line < $(binutils_TEXI) > addr2line.pod
4258bf4d 50 -($(POD2MAN) addr2line.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 51 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 52 rm -f addr2line.pod
c45021f2 53
f33e8c5b 54ar.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 55 touch $@
75aa6618 56 -$(TEXI2POD) $(MANCONF) -Dar < $(binutils_TEXI) > ar.pod
4258bf4d 57 -($(POD2MAN) ar.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 58 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 59 rm -f ar.pod
c45021f2 60
f33e8c5b 61dlltool.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 62 touch $@
75aa6618 63 -$(TEXI2POD) $(MANCONF) -Ddlltool < $(binutils_TEXI) > dlltool.pod
4258bf4d 64 -($(POD2MAN) dlltool.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 65 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 66 rm -f dlltool.pod
c45021f2 67
f33e8c5b 68nlmconv.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 69 touch $@
75aa6618 70 -$(TEXI2POD) $(MANCONF) -Dnlmconv < $(binutils_TEXI) > nlmconv.pod
4258bf4d 71 -($(POD2MAN) nlmconv.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 72 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 73 rm -f nlmconv.pod
c45021f2 74
f33e8c5b 75nm.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 76 touch $@
75aa6618 77 -$(TEXI2POD) $(MANCONF) -Dnm < $(binutils_TEXI) > nm.pod
4258bf4d 78 -($(POD2MAN) nm.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 79 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 80 rm -f nm.pod
c45021f2 81
f33e8c5b 82objcopy.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 83 touch $@
75aa6618 84 -$(TEXI2POD) $(MANCONF) -Dobjcopy < $(binutils_TEXI) > objcopy.pod
4258bf4d 85 -($(POD2MAN) objcopy.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 86 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 87 rm -f objcopy.pod
c45021f2 88
f33e8c5b 89objdump.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 90 touch $@
75aa6618 91 -$(TEXI2POD) $(MANCONF) -Dobjdump < $(binutils_TEXI) > objdump.pod
4258bf4d 92 -($(POD2MAN) objdump.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 93 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 94 rm -f objdump.pod
c45021f2 95
f33e8c5b 96ranlib.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 97 touch $@
75aa6618 98 -$(TEXI2POD) $(MANCONF) -Dranlib < $(binutils_TEXI) > ranlib.pod
4258bf4d 99 -($(POD2MAN) ranlib.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 100 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 101 rm -f ranlib.pod
c45021f2 102
f33e8c5b 103readelf.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 104 touch $@
75aa6618 105 -$(TEXI2POD) $(MANCONF) -Dreadelf < $(binutils_TEXI) > readelf.pod
4258bf4d 106 -($(POD2MAN) readelf.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 107 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 108 rm -f readelf.pod
c45021f2 109
f33e8c5b 110size.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 111 touch $@
75aa6618 112 -$(TEXI2POD) $(MANCONF) -Dsize < $(binutils_TEXI) > size.pod
4258bf4d 113 -($(POD2MAN) size.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 114 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 115 rm -f size.pod
c45021f2 116
f33e8c5b 117strings.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 118 touch $@
75aa6618 119 -$(TEXI2POD) $(MANCONF) -Dstrings < $(binutils_TEXI) > strings.pod
4258bf4d 120 -($(POD2MAN) strings.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 121 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 122 rm -f strings.pod
c45021f2 123
f33e8c5b 124strip.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 125 touch $@
75aa6618 126 -$(TEXI2POD) $(MANCONF) -Dstrip < $(binutils_TEXI) > strip.pod
4258bf4d 127 -($(POD2MAN) strip.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 128 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 129 rm -f strip.pod
c45021f2 130
f33e8c5b 131windres.1: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 132 touch $@
75aa6618 133 -$(TEXI2POD) $(MANCONF) -Dwindres < $(binutils_TEXI) > windres.pod
4258bf4d 134 -($(POD2MAN) windres.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 135 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 136 rm -f windres.pod
c45021f2 137
f33e8c5b 138cxxfilt.man: $(binutils_TEXI) $(binutils_TEXINFOS)
c45021f2 139 touch $@
75aa6618 140 -$(TEXI2POD) $(MANCONF) -Dcxxfilt < $(binutils_TEXI) > $(DEMANGLER_NAME).pod
4258bf4d 141 -($(POD2MAN) $(DEMANGLER_NAME).pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 142 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 143 rm -f $(DEMANGLER_NAME).pod
c45021f2
NC
144
145MAINTAINERCLEANFILES = config.texi
c45021f2
NC
146MOSTLYCLEANFILES = $(DEMANGLER_NAME).1
147
148$(DEMANGLER_NAME).1: cxxfilt.man Makefile
38131e67
L
149 if test -f cxxfilt.man; then \
150 man=cxxfilt.man; \
151 else \
152 man=$(srcdir)/cxxfilt.man; \
153 fi; \
4258bf4d 154 sed -e 's/@PROGRAM@/$(DEMANGLER_NAME)/' \
38131e67 155 -e 's/cxxfilt/$(DEMANGLER_NAME)/' < $$man \
c45021f2
NC
156 > $(DEMANGLER_NAME).1
157
7562a296
HPN
158# We want install to imply install-info as per GNU standards, despite the
159# cygnus option.
42ecbf5e 160install-data-local: install-info
7562a296 161
108a6f8e
CD
162html__strip_dir = `echo $$p | sed -e 's|^.*/||'`;
163
164install-html: install-html-am
165
166install-html-am: $(HTMLS)
167 @$(NORMAL_INSTALL)
168 test -z "$(htmldir)" || $(mkdir_p) "$(DESTDIR)$(htmldir)"
169 @list='$(HTMLS)'; for p in $$list; do \
170 if test -f "$$p" || test -d "$$p"; then d=""; else d="$(srcdir)/"; fi; \
171 f=$(html__strip_dir) \
172 if test -d "$$d$$p"; then \
173 echo " $(mkdir_p) '$(DESTDIR)$(htmldir)/$$f'"; \
174 $(mkdir_p) "$(DESTDIR)$(htmldir)/$$f" || exit 1; \
175 echo " $(INSTALL_DATA) '$$d$$p'/* '$(DESTDIR)$(htmldir)/$$f'"; \
176 $(INSTALL_DATA) "$$d$$p"/* "$(DESTDIR)$(htmldir)/$$f"; \
177 else \
178 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(htmldir)/$$f'"; \
179 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(htmldir)/$$f"; \
180 fi; \
181 done
182
d5fbea21
DJ
183MAINTAINERCLEANFILES += binutils.info
184
185# Automake 1.9 will only build info files in the objdir if they are
186# mentioned in DISTCLEANFILES. It doesn't have to be unconditional,
187# though, so we use a bogus condition.
188if GENINSRC_NEVER
189DISTCLEANFILES = binutils.info
190endif
191
c45021f2
NC
192# Maintenance
193
194# We need it for the taz target in ../../Makefile.in.
42ecbf5e 195info-local: $(MANS)
This page took 0.306478 seconds and 4 git commands to generate.