public inbox for java@gcc.gnu.org
 help / color / mirror / Atom feed
From: Andrew Haley <aph@redhat.com>
To: GCC Patches <gcc-patches@gcc.gnu.org>
Cc: java@gcc.gnu.org
Subject: Patch: move lang_specific_driver after setup of cc_libexec_prefix
Date: Wed, 06 Jan 2010 15:06:00 -0000	[thread overview]
Message-ID: <4B44A6E8.2070300@redhat.com> (raw)

gcj is not relocatable because the libexec prefix is set *after*
lang_specific_driver is called.  Unfortunately, lang_specific_driver
needs to know the libexec prefix to pass it to ecj1.  I can't see any
reason why lang_specific_driver needs to be called before the libexec
prefix is set, and it doesn't seem to break anything.

Fixed thusly, bootstrapped x86_64 GNU/Linux.

OK?

Andrew.


2010-01-06  Andrew Haley  <aph@redhat.com>

	* gcc.c (process_command): Move lang_specific_driver before
	setting cc_libexec_prefix.

Index: gcc/gcc.c
===================================================================
--- gcc/gcc.c   (revision 155475)
+++ gcc/gcc.c   (working copy)
@@ -3599,12 +3599,6 @@
                     CONST_CAST2 (const char *const **, const char ***,
                                  &argv));

-  /* Do language-specific adjustment/addition of flags.  */
-  lang_specific_driver (&argc,
-                       CONST_CAST2 (const char *const **, const char ***,
-                                    &argv),
-                       &added_libraries);
-
   /* Handle any -no-canonical-prefixes flag early, to assign the function
      that builds relative prefixes.  This function creates default search
      paths that are needed later in normal option handling.  */
@@ -3660,6 +3654,12 @@
      is relocated. The toolchain was either relocated using GCC_EXEC_PREFIX
      or an automatically created GCC_EXEC_PREFIX from argv[0].  */

+  /* Do language-specific adjustment/addition of flags.  */
+  lang_specific_driver (&argc,
+                       CONST_CAST2 (const char *const **, const char ***,
+                                    &argv),
+                       &added_libraries);
+
   if (gcc_exec_prefix)
     {
       int len = strlen (gcc_exec_prefix);

             reply	other threads:[~2010-01-06 15:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-06 15:06 Andrew Haley [this message]
2010-01-14 15:20 ` Joseph S. Myers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B44A6E8.2070300@redhat.com \
    --to=aph@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=java@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).