public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* unstriped PE executables contain data from the import library after the end of the last section - is this correct ?
@ 2002-07-08  6:50 Pavel Tsekov
  2002-07-09  1:15 ` Pavel Tsekov
  0 siblings, 1 reply; 4+ messages in thread
From: Pavel Tsekov @ 2002-07-08  6:50 UTC (permalink / raw)
  To: binutils; +Cc: cygwin

Hello,

Some days ago I sent a simialiar message to the binutils list but I
haven't received an answer yet - http://sources.redhat.com/ml/binutils/2002-07/msg00122.html.

I assume this is because I haven't asked smart-enough. Here is a
refined version of the original question, which I hope will qualify
for an answer :)

In short: I noticed that the executables produced with cygwin tools
contain some additional data after the last valid section i.e. having
an executable with the following sections:

  .text
  .data
  .bss
  .idata
  .stab
  .stabstr

there will be some data after the end of the .stabstr section.

Stripping with --strip-debug removes the data from .stab and .stabstr,
but this additional data is still there.

Stripping with --strip-unneeded still leaves some of it the binary.

Stripping with --strip-all removes the last pieces of this data
completly.

Now since my initial post I tried to find what this data is and it
seems that it is the output of the functions make_one() and friends
from ld/pe-dll.c. Now my question is - what is the purpose of having
this data from the import library, appended to the executable itself ?
Is this correct ?

Thanks.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: unstriped PE executables contain data from the import library after the end of the last section - is this correct ?
  2002-07-08  6:50 unstriped PE executables contain data from the import library after the end of the last section - is this correct ? Pavel Tsekov
@ 2002-07-09  1:15 ` Pavel Tsekov
  2002-07-09  8:45   ` Charles Wilson
  0 siblings, 1 reply; 4+ messages in thread
From: Pavel Tsekov @ 2002-07-09  1:15 UTC (permalink / raw)
  To: cygwin

PT> Now since my initial post I tried to find what this data is and it
PT> seems that it is the output of the functions make_one() and friends
PT> from ld/pe-dll.c. Now my question is - what is the purpose of having
PT> this data from the import library, appended to the executable itself ?
PT> Is this correct ?

I was advised to post to the binutils and/or cygwin ml, when I
initially posted on cygwin-apps.  Now, it seems that neither binutils
people, nor anyone on cygwin is interested to answer this question.

Is the answer really that obvious so noone cares to answer ?


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: unstriped PE executables contain data from the import library after the end of the last section - is this correct ?
  2002-07-09  1:15 ` Pavel Tsekov
@ 2002-07-09  8:45   ` Charles Wilson
  2002-07-09  8:51     ` Re[2]: " Pavel Tsekov
  0 siblings, 1 reply; 4+ messages in thread
From: Charles Wilson @ 2002-07-09  8:45 UTC (permalink / raw)
  To: Pavel Tsekov

Pavel Tsekov wrote:

> PT> Now since my initial post I tried to find what this data is and it
> PT> seems that it is the output of the functions make_one() and friends
> PT> from ld/pe-dll.c. Now my question is - what is the purpose of having
> PT> this data from the import library, appended to the executable itself ?
> PT> Is this correct ?
> 
> I was advised to post to the binutils and/or cygwin ml, when I
> initially posted on cygwin-apps.  Now, it seems that neither binutils
> people, nor anyone on cygwin is interested to answer this question.
> 
> Is the answer really that obvious so noone cares to answer ?


It's apparent that no one KNOWS the answer.  I'd have to hunt thru the 
binutils code to answer your question.  But it's your question -- you 
hunt thru the code.

--Chuck



--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re[2]: unstriped PE executables contain data from the import library after the end of the last section - is this correct ?
  2002-07-09  8:45   ` Charles Wilson
@ 2002-07-09  8:51     ` Pavel Tsekov
  0 siblings, 0 replies; 4+ messages in thread
From: Pavel Tsekov @ 2002-07-09  8:51 UTC (permalink / raw)
  To: cygwin

Hello Charles,

Tuesday, July 09, 2002, 5:22:02 PM, you wrote:

CW> Pavel Tsekov wrote:

>> PT> Now since my initial post I tried to find what this data is and it
>> PT> seems that it is the output of the functions make_one() and friends
>> PT> from ld/pe-dll.c. Now my question is - what is the purpose of having
>> PT> this data from the import library, appended to the executable itself ?
>> PT> Is this correct ?
>> 
>> I was advised to post to the binutils and/or cygwin ml, when I
>> initially posted on cygwin-apps.  Now, it seems that neither binutils
>> people, nor anyone on cygwin is interested to answer this question.
>> 
>> Is the answer really that obvious so noone cares to answer ?


CW> It's apparent that no one KNOWS the answer.  I'd have to hunt thru the 
CW> binutils code to answer your question.  But it's your question -- you 
CW> hunt thru the code.

Thanks! :) As for looking at the code  - I would (and I've actually done
so), but some pointers would be appreciated. I'e where is the code
that reads the import library ? I need function names to start with...

I suspect, that this data is some kind of temporary storage,
which is used when import libraries are read and it is dumped
along with the executable when writing it to disk... IMO, this
doesn't seem to be correct - unfortunately noone confirm or denies it
;) Does this sound plausible ? Well I guess I'll have to find out by myself :)


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-07-09 15:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-07-08  6:50 unstriped PE executables contain data from the import library after the end of the last section - is this correct ? Pavel Tsekov
2002-07-09  1:15 ` Pavel Tsekov
2002-07-09  8:45   ` Charles Wilson
2002-07-09  8:51     ` Re[2]: " Pavel Tsekov

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).