草庐IT

backtrace_symbols

全部标签

c++ - 无法将 boost 库连接到我的项目 "symbol lookup error"

我有以下情况:我已经创建了动态库lib.so。这个库使用了另一个静态库lib.a。它们都使用Boost库(我将它们链接到CMake文件中)。(我在Java项目中使用了这个动态库)这是lib.so中file.cpp的代码,从lib.a调用getFilesFromDirectory()#include"DrawingDetector.h"#include"../../DrawingDetection.h"#include#includeusingnamespacestd;JNIEXPORTvoidJNICALLJava_DrawingDetector_detectImage(JNIEnv*

c++ - 升级到 OS X Mavericks 后架构 x86_64 的 OpenCV undefined symbol

我有一个运行良好的opencv项目。今天我已经将我的OSXlion升级到Maverick,我收到以下imwrite函数的错误:Undefinedsymbolsforarchitecturex86_64:"cv::imwrite(std::__1::basic_string,std::__1::allocator>const&,cv::_InputArrayconst&,std::__1::vector>const&)",referencedfrom:_maininHello.old:symbol(s)notfoundforarchitecturex86_64我不得不说其他opencv函

c++ - 带有 OO 的模板导致 Unresolved external symbol 问题

我没有.cpp文件,因为我正在使用模板。但是还是遇到了unresolvedexternalsymbol的问题。有人知道原因吗?如果你能帮助我,非常感谢。templateclassSQLiteHelper{public:staticSQLiteHelper*getInstance(T*factory){if(NULL==m_sInstance){m_sInstance=newSQLiteHelper(factory);}returnm_sInstance;}private:SQLiteHelper(T*factory){m_factory=factory;}private:staticS

C++ 重复符号链接(symbolic link)器错误与适当的包含保护?

我正在编写一个程序来测试具体的继承,但我无法解决Clang返回的重复符号链接(symboliclink)器错误。我的理解是重复的符号总是不正确的包含/守卫的结果。我已经三次检查了我的包含/守卫,但我找不到任何错误。重复的符号可能是包含guard以外的其他东西的结果吗?非常感谢,随着我的编程技能的提高,我打算经常在这里做出贡献。.h#ifndefPOINTARRAY_H#definePOINTARRAY_H#include"array.h"namespaceJules{namespaceContainers{classPointArray:publicArray{public:Point

c++ - Boost Spirit Qi Symbols默认值和NULL值

BoostSpiritqi::symbols实现了一个键值对映射:给一个字符串的键,它可以返回某个值。我的问题是:1)对于一个空字符串,是否可以返回一个默认值?(代码中的Q1)2)对于非空字符串或键值对映射中列出的键,是否可以返回一个值表示该键无效?(代码中的Q2)**以下代码基于BOOSTSPIRIT文档。**在此先感谢您的任何建议。#include#include#include#include#include#include#include#include#includetemplatevoidtest_parser_attr(charconst*input,Pconst&p,T

c++ - 将 HDF5 库链接到 Visual C++ DLL 项目 : unresolved external symbol __imp__*

我正在使用MSVisualC++2010Express构建一个插件,我想包含来自HDF5library的功能.我尝试过使用CMake从源代码构建HDF5,并安装预编译库(HDF5-1.8.7_CMake_x86_shared.zip对于VC2008)。对于任一构建目录/方法,我都修改了我的项目属性:C/C++>General>AdditionalIncludeDirectories:为HDF5添加includeLinker>General>AdditionalLibraryDirectories:为HDF5添加lib这是我的DLL模块的片段:#include"cpp/H5Cpp.h"s

c++ - gdb backtrace 没有显示 main() 的完整堆栈跟踪

我正在使用Xalanlibrary.我的程序在Xalan调用中的某处崩溃。我希望看到从main()一直到崩溃点的完整堆栈跟踪。我正在使用以下命令行进行编译g++-oprogram.out-g-O0-lxalan-cmyprogram.out我正在使用“backtracefull”命令并获得以下输出#00xb79313b4inxalanc_1_11::XPath::findRoot(xalanc_1_11::XPathExecutionContext&,xalanc_1_11::XalanNode*,intconst*,int,xalanc_1_11::MutableNodeRefLis

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++ - 从 stdexcept 类继承时为 "Undefined Symbols"

这是在中定义的异常:classlength_error:publiclogic_error{public:explicitlength_error(conststring&__arg);};这是我的异常(exception)情况:#include#includeusingnamespacestd;classrpn_expression_error:publiclogic_error{public:explicitrpn_expression_error(conststring&__arg);};为什么在时会出现此错误?不是吗?Undefinedsymbols:rpn_expressio

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