Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/gnu/dist/toolchain/gcc Trim the gcc frontend's paths way dow...



details:   https://anonhg.NetBSD.org/src/rev/1c7217afb649
branches:  trunk
changeset: 513828:1c7217afb649
user:      tv <tv%NetBSD.org@localhost>
date:      Tue Aug 14 13:36:09 2001 +0000

description:
Trim the gcc frontend's paths way down to size.  We know where system-supplied
libraries and so forth are, so we don't need to go looking in 9+ locations
for it.

diffstat:

 gnu/dist/toolchain/gcc/config/netbsd.h |   4 ++--
 gnu/dist/toolchain/gcc/gcc.c           |  12 ++++++++++++
 2 files changed, 14 insertions(+), 2 deletions(-)

diffs (94 lines):

diff -r cf117af9e0ea -r 1c7217afb649 gnu/dist/toolchain/gcc/config/netbsd.h
--- a/gnu/dist/toolchain/gcc/config/netbsd.h    Tue Aug 14 13:15:45 2001 +0000
+++ b/gnu/dist/toolchain/gcc/config/netbsd.h    Tue Aug 14 13:36:09 2001 +0000
@@ -29,8 +29,8 @@
 /* Under NetBSD, the normal location of the various *crt*.o files is the
    /usr/lib directory.  */
 
-#undef MD_STARTFILE_PREFIX
-#define MD_STARTFILE_PREFIX            "/usr/lib/"
+#undef STANDARD_STARTFILE_PREFIX
+#define STANDARD_STARTFILE_PREFIX      "/usr/lib/"
 
 #endif
 
diff -r cf117af9e0ea -r 1c7217afb649 gnu/dist/toolchain/gcc/gcc.c
--- a/gnu/dist/toolchain/gcc/gcc.c      Tue Aug 14 13:15:45 2001 +0000
+++ b/gnu/dist/toolchain/gcc/gcc.c      Tue Aug 14 13:36:09 2001 +0000
@@ -3057,6 +3057,7 @@
      (such as cpp) rather than those of the host system.  */
   /* Use 2 as fourth arg meaning try just the machine as a suffix,
      as well as trying the machine and the version.  */
+#ifndef NETBSD_NATIVE
 #ifndef OS2
   add_prefix (&exec_prefixes, standard_exec_prefix, "BINUTILS",
              0, 2, warn_std_ptr);
@@ -3108,6 +3109,7 @@
   add_prefix (&startfile_prefixes,
              concat (tooldir_prefix, "lib", dir_separator_str, NULL_PTR),
              "BINUTILS", 0, 0, NULL_PTR);
+#endif
 
   /* More prefixes are enabled in main, after we read the specs file
      and determine whether this is cross-compilation or not.  */
@@ -4796,9 +4798,11 @@
 
   /* Read specs from a file if there is one.  */
 
+#ifndef NETBSD_NATIVE
   machine_suffix = concat (spec_machine, dir_separator_str,
                           spec_version, dir_separator_str, NULL_PTR);
   just_machine_suffix = concat (spec_machine, dir_separator_str, NULL_PTR);
+#endif
 
   specs_file = find_a_file (&startfile_prefixes, "specs", R_OK);
   /* Read the specs file unless it is a default one.  */
@@ -4807,6 +4811,7 @@
   else
     init_spec ();
 
+#ifndef NETBSD_NATIVE
   /* We need to check standard_exec_prefix/just_machine_suffix/specs
      for any override of as, ld and libraries. */
   specs_file = (char *) alloca (strlen (standard_exec_prefix)
@@ -4818,14 +4823,17 @@
   strcat (specs_file, "specs");
   if (access (specs_file, R_OK) == 0)
     read_specs (specs_file, TRUE);
+#endif
  
   /* If not cross-compiling, look for startfiles in the standard places.  */
   if (*cross_compile == '0')
     {
 #ifdef MD_EXEC_PREFIX
       add_prefix (&exec_prefixes, md_exec_prefix, "GCC", 0, 0, NULL_PTR);
+#ifndef NETBSD_NATIVE
       add_prefix (&startfile_prefixes, md_exec_prefix, "GCC", 0, 0, NULL_PTR);
 #endif
+#endif
 
 #ifdef MD_STARTFILE_PREFIX
       add_prefix (&startfile_prefixes, md_startfile_prefix, "GCC",
@@ -4865,10 +4873,12 @@
                      NULL_PTR, 0, 0, NULL_PTR);
        }                      
 
+#ifndef NETBSD_NATIVE
       add_prefix (&startfile_prefixes, standard_startfile_prefix_1,
                  "BINUTILS", 0, 0, NULL_PTR);
       add_prefix (&startfile_prefixes, standard_startfile_prefix_2,
                  "BINUTILS", 0, 0, NULL_PTR);
+#endif
 #if 0 /* Can cause surprises, and one can use -B./ instead.  */
       add_prefix (&startfile_prefixes, "./", NULL_PTR, 0, 1, NULL_PTR);
 #endif
@@ -4923,7 +4933,9 @@
 
   if (print_search_dirs)
     {
+#ifndef NETBSD_NATIVE
       printf ("install: %s%s\n", standard_exec_prefix, machine_suffix);
+#endif
       printf ("programs: %s\n", build_search_list (&exec_prefixes, "", 0));
       printf ("libraries: %s\n", build_search_list (&startfile_prefixes, "", 0));
       exit (0);



Home | Main Index | Thread Index | Old Index