(default_compilers): Add null entries for languages we heard of.
authorRichard Kenner <kenner@gcc.gnu.org>
Wed, 3 Jul 1996 21:09:09 +0000 (17:09 -0400)
committerRichard Kenner <kenner@gcc.gnu.org>
Wed, 3 Jul 1996 21:09:09 +0000 (17:09 -0400)
(main): If found one of those entries, say compiler not installed.

From-SVN: r12388

gcc/gcc.c

index 12549fca09112a35ab9c4299de2ad183e483042b..6b46cdbee1c571b275b72b419da9dcb0b97d96ab 100644 (file)
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -558,6 +558,14 @@ static int n_compilers;
 
 static struct compiler default_compilers[] =
 {
+  /* Add lists of suffixes of known languages here.  If those languages
+     were no present when we built the driver, we will hit these copies
+     and given a more meaningful error than "file not used since
+     linking is not done".  */
+  {".cc", "#C++"}, {".cxx", "#C++"}, {".cpp", "#C++"}, {".c++", "#C++"},
+  {".C", "#C++"}, {".ads", "#Ada"}, {".adb", "#Ada"}, {".ada", "#Ada"},
+  {".f", "#Fortran"},
+  /* Next come the entries for C.  */
   {".c", "@c"},
   {"@c",
    "cpp -lang-c%{ansi:89} %{nostdinc*} %{C} %{v} %{A*} %{I*} %{P} %I\
@@ -4259,6 +4267,10 @@ main (argc, argv)
          register char *p;
          int len;
 
+         if (cp->spec[0][0] == '#')
+           error ("%s: %s compiler not installed on this system",
+                  input_filename, &cp->spec[0][1]);
+
          input_basename = input_filename;
          for (p = input_filename; *p; p++)
            if (*p == '/' || *p == DIR_SEPARATOR)