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 # Windows resource compiler support. It's fine to use xz_CPPFLAGS
11 $(RC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
12 $(xzdec_CPPFLAGS) $(CPPFLAGS) $(RCFLAGS) -i $< -o $@
17 ../common/tuklib_progname.c \
18 ../common/tuklib_exit.c
21 xzdec_SOURCES += xzdec_w32res.rc
26 -I$(top_srcdir)/src/common \
27 -I$(top_srcdir)/src/liblzma/api \
29 xzdec_LDADD = $(top_builddir)/src/liblzma/liblzma.la
32 xzdec_LDADD += $(top_builddir)/lib/libgnu.a
35 xzdec_LDADD += $(LTLIBINTL)
40 ../common/tuklib_progname.c \
41 ../common/tuklib_exit.c
44 lzmadec_SOURCES += lzmadec_w32res.rc
47 lzmadec_CPPFLAGS = $(xzdec_CPPFLAGS) -DLZMADEC
48 lzmadec_LDFLAGS = $(xzdec_LDFLAGS)
49 lzmadec_LDADD = $(xzdec_LDADD)
57 dist_man_MANS = xzdec.1
61 bin_PROGRAMS += lzmadec
63 # Create the symlink lzmadec.1->xzdec.1 only if xzdec.1 was installed.
64 # This is better than creating a dangling symlink. The correct solution
65 # would be to install xzdec.1 as lzmadec.1 but this code is already too
66 # complicated so I won't do it. Installing only lzmadec is a bit unusual
67 # situation anyway so it's not that important.
69 lzmadecmanlink += lzmadec
74 # The installation of translated man pages abuses Automake internals
75 # by calling "install-man" with redefined dist_man_MANS and man_MANS.
76 # If this breaks some day, don't blame Automake developers.
79 if test "$(USE_NLS)" = yes && test -d "$(top_srcdir)/po4a/man"; then \
80 languages=`ls "$(top_srcdir)/po4a/man"`; \
82 target=`echo xzdec | sed '$(transform)'` && \
83 link=`echo lzmadec | sed '$(transform)'` && \
84 for lang in . $$languages; do \
85 man="$(top_srcdir)/po4a/man/$$lang/xzdec.1" ; \
86 if test -f "$$man"; then \
87 $(MAKE) dist_man_MANS="$$man" man_MANS= \
88 mandir="$(mandir)/$$lang" install-man; \
90 man1dir="$(DESTDIR)$(mandir)/$$lang/man1" && \
91 if test -f "$$man1dir/$$target.1"; then \
92 if test -n "$(lzmadecmanlink)"; then ( \
95 $(LN_S) "$$target.1" "$$link.1" \
102 if test "$(USE_NLS)" = yes && test -d "$(top_srcdir)/po4a/man"; then \
103 languages=`ls "$(top_srcdir)/po4a/man"`; \
105 for lang in . $$languages; do \
106 for name in xzdec $(lzmadecmanlink); do \
107 name=`echo $$name | sed '$(transform)'` && \
108 rm -f "$(DESTDIR)$(mandir)/$$lang/man1/$$name.1"; \