New upstream version 1.8
[debian/gzip] / tests / Makefile.am
1 ## Process this file with automake to create Makefile.in
2 # Copyright 2010-2016 Free Software Foundation, Inc.
3 #
4 # This program is free software; you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License as published by
6 # the Free Software Foundation; either version 3, or (at your option)
7 # any later version.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License
15 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
16
17 TESTS =                                 \
18   gzip-env                              \
19   helin-segv                            \
20   help-version                          \
21   hufts                                 \
22   keep                                  \
23   list                                  \
24   memcpy-abuse                          \
25   mixed                                 \
26   null-suffix-clobber                   \
27   stdin                                 \
28   trailing-nul                          \
29   unpack-invalid                        \
30   z-suffix                              \
31   zdiff                                 \
32   zgrep-f                               \
33   zgrep-context                         \
34   zgrep-signal                          \
35   znew-k
36
37 EXTRA_DIST =                            \
38   $(TESTS)                              \
39   init.cfg                              \
40   init.sh                               \
41   hufts-segv.gz
42
43 built_programs = \
44   gzip          \
45   gunzip        \
46   gzexe         \
47   zcat          \
48   zcmp          \
49   zdiff         \
50   zegrep        \
51   zfgrep        \
52   zforce        \
53   zgrep         \
54   zless         \
55   zmore         \
56   znew
57
58 TESTS_ENVIRONMENT =                                     \
59   tmp__=$$TMPDIR; test -d "$$tmp__" || tmp__=.;         \
60   TMPDIR=$$tmp__; export TMPDIR;                        \
61                                                         \
62   if test -n "$$BASH_VERSION" || (eval "export v=x") 2>/dev/null; then \
63     export_with_values () { export "$$@"; };            \
64   else                                                  \
65     export_with_values ()                               \
66     {                                                   \
67       sed_extract_var='s/=.*//';                        \
68       sed_quote_value="s/'/'\\\\''/g;s/=\\(.*\\)/='\\1'/";\
69       for arg in "$$@"; do                              \
70         var=`echo "$$arg" | sed "$$sed_extract_var"`;   \
71         arg=`echo "$$arg" | sed "$$sed_quote_value"`;   \
72         eval "$$arg";                                   \
73         export "$$var";                                 \
74       done;                                             \
75     };                                                  \
76   fi;                                                   \
77                                                         \
78   export_with_values                                    \
79   LC_ALL=C                                              \
80   VERSION=$(VERSION)                                    \
81   abs_top_builddir='$(abs_top_builddir)'                \
82   abs_top_srcdir='$(abs_top_srcdir)'                    \
83   abs_srcdir='$(abs_srcdir)'                            \
84   built_programs='$(built_programs)'                    \
85   srcdir='$(srcdir)'                                    \
86   top_srcdir='$(top_srcdir)'                            \
87   CC='$(CC)'                                            \
88   GREP='$(GREP)'                                        \
89   GZIP_TEST_NAME=`echo $$tst|sed 's,^\./,,;s,/,-,g'`    \
90   MAKE=$(MAKE)                                          \
91   PACKAGE_BUGREPORT='$(PACKAGE_BUGREPORT)'              \
92   PACKAGE_VERSION=$(PACKAGE_VERSION)                    \
93   PERL='$(PERL)'                                        \
94   SHELL='$(SHELL)'                                      \
95   PATH='$(abs_top_builddir)$(PATH_SEPARATOR)'"$$PATH"   \
96   ; 9>&2
97
98 VERBOSE = yes