- /* If this section does not have .text-type section flags or there's no
- MMO_TEXT_SECTION_NAME, we don't have anything to say. */
- if ((bfd_get_section_flags (s->owner, s) & (SEC_CODE | SEC_READONLY)) == 0)
- return false;
-
- if (hold_text.os == NULL)
- hold_text.os = lang_output_section_find (MMO_TEXT_SECTION_NAME);
-
- place = &hold_text;
-
- /* If there's an output section by this name, we'll use it, regardless
- of section flags, in contrast to what's done in elf32.em. */
-
- /* Start building a list of statements for this section.
- First save the current statement pointer. */
- old = stat_ptr;
-
- /* Add the output section statements for this orphan to our own private
- list, inserting them later into the global statement list. */
- stat_ptr = &add;
- lang_list_init (stat_ptr);
-
- os = lang_enter_output_section_statement (bfd_get_section_name (s->owner,
- s),
- NULL, 0,
- (bfd_vma) 0,
- (etree_type *) NULL,
- (etree_type *) NULL,
- (etree_type *) NULL);
-
- lang_add_section (&os->children, s, os, file);
-
- lang_leave_output_section_statement
- ((bfd_vma) 0, "*default*",
- (struct lang_output_section_phdr_list *) NULL, NULL);
-
- /* Restore the global list pointer. */
- stat_ptr = old;
-
- snew = os->bfd_section;
- if (snew == NULL)
- /* /DISCARD/ section. */
- return true;
-
- /* We need an output section for .text as a root, so if there was none
- (might happen with a peculiar linker script such as in "map
- addresses", map-address.exp), we grab the output section created
- above. */
- if (hold_text.os == NULL)