From patchwork Tue Dec 13 17:40:57 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rainer Orth X-Patchwork-Id: 131151 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 23D7D1007D3 for ; Wed, 14 Dec 2011 04:41:25 +1100 (EST) Received: (qmail 26339 invoked by alias); 13 Dec 2011 17:41:17 -0000 Received: (qmail 26300 invoked by uid 22791); 13 Dec 2011 17:41:15 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD, TW_BF, TW_IB, T_TVD_MIME_NO_HEADERS X-Spam-Check-By: sourceware.org Received: from snape.CeBiTec.Uni-Bielefeld.DE (HELO smtp-relay.CeBiTec.Uni-Bielefeld.DE) (129.70.160.84) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 13 Dec 2011 17:41:01 +0000 Received: from localhost (localhost.CeBiTec.Uni-Bielefeld.DE [127.0.0.1]) by smtp-relay.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTP id 1C20B310; Tue, 13 Dec 2011 18:41:00 +0100 (CET) Received: from smtp-relay.CeBiTec.Uni-Bielefeld.DE ([127.0.0.1]) by localhost (malfoy.CeBiTec.Uni-Bielefeld.DE [127.0.0.1]) (amavisd-new, port 10024) with LMTP id zjh0Fu4PPG+j; Tue, 13 Dec 2011 18:40:58 +0100 (CET) Received: from manam.CeBiTec.Uni-Bielefeld.DE (manam.CeBiTec.Uni-Bielefeld.DE [129.70.161.120]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp-relay.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTPS id 643FE30F; Tue, 13 Dec 2011 18:40:58 +0100 (CET) Received: (from ro@localhost) by manam.CeBiTec.Uni-Bielefeld.DE (8.14.5+Sun/8.14.5/Submit) id pBDHevpP029890; Tue, 13 Dec 2011 18:40:57 +0100 (MET) From: Rainer Orth To: gcc-patches@gcc.gnu.org Cc: java-patches@gcc.gnu.org, libffi-discuss@sourceware.org Subject: [libffi] Build 64-bit multilib for i?86-linux Date: Tue, 13 Dec 2011 18:40:57 +0100 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (usg-unix-v) MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org I've recently tried a i686-unknown-linux-gnu --enable-targets=all bootstrap, which failed to link the 64-bit jv-convert etc.: ./.libs/libgcj.so: undefined reference to `ffi_raw_call' ./.libs/libgcj.so: undefined reference to `ffi_prep_raw_closure_loc' ./.libs/libgcj.so: undefined reference to `ffi_prep_cif_machdep' ./.libs/libgcj.so: undefined reference to `ffi_prep_closure_loc' ./.libs/libgcj.so: undefined reference to `ffi_call' collect2: error: ld returned 1 exit status make[5]: *** [jv-convert] Error 1 This happens because libffi doesn't build the x86_64 objects in this configuration. The following patch fixes this and allowed (together with a libjava patch to be submitted shortly) the bootstrap to finish. I've also bootstrapped x86_64-unknown-linux-gnu without regressions. The same issue still exists in upstream libffi, and should be harmless without --enable-targets=all since the added files are empty then. Ok for mainline gcc? Rainer 2011-12-13 Rainer Orth * configure.ac (i?86-*-*): Set TARGET to X86_64. * configure: Regenerate. diff --git a/libffi/configure.ac b/libffi/configure.ac --- a/libffi/configure.ac +++ b/libffi/configure.ac @@ -99,7 +99,7 @@ case "$host" in TARGET=X86_64; TARGETDIR=x86 ;; i?86-*-*) - TARGET=X86; TARGETDIR=x86 + TARGET=X86_64; TARGETDIR=x86 ;; ia64*-*-*)