]> icculus.org git repositories - icculus/xz.git/blob - Makefile.am
Fix data corruption in LZ/LZMA2 encoder.
[icculus/xz.git] / Makefile.am
1 ##
2 ## Author: Lasse Collin
3 ##
4 ## This file has been put into the public domain.
5 ## You can do whatever you want with this file.
6 ##
7
8 DIST_SUBDIRS = lib src po tests debug
9 SUBDIRS =
10
11 if COND_GNULIB
12 SUBDIRS += lib
13 endif
14
15 SUBDIRS += src po tests
16
17 doc_DATA = \
18         AUTHORS \
19         COPYING \
20         COPYING.GPLv2 \
21         NEWS \
22         README \
23         THANKS \
24         TODO \
25         doc/history.txt \
26         doc/xz-file-format.txt \
27         doc/lzma-file-format.txt
28
29 EXTRA_DIST = \
30         version.sh \
31         Doxyfile.in \
32         extra \
33         doc \
34         windows \
35         COPYING.GPLv2 \
36         COPYING.GPLv3 \
37         COPYING.LGPLv2.1
38
39 ACLOCAL_AMFLAGS = -I m4
40
41 # List of man pages to conver to PDF and plain text in the dist-hook target.
42 manfiles = \
43         src/xz/xz.1 \
44         src/xzdec/xzdec.1 \
45         src/scripts/xzdiff.1 \
46         src/scripts/xzgrep.1 \
47         src/scripts/xzless.1 \
48         src/scripts/xzmore.1
49
50 # Create ChangeLog from output of "git log --date=iso --stat".
51 # Convert the man pages to PDF and plain text (ASCII only) formats.
52 dist-hook:
53         test -d "$(srcdir)/.git" && type git > /dev/null 2>&1 \
54                 && ( cd "$(srcdir)" && git log --date=iso --stat ) \
55                         > "$(distdir)/ChangeLog"
56         if type groff > /dev/null 2>&1 && type ps2pdf > /dev/null 2>&1; then \
57                 dest="$(distdir)/doc/man" && \
58                 mkdir "$$dest" && \
59                 mkdir "$$dest/pdf-a4" "$$dest/pdf-letter" "$$dest/txt" && \
60                 for FILE in $(manfiles); do \
61                         BASE=`basename $$FILE .1` && \
62                         groff -man -t -Tps -P-pa4 < "$(srcdir)/$$FILE" \
63                                 | ps2pdf - - \
64                                 > "$$dest/pdf-a4/$$BASE-a4.pdf" && \
65                         groff -man -t -Tps -P-pletter < "$(srcdir)/$$FILE" \
66                                 | ps2pdf - - \
67                                 > "$$dest/pdf-letter/$$BASE-letter.pdf" && \
68                         groff -man -t -Tascii < "$(srcdir)/$$FILE" \
69                                 | col -bx > "$$dest/txt/$$BASE.txt"; \
70                 done; \
71         fi
72
73 # This works with GNU tar and gives cleaner package than normal 'make dist'.
74 mydist:
75         TAR_OPTIONS='--owner=0 --group=0 --numeric-owner --mode=u+rw,go+r-w' \
76                 $(MAKE) dist-gzip