]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
backport: re PR bootstrap/14356 (gcc.c:3661: error: assignment of read-only location)
authorKelley Cook <kcook@gcc.gnu.org>
Thu, 25 Mar 2004 00:58:37 +0000 (00:58 +0000)
committerR. Kelley Cook <kcook@gcc.gnu.org>
Thu, 25 Mar 2004 00:58:37 +0000 (00:58 +0000)
2004-03-24  Kelley Cook  <kcook@gcc.gnu.org>

Backport:
2004-03-01  Mark Mitchell  <mark@codesourcery.com>

PR bootstrap/14356
* gcc.c (process_command): Remove const-qualification from argv.
(main): Likewise.

From-SVN: r79944

gcc/ChangeLog
gcc/gcc.c

index d7ac71ab1804daa77aebaf06b5b70431396ce426..7ad06262a0714b320feb84962ebcd7d836fb55a9 100644 (file)
@@ -1,3 +1,12 @@
+2004-03-24  Kelley Cook  <kcook@gcc.gnu.org>
+
+       Backport:
+       2004-03-01  Mark Mitchell  <mark@codesourcery.com>
+
+       PR bootstrap/14356
+       * gcc.c (process_command): Remove const-qualification from argv.
+       (main): Likewise.
+
 2004-03-24  Alexandre Oliva  <aoliva@redhat.com>
 
        PR preprocessor/14438
index 86fb2eb4ed55ec884c06d1155632832f49604fe7..1de6e4264ff07bbc452eda28b4706232b42eed76 100644 (file)
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -328,7 +328,7 @@ static void display_help    PARAMS ((void));
 static void add_preprocessor_option    PARAMS ((const char *, int));
 static void add_assembler_option       PARAMS ((const char *, int));
 static void add_linker_option          PARAMS ((const char *, int));
-static void process_command            PARAMS ((int, const char *const *));
+static void process_command            PARAMS ((int, const char **));
 static int execute                     PARAMS ((void));
 static void alloc_args                 PARAMS ((void));
 static void clear_args                 PARAMS ((void));
@@ -3050,7 +3050,7 @@ add_linker_option (option, len)
 static void
 process_command (argc, argv)
      int argc;
-     const char *const *argv;
+     const char **argv;
 {
   int i;
   const char *temp;
@@ -3279,10 +3279,10 @@ process_command (argc, argv)
     }
 
   /* Convert new-style -- options to old-style.  */
-  translate_options (&argc, &argv);
+  translate_options (&argc, (const char *const **) &argv);
 
   /* Do language-specific adjustment/addition of flags.  */
-  lang_specific_driver (&argc, &argv, &added_libraries);
+  lang_specific_driver (&argc, (const char *const **) &argv, &added_libraries);
 
   /* Scan argv twice.  Here, the first time, just count how many switches
      there will be in their vector, and how many input files in theirs.
@@ -5917,12 +5917,12 @@ fatal_error (signum)
   kill (getpid (), signum);
 }
 
-extern int main PARAMS ((int, const char *const *));
+extern int main PARAMS ((int, const char **));
 
 int
 main (argc, argv)
      int argc;
-     const char *const *argv;
+     const char **argv;
 {
   size_t i;
   int value;