[ros-kernel] NASM hacker needed

Mike Nordell tamlin at algonet.se
Sat Feb 7 11:56:19 CET 2004


Royce Mitchell III wrote:

> I have an .S file I'm trying to get to work.
[snip]
> Here's a snippet of the output I'm getting when trying to link:
>
> tebimports.obj : error LNK2001: unresolved external symbol glCallList at 4
[snip]
> Now, if I change the 2nd macro to this:

[snip]
> I get the following from the linker:
>
> tebimports.obj : error LNK2001: unresolved external symbol _glCallList at 4
[snip]
> So whatever I define the function name to be in my .S file, the linker
> complains it can't find that function name :(

Even that I have about zero experience with nasm, perhaps some of the
following could help?

First I recommend you run "dumpbin /symbols" on the generated object file.
For a comparison of what the symbols should look like, you could try
creating a dummy C file like:

void __stdcall glCallList(int a) {}

The exported symbol should be "_glCallList at 4" with External linkage.

Could it possibly be so simple that you're missing "GLOBAL x" (or "global
x:function", or any other nasm-allowed construction to tag a name as
public), where x is the (fully decorated) function name?

I hope some of it helps.

/Mike



More information about the Ros-kernel mailing list