Re: fatal error LNK1104: cannot open file 'QuantLib-vc80-mt-0_9_7.lib'

Posted by Norman Fung-2 on
URL: http://quantlib.414.s1.nabble.com/fatal-error-LNK1104-cannot-open-file-QuantLib-vc80-mt-0-9-7-lib-tp532p535.html

hello

Just managed to compile+run the examples as well!

Thanks guys

Norman

On Fri, Jan 2, 2009 at 9:46 PM, <[hidden email]> wrote:
Hi All,


Quoting Luigi Ballabio <[hidden email]>:

On Fri, 2009-01-02 at 18:49 +0800, Norman Fung wrote:
I created a simple WIN32 console application. I keep getting this
error as soon as I add this line to main.cpp:
#include <ql/quantlib.hpp>
The linker error is:

Error    29    fatal error LNK1104: cannot open file
'QuantLib-vc80-mt-0_9_7.lib'    SimpleWIN32Console

I then checked lib folder, there exists the following two files (but
not the one in linker error message):
(file-a) QuantLib-vc80-mt-s-0_9_7.lib
(file-b) QuantLib-vc80-mt-sgd-0_9_7.lib

You compiled the static-runtime version of QuantLib. In your application
project, instead, the run-time settings tell the linker to look for the
shared-runtime version. You'll have to sync the two; either recompile
QuantLib in Release mode (no static runtime), or change your project
settings (in the properties, they're under Configuration Properties /
C/C++ / Code Generation; choose "Multi-threaded DLL".)

Luigi

P.S. The other issue you have with multiply-defined symbols is probably
due to your using a renamed library, thus pulling in two versions
(static and shared) of the runtime.

More background on these issues is available at the following link:

http://quantlib.org/objecthandler/conventions.html

Regards,
Eric



------------------------------------------------------------------------------

_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users