diff options
author | H.J. Lu <hjl@lucon.org> | 2009-04-11 14:06:56 +0000 |
---|---|---|
committer | H.J. Lu <hjl@lucon.org> | 2009-04-11 14:06:56 +0000 |
commit | 8938bac07c1994c91a31885aec5c9632b4c1584a (patch) | |
tree | 06d6084f9ddf1aae5a34b64b5219296ff1291d7b /ld/ldfile.c | |
parent | c7287cacbaa646525367ed7a74cfcbd5ff7515b6 (diff) | |
download | binutils-redhat-8938bac07c1994c91a31885aec5c9632b4c1584a.tar.gz |
2009-04-11 H.J. Lu <hongjiu.lu@intel.com>
PR ld/10047
* ldfile.c (ldfile_find_command_file): First try raw name.
Diffstat (limited to 'ld/ldfile.c')
-rw-r--r-- | ld/ldfile.c | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/ld/ldfile.c b/ld/ldfile.c index 422416a8b4..2aff713964 100644 --- a/ld/ldfile.c +++ b/ld/ldfile.c @@ -542,10 +542,10 @@ find_scripts_dir (void) return NULL; } -/* If DEFAULT_ONLY is false, try to open NAME; if that fails, look for - it in directories specified with -L, then in the default script - directory, without and with EXTEND appended. If DEFAULT_ONLY is - true, the search is restricted to the default script location. */ +/* Try to open NAME; if that fails, look for it in directories specified + with -L, then in the default script directory, without and with EXTEND + appended. If DEFAULT_ONLY is true, the search is restricted to the + default script location. */ static FILE * ldfile_find_command_file (const char *name, const char *extend, @@ -556,13 +556,10 @@ ldfile_find_command_file (const char *name, const char *extend, char *buffer; static search_dirs_type *script_search; - if (!default_only) - { - /* First try raw name. */ - result = try_open (name, ""); - if (result != NULL) - return result; - } + /* First try raw name for uninstalled linker. */ + result = try_open (name, ""); + if (result != NULL) + return result; if (!script_search) { |