This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: Q: Reasoning behind ld -r/-Ur turning off READONLY section flag?
- To: tdel at windriver dot com
- Subject: Re: Q: Reasoning behind ld -r/-Ur turning off READONLY section flag?
- From: Nick Clifton <nickc at cygnus dot com>
- Date: Thu, 8 Jun 2000 10:00:14 -0700
- CC: binutils at sourceware dot cygnus dot com
Hi Tom,
: Can anyone tell me the reason why we are resetting the text section
: READONLY flag to R/W on partial links? Didn't notice anything offhand in
: ChangeLog.
:
: case 'i':
: case 'r':
: link_info.relocateable = true;
: config.build_constructors = false;
: config.magic_demand_paged = false;
: config.text_read_only = false; <<<<<<<< Bzzt!
: config.dynamic_link = false;
: break;
You are right, this does look completely bogus. Checking the logs at
Red Hat I found that this line was checked in in Feb 94 by David
Mackenzie (then employed at Cygnus) but all that the ChangeLog entry
says is:
* lexsup.c: Remove #if 0'd code.
(parse_args): Rewrite to use getopt_long_only.
As far as I can tell there is no good reason for the text section to
become read/write on partial relocation, so I think it should be
removed. Unless someone can suggest a reason not to, I will check a
patch in to fix this next week.
Cheers
Nick