• <i id='SmltJ'><tr id='SmltJ'><dt id='SmltJ'><q id='SmltJ'><span id='SmltJ'><b id='SmltJ'><form id='SmltJ'><ins id='SmltJ'></ins><ul id='SmltJ'></ul><sub id='SmltJ'></sub></form><legend id='SmltJ'></legend><bdo id='SmltJ'><pre id='SmltJ'><center id='SmltJ'></center></pre></bdo></b><th id='SmltJ'></th></span></q></dt></tr></i><div id='SmltJ'><tfoot id='SmltJ'></tfoot><dl id='SmltJ'><fieldset id='SmltJ'></fieldset></dl></div>
  • <small id='SmltJ'></small><noframes id='SmltJ'>

        <bdo id='SmltJ'></bdo><ul id='SmltJ'></ul>

        <tfoot id='SmltJ'></tfoot>
        <legend id='SmltJ'><style id='SmltJ'><dir id='SmltJ'><q id='SmltJ'></q></dir></style></legend>
      1. Boost-log 链接器错误

        Boost-log linker error(Boost-log 链接器错误)

          <small id='9LxeW'></small><noframes id='9LxeW'>

            <bdo id='9LxeW'></bdo><ul id='9LxeW'></ul>
          • <i id='9LxeW'><tr id='9LxeW'><dt id='9LxeW'><q id='9LxeW'><span id='9LxeW'><b id='9LxeW'><form id='9LxeW'><ins id='9LxeW'></ins><ul id='9LxeW'></ul><sub id='9LxeW'></sub></form><legend id='9LxeW'></legend><bdo id='9LxeW'><pre id='9LxeW'><center id='9LxeW'></center></pre></bdo></b><th id='9LxeW'></th></span></q></dt></tr></i><div id='9LxeW'><tfoot id='9LxeW'></tfoot><dl id='9LxeW'><fieldset id='9LxeW'></fieldset></dl></div>
                  <tbody id='9LxeW'></tbody>
              1. <legend id='9LxeW'><style id='9LxeW'><dir id='9LxeW'><q id='9LxeW'></q></dir></style></legend>
                <tfoot id='9LxeW'></tfoot>

                1. 本文介绍了Boost-log 链接器错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我已经从源代码下载并构建了 Boost 1.55.我正在尝试使用 Boost-log.在基本情况下 (http://boost-log.sourceforge.net/libs/log/doc/html)/log/tutorial.html#log.tutorial.trivial 它工作正常没有任何问题,但是当我尝试使用一些更高级的功能(像这样 - http://boost-log.sourceforge.net/libs/log/example/doc/tutorial_fmt_stream.cpp )我收到此错误:

                  i've downloaded and builded Boost 1.55 from source. I'm trying to use Boost-log. In basic case (http://boost-log.sourceforge.net/libs/log/doc/html)/log/tutorial.html#log.tutorial.trivial it's working fine without any problems, but when i try to use some more advanced features(like this - http://boost-log.sourceforge.net/libs/log/example/doc/tutorial_fmt_stream.cpp ) i'm getting this error:

                  main.obj:错误 LNK2019:未解析的外部符号void __cdeclboost::filesystem::path_traits::convert(char const *,char const*,类 std::basic_string,类 std::allocator>&,class std::codecvt const &)" (?convert@path_traitsboost@@YAXPBD0AAV?$basic_string@GU?$char_traits@G@V?$allocator@G@ABV?$codecvt@GDH@Z)在函数void __cdecl"中引用boost::filesystem::path_traits::dispatch,class std::allocator > >(classstd::basic_string, 类std::allocator > const &,class std::basic_string,classstd::allocator > &,class std::codecvt const &)"(??$dispatch@V?$basic_string@GU?$char_traits@G@V?$allocator@G@@path_traitsboost@@YAXABV?$basic_string@DU?$char_traits@D@V?$allocator@D@AAV?$basic_string@GU?$char_traits@G@V?$allocator@GABV?$codecvt@GDH@Z)

                  main.obj : error LNK2019: unresolved external symbol "void __cdecl boost::filesystem::path_traits::convert(char const *,char const *,class std::basic_string,class std::allocator> &,class std::codecvt const &)" (?convert@path_traitsboost@@YAXPBD0AAV?$basic_string@GU?$char_traits@G@V?$allocator@G@ABV?$codecvt@GDH@Z) referenced in function "void __cdecl boost::filesystem::path_traits::dispatch,class std::allocator > >(class std::basic_string,class std::allocator > const &,class std::basic_string,class std::allocator > &,class std::codecvt const &)" (??$dispatch@V?$basic_string@GU?$char_traits@G@V?$allocator@G@@path_traitsboost@@YAXABV?$basic_string@DU?$char_traits@D@V?$allocator@D@AAV?$basic_string@GU?$char_traits@G@V?$allocator@GABV?$codecvt@GDH@Z)

                  1>main.obj:错误 LNK2019:未解析的外部符号void __cdeclboost::log::v2s_mt_nt5::aux::code_convert(unsigned short const*,unsigned int,class std::basic_string,class std::allocator > &,classstd::locale const &)"(?code_convertv2s_mt_nt5boost@@YAXPBGIAAV?$basic_string@DU?$char_traits@D@V?$allocator@D@ABVlocale@Z)在函数private: void __thiscall"中引用boost::log::v2s_mt_nt5::basic_formatting_ostream,class std::allocator>::aligned_write(unsigned short const *,__int64)" (??$aligned_write@G@?$basic_formatting_ostream@DU?$char_traits@D@V?$allocator@D@v2s_mt_nt5boost@@AAEXPBG_J@Z)

                  1>main.obj : error LNK2019: unresolved external symbol "void __cdecl boost::log::v2s_mt_nt5::aux::code_convert(unsigned short const *,unsigned int,class std::basic_string,class std::allocator > &,class std::locale const &)" (?code_convertv2s_mt_nt5boost@@YAXPBGIAAV?$basic_string@DU?$char_traits@D@V?$allocator@D@ABVlocale@Z) referenced in function "private: void __thiscall boost::log::v2s_mt_nt5::basic_formatting_ostream,class std::allocator> ::aligned_write(unsigned short const *,__int64)" (??$aligned_write@G@?$basic_formatting_ostream@DU?$char_traits@D@V?$allocator@D@v2s_mt_nt5boost@@AAEXPBG_J@Z)

                  1>main.obj : error LNK2019: 未解析的外部符号 "public: static类 std::codecvt const &__cdeclboost::filesystem::path::codecvt(void)"(?codecvtfilesystem@SAABV?$codecvt@GDH@XZ)在函数public: __thiscall"中引用boost::filesystem::path::path(char const (&)[14],void*)" (??$?0$$BY0O@$$CBDfilesystem@QAE@AAY0O@$$CBDPAX@Z)

                  1>main.obj : error LNK2019: unresolved external symbol "public: static class std::codecvt const & __cdecl boost::filesystem::path::codecvt(void)" (?codecvtfilesystem@SAABV?$codecvt@GDH@XZ) referenced in function "public: __thiscall boost::filesystem::path::path(char const (&)[14],void *)" (??$?0$$BY0O@$$CBDfilesystem@QAE@AAY0O@$$CBDPAX@Z)

                  所以基本上它无法在 .lib 文件中找到函数 convert(...)、code_convert(...) 和 codecvt(...).

                  So basically it can't find functions convert(...), code_convert(...) and codecvt(...) in .lib files.

                  我已经尝试将所有发布库(在构建 boost 时制作的 .lib 文件)添加到附加库"中,通常我认为 Visual Studio 可以找到所有库,但在库中找不到这些函数.有什么想法可以解决这个问题吗?

                  I've already tried to add all release libraries (.lib files made while building boost) to "additional libraries" and generally i think that visual studio find all libraries, but can't find those functions in libraries. Any ideas how can i fix this?

                  我已经使用 Visual Studio 2010 (msvc10.0)、32 位、发布和调试从源代码构建了 Boost 1.55.我正在使用 Windows 7 x64.

                  I've build Boost 1.55 from source using visual studio 2010 (msvc10.0), 32 bit, release and debug. I'm working on windows 7 x64.

                  推荐答案

                  我遇到了同样的问题,我可以通过更改 VisualStudio 2010 上的项目属性之一来解决它.

                  I had the same problem and I could fix it by changing one of the Project properties on VisualStudio 2010.

                  前往:

                  属性页 -> 配置属性 -> C/C++ -> 语言 -> 将 WChar_t 视为内置类型:

                  并将属性设置为:

                  是 (/Zc:wchar_t)

                  希望对你有帮助:)

                  保重,

                  这篇关于Boost-log 链接器错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  How to limit the number of running instances in C++(C++中如何限制运行实例的数量)
                  Using boost::asio::async_read with stdin?(将 boost::asio::async_read 与 stdin 一起使用?)
                  How to find out what dependencies (i.e other Boost libraries) a particular Boost library requires?(如何找出特定 Boost 库需要哪些依赖项(即其他 Boost 库)?)
                  What#39;s the purpose of a leading quot;::quot; in a C++ method call(引导“::的目的是什么?在 C++ 方法调用中)
                  Boost Spirit x3: parse into structs(Boost Spirit x3:解析为结构体)
                  How boost auto-linking makes choice?(boost自动链接如何做出选择?)

                      <tbody id='R5WKQ'></tbody>
                    • <legend id='R5WKQ'><style id='R5WKQ'><dir id='R5WKQ'><q id='R5WKQ'></q></dir></style></legend>
                          <bdo id='R5WKQ'></bdo><ul id='R5WKQ'></ul>

                            <small id='R5WKQ'></small><noframes id='R5WKQ'>

                            <i id='R5WKQ'><tr id='R5WKQ'><dt id='R5WKQ'><q id='R5WKQ'><span id='R5WKQ'><b id='R5WKQ'><form id='R5WKQ'><ins id='R5WKQ'></ins><ul id='R5WKQ'></ul><sub id='R5WKQ'></sub></form><legend id='R5WKQ'></legend><bdo id='R5WKQ'><pre id='R5WKQ'><center id='R5WKQ'></center></pre></bdo></b><th id='R5WKQ'></th></span></q></dt></tr></i><div id='R5WKQ'><tfoot id='R5WKQ'></tfoot><dl id='R5WKQ'><fieldset id='R5WKQ'></fieldset></dl></div>
                          1. <tfoot id='R5WKQ'></tfoot>