1 ## Process this file with automake to produce Makefile.in
3 ACLOCAL_AMFLAGS = -I m4
5 SUBDIRS = lpc10 libgsm src
6 DIST_SUBDIRS = lpc10 libgsm src msvc9 msvc10
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 \
19 pkgconfigdir = @PKGCONFIGDIR@
20 pkgconfig_DATA = sox.pc
24 $(RM) $@ && $(LN_S) $< $@
26 README: README.sh FEATURES.in
29 # Rule for making text man pages. Uses GNU nroff's -c so not portable.
31 tbl $< | nroff -man -c | sed "s/.
\b//g" > $@
33 tbl $< | nroff -man -c | sed "s/.
\b//g" > $@
35 tbl $< | nroff -man -c | sed "s/.
\b//g" > $@
37 DOCTXT = sox.txt soxi.txt soxformat.txt libsox.txt README
40 # Rule for making PDF man pages
42 pdfroff -t -man --no-toc-relocation -Tps $< > $@
44 pdfroff -t -man --no-toc-relocation -Tps $< > $@
46 pdfroff -t -man --no-toc-relocation -Tps $< > $@
48 DOCPDF = sox.pdf soxi.pdf soxformat.pdf libsox.pdf
53 test -z "$(pdfdir)" || $(MKDIR_P) "$(DESTDIR)$(pdfdir)"
54 @list='$(DOCPDF)'; for p in $$list; do \
55 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
57 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(pdfdir)/$$f'"; \
58 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(pdfdir)/$$f"; \
63 @list='$(DOCPDF)'; for p in $$list; do \
65 echo " $(RM) '$(DESTDIR)$(pdfdir)/$$f'"; \
66 $(RM) "$(DESTDIR)$(pdfdir)/$$f"; \
70 $(RM) mingw32-config.cache
73 # Rule for making HTML man pages
75 # Get rid on unneeded Content-Type, man directory and manpage index in extension.
76 # e.g. ../man1/soxi.1.html becomes ../soxi.html
77 # Return to Main Contents and link to man2html are also modified.
78 FIXHTML = sed 's,<head>,&<link rel="stylesheet" href="http://sox.sourceforge.net/pub/skins/sox/sox.css" type="text/css"></link>,'
81 groff -t -man -Thtml -P -Dsoxpng $< | $(FIXHTML) > $@
83 groff -t -man -Thtml -P -Dsoxpng $< | $(FIXHTML) > $@
85 groff -t -man -Thtml -P -Dsoxpng $< | $(FIXHTML) > $@
87 DOCHTML = sox.html soxi.html soxformat.html libsox.html
92 test -z "$(htmldir)/soxpng" || $(MKDIR_P) "$(DESTDIR)$(htmldir)/soxpng"
93 @list='$(DOCHTML)'; for p in $$list; do \
94 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
96 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(htmldir)//$$f'"; \
97 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(htmldir)/$$f"; \
99 @for p in soxpng/*; do \
100 if test -f "$$p"; then d=; else d="$(srcdir)"; fi; \
102 echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(htmldir)/soxpng/$$f'"; \
103 $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(htmldir)/soxpng/$$f"; \
108 @list='$(DOCHTML)'; for p in $$list; do \
110 echo " $(RM) '$(DESTDIR)$(htmldir)/$$f'"; \
111 $(RM) "$(DESTDIR)$(htmldir)/$$f"; \
113 $(RM) -fr "$(DESTDIR)$(htmldir)/soxpng";
115 DISTCLEANFILES = $(DOCHTML) $(DOCPDF)
116 MAINTAINERCLEANFILES = $(DOCTXT)
119 cd $(DESTDIR)$(mandir)/man1 && $(RM) play.1 && $(LN_S) sox.1 play.1
120 cd $(DESTDIR)$(mandir)/man1 && $(RM) rec.1 && $(LN_S) sox.1 rec.1
121 cd $(DESTDIR)$(mandir)/man7 && $(RM) soxeffect.7 && $(LN_S) ../man1/sox.1 soxeffect.7
124 $(RM) $(DESTDIR)$(mandir)/man1/play.1
125 $(RM) $(DESTDIR)$(mandir)/man1/rec.1
126 $(RM) $(DESTDIR)$(mandir)/man7/soxeffect.7
128 # Automatically update libtool script if it gets out-of-date
129 libtool: $(LIBTOOL_DEPS)
130 $(SHELL) ./config.status --recheck