ld whitespace fixes
[deliverable/binutils-gdb.git] / ld / emultempl / nds32elf.em
index 8a2be29769ddbcaf81ab87f94c15111d3d0db507..a2416d24cccd4eb5d6e0480a4ebd357be7f379c8 100644 (file)
@@ -1,5 +1,5 @@
 # This shell script emits a C file. -*- C -*-
-# Copyright (C) 2012-2015 Free Software Foundation, Inc.
+# Copyright (C) 2012-2017 Free Software Foundation, Inc.
 # Contributed by Andes Technology Corporation.
 #
 # This file is part of the GNU Binutils.
@@ -22,7 +22,6 @@
 
 fragment <<EOF
 
-#include "libbfd.h"
 #include "elf-bfd.h"
 #include "elf/nds32.h"
 #include "bfd_stdint.h"
@@ -52,8 +51,8 @@ nds32_elf_create_output_section_statements (void)
   if (strstr (bfd_get_target (link_info.output_bfd), "nds32") == NULL)
     {
       /* Check the output target is nds32.  */
-      einfo ("%F%X%P: error: Cannot change output format whilst "
-            "linking NDS32 binaries.\n");
+      einfo (_("%F%X%P: error: Cannot change output format whilst "
+              "linking NDS32 binaries.\n"));
       return;
     }
 
@@ -70,7 +69,7 @@ nds32_elf_create_output_section_statements (void)
 static void
 nds32_elf_after_parse (void)
 {
-  if (link_info.relocatable)
+  if (bfd_link_relocatable (&link_info))
     DISABLE_RELAXATION;
 
   if (!RELAXATION_ENABLED)
@@ -88,13 +87,13 @@ nds32_elf_after_parse (void)
   else
     update_ex9_table = 0;
 
-  if (link_info.shared)
+  if (bfd_link_pic (&link_info))
     {
       target_optimize = target_optimize & (!NDS32_RELAX_JUMP_IFC_ON);
       target_optimize = target_optimize & (!NDS32_RELAX_EX9_ON);
     }
 
-  after_parse_default ();
+  gld${EMULATION_NAME}_after_parse ();
 }
 
 static void
@@ -157,14 +156,14 @@ nds32_elf_after_open (void)
   /* Check object files if the target is dynamic linked executable
      or shared object.  */
   if (elf_hash_table (&link_info)->dynamic_sections_created
-      || link_info.shared || link_info.pie)
+      || bfd_link_pic (&link_info))
     {
       for (abfd = link_info.input_bfds; abfd != NULL; abfd = abfd->link.next)
        {
          if (!(elf_elfheader (abfd)->e_flags & E_NDS32_HAS_PIC))
            {
              /* Non-PIC object file is used.  */
-             if (link_info.shared || link_info.pie)
+             if (bfd_link_pic (&link_info))
                {
                  /* For PIE or shared object, all input must be PIC.  */
                  einfo (_("%B: must use -fpic to compile this file "
@@ -196,7 +195,7 @@ nds32_elf_after_allocation (void)
     {
       /* Initialize ex9 hash table.  */
       if (!nds32_elf_ex9_init ())
-        return;
+       return;
     }
 
   /* Call default after allocation callback.
@@ -294,7 +293,7 @@ PARSE_AND_LIST_OPTIONS='
 '
 PARSE_AND_LIST_ARGS_CASES='
   case OPTION_BASELINE:
-    einfo ("%P: --mbaseline is not used anymore.\n");
+    einfo (_("%P: --mbaseline is not used anymore.\n"));
     break;
   case OPTION_ELIM_GC_RELOCS:
     eliminate_gc_relocs = 1;
@@ -305,7 +304,7 @@ PARSE_AND_LIST_ARGS_CASES='
     break;
   case OPTION_REDUCE_FP_UPDATE:
   case OPTION_NO_REDUCE_FP_UPDATE:
-    einfo ("%P: --relax-[no-]reduce-fp-updat is not used anymore.\n");
+    einfo (_("%P: --relax-[no-]reduce-fp-updat is not used anymore.\n"));
     break;
   case OPTION_EXPORT_SYMBOLS:
     if (!optarg)
This page took 0.026015 seconds and 4 git commands to generate.