public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Andreas Schwab <schwab@suse.de>
To: "David S. Miller" <davem@davemloft.net>
Cc: nickc@redhat.com, binutils@sources.redhat.com
Subject: Re: Problems compiling elfxx-sparc.c
Date: Thu, 21 Apr 2005 12:20:00 -0000	[thread overview]
Message-ID: <jek6mw1fv3.fsf@sykes.suse.de> (raw)
In-Reply-To: <20050420161458.34aca57c.davem@davemloft.net> (David S. Miller's message of "Wed, 20 Apr 2005 16:14:58 -0700")

"David S. Miller" <davem@davemloft.net> writes:

> On Thu, 21 Apr 2005 00:38:21 +0200
> Andreas Schwab <schwab@suse.de> wrote:
>
>> > +      ret->dynamic_interpreter =
>> > +	(const unsigned char *) ELF64_DYNAMIC_INTERPRETER;
>> 
>> Wouldn't it be better to change the type of dynamic_interpreter instead?
>> The only other use of it has to cast it anyway.
>
> Feel free to commit such a change, I have no objections.

Thanks, I've checked in this patch, tested with a cross build with
--enable-targets="sparc-suse-linux sparc64-suse-linux".

Andreas.

2005-04-21  Andreas Schwab  <schwab@suse.de>

	* elfxx-sparc.h (struct _bfd_sparc_elf_link_hash_table): Remove
	unsigned from type of dynamic_interpreter.
	* elfxx-sparc.c (_bfd_sparc_elf_link_hash_table_create): Remove
	casts again.

Index: elfxx-sparc.c
===================================================================
RCS file: /cvs/src/src/bfd/elfxx-sparc.c,v
retrieving revision 1.2
diff -u -a -p -r1.2 elfxx-sparc.c
--- elfxx-sparc.c	20 Apr 2005 18:39:26 -0000	1.2
+++ elfxx-sparc.c	21 Apr 2005 12:16:04 -0000
@@ -778,8 +778,7 @@ _bfd_sparc_elf_link_hash_table_create (b
       ret->align_power_max = 4;
       ret->bytes_per_word = 8;
       ret->bytes_per_rela = sizeof (Elf64_External_Rela);
-      ret->dynamic_interpreter =
-	(const unsigned char *) ELF64_DYNAMIC_INTERPRETER;
+      ret->dynamic_interpreter = ELF64_DYNAMIC_INTERPRETER;
       ret->dynamic_interpreter_size = sizeof ELF64_DYNAMIC_INTERPRETER;
     }
   else
@@ -796,8 +795,7 @@ _bfd_sparc_elf_link_hash_table_create (b
       ret->align_power_max = 3;
       ret->bytes_per_word = 4;
       ret->bytes_per_rela = sizeof (Elf32_External_Rela);
-      ret->dynamic_interpreter =
-	(const unsigned char *) ELF32_DYNAMIC_INTERPRETER;
+      ret->dynamic_interpreter = ELF32_DYNAMIC_INTERPRETER;
       ret->dynamic_interpreter_size = sizeof ELF32_DYNAMIC_INTERPRETER;
     }
 
Index: elfxx-sparc.h
===================================================================
RCS file: /cvs/src/src/bfd/elfxx-sparc.h,v
retrieving revision 1.1
diff -u -a -p -r1.1 elfxx-sparc.h
--- elfxx-sparc.h	19 Apr 2005 21:26:30 -0000	1.1
+++ elfxx-sparc.h	21 Apr 2005 12:16:04 -0000
@@ -66,7 +66,7 @@ struct _bfd_sparc_elf_link_hash_table
   bfd_vma (*r_info) (Elf_Internal_Rela *, bfd_vma, bfd_vma);
   bfd_vma (*r_symndx) (bfd_vma);
   int (*build_plt_entry) (bfd *, asection *, bfd_vma, bfd_vma, bfd_vma *);
-  const unsigned char *dynamic_interpreter;
+  const char *dynamic_interpreter;
   int dynamic_interpreter_size;
   unsigned int word_align_power;
   unsigned int align_power_max;

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

  reply	other threads:[~2005-04-21 12:20 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-04-20 10:19 Nick Clifton
2005-04-20 13:15 ` Andreas Schwab
2005-04-20 18:26   ` David S. Miller
2005-04-20 18:40   ` David S. Miller
2005-04-20 22:38     ` Andreas Schwab
2005-04-20 23:21       ` David S. Miller
2005-04-21 12:20         ` Andreas Schwab [this message]
2005-04-21  3:16     ` Alan Modra
2005-04-21  3:24       ` David S. Miller
2005-04-22  3:19         ` Alan Modra
2005-04-22  3:53           ` David S. Miller
2005-04-21 10:50     ` Nick Clifton
2005-04-21 11:54       ` Eric Botcazou
2005-04-21 13:42         ` Ian Lance Taylor
2005-04-21 18:48           ` David S. Miller
2005-04-22  9:52             ` Nick Clifton
2005-04-22 10:02               ` Nick Clifton
2005-04-22 13:25               ` Ian Lance Taylor
2005-04-22 19:10                 ` David S. Miller
2005-04-25  9:47                   ` Nick Clifton
2005-04-25 18:32                     ` David S. Miller
2005-04-25 19:10                       ` David S. Miller
2005-04-25 21:54                         ` David S. Miller
2005-04-26  8:45                           ` Nick Clifton

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=jek6mw1fv3.fsf@sykes.suse.de \
    --to=schwab@suse.de \
    --cc=binutils@sources.redhat.com \
    --cc=davem@davemloft.net \
    --cc=nickc@redhat.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).