Bug 64607 - [5 Regression] Multilib test stops working in libffi
Summary: [5 Regression] Multilib test stops working in libffi
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: libffi (show other bugs)
Version: 5.0
: P1 normal
Target Milestone: 5.0
Assignee: Richard Henderson
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-01-14 23:23 UTC by H.J. Lu
Modified: 2015-01-20 21:31 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2015-01-14 00:00:00


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description H.J. Lu 2015-01-14 23:23:23 UTC
After merging with libffi upstream, multilib test stops working in libffi.

https://gcc.gnu.org/ml/gcc-testresults/2015-01/msg01438.html

shows

		=== libffi tests ===


Running target unix

		=== libffi Summary ===

# of expected passes		2204

instead of

https://gcc.gnu.org/ml/gcc-testresults/2015-01/msg00030.html

		=== libffi tests ===


Running target unix/-m32

		=== libffi Summary for unix/-m32 ===

# of expected passes		24

Running target unix

		=== libffi Summary for unix ===

# of expected passes		24

		=== libffi Summary ===

# of expected passes		3638
# of unsupported tests		110

It is due to

commit f8cdf11467181f2a9a6b7e748167569aa58e3a81
Author: Ryan VanderMeulen <ryanvm@gmail.com>
Date:   Mon Mar 10 15:04:58 2014 -0400

    Replace double quotes with single quotes in Makefile.in to improve compatibility between some versions of MSYS and gmake. From Mozilla bug 943728.
    https://bugzilla.mozilla.org/show_bug.cgi?id=943728

:100644 100644 03bfdff9f9d9477cab36c6f41583a2988335137d e930f53fde6e827c649d2a1cdeb4e39fd20f4286 M	ChangeLog
:100644 100644 08f66206d39f42818284fbe503939f6f0ec0bb20 70d9bb7447ed4821fed14bf4419474ad390dd537 M	Makefile.in


commit 46c5d3c30fdc2b43c076ad955078d7c5f1e75b37
Author: Ryan VanderMeulen <ryanvm@gmail.com>
Date:   Sun Mar 16 21:16:08 2014 -0400

    Change double quotes in Makefile.am to single quotes.
    
    This was originally done in PR #84, except the change was made to Makefile.in instead of Makefile.am and was therefore reverted the next time the files were regenerated.

:100644 100644 557d5269301b136ade693997102fccb66b8e9e43 e2011e7e31e9fccb0db935dcf1b2c4991c7f1207 M	Makefile.am

It doesn't work with

make check -k RUNTESTFLAGS="--target_board='unix{-m32,}'"
Comment 1 Richard Henderson 2015-01-15 21:45:46 UTC
Mine
Comment 2 Dominique d'Humieres 2015-01-16 10:22:53 UTC
As expected from comment 0, the following patch restores the previous behavior.

--- ../_clean/libffi/Makefile.in	2015-01-12 17:31:37.000000000 +0100
+++ libffi/Makefile.in	2015-01-15 23:02:11.000000000 +0100
@@ -336,39 +336,39 @@ MAINTAINERCLEANFILES = $(srcdir)/doc/lib
 # values defined in terms of make variables, as is the case for CC and
 # friends when we are called from the top level Makefile.
 AM_MAKEFLAGS = \
-	'AR_FLAGS=$(AR_FLAGS)' \
-	'CC_FOR_BUILD=$(CC_FOR_BUILD)' \
-	'CFLAGS=$(CFLAGS)' \
-	'CXXFLAGS=$(CXXFLAGS)' \
-	'CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)' \
-	'CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)' \
-	'INSTALL=$(INSTALL)' \
-	'INSTALL_DATA=$(INSTALL_DATA)' \
-	'INSTALL_PROGRAM=$(INSTALL_PROGRAM)' \
-	'INSTALL_SCRIPT=$(INSTALL_SCRIPT)' \
-	'JC1FLAGS=$(JC1FLAGS)' \
-	'LDFLAGS=$(LDFLAGS)' \
-	'LIBCFLAGS=$(LIBCFLAGS)' \
-	'LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)' \
-	'MAKE=$(MAKE)' \
-	'MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)' \
-	'PICFLAG=$(PICFLAG)' \
-	'PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)' \
-	'RUNTESTFLAGS=$(RUNTESTFLAGS)' \
-	'SHELL=$(SHELL)' \
-	'exec_prefix=$(exec_prefix)' \
-	'infodir=$(infodir)' \
-	'libdir=$(libdir)' \
-	'mandir=$(mandir)' \
-	'prefix=$(prefix)' \
-	'AR=$(AR)' \
-	'AS=$(AS)' \
-	'CC=$(CC)' \
-	'CXX=$(CXX)' \
-	'LD=$(LD)' \
-	'NM=$(NM)' \
-	'RANLIB=$(RANLIB)' \
-	'DESTDIR=$(DESTDIR)'
+	"AR_FLAGS=$(AR_FLAGS)" \
+	"CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+	"CFLAGS=$(CFLAGS)" \
+	"CXXFLAGS=$(CXXFLAGS)" \
+	"CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+	"CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
+	"INSTALL=$(INSTALL)" \
+	"INSTALL_DATA=$(INSTALL_DATA)" \
+	"INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+	"INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
+	"JC1FLAGS=$(JC1FLAGS)" \
+	"LDFLAGS=$(LDFLAGS)" \
+	"LIBCFLAGS=$(LIBCFLAGS)" \
+	"LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
+	"MAKE=$(MAKE)" \
+	"MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
+	"PICFLAG=$(PICFLAG)" \
+	"PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
+	"RUNTESTFLAGS=$(RUNTESTFLAGS)" \
+	"SHELL=$(SHELL)" \
+	"exec_prefix=$(exec_prefix)" \
+	"infodir=$(infodir)" \
+	"libdir=$(libdir)" \
+	"mandir=$(mandir)" \
+	"prefix=$(prefix)" \
+	"AR=$(AR)" \
+	"AS=$(AS)" \
+	"CC=$(CC)" \
+	"CXX=$(CXX)" \
+	"LD=$(LD)" \
+	"NM=$(NM)" \
+	"RANLIB=$(RANLIB)" \
+	"DESTDIR=$(DESTDIR)"
 
 
 # Subdir rules rely on $(FLAGS_TO_PASS)


		=== libffi tests ===


Running target unix/-m32

		=== libffi Summary for unix/-m32 ===

# of expected passes		1904
# of unsupported tests		30

Running target unix/-m64

		=== libffi Summary for unix/-m64 ===

# of expected passes		1904
# of unsupported tests		30

		=== libffi Summary ===

# of expected passes		3808
# of unsupported tests		60
Comment 3 Richard Henderson 2015-01-16 20:51:47 UTC
Author: rth
Date: Fri Jan 16 20:51:14 2015
New Revision: 219772

URL: https://gcc.gnu.org/viewcvs?rev=219772&root=gcc&view=rev
Log:
PR libffi/64607

 * Makefile.am (AM_MAKEFLAGS): Use double quotes on subvariables.
 * Makefile.in: Rebuilt.

Modified:
    trunk/libffi/ChangeLog
    trunk/libffi/Makefile.am
    trunk/libffi/Makefile.in
Comment 4 Richard Henderson 2015-01-16 20:54:55 UTC
Honestly, I'm not sure I saw the problem either before or after,
but I've applied Dominique's patch.  Should be fixed.
Comment 5 Richard Henderson 2015-01-19 17:58:39 UTC
Author: rth
Date: Mon Jan 19 17:58:06 2015
New Revision: 219852

URL: https://gcc.gnu.org/viewcvs?rev=219852&root=gcc&view=rev
Log:
PR libffi/64607

 * testsuite/lib/libffi.exp (libffi-init): Append -L for the
 just built libstdc++.

Modified:
    trunk/libffi/ChangeLog
    trunk/libffi/testsuite/lib/libffi.exp
Comment 6 Richard Henderson 2015-01-20 21:31:03 UTC
Works for me.