Fix problem where mixed section types can cause internal error during a -r link.
[deliverable/binutils-gdb.git] / gold / testsuite / testfile.cc
index da3dc61790e1eb78008664c428e33c7eb7572e6d..da83b3b4f4594e474c3226a5f3acddff5dc98a44 100644 (file)
@@ -1,6 +1,6 @@
 // testfile.cc -- Dummy ELF objects for testing purposes.
 
-// Copyright 2006, 2007, 2008, 2009, 2011, 2012 Free Software Foundation, Inc.
+// Copyright (C) 2006-2017 Free Software Foundation, Inc.
 // Written by Ian Lance Taylor <iant@google.com>.
 
 // This file is part of gold.
@@ -71,11 +71,19 @@ class Target_test : public Sized_target<size, big_endian>
                          const unsigned char*, Relocatable_relocs*)
   { ERROR("call to Target_test::scan_relocatable_relocs"); }
 
+  void
+  emit_relocs_scan(Symbol_table*, Layout*,
+                  Sized_relobj_file<size, big_endian>*, unsigned int,
+                  unsigned int, const unsigned char*,
+                  size_t, Output_section*, bool, size_t,
+                  const unsigned char*, Relocatable_relocs*)
+  { ERROR("call to Target_test::emit_relocs_scan"); }
+
   void
   relocate_relocs(const Relocate_info<size, big_endian>*,
                  unsigned int, const unsigned char*, size_t,
                  Output_section*, typename elfcpp::Elf_types<size>::Elf_Off,
-                  const Relocatable_relocs*, unsigned char*,
+                 unsigned char*,
                  typename elfcpp::Elf_types<size>::Elf_Addr,
                  section_size_type, unsigned char*,
                  section_size_type)
@@ -107,7 +115,10 @@ const Target::Target_info Target_test<size, big_endian>::test_target_info =
   0,                                   // small_common_section_flags
   0,                                   // large_common_section_flags
   NULL,                                        // attributes_section
-  NULL                                 // attributes_vendor
+  NULL,                                        // attributes_vendor
+  "_start",                            // entry_symbol_name
+  32,                                  // hash_entry_size
+  elfcpp::SHT_PROGBITS,                        // unwind_section_type
 };
 
 // The test targets.
This page took 0.02396 seconds and 4 git commands to generate.