gas/
[deliverable/binutils-gdb.git] / gold / archive.h
index 9107d1e612fe519f52de0c8b4691043548e7d0f7..c5ba114ed5c446ebb79e719fa0e640eeaecd7abe 100644 (file)
@@ -1,6 +1,6 @@
 // archive.h -- archive support for gold      -*- C++ -*-
 
-// Copyright 2006, 2007, 2008, 2010 Free Software Foundation, Inc.
+// Copyright 2006, 2007, 2008, 2010, 2011 Free Software Foundation, Inc.
 // Written by Ian Lance Taylor <iant@google.com>.
 
 // This file is part of gold.
@@ -152,6 +152,10 @@ class Archive
   bool
   add_symbols(Symbol_table*, Layout*, Input_objects*, Mapfile*);
 
+  // Return whether the archive defines the symbol.
+  bool
+  defines_symbol(Symbol*) const;
+
   // Dump statistical information to stderr.
   static void
   print_stats();
@@ -381,7 +385,7 @@ class Archive
   // The directory search path.
   Dirsearch* dirpath_;
   // The task reading this archive.
-  Task *task_;
+  Tasktask_;
   // Number of members in this archive;
   unsigned int num_members_;
   // True if we exclude this library archive from automatic export.
@@ -445,7 +449,7 @@ class Add_archive_symbols : public Task
   Task_token* next_blocker_;
 };
 
-// This class represents the files surrunded by a --start-lib ... --end-lib.
+// This class represents the files surrounded by a --start-lib ... --end-lib.
 
 class Lib_group
 {
@@ -481,7 +485,7 @@ class Lib_group
   // For reading the files.
   const Input_file_lib* lib_;
   // The task reading this lib group.
-  Task *task_;
+  Tasktask_;
   // Table of the objects in the group.
   std::vector<Archive_member> members_;
 };
@@ -495,7 +499,8 @@ class Add_lib_group_symbols : public Task
                         Input_objects* input_objects,
                         Lib_group* lib, Task_token* next_blocker)
       : symtab_(symtab), layout_(layout), input_objects_(input_objects),
-        lib_(lib), this_blocker_(NULL), next_blocker_(next_blocker)
+        lib_(lib), readsyms_blocker_(NULL), this_blocker_(NULL),
+        next_blocker_(next_blocker)
   { }
 
   ~Add_lib_group_symbols();
@@ -513,9 +518,10 @@ class Add_lib_group_symbols : public Task
 
   // Set the blocker to use for this task.
   void
-  set_blocker(Task_token* this_blocker)
+  set_blocker(Task_token* readsyms_blocker, Task_token* this_blocker)
   {
-    gold_assert(this->this_blocker_ == NULL);
+    gold_assert(this->readsyms_blocker_ == NULL && this->this_blocker_ == NULL);
+    this->readsyms_blocker_ = readsyms_blocker;
     this->this_blocker_ = this_blocker;
   }
 
@@ -529,7 +535,8 @@ class Add_lib_group_symbols : public Task
   Symbol_table* symtab_;
   Layout* layout_;
   Input_objects* input_objects_;
-  Lib_group * lib_;
+  Lib_group* lib_;
+  Task_token* readsyms_blocker_;
   Task_token* this_blocker_;
   Task_token* next_blocker_;
 };
This page took 0.024291 seconds and 4 git commands to generate.