[Expat-discuss] Trouble using static expat in MS VC 6

Oriol omagrane@anthill.es
Thu Nov 21 20:09:27 2002


    Hi, Karl! Thank you for your quick reply!
    After building expat-1.95.5 I obtained four different subdirectories
with libraries in: Debug, Debug_static, Release and Release_static. So I
added "libexpat.lib" to Project->Settings->Link->Library modules, and the
path to this library in Tools->Options->Directories->Libraries.
    So I think I am linking the static library, not the dll.
    Is it right?
    What else could be that external reference error due?

    Thank you very much again.

    Oriol



----- Original Message -----
From: "Karl Waclawek" <karl@waclawek.net>
To: "Oriol" <omagrane@anthill.es>; <expat-discuss@libexpat.org>
Sent: Thursday, November 21, 2002 7:58 PM
Subject: Re: [Expat-discuss] Trouble using static expat in MS VC 6


> You may have linked to the Dll import library instead of the static
library.
> They have the same names, but should be in different Release directories.
>
> The upcoming version of Expat will have a different naming scheme,
> with the name post-fixed according to the version of the runtime
> library used (multi-threaded or not, etc.). By default it will
> build as libexpatMT.lib.
>
> Karl
>
> ----- Original Message -----
> From: "Oriol" <omagrane@anthill.es>
> To: <expat-discuss@libexpat.org>
> Sent: Thursday, November 21, 2002 1:40 PM
> Subject: [Expat-discuss] Trouble using static expat in MS VC 6
>
>
>
>     Hi,
>     I've installed and successfully built expat 1.95.5 under Visual C 6.
>     However, problems arise when I try to use it.
>     I need to statically link the expat library to my program, but after a
successful compilation,
> the linker stops with this error: MyProgram.obj : "error LNK2001:
unresolved external symbol
> __imp__XML_ParserCreate"
>     The library paths already include the directory where libexpat.lib
lives, so the problem is not
> a missing library.
>     Furthermore I've declared the symbol XML_STATIC in
Resources->Preprocessor, but the problem
> still remains.
>     Any idea?
>
>
>





More information about the Expat-discuss mailing list