5

I have a VS 2005 solution that has numerous projects (most are DLL, 1 EXE which is a CppUnit project) and I am trying to add a fixed back-end DLL for the Pantheios logger so that I can use a single logger instance throughout the solution. Following the directions from the below URLs:

I seem to have a fixed back-end DLL that supports basic Pantheios logging statements e.g. log_DEBUG, log_ERROR etc. and even the Tracing API (http://www.pantheios.org/doc/html/group__group____tracing.html) e.g. PANTHEIOS_TRACE_NOTICE.

But I am stuck going forward because Pantheios requires "inserters" (an API to convert fundamental types to string) (http://www.pantheios.org/doc/html/group__group____application__layer__interface____inserters.html) to handle for example int, double, float, pointer etc.

I don't know how implement these "inserters" in the fixed back-end DLL that I created. If I simply call them from my other DLLs then I get an error such as this:

DLLApp.obj : error LNK2019: unresolved external symbol "public: __thiscall pantheios::integer::integer(int,int)" (??0integer@pantheios@@QAE@HH@Z) referenced in function "public: void __thiscall DLLApp::DLLAppSetup(void)" (?DLLAppSetup@DLLApp@@QAEXXZ)

I am not sure if I can (and need to) export the "integer" (and other inserter) class using the .DEF as mentioned in the sourceforge.net article OR if there is something else I am missing.

Any help would be most appreciated. Thanks in advance.

Community
  • 1
  • 1
ossandcad
  • 778
  • 5
  • 18
  • Is this question difficult to answer? Or not a commonly encountered scenario? Or perhaps not properly asked? Comments/suggestions most welcome. Thanks in advance. – ossandcad Nov 12 '09 at 23:15
  • Maybe it's too off the beaten track. Have you tried asking the Pantheios project? – dcw Mar 01 '10 at 22:18
  • I have asked the Pantheios project at http://sourceforge.net/projects/pantheios/forums/forum/647484/topic/1639420 before I posted here. Matt (the author) is usually very good at posting replies but has not answered any of mine (yet). I am guess it is too off the beaten track - though I would have assumed that using a single logger across multiple DLLs would have been common. – ossandcad Mar 29 '10 at 22:43
  • Have you had a reply from the project yet? I have some ideas on your question if not – dcw Nov 25 '10 at 19:24
  • @dcw Nope no reply/solution yet. Any suggestions you have would be most appreciated. For now I am simply using boost::lexical_cast and providing operator<< where required/possible. Now if I could only figure out how to contact you directly so that you don't have to watch this space. – ossandcad Dec 03 '10 at 18:46

1 Answers1

1

In project properties page, change character set as "Use Multi-Byte Character Set"

Seçkin Durgay
  • 2,758
  • 4
  • 27
  • 36
  • Could you perhaps expand your answer? I am not sure how changing the character set allows to meet 'integer' dependency. Also newer versions of Pantheios do support the wide character set (in VS case, Unicode or wchar_t). – ossandcad Mar 16 '12 at 15:56
  • Right click to project, properties > configuration properties > general > Character Set > Use Multi-Byte Character Set – Seçkin Durgay Mar 20 '12 at 08:12
  • I should apologize. I didn't mean to ask 'how to change character set?'. I meant to ask 'how does it help?', since the class doesn't mention missing character-type. – ossandcad Apr 06 '12 at 18:18