2 ## Author: Lasse Collin
4 ## This file has been put into the public domain.
5 ## You can do whatever you want with this file.
8 # Use -n to prevent gzip from adding a timestamp to the .gz headers.
11 DIST_SUBDIRS = lib src po tests debug
18 SUBDIRS += src po tests
30 doc/xz-file-format.txt \
31 doc/lzma-file-format.txt
33 examplesdir = $(docdir)/examples
34 dist_examples_DATA = \
35 doc/examples/00_README.txt \
36 doc/examples/01_compress_easy.c \
37 doc/examples/02_decompress.c \
38 doc/examples/03_compress_custom.c \
41 examplesolddir = $(docdir)/examples_old
42 dist_examplesold_DATA = \
43 doc/examples_old/xz_pipe_comp.c \
44 doc/examples_old/xz_pipe_decomp.c
57 build-aux/manconv.sh \
60 ACLOCAL_AMFLAGS = -I m4
62 # List of man pages to conver to PDF and plain text in the dist-hook target.
66 src/lzmainfo/lzmainfo.1 \
67 src/scripts/xzdiff.1 \
68 src/scripts/xzgrep.1 \
69 src/scripts/xzless.1 \
72 # Create ChangeLog from output of "git log --date=iso --stat".
73 # Convert the man pages to PDF and plain text (ASCII only) formats.
75 if test -d "$(srcdir)/.git" && type git > /dev/null 2>&1; then \
76 ( cd "$(srcdir)" && git log --date=iso --stat ) \
77 > "$(distdir)/ChangeLog"; \
79 if type groff > /dev/null 2>&1 && type ps2pdf > /dev/null 2>&1; then \
80 dest="$(distdir)/doc/man" && \
81 $(MKDIR_P) "$$dest/pdf-a4" "$$dest/pdf-letter" "$$dest/txt" && \
82 for FILE in $(manfiles); do \
83 BASE=`basename $$FILE .1` && \
84 sh "$(srcdir)/build-aux/manconv.sh" pdf a4 \
85 < "$(srcdir)/$$FILE" \
86 > "$$dest/pdf-a4/$$BASE-a4.pdf" && \
87 sh "$(srcdir)/build-aux/manconv.sh" pdf letter \
88 < "$(srcdir)/$$FILE" \
89 > "$$dest/pdf-letter/$$BASE-letter.pdf" && \
90 sh "$(srcdir)/build-aux/manconv.sh" ascii \
91 < "$(srcdir)/$$FILE" \
92 > "$$dest/txt/$$BASE.txt"; \
96 # This works with GNU tar and gives cleaner package than normal 'make dist'.
99 if test -d "$(srcdir)/.git" && type git > /dev/null 2>&1; then \
100 SNAPSHOT=`cd "$(srcdir)" && git describe --abbrev=4 | cut -b2-`; \
101 test -n "$$SNAPSHOT" && VERSION=$$SNAPSHOT; \
103 TAR_OPTIONS='--owner=0 --group=0 --numeric-owner --mode=u+rw,go+r-w' \
104 $(MAKE) VERSION="$$VERSION" dist-gzip