* tests/regression/Makefile.am: Always use the same bootclasspath for
[cacao.git] / tests / regression / native / Makefile.am
1 ## src/tests/regression/native/Makefile.am
2 ##
3 ## Copyright (C) 1996-2005, 2006, 2008
4 ## CACAOVM - Verein zur Foerderung der freien virtuellen Maschine CACAO
5 ##
6 ## This file is part of CACAO.
7 ##
8 ## This program is free software; you can redistribute it and/or
9 ## modify it under the terms of the GNU General Public License as
10 ## published by the Free Software Foundation; either version 2, or (at
11 ## your option) any later version.
12 ##
13 ## This program is distributed in the hope that it will be useful, but
14 ## WITHOUT ANY WARRANTY; without even the implied warranty of
15 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16 ## General Public License for more details.
17 ##
18 ## You should have received a copy of the GNU General Public License
19 ## along with this program; if not, write to the Free Software
20 ## Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
21 ## 02110-1301, USA.
22
23
24 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/src -I$(top_srcdir)/src/vm/jit/$(ARCH_DIR) -I$(top_srcdir)/src/vm/jit/$(ARCH_DIR)/$(OS_DIR) -I$(top_builddir)
25
26 JAVA          = $(top_builddir)/src/cacao/cacao
27 JAVAH         = $(CACAOH)
28 BOOTCLASSPATH = $(top_builddir)/src/lib/classes:$(CLASSPATH_CLASSES)
29 JAVACMD       = $(JAVA) -Xbootclasspath:$(BOOTCLASSPATH)
30 JAVACCMD      = $(JAVAC) -bootclasspath $(BOOTCLASSPATH)
31 JAVAHCMD      = $(JAVAH) -bootclasspath $(BOOTCLASSPATH)
32
33 SOURCE_FILES = \
34         checkjni.java \
35         testarguments.java
36
37 EXTRA_DIST = \
38         $(SOURCE_FILES) \
39         checkjni.c \
40         testarguments.c \
41         \
42         checkjni.output \
43         testarguments.output
44
45 CLEANFILES = \
46         *.class \
47         *.h \
48         *.so \
49         *.thisoutput \
50         *.this2output
51
52 NOTESTNAMES = \
53         test
54
55 TESTNAMES = \
56         checkjni \
57         testarguments
58
59 check: $(TESTNAMES)
60
61 $(TESTNAMES) $(NOTESTNAMES):
62         @$(JAVACCMD) -d . $(srcdir)/$@.java
63         @$(JAVAHCMD) $@
64         @$(CC) -shared $(AM_CPPFLAGS) $(CFLAGS) $(srcdir)/$@.c -o lib$@.so -fPIC
65         @LD_LIBRARY_PATH=$(top_builddir)/src/cacao/.libs:. $(SHELL) $(srcdir)/../Test.sh "$(JAVACMD)" $@ $(srcdir)
66
67
68 ## Local variables:
69 ## mode: Makefile
70 ## indent-tabs-mode: t
71 ## c-basic-offset: 4
72 ## tab-width: 8
73 ## compile-command: "automake --add-missing"
74 ## End: