source: vendor/automake/1.10/tests/python2.test

Last change on this file was 3147, checked in by bird, 18 years ago

automake 1.10

File size: 1.9 KB
Line 
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 Automake; see the file COPYING. If not, write to
18# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19# Boston, MA 02110-1301, USA.
20
21# Make sure that Automake suggests using AM_PATH_PYTHON.
22
23. ./defs || exit 1
24
25set -e
26
27echo 1
28# pythondir not defined
29
30cat > Makefile.am <<'END'
31PYTHON = x
32python_PYTHON = foo.py
33END
34
35$ACLOCAL
36AUTOMAKE_fails -a
37grep AM_PATH_PYTHON stderr
38
39echo 2
40# pkgpythondir not defined
41
42cat > Makefile.am <<'END'
43PYTHON = x
44pkgpython_PYTHON = foo.py
45END
46
47$ACLOCAL
48AUTOMAKE_fails -a
49grep AM_PATH_PYTHON stderr
50
51
52echo 3
53# pyexecdir not defined
54
55cat > Makefile.am <<'END'
56PYTHON = x
57pyexec_PYTHON = foo.py
58END
59
60$ACLOCAL
61AUTOMAKE_fails -a
62grep AM_PATH_PYTHON stderr
63
64
65echo 4
66# pkgpyexecdir not defined
67
68cat > Makefile.am <<'END'
69PYTHON = x
70pkgpyexec_PYTHON = foo.py
71END
72
73$ACLOCAL
74AUTOMAKE_fails -a
75grep AM_PATH_PYTHON stderr
76
77
78echo 5
79# PYTHON not defined.
80
81cat > Makefile.am <<'END'
82pkgpyexecdir = /here/we/go
83pkgpyexec_PYTHON = foo.py
84END
85
86$ACLOCAL
87AUTOMAKE_fails -a
88grep AM_PATH_PYTHON stderr
89
90
91echo 6
92# Ok.
93
94cat > Makefile.am <<'END'
95PYTHON = x
96pkgpyexecdir = /here/we/go
97pkgpyexec_PYTHON = foo.py
98END
99
100$ACLOCAL
101$AUTOMAKE -a
102test -f py-compile
103
104
105echo 7
106# Ok.
107
108cat > Makefile.am <<'END'
109PYTHON = x
110fubardir = /here/we/go
111fubar_PYTHON = foo.py
112END
113
114$ACLOCAL
115$AUTOMAKE -a
Note: See TracBrowser for help on using the repository browser.