Annotation of mandoc/Makefile, Revision 1.200
1.193 kristaps 1: .SUFFIXES: .html .xml .sgml .1.txt .3.txt .7.txt .1 .3 .7 .md5 .tar.gz
1.79 kristaps 2:
1.99 kristaps 3: BINDIR = $(PREFIX)/bin
4: INCLUDEDIR = $(PREFIX)/include
5: LIBDIR = $(PREFIX)/lib
6: MANDIR = $(PREFIX)/man
7: INSTALL_PROGRAM = install -m 0755
8: INSTALL_DATA = install -m 0444
9: INSTALL_LIB = install -m 0644
10: INSTALL_MAN = $(INSTALL_DATA)
11:
1.200 ! kristaps 12: VERSION = 1.8.3
! 13: VDATE = 23 July 2009
1.7 kristaps 14:
1.131 kristaps 15: VFLAGS = -DVERSION=\"$(VERSION)\"
1.143 kristaps 16: CFLAGS += -W -Wall -Wstrict-prototypes -Wno-unused-parameter -g
1.113 kristaps 17: CFLAGS += $(VFLAGS)
1.182 kristaps 18: LINTFLAGS += $(VFLAGS)
1.132 kristaps 19:
1.165 kristaps 20: MDOCLNS = mdoc_macro.ln mdoc.ln mdoc_hash.ln mdoc_strings.ln \
21: mdoc_argv.ln mdoc_validate.ln mdoc_action.ln \
1.187 kristaps 22: lib.ln att.ln arch.ln vol.ln msec.ln st.ln \
23: mandoc.ln
1.165 kristaps 24: MDOCOBJS = mdoc_macro.o mdoc.o mdoc_hash.o mdoc_strings.o \
1.163 kristaps 25: mdoc_argv.o mdoc_validate.o mdoc_action.o lib.o att.o \
1.187 kristaps 26: arch.o vol.o msec.o st.o mandoc.o
1.165 kristaps 27: MDOCSRCS = mdoc_macro.c mdoc.c mdoc_hash.c mdoc_strings.c \
1.163 kristaps 28: mdoc_argv.c mdoc_validate.c mdoc_action.c lib.c att.c \
1.187 kristaps 29: arch.c vol.c msec.c st.c mandoc.c
1.148 kristaps 30:
1.156 kristaps 31: MANLNS = man_macro.ln man.ln man_hash.ln man_validate.ln \
1.187 kristaps 32: man_action.ln mandoc.ln
1.156 kristaps 33: MANOBJS = man_macro.o man.o man_hash.o man_validate.o \
1.187 kristaps 34: man_action.o mandoc.o
1.156 kristaps 35: MANSRCS = man_macro.c man.c man_hash.c man_validate.c \
1.187 kristaps 36: man_action.c mandoc.c
1.132 kristaps 37:
1.165 kristaps 38: MAINLNS = main.ln mdoc_term.ln ascii.ln term.ln tree.ln \
1.160 kristaps 39: compat.ln man_term.ln
1.165 kristaps 40: MAINOBJS = main.o mdoc_term.o ascii.o term.o tree.o compat.o \
1.160 kristaps 41: man_term.o
1.165 kristaps 42: MAINSRCS = main.c mdoc_term.c ascii.c term.c tree.c compat.c \
1.160 kristaps 43: man_term.c
1.132 kristaps 44:
1.148 kristaps 45: LLNS = llib-llibmdoc.ln llib-llibman.ln llib-lmandoc.ln
1.157 kristaps 46: LNS = $(MAINLNS) $(MDOCLNS) $(MANLNS)
1.148 kristaps 47: LIBS = libmdoc.a libman.a
1.158 kristaps 48: OBJS = $(MDOCOBJS) $(MAINOBJS) $(MANOBJS)
1.150 kristaps 49: SRCS = $(MDOCSRCS) $(MAINSRCS) $(MANSRCS)
1.131 kristaps 50: DATAS = arch.in att.in lib.in msec.in st.in vol.in ascii.in
1.187 kristaps 51: HEADS = mdoc.h libmdoc.h man.h libman.h term.h libmandoc.h
1.142 kristaps 52: SGMLS = index.sgml
1.193 kristaps 53: XSLS = ChangeLog.xsl
54: HTMLS = index.html ChangeLog.html
55: XMLS = ChangeLog.xml
1.131 kristaps 56: STATICS = style.css external.png
1.195 kristaps 57: MD5S = mdocml-$(VERSION).md5
58: TARGZS = mdocml-$(VERSION).tar.gz
1.168 kristaps 59: MANS = mandoc.1 mdoc.3 mdoc.7 manuals.7 mandoc_char.7 \
60: man.7 man.3
61: TEXTS = mandoc.1.txt mdoc.3.txt mdoc.7.txt manuals.7.txt \
62: mandoc_char.7.txt man.7.txt man.3.txt
1.132 kristaps 63: BINS = mandoc
1.168 kristaps 64: CLEAN = $(BINS) $(LNS) $(LLNS) $(LIBS) $(OBJS) $(HTMLS) \
1.195 kristaps 65: $(TARGZS) tags $(TEXTS) $(MD5S) $(XMLS)
1.198 kristaps 66: INSTALL = $(SRCS) $(HEADS) Makefile $(MANS) $(SGMLS) $(STATICS) \
67: $(DATAS) $(XSLS)
1.81 kristaps 68:
1.50 kristaps 69: all: $(BINS)
1.32 kristaps 70:
1.50 kristaps 71: lint: $(LLNS)
1.42 kristaps 72:
1.1 kristaps 73: clean:
74: rm -f $(CLEAN)
75:
1.89 kristaps 76: cleanlint:
77: rm -f $(LNS) $(LLNS)
78:
1.60 kristaps 79: dist: mdocml-$(VERSION).tar.gz
1.59 kristaps 80:
1.185 kristaps 81: html: $(HTMLS)
1.20 kristaps 82:
1.193 kristaps 83: www: all $(HTMLS) $(MD5S) $(TARGZS) $(TEXTS)
1.79 kristaps 84:
1.80 kristaps 85: installwww: www
1.169 kristaps 86: install -m 0444 $(TEXTS) $(HTMLS) $(STATICS) $(PREFIX)/
1.81 kristaps 87: install -m 0444 mdocml-$(VERSION).tar.gz $(PREFIX)/snapshots/
1.186 kristaps 88: install -m 0444 mdocml-$(VERSION).md5 $(PREFIX)/snapshots/
1.91 kristaps 89: install -m 0444 mdocml-$(VERSION).tar.gz $(PREFIX)/snapshots/mdocml.tar.gz
1.186 kristaps 90: install -m 0444 mdocml-$(VERSION).md5 $(PREFIX)/snapshots/mdocml.md5
1.80 kristaps 91:
1.60 kristaps 92: install:
1.101 kristaps 93: mkdir -p $(BINDIR)
94: mkdir -p $(MANDIR)/man1
1.131 kristaps 95: mkdir -p $(MANDIR)/man7
1.132 kristaps 96: $(INSTALL_PROGRAM) mandoc $(BINDIR)
97: $(INSTALL_MAN) mandoc.1 $(MANDIR)/man1
1.131 kristaps 98: $(INSTALL_MAN) mdoc.7 $(MANDIR)/man7
1.60 kristaps 99:
100: uninstall:
1.132 kristaps 101: rm -f $(BINDIR)/mandoc
102: rm -f $(MANDIR)/man1/mandoc.1
1.131 kristaps 103: rm -f $(MANDIR)/man7/mdoc.7
1.20 kristaps 104:
1.148 kristaps 105: man_macro.ln: man_macro.c libman.h
106: man_macro.o: man_macro.c libman.h
1.108 kristaps 107:
1.148 kristaps 108: lib.ln: lib.c lib.in libmdoc.h
109: lib.o: lib.c lib.in libmdoc.h
1.108 kristaps 110:
1.148 kristaps 111: att.ln: att.c att.in libmdoc.h
112: att.o: att.c att.in libmdoc.h
1.108 kristaps 113:
1.148 kristaps 114: arch.ln: arch.c arch.in libmdoc.h
115: arch.o: arch.c arch.in libmdoc.h
116:
117: vol.ln: vol.c vol.in libmdoc.h
118: vol.o: vol.c vol.in libmdoc.h
1.108 kristaps 119:
1.127 kristaps 120: ascii.ln: ascii.c ascii.in term.h
121: ascii.o: ascii.c ascii.in term.h
1.108 kristaps 122:
1.148 kristaps 123: msec.ln: msec.c msec.in libmdoc.h
124: msec.o: msec.c msec.in libmdoc.h
1.108 kristaps 125:
1.148 kristaps 126: st.ln: st.c st.in libmdoc.h
127: st.o: st.c st.in libmdoc.h
1.108 kristaps 128:
1.148 kristaps 129: mdoc_macro.ln: mdoc_macro.c libmdoc.h
130: mdoc_macro.o: mdoc_macro.c libmdoc.h
1.21 kristaps 131:
1.160 kristaps 132: mdoc_term.ln: mdoc_term.c term.h mdoc.h
133: mdoc_term.o: mdoc_term.c term.h mdoc.h
1.74 kristaps 134:
1.165 kristaps 135: mdoc_strings.ln: mdoc_strings.c libmdoc.h
136: mdoc_strings.o: mdoc_strings.c libmdoc.h
1.148 kristaps 137:
138: man_hash.ln: man_hash.c libman.h
139: man_hash.o: man_hash.c libman.h
140:
141: mdoc_hash.ln: mdoc_hash.c libmdoc.h
142: mdoc_hash.o: mdoc_hash.c libmdoc.h
1.52 kristaps 143:
1.148 kristaps 144: mdoc.ln: mdoc.c libmdoc.h
145: mdoc.o: mdoc.c libmdoc.h
1.21 kristaps 146:
1.148 kristaps 147: man.ln: man.c libman.h
148: man.o: man.c libman.h
1.47 kristaps 149:
1.132 kristaps 150: main.ln: main.c mdoc.h
151: main.o: main.c mdoc.h
152:
1.173 kristaps 153: compat.ln: compat.c
154: compat.o: compat.c
155:
1.165 kristaps 156: term.ln: term.c term.h man.h mdoc.h
157: term.o: term.c term.h man.h mdoc.h
1.53 kristaps 158:
1.163 kristaps 159: mdoc_argv.ln: mdoc_argv.c libmdoc.h
160: mdoc_argv.o: mdoc_argv.c libmdoc.h
1.53 kristaps 161:
1.155 kristaps 162: man_validate.ln: man_validate.c libman.h
163: man_validate.o: man_validate.c libman.h
164:
165: mdoc_validate.ln: mdoc_validate.c libmdoc.h
166: mdoc_validate.o: mdoc_validate.c libmdoc.h
1.54 kristaps 167:
1.156 kristaps 168: mdoc_action.ln: mdoc_action.c libmdoc.h
169: mdoc_action.o: mdoc_action.c libmdoc.h
1.56 kristaps 170:
1.148 kristaps 171: libmdoc.h: mdoc.h
1.39 kristaps 172:
1.193 kristaps 173: ChangeLog.xml:
1.196 kristaps 174: cvs2cl --xml --xml-encoding iso-8859-15 -t --noxmlns -f $@
1.193 kristaps 175:
1.194 kristaps 176: ChangeLog.html: ChangeLog.xml ChangeLog.xsl
1.193 kristaps 177: xsltproc -o $@ ChangeLog.xsl ChangeLog.xml
1.175 kristaps 178:
1.60 kristaps 179: mdocml-$(VERSION).tar.gz: $(INSTALL)
180: mkdir -p .dist/mdocml/mdocml-$(VERSION)/
181: install -m 0644 $(INSTALL) .dist/mdocml/mdocml-$(VERSION)/
182: ( cd .dist/mdocml/ && tar zcf ../../$@ mdocml-$(VERSION)/ )
183: rm -rf .dist/
184:
1.148 kristaps 185: llib-llibmdoc.ln: $(MDOCLNS)
1.181 kristaps 186: $(LINT) -Clibmdoc $(MDOCLNS)
1.148 kristaps 187:
188: llib-llibman.ln: $(MANLNS)
1.181 kristaps 189: $(LINT) -Clibman $(MANLNS)
1.60 kristaps 190:
1.132 kristaps 191: llib-lmandoc.ln: $(MAINLNS) llib-llibmdoc.ln
1.181 kristaps 192: $(LINT) -Cmandoc $(MAINLNS) llib-llibmdoc.ln
1.60 kristaps 193:
1.148 kristaps 194: libmdoc.a: $(MDOCOBJS)
195: $(AR) rs $@ $(MDOCOBJS)
196:
197: libman.a: $(MANOBJS)
198: $(AR) rs $@ $(MANOBJS)
1.60 kristaps 199:
1.148 kristaps 200: mandoc: $(MAINOBJS) libmdoc.a libman.a
201: $(CC) $(CFLAGS) -o $@ $(MAINOBJS) libmdoc.a libman.a
1.75 kristaps 202:
1.79 kristaps 203: .sgml.html:
204: validate $<
1.85 kristaps 205: sed -e "s!@VERSION@!$(VERSION)!" -e "s!@VDATE@!$(VDATE)!" $< > $@
1.168 kristaps 206:
207: .1.1.txt:
1.183 kristaps 208: ./mandoc -Wall,error -fstrict $< | col -b > $@
1.168 kristaps 209:
210: .3.3.txt:
1.183 kristaps 211: ./mandoc -Wall,error -fstrict $< | col -b > $@
1.168 kristaps 212:
213: .7.7.txt:
1.183 kristaps 214: ./mandoc -Wall,error -fstrict $< | col -b > $@
1.185 kristaps 215:
216: .tar.gz.md5:
1.186 kristaps 217: md5 $< > $@
CVSweb