From: ian AT cygnus DOT com (Ian Lance Taylor) Subject: Import hints 17 Feb 1998 17:59:36 -0800 Message-ID: <199802180132.UAA11771.cygnus.cygwin32.developers@subrogation.cygnus.com> Reply-To: cygwin32-developers AT cygnus DOT com To: cygwin32-developers AT cygnus DOT com Well, it seems to me that this patch to binutils/dlltool.c is appropriate to avoid what appears to be an off by one error in the import hint number. I would really appreciate if people could try this out. You need to rebuild your .a file (e.g., libcygwin.a) with the new dlltool, and then relink your programs, to see if it makes any difference. Ian Index: dlltool.c =================================================================== RCS file: /cvs/cvsfiles/devo/binutils/dlltool.c,v retrieving revision 1.46 diff -u -r1.46 dlltool.c --- dlltool.c 1997/06/12 16:30:55 1.46 +++ dlltool.c 1998/02/18 01:32:22 @@ -1585,7 +1585,10 @@ case IDATA6: if (!exp->noname) { - int idx = exp->hint + 1; + /* This used to add 1 to exp->hint. I don't know + why it did that, and it does not match what I see + in programs compiled with the MS tools. */ + int idx = exp->hint; si->size = strlen (xlate (exp->name)) + 3; si->data = xmalloc (si->size); si->data[0] = idx & 0xff;