1 | #! /bin/sh
|
---|
2 | # Copyright (C) 2002, 2003 Free Software Foundation, Inc.
|
---|
3 | #
|
---|
4 | # This file is part of GNU Automake.
|
---|
5 | #
|
---|
6 | # GNU Automake is free software; you can redistribute it and/or modify
|
---|
7 | # it under the terms of the GNU General Public License as published by
|
---|
8 | # the Free Software Foundation; either version 2, or (at your option)
|
---|
9 | # any later version.
|
---|
10 | #
|
---|
11 | # GNU Automake is distributed in the hope that it will be useful,
|
---|
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
14 | # GNU General Public License for more details.
|
---|
15 | #
|
---|
16 | # You should have received a copy of the GNU General Public License
|
---|
17 | # along with autoconf; see the file COPYING. If not, write to
|
---|
18 | # the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
---|
19 | # Boston, MA 02111-1307, USA.
|
---|
20 |
|
---|
21 | # Check gettext support.
|
---|
22 |
|
---|
23 | required='gettext'
|
---|
24 | . ./defs || exit 1
|
---|
25 |
|
---|
26 | set -e
|
---|
27 |
|
---|
28 | cat >>configure.in <<END
|
---|
29 | AM_GNU_GETTEXT
|
---|
30 | AC_OUTPUT
|
---|
31 | END
|
---|
32 |
|
---|
33 | : >Makefile.am
|
---|
34 | mkdir po intl
|
---|
35 |
|
---|
36 | $ACLOCAL
|
---|
37 |
|
---|
38 | # po/ and intl/ are required
|
---|
39 |
|
---|
40 | $AUTOMAKE --add-missing 2>stderr && exit 1
|
---|
41 | cat stderr
|
---|
42 | grep 'AM_GNU_GETTEXT.*SUBDIRS' stderr
|
---|
43 |
|
---|
44 | echo 'SUBDIRS = po' >Makefile.am
|
---|
45 | $AUTOMAKE --add-missing 2>stderr && exit 1
|
---|
46 | cat stderr
|
---|
47 | grep 'AM_GNU_GETTEXT.*intl' stderr
|
---|
48 |
|
---|
49 | echo 'SUBDIRS = intl' >Makefile.am
|
---|
50 | $AUTOMAKE --add-missing 2>stderr && exit 1
|
---|
51 | cat stderr
|
---|
52 | grep 'AM_GNU_GETTEXT.*po' stderr
|
---|
53 |
|
---|
54 | # Ok.
|
---|
55 |
|
---|
56 | echo 'SUBDIRS = po intl' >Makefile.am
|
---|
57 | $AUTOMAKE --add-missing
|
---|
58 |
|
---|
59 | # Make sure distcheck runs ./configure --with-included-gettext
|
---|
60 | grep 'with-included-gettext' Makefile.in
|
---|
61 |
|
---|
62 | # `SUBDIRS = po intl' isn't required if po/ doesn't exist.
|
---|
63 | # PR/381.
|
---|
64 |
|
---|
65 | rmdir po
|
---|
66 | mkdir sub
|
---|
67 | echo 'SUBDIRS = sub' >Makefile.am
|
---|
68 | $AUTOMAKE
|
---|
69 |
|
---|
70 | # Still, SUBDIRS must be defined.
|
---|
71 |
|
---|
72 | : >Makefile.am
|
---|
73 | $AUTOMAKE --add-missing 2>stderr && exit 1
|
---|
74 | cat stderr
|
---|
75 | grep 'AM_GNU_GETTEXT.*SUBDIRS' stderr
|
---|