aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2009-09-09 13:19:51 +0000
committerAlan Modra <amodra@gmail.com>2009-09-09 13:19:51 +0000
commit22ba0981786d9fc6ab459bc449735d51f437dbe8 (patch)
tree1aea7c34b378078ab887d80ec10ee1f88cfd22e3 /gas
parent53b0eb27a9f231167f09e862695004b89c3d3c1a (diff)
downloadgdb-22ba0981786d9fc6ab459bc449735d51f437dbe8.zip
gdb-22ba0981786d9fc6ab459bc449735d51f437dbe8.tar.gz
gdb-22ba0981786d9fc6ab459bc449735d51f437dbe8.tar.bz2
* config/obj-coff.h (USE_UNIQUE): Don't define.
* config/obj-coff.c (weak_uniquify): Use an_external_name when TE_PE. * symbols.c (an_external_name): Define when TE_PE. (S_SET_EXTERNAL): Assign an_external_name when TE_PE. * tc.h (an_external_name): Declare when TE_PE.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog6
-rw-r--r--gas/config/obj-coff.c2
-rw-r--r--gas/config/obj-coff.h3
-rw-r--r--gas/symbols.c4
-rw-r--r--gas/tc.h2
5 files changed, 10 insertions, 7 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index a52d8f4..daefbd6 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,5 +1,11 @@
2009-09-09 Alan Modra <amodra@bigpond.net.au>
+ * config/obj-coff.h (USE_UNIQUE): Don't define.
+ * config/obj-coff.c (weak_uniquify): Use an_external_name when TE_PE.
+ * symbols.c (an_external_name): Define when TE_PE.
+ (S_SET_EXTERNAL): Assign an_external_name when TE_PE.
+ * tc.h (an_external_name): Declare when TE_PE.
+
* config/tc-i386.c (i386_target_format): Avoid duplicate case label.
2009-09-08 Kaz Kojima <kkojima@rr.iij4u.or.jp>
diff --git a/gas/config/obj-coff.c b/gas/config/obj-coff.c
index ed6a718..271b01e 100644
--- a/gas/config/obj-coff.c
+++ b/gas/config/obj-coff.c
@@ -1117,7 +1117,7 @@ weak_uniquify (const char * name)
char *ret;
const char * unique = "";
-#ifdef USE_UNIQUE
+#ifdef TE_PE
if (an_external_name != NULL)
unique = an_external_name;
#endif
diff --git a/gas/config/obj-coff.h b/gas/config/obj-coff.h
index 513890f..7b9b744 100644
--- a/gas/config/obj-coff.h
+++ b/gas/config/obj-coff.h
@@ -162,9 +162,6 @@
#endif
#ifdef TE_PE
-/* PE weak symbols need USE_UNIQUE. */
-#define USE_UNIQUE 1
-
#define obj_set_weak_hook pecoff_obj_set_weak_hook
#define obj_clear_weak_hook pecoff_obj_clear_weak_hook
#endif
diff --git a/gas/symbols.c b/gas/symbols.c
index c72946b..9ce4588 100644
--- a/gas/symbols.c
+++ b/gas/symbols.c
@@ -59,7 +59,7 @@ symbolS abs_symbol;
#define LOCAL_LABEL_CHAR '\002'
struct obstack notes;
-#ifdef USE_UNIQUE
+#ifdef TE_PE
/* The name of an external symbol which is
used to make weak PE symbol names unique. */
const char * an_external_name;
@@ -2204,7 +2204,7 @@ S_SET_EXTERNAL (symbolS *s)
s->bsym->flags |= BSF_GLOBAL;
s->bsym->flags &= ~(BSF_LOCAL | BSF_WEAK);
-#ifdef USE_UNIQUE
+#ifdef TE_PE
if (! an_external_name && S_GET_NAME(s)[0] != '.')
an_external_name = S_GET_NAME (s);
#endif
diff --git a/gas/tc.h b/gas/tc.h
index 4386fe5..ff1cf36 100644
--- a/gas/tc.h
+++ b/gas/tc.h
@@ -41,7 +41,7 @@ extern int md_short_jump_size;
extern int md_long_jump_size;
#endif
-#ifdef USE_UNIQUE
+#ifdef TE_PE
/* The name of an external symbol which is
used to make weak PE symbol names unique. */
extern const char * an_external_name;