]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blame - binutils/doc/Makefile.am
Update year range in copyright notice of binutils files
[thirdparty/binutils-gdb.git] / binutils / doc / Makefile.am
CommitLineData
c45021f2 1## Process this file with automake to generate Makefile.in
5bf135a7 2#
250d07de 3# Copyright (C) 2012-2021 Free Software Foundation, Inc.
5bf135a7
NC
4#
5# This file is free software; you can redistribute it and/or modify
6# it under the terms of the GNU General Public License as published by
7# the Free Software Foundation; either version 3 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU General Public License for more details.
14#
15# You should have received a copy of the GNU General Public License
16# along with this program; see the file COPYING3. If not see
17# <http://www.gnu.org/licenses/>.
18#
c45021f2 19
d388f643 20AUTOMAKE_OPTIONS = info-in-builddir no-texinfo.tex foreign
c45021f2
NC
21
22# What version of the manual you want; "all" includes everything
23CONFIG=all
24
25# Options to extract the man page from as.texinfo
26MANCONF = -Dman
27
38fc1cb1 28TEXI2POD = perl $(top_srcdir)/../etc/texi2pod.pl $(AM_MAKEINFOFLAGS)
c45021f2 29
c7c55b78
NC
30POD2MAN = pod2man --center="GNU Development Tools" \
31 --release="binutils-$(VERSION)" --section=1
c45021f2
NC
32
33# List of man pages generated from binutils.texi
34man_MANS = \
35 addr2line.1 \
36 ar.1 \
37 dlltool.1 \
c45021f2
NC
38 nm.1 \
39 objcopy.1 \
40 objdump.1 \
41 ranlib.1 \
42 readelf.1 \
43 size.1 \
44 strings.1 \
45 strip.1 \
30fd33bb 46 elfedit.1 \
c45021f2 47 windres.1 \
692ed3e7 48 windmc.1 \
c45021f2
NC
49 $(DEMANGLER_NAME).1
50
51info_TEXINFOS = binutils.texi
42ecbf5e 52binutils_TEXI = $(srcdir)/binutils.texi
c45021f2 53
c428fa83 54AM_MAKEINFOFLAGS = -I "$(srcdir)" -I "$(top_srcdir)/../libiberty" \
9975e4c4 55 -I "$(top_srcdir)/../bfd/doc" -I ../../bfd/doc
c428fa83 56TEXI2DVI = texi2dvi -I "$(srcdir)" -I "$(top_srcdir)/../libiberty" \
9975e4c4 57 -I "$(top_srcdir)/../bfd/doc" -I ../../bfd/doc
c45021f2 58
c45021f2 59# Man page generation from texinfo
89ae5e69 60addr2line.1: $(binutils_TEXI)
c45021f2 61 touch $@
75aa6618 62 -$(TEXI2POD) $(MANCONF) -Daddr2line < $(binutils_TEXI) > addr2line.pod
4258bf4d 63 -($(POD2MAN) addr2line.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 64 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 65 rm -f addr2line.pod
c45021f2 66
89ae5e69 67ar.1: $(binutils_TEXI)
c45021f2 68 touch $@
75aa6618 69 -$(TEXI2POD) $(MANCONF) -Dar < $(binutils_TEXI) > ar.pod
4258bf4d 70 -($(POD2MAN) ar.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 71 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 72 rm -f ar.pod
c45021f2 73
89ae5e69 74dlltool.1: $(binutils_TEXI)
c45021f2 75 touch $@
75aa6618 76 -$(TEXI2POD) $(MANCONF) -Ddlltool < $(binutils_TEXI) > dlltool.pod
4258bf4d 77 -($(POD2MAN) dlltool.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 78 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 79 rm -f dlltool.pod
c45021f2 80
89ae5e69 81nm.1: $(binutils_TEXI)
c45021f2 82 touch $@
75aa6618 83 -$(TEXI2POD) $(MANCONF) -Dnm < $(binutils_TEXI) > nm.pod
4258bf4d 84 -($(POD2MAN) nm.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 85 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 86 rm -f nm.pod
c45021f2 87
89ae5e69 88objcopy.1: $(binutils_TEXI)
c45021f2 89 touch $@
75aa6618 90 -$(TEXI2POD) $(MANCONF) -Dobjcopy < $(binutils_TEXI) > objcopy.pod
4258bf4d 91 -($(POD2MAN) objcopy.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 92 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 93 rm -f objcopy.pod
c45021f2 94
89ae5e69 95objdump.1: $(binutils_TEXI)
c45021f2 96 touch $@
75aa6618 97 -$(TEXI2POD) $(MANCONF) -Dobjdump < $(binutils_TEXI) > objdump.pod
4258bf4d 98 -($(POD2MAN) objdump.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 99 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 100 rm -f objdump.pod
c45021f2 101
89ae5e69 102ranlib.1: $(binutils_TEXI)
c45021f2 103 touch $@
75aa6618 104 -$(TEXI2POD) $(MANCONF) -Dranlib < $(binutils_TEXI) > ranlib.pod
4258bf4d 105 -($(POD2MAN) ranlib.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 106 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 107 rm -f ranlib.pod
c45021f2 108
89ae5e69 109readelf.1: $(binutils_TEXI)
c45021f2 110 touch $@
75aa6618 111 -$(TEXI2POD) $(MANCONF) -Dreadelf < $(binutils_TEXI) > readelf.pod
4258bf4d 112 -($(POD2MAN) readelf.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 113 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 114 rm -f readelf.pod
c45021f2 115
89ae5e69 116size.1: $(binutils_TEXI)
c45021f2 117 touch $@
75aa6618 118 -$(TEXI2POD) $(MANCONF) -Dsize < $(binutils_TEXI) > size.pod
4258bf4d 119 -($(POD2MAN) size.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 120 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 121 rm -f size.pod
c45021f2 122
89ae5e69 123strings.1: $(binutils_TEXI)
c45021f2 124 touch $@
75aa6618 125 -$(TEXI2POD) $(MANCONF) -Dstrings < $(binutils_TEXI) > strings.pod
4258bf4d 126 -($(POD2MAN) strings.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 127 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 128 rm -f strings.pod
c45021f2 129
89ae5e69 130strip.1: $(binutils_TEXI)
c45021f2 131 touch $@
75aa6618 132 -$(TEXI2POD) $(MANCONF) -Dstrip < $(binutils_TEXI) > strip.pod
4258bf4d 133 -($(POD2MAN) strip.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 134 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 135 rm -f strip.pod
c45021f2 136
89ae5e69 137elfedit.1: $(binutils_TEXI)
30fd33bb
L
138 touch $@
139 -$(TEXI2POD) $(MANCONF) -Delfedit < $(binutils_TEXI) > elfedit.pod
140 -($(POD2MAN) elfedit.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
141 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
142 rm -f elfedit.pod
143
89ae5e69 144windres.1: $(binutils_TEXI)
c45021f2 145 touch $@
75aa6618 146 -$(TEXI2POD) $(MANCONF) -Dwindres < $(binutils_TEXI) > windres.pod
4258bf4d 147 -($(POD2MAN) windres.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 148 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 149 rm -f windres.pod
c45021f2 150
89ae5e69 151windmc.1: $(binutils_TEXI)
692ed3e7
NC
152 touch $@
153 -$(TEXI2POD) $(MANCONF) -Dwindmc < $(binutils_TEXI) > windmc.pod
154 -($(POD2MAN) windmc.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
155 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
156 rm -f windmc.pod
157
89ae5e69 158cxxfilt.man: $(binutils_TEXI)
c45021f2 159 touch $@
75aa6618 160 -$(TEXI2POD) $(MANCONF) -Dcxxfilt < $(binutils_TEXI) > $(DEMANGLER_NAME).pod
4258bf4d 161 -($(POD2MAN) $(DEMANGLER_NAME).pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
c45021f2 162 mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
4258bf4d 163 rm -f $(DEMANGLER_NAME).pod
c45021f2 164
9979ab66 165MAINTAINERCLEANFILES = $(man_MANS) binutils.info cxxfilt.man
c45021f2
NC
166
167$(DEMANGLER_NAME).1: cxxfilt.man Makefile
38131e67
L
168 if test -f cxxfilt.man; then \
169 man=cxxfilt.man; \
170 else \
171 man=$(srcdir)/cxxfilt.man; \
172 fi; \
4258bf4d 173 sed -e 's/@PROGRAM@/$(DEMANGLER_NAME)/' \
38131e67 174 -e 's/cxxfilt/$(DEMANGLER_NAME)/' < $$man \
c45021f2
NC
175 > $(DEMANGLER_NAME).1
176
177# Maintenance
178
179# We need it for the taz target in ../../Makefile.in.
42ecbf5e 180info-local: $(MANS)