From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13853 invoked by alias); 31 May 2007 06:39:57 -0000 Received: (qmail 13834 invoked by uid 22791); 31 May 2007 06:39:56 -0000 X-Spam-Check-By: sourceware.org Received: from wr-out-0506.google.com (HELO wr-out-0506.google.com) (64.233.184.230) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 31 May 2007 06:39:51 +0000 Received: by wr-out-0506.google.com with SMTP id 67so60501wri for ; Wed, 30 May 2007 23:39:49 -0700 (PDT) Received: by 10.82.180.17 with SMTP id c17mr15321782buf.1180593589043; Wed, 30 May 2007 23:39:49 -0700 (PDT) Received: from scientist.mobile.usilu.net ( [195.176.176.226]) by mx.google.com with ESMTP id u9sm2952093muf.2007.05.30.23.39.47; Wed, 30 May 2007 23:39:47 -0700 (PDT) Message-ID: <465E6DB3.50405@gnu.org> Date: Thu, 31 May 2007 09:37:00 -0000 From: Paolo Bonzini User-Agent: Thunderbird 2.0.0.0 (Macintosh/20070326) MIME-Version: 1.0 To: tromey@redhat.com CC: "H. J. Lu" , Andreas Schwab , Matthias Klose , gcc-patches@gcc.gnu.org, java-patches@gcc.gnu.org Subject: Re: PATCH: PR libjava/32078: Update libtool in classpath References: <465C2D27.10500@gnu.org> <20070529155820.GA13758@lucon.org> <20070529171642.GA14163@lucon.org> <20070529174124.GA14440@lucon.org> <20070529192656.GA15014@lucon.org> <20070530173736.GA14053@lucon.org> In-Reply-To: Content-Type: multipart/mixed; boundary="------------020406010705050603020901" Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2007-05/txt/msg02130.txt.bz2 This is a multi-part message in MIME format. --------------020406010705050603020901 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-length: 598 > H.J.> My change in classpath won't work without my libtool.m4 change. I > H.J.> will check in my libtool.m4 change to enable libjava build again. We > H.J.> can always back it out later when a better solution is found. > > I'm sympathetic to this but it isn't how GCC development works. > Unfortunately, I think we have to keep things broken until someone > reviews the change. IMO it definitely doesn't qualify as obvious. No big deal. Here's the patch to fix it locally. My apologies for the prolonged breakage, and thanks to Andrew Haley for making the problem more clear to me. Paolo --------------020406010705050603020901 Content-Type: text/plain; x-mac-type="0"; x-mac-creator="0"; name="pr32098-proper-fix.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="pr32098-proper-fix.patch" Content-length: 3068 2003-05-31 Paolo Bonzini PR libjava/32098 * libtool.m4: Revert previous change. * ltgcc.m4: Put it here. libjava: 2003-05-31 Paolo Bonzini PR libjava/32098 * aclocal.m4: Regenerate. * configure: Regenerate. Index: libtool.m4 =================================================================== --- libtool.m4 (revision 125214) +++ libtool.m4 (working copy) @@ -6757,14 +6757,9 @@ _LT_TAG_COMPILER _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE -# We can't call gcj to test gcj features when building libjava in gcc -# since gcj may depend on ecj1 which may not be available yet. We use -# gcc to test gcj features. -ac_ext=c -lt_simple_compile_test_code="int some_variable = 0;" -lt_simple_link_test_code='int main(){return(0);}' - # Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${GCJ-"gcj"} compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) @@ -6791,6 +6786,7 @@ if test -n "$compiler"; then fi AC_LANG_RESTORE +CC="$lt_save_CC" ])# _LT_LANG_GCJ_CONFIG Index: ltgcc.m4 =================================================================== --- ltgcc.m4 (revision 0) +++ ltgcc.m4 (revision 0) @@ -0,0 +1,60 @@ +# _LT_LANG_GCJ_CONFIG([TAG]) +# -------------------------- +# Ensure that the configuration variables for the GNU Java Compiler compiler +# are suitably defined. These variables are subsequently used by _LT_CONFIG +# to write the compiler configuration to `libtool'. Locally modified to +# run its tests on C programs, because we cannot link Java programs until +# we have finished building libjava. +AC_DEFUN([_LT_LANG_GCJ_CONFIG], +[AC_REQUIRE([LT_PROG_GCJ])dnl +AC_LANG_SAVE + +# Source file extension for Java test sources. +ac_ext=c + +# Object file extension for compiled Java test sources. +objext=o +_LT_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_TAG_COMPILER + +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE + +# Allow CC to be a program name with arguments. +compiler=$CC +_LT_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) + +# GCJ did not exist at the time GCC didn't implicitly link libc in. +_LT_TAGVAR(archive_cmds_need_lc, $1)=no + +_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds + +## CAVEAT EMPTOR: +## There is no encapsulation within the following macros, do not change +## the running order or otherwise move them around unless you know exactly +## what you are doing... +if test -n "$compiler"; then + _LT_COMPILER_NO_RTTI($1) + _LT_COMPILER_PIC($1) + _LT_COMPILER_C_O($1) + _LT_COMPILER_FILE_LOCKS($1) + _LT_LINKER_SHLIBS($1) + _LT_SYS_DYNAMIC_LINKER($1) + _LT_LINKER_HARDCODE_LIBPATH($1) + + _LT_CONFIG($1) +fi + +_LT_TAGVAR(compiler, $1)=${GCJ-gcj} +AC_LANG_RESTORE +])# _LT_LANG_GCJ_CONFIG --------------020406010705050603020901--