(EXTRA_DIST): Add .x-po-check.
[platform/upstream/coreutils.git] / Makefile.am
1 ## Process this file with automake to produce Makefile.in -*-Makefile-*-
2
3 SUBDIRS = lib src doc man po tests
4 EXTRA_DIST = Makefile.cfg Makefile.maint GNUmakefile \
5   .kludge-stamp .prev-version THANKS-to-translators THANKStt.in \
6   .x-po-check \
7   .x-sc_space_tab .x-sc_sun_os_names \
8   .x-sc_file_system .x-sc_obsolete_symbols \
9   .x-sc_unmarked_diagnostics \
10   .x-sc_useless_cpp_parens \
11   .x-sc_no_if_have_config_h \
12   .x-sc_require_config_h \
13   .x-sc_prohibit_assert_without_use \
14   .x-sc_two_space_separator_in_usage \
15   announce-gen \
16   build-aux/cvsu \
17   m4/ChangeLog \
18   old/fileutils/ChangeLog \
19   old/fileutils/ChangeLog-1997 \
20   old/sh-utils/ChangeLog \
21   old/sh-utils/ChangeLog.0 \
22   old/textutils/ChangeLog \
23   old/fileutils/NEWS \
24   old/sh-utils/NEWS \
25   old/textutils/NEWS
26
27 install-root:
28         cd src && $(MAKE) $@
29
30 ACLOCAL_AMFLAGS = -I m4
31
32 # Some tests always need root privileges, others need them only sometimes.
33 check-root:
34         cd tests && $(MAKE) $@
35
36 dist-hook:
37         test -x $(srcdir)/build-aux/install-sh
38
39 distcheck-hook:
40         $(MAKE) my-distcheck
41
42 # Just prior to distribution, ...
43 # transform the automake-generated rule that runs `rm -f rm'.
44 # On some systems, that command would fail with a diagnostic like
45 # `rm: cannot unlink `rm': Text file busy' when `.' appears so early
46 # in the shell's search path that running `rm' would run the `rm'
47 # executable in the current directory.
48 # Similarly, adjust the clean-binPROGRAMS rule.
49
50 rm_subst = \
51   s!(rm -f (rm|\$$\(bin_PROGRAMS\)))$$!$$1 > /dev/null 2>&1 || /bin/$$1!
52 .kludge-stamp: $(srcdir)/src/Makefile.in
53         perl -pi -e '$(rm_subst)' $(srcdir)/src/Makefile.in
54         touch $@
55
56 THANKS-to-translators: po/LINGUAS THANKStt.in
57         (                                                               \
58           cat $(srcdir)/THANKStt.in;                                    \
59           for lang in `cat po/LINGUAS`; do                              \
60             echo http://www.iro.umontreal.ca/contrib/po/HTML/team-$$lang.html; \
61           done;                                                         \
62         ) > $@-tmp && mv $@-tmp $@