Add test suites for CLISP, CFFI, UFFI.

git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@8429 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
Matthias Köppe 2006-01-14 13:36:28 +00:00
commit 280d183818
12 changed files with 290 additions and 10 deletions

View file

@ -947,3 +947,49 @@ allegrocl_cpp: $(SRCS)
allegrocl_clean:
##################################################################
##### CLISP ######
##################################################################
clisp: $(SRCS)
$(SWIG) -clisp $(SWIGOPT) $(INTERFACE)
clisp_cpp: $(SRCS)
$(SWIG) -c++ -clisp $(SWIGOPT) $(INTERFACE)
clisp_clean:
##################################################################
##### CFFI ######
##################################################################
cffi: $(SRCS)
$(SWIG) -cffi $(SWIGOPT) $(INTERFACE)
# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCS)
# $(LDSHARED) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO)
cffi_cpp: $(SRCS)
$(SWIG) -c++ -cffi $(SWIGOPT) $(INTERFACE)
$(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES)
$(CXXSHARED) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO)
cffi_clean:
##################################################################
##### UFFI ######
##################################################################
uffi: $(SRCS)
$(SWIG) -uffi $(SWIGOPT) $(INTERFACE)
# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCS)
# $(LDSHARED) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO)
uffi_cpp: $(SRCS)
$(SWIG) -c++ -uffi $(SWIGOPT) $(INTERFACE)
# $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES)
# $(CXXSHARED) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO)
uffi_clean:

View file

@ -0,0 +1,62 @@
*_wrap.c
*_wrap.cxx
Makefile
SunWS_cache
abstract_access.cl
abstract_inherit.cl
abstract_inherit_ok.cl
abstract_signature.cl
abstract_typedef.cl
abstract_typedef2.cl
abstract_virtual.cl
access_change.cl
add_link.cl
aggregate.cl
anonymous_bitfield.cl
argout.cl
array_member.cl
array_typedef_memberin.cl
arrayref.cl
arrays.cl
arrays_dimensionless.cl
arrays_global.cl
arrays_global_twodim.cl
arrays_scope.cl
bloody_hell.cl
char_constant.cl
clientdata_prop_a.cl
clientdata_prop_b.cl
const_const.cl
director_string.cl
empty.cl
enums.cl
extern_declaration.cl
function_typedef.cl
immutable.cl
imports_a.cl
imports_b.cl
inctest.cl
lextype.cl
li_carrays.cl
li_cdata.cl
li_cmalloc.cl
li_constraints.cl
li_cpointer.cl
li_math.cl
li_std_except.cl
long_long.cl
name.cl
nested.cl
newobject2.cl
overload_extend.cl
overload_extendc.cl
preproc.cl
ret_by_value.cl
sizeof_pointer.cl
sneaky1.cl
struct_rename.cl
template_typedef_cplx2.cl
template_typedef_import.cl
typedef_struct.cl
typemap_subst.cl
unions.cl

View file

@ -12,8 +12,7 @@ top_builddir = @top_builddir@
include $(srcdir)/../common.mk
# no C++ tests for now
CPP_TEST_CASES =
#CPP_TEST_CASES +=
#C_TEST_CASES +=
# Rules for the different types of tests
@ -41,7 +40,7 @@ run_testcase = \
# Clean: (does nothing, we dont generate extra allegrocl code)
%.clean:
clean:
$(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile allegrocl_clean

View file

@ -0,0 +1,4 @@
*.lisp
*_wrap.c*
Makefile
SunWS_cache

View file

@ -0,0 +1,48 @@
#######################################################################
# $Header$
# Makefile for cffi test-suite
#######################################################################
LANGUAGE = cffi
CFFI = @CFFIBIN@
SCRIPTSUFFIX = _runme.lisp
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = @top_builddir@
include $(srcdir)/../common.mk
# no C++ tests for now
CPP_TEST_CASES =
#C_TEST_CASES +=
# Rules for the different types of tests
%.cpptest:
$(setup) \
($(swig_and_compile_cpp); ) &&\
$(run_testcase)
%.ctest:
$(setup) \
($(swig_and_compile_c); ) &&\
$(run_testcase)
%.multicpptest:
$(setup) \
($(swig_and_compile_multi_cpp); ) &&\
$(run_testcase)
# Runs the testcase. A testcase is only run if
# a file is found which has _runme.lisp appended after the testcase name.
run_testcase = \
if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then ( \
env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(CFFIBIN) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX);) \
fi;
# Clean: (does nothing, we dont generate extra cffi code)
%.clean:
clean:
$(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile cffi_clean

View file

@ -0,0 +1,2 @@
Makefile
*.lisp

View file

@ -0,0 +1,48 @@
#######################################################################
# $Header$
# Makefile for clisp test-suite
#######################################################################
LANGUAGE = clisp
CLISP = @CLISPBIN@
SCRIPTSUFFIX = _runme.lisp
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = @top_builddir@
include $(srcdir)/../common.mk
# no C++ tests for now
CPP_TEST_CASES =
#C_TEST_CASES +=
# Rules for the different types of tests
%.cpptest:
$(setup) \
($(swig_and_compile_cpp); ) &&\
$(run_testcase)
%.ctest:
$(setup) \
($(swig_and_compile_c); ) &&\
$(run_testcase)
%.multicpptest:
$(setup) \
($(swig_and_compile_multi_cpp); ) &&\
$(run_testcase)
# Runs the testcase. A testcase is only run if
# a file is found which has _runme.lisp appended after the testcase name.
run_testcase = \
if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then ( \
env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(CLISPBIN) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX);) \
fi;
# Clean: (does nothing, we dont generate extra clisp code)
%.clean:
clean:
$(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile clisp_clean

View file

@ -1,3 +1,4 @@
*wrap*
*-guile
*wrap*
Makefile
SunWS_cache

View file

@ -1,3 +1,4 @@
*wrap*
*-guile
*wrap*
Makefile
SunWS_cache

View file

@ -0,0 +1,3 @@
Makefile
*.cl
*_wrap.c*

View file

@ -0,0 +1,48 @@
#######################################################################
# $Header$
# Makefile for uffi test-suite
#######################################################################
LANGUAGE = uffi
UFFI = @UFFIBIN@
SCRIPTSUFFIX = _runme.lisp
srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = @top_builddir@
include $(srcdir)/../common.mk
# no C++ tests for now
CPP_TEST_CASES =
#C_TEST_CASES +=
# Rules for the different types of tests
%.cpptest:
$(setup) \
($(swig_and_compile_cpp); ) &&\
$(run_testcase)
%.ctest:
$(setup) \
($(swig_and_compile_c); ) &&\
$(run_testcase)
%.multicpptest:
$(setup) \
($(swig_and_compile_multi_cpp); ) &&\
$(run_testcase)
# Runs the testcase. A testcase is only run if
# a file is found which has _runme.lisp appended after the testcase name.
run_testcase = \
if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then ( \
env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(UFFIBIN) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX);) \
fi;
# Clean: (does nothing, we dont generate extra uffi code)
%.clean:
clean:
$(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile uffi_clean

View file

@ -43,6 +43,9 @@ skip-csharp = test -n "@SKIP_CSHARP@"
skip-modula3 = test -n "@SKIP_MODULA3@"
skip-lua = test -n "@SKIP_LUA@"
skip-allegrocl = test -n "@SKIP_ALLEGROCL@"
skip-clisp = test -n "@SKIP_CLISP@"
skip-cffi = test -n "@SKIP_CFFI@"
skip-uffi = test -n "@SKIP_UFFI@"
# Additional dependencies for some tests
skip-gcj = test -n "@SKIP_GCJ@"
@ -94,7 +97,10 @@ check-examples: \
check-csharp-examples \
check-modula3-examples \
check-lua-examples \
check-allegrocl-examples
check-allegrocl-examples \
check-clisp-examples \
check-uffi-examples \
check-cffi-examples
check-%-examples:
@passed=true; \
@ -172,7 +178,10 @@ check-test-suite: \
check-modula3-test-suite \
check-lua-test-suite \
check-allegrocl-test-suite \
# check-chicken-test-suite
check-clisp-test-suite \
check-uffi-test-suite \
check-cffi-test-suite \
check-chicken-test-suite
check-%-test-suite:
@passed=true; \
@ -206,7 +215,10 @@ all-test-suite: \
all-modula3-test-suite \
all-lua-test-suite \
all-allegrocl-test-suite \
# all-chicken-test-suite
all-clisp-test-suite \
all-uffi-test-suite \
all-cffi-test-suite \
all-chicken-test-suite
all-%-test-suite:
@$(MAKE) -k -s check-$*-test-suite ACTION=all
@ -228,7 +240,10 @@ broken-test-suite: \
broken-modula3-test-suite \
broken-lua-test-suite \
broken-allegrocl-test-suite \
# broken-chicken-test-suite
broken-clisp-test-suite \
broken-uffi-test-suite \
broken-cffi-test-suite \
broken-chicken-test-suite
broken-%-test-suite:
@$(MAKE) -k -s check-$*-test-suite ACTION=broken
@ -299,6 +314,9 @@ noskip-test-suite: \
noskip-csharp-test-suite \
noskip-lua-test-suite \
noskip-allegrocl-test-suite \
noskip-clisp-test-suite \
noskip-uffi-test-suite \
noskip-cffi-test-suite \
noskip-chicken-test-suite
noskip-%-test-suite:
@ -343,7 +361,7 @@ install-main:
@$(INSTALL_PROGRAM) $(TARGET) $(DESTDIR)$(BIN_DIR)/$(TARGET)
lib-languages = gcj typemaps tcl perl5 python guile java mzscheme ruby php4 ocaml \
pike chicken csharp modula3 allegrocl clisp lua cffi
pike chicken csharp modula3 allegrocl clisp lua cffi uffi
lib-modules = std