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