This is the mail archive of the
cygwin-patches
mailing list for the Cygwin project.
Re: AttachConsole broken autoload
- From: Christopher Faylor <cgf-use-the-mailinglist-please at cygwin dot com>
- To: cygwin-patches at cygwin dot com
- Date: Sat, 4 Jul 2009 10:17:21 -0400
- Subject: Re: AttachConsole broken autoload
- References: <4A4F4F5B.8090806@gmail.com>
- Reply-to: cygwin-patches at cygwin dot com
On Sat, Jul 04, 2009 at 01:47:23PM +0100, Dave Korn wrote:
>
> Got this error when I tried to run with a DLL built from today's CVS HEAD:
>
>> ---------------------------
>> bash.exe - Entry Point Not Found
>> ---------------------------
>> The procedure entry point AttachConsole could not be located in the dynamic link library KERNEL32.dll.
>> ---------------------------
>> OK
>> ---------------------------
>
> Checked that it doesn't exist on W2K:
>
>http://msdn.microsoft.com/en-us/library/ms681952(VS.85).aspx
>> Minimum supported client Windows XP
>> Minimum supported server Windows Server 2003
>
> Something's gone wrong with the autoload definition, because here's the
>reference:
>
>> $ nm fhandler_console.o | grep AttachConsole
>> U _AttachConsole@4
>
>... but here's the definition:
>
>> $ nm autoload.o | grep AttachConsole
>> 00000000 T _AttachConsole@0
>> 00000000 T _win32_AttachConsole@0
>
>... leading to the DLL still having an explicit import for it:
>
>> $ dumpbin /imports new-cygwin1.dll | grep AttachConsole
>> D AttachConsole
>
> Attached patch looks like the obvious fix to me and builds a DLL without an
>import for AttachConsole; resulting DLL loads and runs on W2k. Ok?
>
> * autoload.cc (AttachConsole): Correct size of args.
Yes, I think that's an obvious fix.
cgf