This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Absolute file-path under bash (cygwin32)


marcus@bighorn.dr.lucent.com wrote:
> Well, they are marked, but you have to look a little deeply.  If the binary
> imports cygwin.dll, then it's a cygwin binary.  To find this, you have to
> find the .idata section and look through a list of 5 word headers.  The
> 4th word of the header points to the name of the DLL to be imported.

Yeah, but if it can be done in ld then the lookup becomes very quick.
This is the strategy that Windows and OS/2 use for differentating the
different kinds of executables.
 
> This may not be too bad to do, particularly if this becomes a "tracked alias"
> and is tagged as cygwin/!cygwin automatically.  The information for the
> dozen or so programs frequently run would be cached pretty quickly.  

It all seems a little messy and slow. Why do something at runtime if it
can be done once at link time with no runtime performance hit?

> Of
> course, the cygwin executable should not expect anything from bash, because
> it should run on its own from any command interpreter, but this would
> interface to non-cygwin programs much nicer.

I agree! As long as pathnames are clearly differentitaed (e.g.
$/foo/bar) and executables are clearly differentiated then bash can do
the right thing with no guessing.

 Paul Prescod


-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]