linking in .lib files

Chris Dawson cdawson at
Wed Nov 7 20:34:09 CST 2001

Hmm, well, the problem is that winemaker/wine are not doing this for me,

1.  When compiling the project, I get a whole bunch of "undefined reference
to xxx_XXXX function" errors.  These are symbols that the .lib defines, so I
know that this library is not getting linked in properly.

2.  When I try to run the program, I get "undefined symbol: xxx_XXXX"
errors, so I assume that Wine isn't doing it's job either.

I guess the most important thing for me is that I get confirmation that .lib
files can be either statically linked in using gcc, or if there is another
existing mechanism for this.  In MSVC I just add the .lib to the list of
library files and make sure the path is there, and it works, so I don't
understand much more about what I might need to do under Linux, especially
with wine.


-----Original Message-----
From: lawson_whitney at [mailto:lawson_whitney at]
Sent: Wednesday, November 07, 2001 6:07 PM
To: cdawson at; lawson_whitney at
Cc: wine-devel at
Subject: Re: linking in .lib files

On Wed, 7 Nov 2001, Chris Dawson wrote:

> Is it possible to link in .lib files using winelib and winemaker?  If
> possible, what switch do I give winemaker?  My application when compiled
> under Windows linked in a .lib file and I would rather not modify the
> code.  I've tried using the -l switch, but this is obviously only for *nix
> libraries even when compiling with winelib.  Or, other suggestions to
> resolve all the undefined reference errors?
> Thanks in advance,
> Chris
I think you don't need to link the .lib files.  let winemaker generate
the .spec file and it will generate code to do what the .lib files do in
windose.  I think.  I am not much on windose, but I like winemaker.
Your app can just call the functions it wants, and winemaker generates
code to take care of the LoadLibrary and GetProcAddress and stuff that
the .lib does, I think.


More information about the wine-devel mailing list