This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

3.4 PATCH: Fix libffi testsuite on MIPS


After the new dejagnu-based libffi testsuite was installed, I noticed that
all tests failed on mips-sgi-irix6.5 (both multilibs).  The failures are
like this:

FAIL: libffi.call/closure_fn0.c (test for excess errors)
Excess errors:
In file included from /.vol/gcc/src/gcc-dist/libffi/testsuite/libffi.call/ffitest.h:4,
                 from /.vol/gcc/src/gcc-dist/libffi/testsuite/libffi.call/closure_fn0.c:10:
/var/tmp/gcc-obj/gcc-3.4-20030905/6.5-cc-java/mips-sgi-irix6.5//libffi/include/ffi.h:156:22: ffi_mips.h: No such file or directory

Executing on host: /var/tmp/gcc-obj/gcc-3.4-20030905/6.5-cc-java/gcc/xgcc -B/var/tmp/gcc-obj/gcc-3.4-20030905/6.5-cc-java/gcc/ /.vol/gcc/src/gcc-dist/libffi/testsuite/libffi.call/closure_fn0.c    -I/var/tmp/gcc-obj/gcc-3.4-20030905/6.5-cc-java/mips-sgi-irix6.5//libffi/include -L/var/tmp/gcc-obj/gcc-3.4-20030905/6.5-cc-java/mips-sgi-irix6.5/libffi/.libs -L/var/tmp/gcc-obj/gcc-3.4-20030905/6.5-cc-java/mips-sgi-irix6.5//libstdc++-v3/src/.libs  -lffi -lm   -o ./closure_fn0.exe

I.e. $objdir/$target/libffi/include (for the generated ffi.h and
fficonfig.h) is searched, but ffi_mips.h lives in $srcdir/../include which
is not.  The following patch fixes this and removes this part of the
failures.

See e.g.

	http://gcc.gnu.org/ml/gcc-testresults/2003-09/msg00313.html

for results (both N32 and N64, where the latter isn't currently supported
by libffi at all ;-).

Even so, all closure tests fails since that API isn't supported on MIPS.
Maybe there should be a mechanism to selectively XFAIL those tests?

Ok for mainline?

	Rainer

-----------------------------------------------------------------------------
Rainer Orth, Faculty of Technology, Bielefeld University



Fri Sep  5 19:15:09 2003  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>

	* testsuite/lib/libffi-dg.exp (libffi_target_compile): Search in
	srcdir for ffi_mips.h.

Index: libffi/testsuite/lib/libffi-dg.exp
===================================================================
RCS file: /cvs/gcc/gcc/libffi/testsuite/lib/libffi-dg.exp,v
retrieving revision 1.1
diff -u -p -r1.1 libffi-dg.exp
--- libffi/testsuite/lib/libffi-dg.exp	4 Sep 2003 14:47:47 -0000	1.1
+++ libffi/testsuite/lib/libffi-dg.exp	16 Sep 2003 14:07:36 -0000
@@ -156,7 +156,8 @@ proc libffi_target_compile { source dest
 	lappend  options [concat "additional_flags=$TOOL_OPTIONS" $options];
     }
 
-    lappend options "additional_flags=-I${libffi_include}"
+    # search for ffi_mips.h in srcdir, too
+    lappend options "additional_flags=-I${libffi_include} -I${srcdir}/../include"
     lappend options "additional_flags=${libffi_link_flags}"
     lappend options "libs= -lffi"
     verbose "options: $options"


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]