public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Nick Clifton <nickc@redhat.com>
To: paul@codesourcery.com
Cc: binutils@sources.redhat.com
Subject: Re: [patch] SymbianOS Arm executables
Date: Fri, 11 Feb 2005 15:15:00 -0000	[thread overview]
Message-ID: <m3d5v7o2h6.fsf@redhat.com> (raw)

Hi Paul,

> 2005-02-10  Paul Brook  <paul@codesourcery.com>
> 
>  * elf-bfd.h (struct elf_link_hash_table): Add exec_reloc_p.
>  * elf.c (_bfd_elf_link_hash_table_init): Initialize it.
>  * elflink.c (bfd_elf_link_record_dynamic_symbol): Create local dynamic
>  symbols in relocatable executables.
>  (bfd_elf_record_link_assignment): Create dynamic section symbols in
>  relocatable executables.
>  (_bfd_elf_link_renumber_dynsyms): Ditto.
>  (bfd_elf_final_link): Ditto.
>  * elf32-arm.c (elf32_arm_final_link_relocate): Copy absolute
>  relocations into relocatable executables.
>  (elf32_arm_check_relocs): Crate dynamic sections for relocatale

                                                         ^^^^^^^^^
                                                         relocatable ?

>  executables.  Also copy absolute relocations.
>  (elf32_arm_adjust_dynamic_symbol): Don't create copy relocations
>  in relocatable executables.
>  (allocate_dynrelocs): Copy relocations for relocatable executables.
>  Output dynamic symbols for symbols defined in linker scripts.

Approved - please apply.  But...

------------------------------------------------------------------------
+  /* True if This target has relocatable executables, so needs dynamic
+     section symbols.  */
+  bfd_boolean exec_reloc_p;

There is no need for a capital T on the word "This".

Also - this is a just personal thing, not a requirement - I really
hate the use of ..._p to indicate a boolean value.  We are coding in C
here not lisp and I think that we should try to drop hold overs from
that language.  Thus I would have called this variable:
"is_relocatable_executable" or
"executable_needs_dynamic_section_syms".

------------------------------------------------------------------------
       /* When generating a shared object, these relocations are copied
 	 into the output file to be resolved at run time.  */
-      if (info->shared
+      if ((info->shared || globals->root.exec_reloc_p)

Since you are updating the if() statement, you should update the
comment describing it.


Cheers
  Nick

             reply	other threads:[~2005-02-11  9:34 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-11 15:15 Nick Clifton [this message]
  -- strict thread matches above, loose matches on Subject: below --
2005-02-09 23:38 Paul Brook
2005-02-10 15:58 ` Richard Earnshaw
2005-02-10 17:29   ` Paul Brook
2005-02-10 19:54     ` Richard Earnshaw

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3d5v7o2h6.fsf@redhat.com \
    --to=nickc@redhat.com \
    --cc=binutils@sources.redhat.com \
    --cc=paul@codesourcery.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).