1 ## Process this file with automake to produce Makefile.in
3 ACLOCAL_AMFLAGS = -I m4
6 DIST_SUBDIRS = lpc10 src
10 # man pages are not considered to be sources, so need to add "dist_"
11 # prefix to ensure they are added to the distribution.
12 dist_man_MANS = sox.1 soxi.1 soxformat.7 libsox.3
13 EXTRA_DIST = sox.txt soxi.txt soxformat.txt libsox.txt \
14 sox.pc.in LICENSE.GPL LICENSE.LGPL \
15 cygbuild README.win32 README.osx scripts/batch-example.bat \
18 pkgconfig_DATA = sox.pc
21 $(RM) $@ && $(LN_S) $< $@
23 README: README.sh FEATURES.in
26 # Rule for making text man pages. Uses GNU nroff's -c so not portable.
28 tbl $< | nroff -man -c | sed "s/.
\b//g" > $@
30 tbl $< | nroff -man -c | sed "s/.
\b//g" > $@
32 tbl $< | nroff -man -c | sed "s/.
\b//g" > $@
34 DOCTXT = sox.txt soxi.txt soxformat.txt libsox.txt README
37 # Rule for making PDF man pages
39 pdfroff -t -man --no-toc-relocation -Tps $< > $@
41 pdfroff -t -man --no-toc-relocation -Tps $< > $@
43 pdfroff -t -man --no-toc-relocation -Tps $< > $@
45 DOCPDF = sox.pdf soxi.pdf soxformat.pdf libsox.pdf
50 test -z "$(pdfdir)" || $(MKDIR_P) "$(DESTDIR)$(pdfdir)"
51 @list='$(DOCPDF)'; for p in $$list; do \
52 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
54 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(pdfdir)/$$f'"; \
55 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(pdfdir)/$$f"; \
60 @list='$(DOCPDF)'; for p in $$list; do \
62 echo " $(RM) '$(DESTDIR)$(pdfdir)/$$f'"; \
63 $(RM) "$(DESTDIR)$(pdfdir)/$$f"; \
67 $(RM) mingw32-config.cache
70 # Rule for making HTML man pages
72 # Get rid on unneeded Content-Type, man directory and manpage index in extension.
73 # e.g. ../man1/soxi.1.html becomes ../soxi.html
74 # Return to Main Contents and link to man2html are also modified.
75 FIXHTML = sed 's,<head>,&<link rel="stylesheet" href="http://sox.sourceforge.net/pub/skins/sox/sox.css" type="text/css"></link>,'
78 groff -t -man -Thtml -P -Dsoxpng $< | $(FIXHTML) > $@
80 groff -t -man -Thtml -P -Dsoxpng $< | $(FIXHTML) > $@
82 groff -t -man -Thtml -P -Dsoxpng $< | $(FIXHTML) > $@
84 DOCHTML = sox.html soxi.html soxformat.html libsox.html
89 test -z "$(htmldir)/soxpng" || $(MKDIR_P) "$(DESTDIR)$(htmldir)/soxpng"
90 @list='$(DOCHTML)'; for p in $$list; do \
91 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
93 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(htmldir)//$$f'"; \
94 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(htmldir)/$$f"; \
96 @for p in soxpng/*; do \
97 if test -f "$$p"; then d=; else d="$(srcdir)"; fi; \
99 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(htmldir)/soxpng/$$f'"; \
100 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(htmldir)/soxpng/$$f"; \
105 @list='$(DOCHTML)'; for p in $$list; do \
107 echo " $(RM) '$(DESTDIR)$(htmldir)/$$f'"; \
108 $(RM) "$(DESTDIR)$(htmldir)/$$f"; \
110 $(RM) -fr "$(DESTDIR)$(htmldir)/soxpng";
112 DISTCLEANFILES = $(DOCHTML) $(DOCPDF)
113 MAINTAINERCLEANFILES = $(DOCTXT)
116 cd $(DESTDIR)$(mandir)/man1 && $(RM) play.1 && $(LN_S) sox.1 play.1
117 cd $(DESTDIR)$(mandir)/man1 && $(RM) rec.1 && $(LN_S) sox.1 rec.1
118 cd $(DESTDIR)$(mandir)/man7 && $(RM) soxeffect.7 && $(LN_S) ../man1/sox.1 soxeffect.7
121 $(RM) $(DESTDIR)$(mandir)/man1/play.1
122 $(RM) $(DESTDIR)$(mandir)/man1/rec.1
123 $(RM) $(DESTDIR)$(mandir)/man7/soxeffect.7