Makefile.in revision 1.1.1.3 1 1.1 christos #
2 1.1 christos # Makefile
3 1.1 christos # Copyright (C) 1999, 2002, 2006
4 1.1 christos # Free Software Foundation
5 1.1 christos #
6 1.1 christos # This file is part of the libiberty library.
7 1.1 christos # Libiberty is free software; you can redistribute it and/or
8 1.1 christos # modify it under the terms of the GNU Library General Public
9 1.1 christos # License as published by the Free Software Foundation; either
10 1.1 christos # version 2 of the License, or (at your option) any later version.
11 1.1 christos #
12 1.1 christos # Libiberty is distributed in the hope that it will be useful,
13 1.1 christos # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 1.1 christos # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 1.1 christos # Library General Public License for more details.
16 1.1 christos #
17 1.1 christos # You should have received a copy of the GNU Library General Public
18 1.1 christos # License along with libiberty; see the file COPYING.LIB. If not,
19 1.1 christos # write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 1.1 christos # Boston, MA 02110-1301, USA.
21 1.1 christos #
22 1.1 christos
23 1.1 christos # This file was written by Tom Tromey <tromey (at] cygnus.com>.
24 1.1 christos
25 1.1 christos #
26 1.1 christos # Makefile for libiberty/testsuite directory
27 1.1 christos #
28 1.1 christos
29 1.1 christos srcdir = @srcdir@
30 1.1 christos VPATH = @srcdir@
31 1.1 christos
32 1.1 christos SHELL = @SHELL@
33 1.1 christos
34 1.1 christos CC = @CC@
35 1.1 christos CFLAGS = @CFLAGS@
36 1.1.1.3 christos LIBCFLAGS = $(CFLAGS) $(LDFLAGS)
37 1.1 christos
38 1.1 christos # Multilib support variables.
39 1.1 christos MULTISRCTOP =
40 1.1 christos
41 1.1 christos INCDIR=$(srcdir)/../$(MULTISRCTOP)../include
42 1.1 christos
43 1.1 christos all:
44 1.1 christos
45 1.1 christos # CHECK is set to "really_check" or the empty string by configure.
46 1.1 christos check: @CHECK@
47 1.1 christos
48 1.1.1.2 christos really-check: check-cplus-dem check-d-demangle check-pexecute check-expandargv \
49 1.1.1.2 christos check-strtol
50 1.1 christos
51 1.1 christos # Run some tests of the demangler.
52 1.1 christos check-cplus-dem: test-demangle $(srcdir)/demangle-expected
53 1.1 christos ./test-demangle < $(srcdir)/demangle-expected
54 1.1 christos
55 1.1.1.2 christos check-d-demangle: test-demangle $(srcdir)/d-demangle-expected
56 1.1.1.2 christos ./test-demangle < $(srcdir)/d-demangle-expected
57 1.1.1.2 christos
58 1.1 christos # Check the pexecute code.
59 1.1 christos check-pexecute: test-pexecute
60 1.1 christos ./test-pexecute
61 1.1 christos
62 1.1 christos # Check the expandargv functionality
63 1.1 christos check-expandargv: test-expandargv
64 1.1 christos ./test-expandargv
65 1.1 christos
66 1.1.1.2 christos # Check the strtol functionality
67 1.1.1.2 christos check-strtol: test-strtol
68 1.1.1.2 christos ./test-strtol
69 1.1.1.2 christos
70 1.1.1.2 christos # Run the demangler fuzzer
71 1.1.1.2 christos fuzz-demangler: demangler-fuzzer
72 1.1.1.2 christos ./demangler-fuzzer
73 1.1.1.2 christos
74 1.1 christos TEST_COMPILE = $(CC) @DEFS@ $(LIBCFLAGS) -I.. -I$(INCDIR) $(HDEFINES)
75 1.1 christos test-demangle: $(srcdir)/test-demangle.c ../libiberty.a
76 1.1 christos $(TEST_COMPILE) -o test-demangle \
77 1.1 christos $(srcdir)/test-demangle.c ../libiberty.a
78 1.1 christos
79 1.1 christos test-pexecute: $(srcdir)/test-pexecute.c ../libiberty.a
80 1.1 christos $(TEST_COMPILE) -DHAVE_CONFIG_H -I.. -o test-pexecute \
81 1.1 christos $(srcdir)/test-pexecute.c ../libiberty.a
82 1.1 christos
83 1.1 christos test-expandargv: $(srcdir)/test-expandargv.c ../libiberty.a
84 1.1 christos $(TEST_COMPILE) -DHAVE_CONFIG_H -I.. -o test-expandargv \
85 1.1 christos $(srcdir)/test-expandargv.c ../libiberty.a
86 1.1 christos
87 1.1.1.2 christos test-strtol: $(srcdir)/test-strtol.c ../libiberty.a
88 1.1.1.2 christos $(TEST_COMPILE) -DHAVE_CONFIG_H -I.. -o test-strtol \
89 1.1.1.2 christos $(srcdir)/test-strtol.c ../libiberty.a
90 1.1.1.2 christos
91 1.1.1.2 christos demangler-fuzzer: $(srcdir)/demangler-fuzzer.c ../libiberty.a
92 1.1.1.2 christos $(TEST_COMPILE) -o demangler-fuzzer \
93 1.1.1.2 christos $(srcdir)/demangler-fuzzer.c ../libiberty.a
94 1.1.1.2 christos
95 1.1 christos # Standard (either GNU or Cygnus) rules we don't use.
96 1.1 christos html install-html info install-info clean-info dvi pdf install-pdf \
97 1.1 christos install etags tags installcheck:
98 1.1 christos
99 1.1 christos # The standard clean rules.
100 1.1 christos mostlyclean:
101 1.1 christos rm -f test-demangle
102 1.1 christos rm -f test-pexecute
103 1.1 christos rm -f test-expandargv
104 1.1.1.2 christos rm -f test-strtol
105 1.1.1.2 christos rm -f demangler-fuzzer
106 1.1 christos rm -f core
107 1.1 christos clean: mostlyclean
108 1.1 christos distclean: clean
109 1.1 christos rm -f Makefile
110 1.1 christos maintainer-clean realclean: distclean
111 1.1 christos
112 1.1 christos Makefile: $(srcdir)/Makefile.in ../config.status
113 1.1 christos CONFIG_FILES=testsuite/Makefile CONFIG_HEADERS= \
114 1.1 christos cd .. && $(SHELL) ./config.status
115