草庐IT

SYMBOL_INFO

全部标签

c++ - SFML 2.1 架构 x86_64 错误的 undefined symbol

我最近安装了SFML2.1并尝试从终端编译和运行,而不是Xcode,他们网站上的示例程序http://www.sfml-dev.org/tutorials/2.0/start-linux.php.PathtowhereIinstalledSFML:/Users/.../Desktop/C++_Code/SMFL/SFML-2.1-osx-gcc-universal但是,我不断收到以下错误:Undefinedsymbolsforarchitecturex86_64:"sf::String::String(charconst*,std::__1::localeconst&)",refere

c++ - swig : undefined symbol: _ZN7hosters11hostersLink7getLinkEi 错误

我正在尝试为这个库创建一个python绑定(bind):http://code.google.com/p/hosterslib/.我正在使用swig,这是代码:%modulepyhosters%{#include"hosters/hosters.hpp"%}%include"hosters/hosters.hpp"我跑swig-c++-python-oswig_wrap.cxxswig.i我用编译g++-O2-fPIC-shared-o_pyhosters.soswig_wrap.cxxpython-config--libs--cflags-lhosters-lcln-lhtmlcxx

c++ - 警告 : 'visibility' attribute ignored - symbol visibility - C++/gcc

相关主题:Whydoesconstimplyinternallinkageinc++,whenitdoesn'tinC?我正在关注GCCvisibilitywiki为我的共享库添加可见性。当我编译我的源文件时它会生成一个警告warning:'visibility'attributeignored[-Wattributes]这是我的代码://my_shared_lib.h#if__GNUC__>=4#defineDLL_API__attribute__((visibility("default")))#defineDLL_LOCAL__attribute__((visibility("h

c++ - 架构 x86_64 的 undefined symbol : OS X, Boost Log,CMake

链接的另一个问题OSX10.9.5x64跨平台项目正在使用CMake工具链构建。使用boost。将所有可执行文件与BoostLog链接时出错(肯定找到了BOOST_PATH,单元测试与Boost测试链接成功)首先尝试。使用Clanggcc-vAppleLLVMversion6.0(clang-600.0.56)(basedonLLVM3.5svn)Target:x86_64-apple-darwin13.4.0Threadmodel:posix建筑boost./bootstrap&&./b2threading=multilink=staticruntime-link=staticins

java - 使用 undefined symbol 加载 JNI 时崩溃

我正在尝试将我的native库链接到Java应用程序,但是当我尝试运行它时,我得到一个java.lang.UnsatisfiedLinkError异常,提示缺少符号(_ZTVN10__cxxabiv117__class_type_infoE)我像使用任何其他共享库一样使用g++编译共享库。这是我第一次尝试使用JNI,我不知道如何正确链接所有内容。 最佳答案 您可以使用工具链附带的c++filt可执行文件来分解丢失的符号。然后就是弄清楚代码的哪一部分没有做它应该做的事情。nm可用于列出代码中定义的符号。如果您看到某个符号在同一行上有一

c++ - type_info 不考虑 cv 限定符 : is this right?

这段代码打印1是正确的行为还是g++4.5的怪癖?#include#includeusingnamespacestd;intmain(){structA{};cout我认为cv限定符的不同类型作为非常不同的类型受到威胁,即使较少的cv限定类型可以隐式转换为更多cv限定的类型。 最佳答案 typeid根据C++标准(摘自ISO/IEC14882:2003的§5.2.8)忽略cv限定符:Thetop-levelcv-qualifiersofthelvalueexpressionorthetype-idthatistheoperandof

c++ - 尝试构建共享库 g++/mac 时 undefined symbol _main

我正在尝试在Mac上构建libdecodeqr。我的C++构建和链接历史都在Windows上,所以这是一个令人兴奋的发现之旅。我终于到了要创建链接库的地步。我正在运行的命令是:g++-shared-olibdecodeqr.so.0.9.3bitstream.ocodedata.ocontainer.oecidecoder.oformatinfo.ogalois.oimagereader.olibdecodeqr.o-L/opt/local/lib-archi386-lcxcore-lcv结果是:Undefinedsymbols:"_main",referencedfrom:start

c++ - ld : duplicate symbol

我有rand.cpp和rand.hpp文件,并且有rand_unif()函数。我在sim_engine.hpp文件中包含了rand.hpp文件。在main.cpp文件中,我包含了sim_engine.hpp文件。如果我运行makefile然后我得到这个错误ld:duplicatesymbolrand_unif()insim_engine.oandmain.oforarchitecturex86_64collect2:ldreturned1exitstatussim_engine.hpp是唯一包含rand.hpp的地方。main.cpp不包含rand.hpp但包含sim_engine.h

c++ - 错误 LNK2019 : unresolved external symbol "" referenced in function

我目前在编译代码时遇到以下错误:errorLNK2019:unresolvedexternalsymbol"public:void__thiscallAgent::printSelf(void)"(?printSelf@Agent@@QAEXXZ)referencedinfunction"public:void__thiscallWorld::processMouse(int,int,int,int)"(?processMouse@World@@QAEXHHHH@Z)World.obj这是我的代码代理.h:classAgent{public:Agent();voidprintSelf(

c++ - 错误 LNK2019 : unresolved external symbol

好的,所以我在尝试找出代码中的问题时遇到了问题。我有很多代码,所以我只会发布编译时出现问题的相关部分。我在一个类中有以下函数,它会编译并且一切都会正常运行,直到我调用函数“CalculateProbabilityResults”并在其中运行第7行代码。我已经在我的程序中“取消注释”了这行代码,这样您就可以更容易地找到它。我很确定我有正确的#include指令,因为它在不调用函数时编译得很好,所以这不是问题,不是吗?我知道我的一些命名符号需要一点帮助,所以请多多包涵。在此先感谢您的帮助。intSQLServer::CalculateProbabilityResults(intprofil