qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [RFT PATCH] configure: Simplify alternate .text segment


From: Richard Henderson
Subject: Re: [Qemu-devel] [RFT PATCH] configure: Simplify alternate .text segment
Date: Wed, 19 Jun 2013 13:09:37 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6

On 06/19/2013 12:57 PM, Ed Maste wrote:
> Sounds good, although we need to pick up __executable_start too I
> think; from my ld --verbose:
> #  PROVIDE (__executable_start = 0x400000); . = 0x400000 + SIZEOF_HEADERS;
> 
> How about this?
> 
>       $ld --verbose | sed \
>         -e '1,/==================================================/d' \
>         -e '/==================================================/,$d' \
>         -e "s/[.] = .* [+] SIZEOF_HEADERS/. = $textseg_addr + 
> SIZEOF_HEADERS/" \
>         -e "s/__executable_start = [0-9x]*/__executable_start =
> $textseg_addr/" > config-host.ld

Looks good.  Perhaps even use the [0-9a-fx]* pattern for the SIZEOF_HEADERS
line too.

I was initially looking at my ld --verbose and trying to think what to do with
the SEGMENT_START("text-segment", 0x08048000) pattern, but that's clearly dumb,
since that implies that the -Ttext-segment option exists and works.  :-P



r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]