gcc.c (main): Read user-specified specs files after computing additional startfile_pr...
authorTom Tromey <tromey@cygnus.com>
Thu, 24 Jun 1999 21:33:54 +0000 (15:33 -0600)
committerJeff Law <law@gcc.gnu.org>
Thu, 24 Jun 1999 21:33:54 +0000 (15:33 -0600)
h
        * gcc.c (main): Read user-specified specs files after computing
        additional startfile_prefixes.

From-SVN: r27742

gcc/gcc.c

index e02bc0c1e9a8ed05c739525d5c9e98fdd225e78f..b4a8d3d26d2628a44659fb033e714a47e3034715 100644 (file)
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -4818,18 +4818,7 @@ main (argc, argv)
   if (access (specs_file, R_OK) == 0)
     read_specs (specs_file, TRUE);
  
-  /* Process any user specified specs in the order given on the command
-     line.  */
-  for (uptr = user_specs_head; uptr; uptr = uptr->next)
-    {
-      char *filename = find_a_file (&startfile_prefixes, uptr->filename, R_OK);
-      read_specs (filename ? filename : uptr->filename, FALSE);
-    }
-
   /* If not cross-compiling, look for startfiles in the standard places.  */
-  /* The fact that these are done here, after reading the specs file,
-     means that it cannot be found in these directories.
-     But that's okay.  It should never be there anyway.  */
   if (*cross_compile == '0')
     {
 #ifdef MD_EXEC_PREFIX
@@ -4892,6 +4881,14 @@ main (argc, argv)
                    "BINUTILS", 0, 0, NULL_PTR);
     }
 
+  /* Process any user specified specs in the order given on the command
+     line.  */
+  for (uptr = user_specs_head; uptr; uptr = uptr->next)
+    {
+      char *filename = find_a_file (&startfile_prefixes, uptr->filename, R_OK);
+      read_specs (filename ? filename : uptr->filename, FALSE);
+    }
+
   /* If we have a GCC_EXEC_PREFIX envvar, modify it for cpp's sake.  */
   if (gcc_exec_prefix)
     {