Cannot understand what linker is complaining about









up vote
-2
down vote

favorite












When compiling my project that uses boost logging library, I am getting following linker error.




LNK2001 unresolved external symbol "public: static class
boost::log::v2s_mt_nt6::sources::severity_logger_mt __cdecl
my_logger::construct_logger(void)"
(?construct_logger@my_logger@@SA?AV?$severity_logger_mt@W4severity_level@trivial@v2s_mt_nt6@log@boost@@@sources@v2s_mt_nt6@log@boost@@XZ)




I don't know how to read this error message with mangled function names. Can anyone tell me in human readable way what function it cannot find?










share|improve this question





















  • Possible duplicate of stackoverflow.com/questions/12573816/…
    – forthe
    Nov 10 at 4:24






  • 2




    Possible duplicate of What is an undefined reference/unresolved external symbol error and how do I fix it?
    – forthe
    Nov 10 at 4:24










  • i have read the links provided and it does not help me at all as those answers are very generic. Please help me understand this specific scenario.
    – BKS
    Nov 10 at 4:26











  • In short: have you been linking against the correct boost library (.lib) files?
    – forthe
    Nov 10 at 4:28










  • Your linker is more informative than most. The first line tells you the linker is trying to find a symbol (something with a name, such as a function) needed in order for your program to run, but not finding it. The second line has unmangled information about that missing symbol - it is a function named my_logger::construct_logger(void) (the void means it is called with no arguments) and has a return type of boost::log::v2s_mt_nt6::sources::severity_logger_mt. The __cdecl is compiler/system specific, but describes the calling convention of your function. The rest is the mangled name.
    – Peter
    Nov 10 at 4:36














up vote
-2
down vote

favorite












When compiling my project that uses boost logging library, I am getting following linker error.




LNK2001 unresolved external symbol "public: static class
boost::log::v2s_mt_nt6::sources::severity_logger_mt __cdecl
my_logger::construct_logger(void)"
(?construct_logger@my_logger@@SA?AV?$severity_logger_mt@W4severity_level@trivial@v2s_mt_nt6@log@boost@@@sources@v2s_mt_nt6@log@boost@@XZ)




I don't know how to read this error message with mangled function names. Can anyone tell me in human readable way what function it cannot find?










share|improve this question





















  • Possible duplicate of stackoverflow.com/questions/12573816/…
    – forthe
    Nov 10 at 4:24






  • 2




    Possible duplicate of What is an undefined reference/unresolved external symbol error and how do I fix it?
    – forthe
    Nov 10 at 4:24










  • i have read the links provided and it does not help me at all as those answers are very generic. Please help me understand this specific scenario.
    – BKS
    Nov 10 at 4:26











  • In short: have you been linking against the correct boost library (.lib) files?
    – forthe
    Nov 10 at 4:28










  • Your linker is more informative than most. The first line tells you the linker is trying to find a symbol (something with a name, such as a function) needed in order for your program to run, but not finding it. The second line has unmangled information about that missing symbol - it is a function named my_logger::construct_logger(void) (the void means it is called with no arguments) and has a return type of boost::log::v2s_mt_nt6::sources::severity_logger_mt. The __cdecl is compiler/system specific, but describes the calling convention of your function. The rest is the mangled name.
    – Peter
    Nov 10 at 4:36












up vote
-2
down vote

favorite









up vote
-2
down vote

favorite











When compiling my project that uses boost logging library, I am getting following linker error.




LNK2001 unresolved external symbol "public: static class
boost::log::v2s_mt_nt6::sources::severity_logger_mt __cdecl
my_logger::construct_logger(void)"
(?construct_logger@my_logger@@SA?AV?$severity_logger_mt@W4severity_level@trivial@v2s_mt_nt6@log@boost@@@sources@v2s_mt_nt6@log@boost@@XZ)




I don't know how to read this error message with mangled function names. Can anyone tell me in human readable way what function it cannot find?










share|improve this question













When compiling my project that uses boost logging library, I am getting following linker error.




LNK2001 unresolved external symbol "public: static class
boost::log::v2s_mt_nt6::sources::severity_logger_mt __cdecl
my_logger::construct_logger(void)"
(?construct_logger@my_logger@@SA?AV?$severity_logger_mt@W4severity_level@trivial@v2s_mt_nt6@log@boost@@@sources@v2s_mt_nt6@log@boost@@XZ)




I don't know how to read this error message with mangled function names. Can anyone tell me in human readable way what function it cannot find?







c++ visual-studio boost linker boost-logging






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 10 at 4:20









BKS

605618




605618











  • Possible duplicate of stackoverflow.com/questions/12573816/…
    – forthe
    Nov 10 at 4:24






  • 2




    Possible duplicate of What is an undefined reference/unresolved external symbol error and how do I fix it?
    – forthe
    Nov 10 at 4:24










  • i have read the links provided and it does not help me at all as those answers are very generic. Please help me understand this specific scenario.
    – BKS
    Nov 10 at 4:26











  • In short: have you been linking against the correct boost library (.lib) files?
    – forthe
    Nov 10 at 4:28










  • Your linker is more informative than most. The first line tells you the linker is trying to find a symbol (something with a name, such as a function) needed in order for your program to run, but not finding it. The second line has unmangled information about that missing symbol - it is a function named my_logger::construct_logger(void) (the void means it is called with no arguments) and has a return type of boost::log::v2s_mt_nt6::sources::severity_logger_mt. The __cdecl is compiler/system specific, but describes the calling convention of your function. The rest is the mangled name.
    – Peter
    Nov 10 at 4:36
















  • Possible duplicate of stackoverflow.com/questions/12573816/…
    – forthe
    Nov 10 at 4:24






  • 2




    Possible duplicate of What is an undefined reference/unresolved external symbol error and how do I fix it?
    – forthe
    Nov 10 at 4:24










  • i have read the links provided and it does not help me at all as those answers are very generic. Please help me understand this specific scenario.
    – BKS
    Nov 10 at 4:26











  • In short: have you been linking against the correct boost library (.lib) files?
    – forthe
    Nov 10 at 4:28










  • Your linker is more informative than most. The first line tells you the linker is trying to find a symbol (something with a name, such as a function) needed in order for your program to run, but not finding it. The second line has unmangled information about that missing symbol - it is a function named my_logger::construct_logger(void) (the void means it is called with no arguments) and has a return type of boost::log::v2s_mt_nt6::sources::severity_logger_mt. The __cdecl is compiler/system specific, but describes the calling convention of your function. The rest is the mangled name.
    – Peter
    Nov 10 at 4:36















Possible duplicate of stackoverflow.com/questions/12573816/…
– forthe
Nov 10 at 4:24




Possible duplicate of stackoverflow.com/questions/12573816/…
– forthe
Nov 10 at 4:24




2




2




Possible duplicate of What is an undefined reference/unresolved external symbol error and how do I fix it?
– forthe
Nov 10 at 4:24




Possible duplicate of What is an undefined reference/unresolved external symbol error and how do I fix it?
– forthe
Nov 10 at 4:24












i have read the links provided and it does not help me at all as those answers are very generic. Please help me understand this specific scenario.
– BKS
Nov 10 at 4:26





i have read the links provided and it does not help me at all as those answers are very generic. Please help me understand this specific scenario.
– BKS
Nov 10 at 4:26













In short: have you been linking against the correct boost library (.lib) files?
– forthe
Nov 10 at 4:28




In short: have you been linking against the correct boost library (.lib) files?
– forthe
Nov 10 at 4:28












Your linker is more informative than most. The first line tells you the linker is trying to find a symbol (something with a name, such as a function) needed in order for your program to run, but not finding it. The second line has unmangled information about that missing symbol - it is a function named my_logger::construct_logger(void) (the void means it is called with no arguments) and has a return type of boost::log::v2s_mt_nt6::sources::severity_logger_mt. The __cdecl is compiler/system specific, but describes the calling convention of your function. The rest is the mangled name.
– Peter
Nov 10 at 4:36




Your linker is more informative than most. The first line tells you the linker is trying to find a symbol (something with a name, such as a function) needed in order for your program to run, but not finding it. The second line has unmangled information about that missing symbol - it is a function named my_logger::construct_logger(void) (the void means it is called with no arguments) and has a return type of boost::log::v2s_mt_nt6::sources::severity_logger_mt. The __cdecl is compiler/system specific, but describes the calling convention of your function. The rest is the mangled name.
– Peter
Nov 10 at 4:36












1 Answer
1






active

oldest

votes

















up vote
0
down vote













Googling "boost log unresolved external symbol" leads to https://www.boost.org/doc/libs/1_59_0/libs/log/doc/html/log/rationale/namespace_mangling.html (first, highlighted hit) which describes BOOST_LOG_DYN_LINK.



This incidentally also the most frequent answer on SO: https://stackoverflow.com/search?tab=votes&q=%5bboost-log%5d%20linker



However ABI issues can play a role, see e.g. Unresolved external when using boost log






share|improve this answer




















    Your Answer






    StackExchange.ifUsing("editor", function ()
    StackExchange.using("externalEditor", function ()
    StackExchange.using("snippets", function ()
    StackExchange.snippets.init();
    );
    );
    , "code-snippets");

    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "1"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader:
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    ,
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













    draft saved

    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53235960%2fcannot-understand-what-linker-is-complaining-about%23new-answer', 'question_page');

    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    0
    down vote













    Googling "boost log unresolved external symbol" leads to https://www.boost.org/doc/libs/1_59_0/libs/log/doc/html/log/rationale/namespace_mangling.html (first, highlighted hit) which describes BOOST_LOG_DYN_LINK.



    This incidentally also the most frequent answer on SO: https://stackoverflow.com/search?tab=votes&q=%5bboost-log%5d%20linker



    However ABI issues can play a role, see e.g. Unresolved external when using boost log






    share|improve this answer
























      up vote
      0
      down vote













      Googling "boost log unresolved external symbol" leads to https://www.boost.org/doc/libs/1_59_0/libs/log/doc/html/log/rationale/namespace_mangling.html (first, highlighted hit) which describes BOOST_LOG_DYN_LINK.



      This incidentally also the most frequent answer on SO: https://stackoverflow.com/search?tab=votes&q=%5bboost-log%5d%20linker



      However ABI issues can play a role, see e.g. Unresolved external when using boost log






      share|improve this answer






















        up vote
        0
        down vote










        up vote
        0
        down vote









        Googling "boost log unresolved external symbol" leads to https://www.boost.org/doc/libs/1_59_0/libs/log/doc/html/log/rationale/namespace_mangling.html (first, highlighted hit) which describes BOOST_LOG_DYN_LINK.



        This incidentally also the most frequent answer on SO: https://stackoverflow.com/search?tab=votes&q=%5bboost-log%5d%20linker



        However ABI issues can play a role, see e.g. Unresolved external when using boost log






        share|improve this answer












        Googling "boost log unresolved external symbol" leads to https://www.boost.org/doc/libs/1_59_0/libs/log/doc/html/log/rationale/namespace_mangling.html (first, highlighted hit) which describes BOOST_LOG_DYN_LINK.



        This incidentally also the most frequent answer on SO: https://stackoverflow.com/search?tab=votes&q=%5bboost-log%5d%20linker



        However ABI issues can play a role, see e.g. Unresolved external when using boost log







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Nov 10 at 22:33









        sehe

        273k32330455




        273k32330455



























            draft saved

            draft discarded
















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.





            Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


            Please pay close attention to the following guidance:


            • Please be sure to answer the question. Provide details and share your research!

            But avoid


            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.

            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53235960%2fcannot-understand-what-linker-is-complaining-about%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            How to how show current date and time by default on contact form 7 in WordPress without taking input from user in datetimepicker

            Syphilis

            Darth Vader #20