I just tried them (I have VC7.1 also), and it worked fine.
Are you selecting the "Static Debug" Configuration when you build?
----- Original Message -----
Sent: Wednesday, May 19, 2004 5:36 PM
Subject: Linking static libs under VC7.1 does not work

I just tried to link the trivial example project with the static build library log4cxxs.lib but get a link error.

I am using log4cxx version 0.9.7.

Any ideas? I want to use the static library in my real application.

------ Build started: Project: trivial, Configuration: Debug Win32 ------

Linking...

LINK : warning LNK4075: ignoring '/EDITANDCONTINUE' due to '/INCREMENTAL:NO' specification

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall log4cxx::Logger::fatal(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,char const *,int)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@[EMAIL PROTECTED]@2@@std@@[EMAIL PROTECTED]) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall log4cxx::Logger::error(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,char const *,int)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@[EMAIL PROTECTED]@2@@std@@[EMAIL PROTECTED]) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall log4cxx::Logger::warn(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,char const *,int)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@[EMAIL PROTECTED]@2@@std@@[EMAIL PROTECTED]) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall log4cxx::Logger::info(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,char const *,int)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@[EMAIL PROTECTED]@2@@std@@[EMAIL PROTECTED]) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: void __thiscall log4cxx::Logger::debug(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &,char const *,int)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@[EMAIL PROTECTED]@2@@std@@[EMAIL PROTECTED]) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static void __cdecl log4cxx::NDC::push(class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > const &)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@[EMAIL PROTECTED]@@[EMAIL PROTECTED]@2@@std@@@Z) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static class log4cxx::helpers::ObjectPtrT<class log4cxx::Logger> __cdecl log4cxx::Logger::getRootLogger(void)" ([EMAIL PROTECTED]@log4cxx@@[EMAIL PROTECTED]@log4cxx@@@[EMAIL PROTECTED]@XZ) referenced in function _main

trivial.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) public: static void __cdecl log4cxx::BasicConfigurator::configure(void)" ([EMAIL PROTECTED]@log4cxx@@SAXXZ) referenced in function _main

../Bin/Debug/trivial.exe : fatal error LNK1120: 8 unresolved externals

Build log was saved at "file://c:\sletmig\log4cxx0.9.7\log4cxx-0.9.7\msvc\examples\Debug\BuildLog.htm"

trivial - 9 error(s), 1 warning(s)


Do you Yahoo!?
SBC Yahoo! - Internet access at a great low price.

Reply via email to