This is the mail archive of the
mailing list for the binutils project.
Re: Stdcall support in binutils
> > Linux is not Windows. It's a completely different ABI.
> I didn't compare Linux vs. Windows, I did ask about the differences in the
> *compiler* (gcc) behaviour on that platforms.
Right. And I said that the ABIs are different, which is what gcc
follows when creating programs. If the two OSs have different
conventions, then gcc must do different things. GCC is highly
configurable, so it does what the OS conventions want, not the other
> Well, I believe that OS has nothing to do with calling conventions. It's
> a job of compiler. And gcc on Linux *does* support stdcall, it just doesn't
> add name decorations.
Well, then gcc doesn't add name decorations. Again, the fact that it
does that on Linux has nothing to do with the way it works for
> > Comparing
> > Windows to Linux is as useless as comparing Windows to Solaris or any
> > other operating system.
> Sure. I won't start flame wars regarding it.
I didn't mean that, I meant that gcc treats different OSs differently,
even when they're on the same CPU. Solaris for x86 is even more
different from Windows than Linux is, yet it runs on the same chip.
> It works fine, until someone (me) will try to link with a dll such as
> kernel32.dll. Why, you know better than me. Because of that, I'm forced
> to use dlltool and dllwrap.
Well, both cygwin and mingw come with import libraries for all the
dlls the OS provides (as best we can) and they already work correctly
with those dlls. You've asked to be able to *create* a dll with
undecorated names. This must be for something besides OS dlls.
> > That's a bug that needs to be reported and eventually fixed.
> What sort of bug report do you need? Sample code?
Yes please. Whatever it takes to provide a minimal useful
demonstration of the bug - preferably, including .c's, .def's, and a
script that invokes the tools.