undefined reference to `dlopen'
g++ -O0 -g3 -I. -Ithird/json -Ithird/core/include -Ithird/vite/include -Ithird/openfst-1.2.10/src/include -o a.out test/test.c test/build/testbuild.o test/train/test_lm2.o test/tool/load_two/load_two.o test/tool/multi_thread/test-multi.o test/tool/mem_check/mem_check.o test/tool/test_ncc/test_nc.o lib/lm.a -lpthread -ldl -lrt -lm -L/usr/local/lib third/vite/lib/vite_g.a third/core/lib/core_g.a -liconv
third/core/lib/core_g.a(sqlite3.o): In function `unixDlOpen':
/home/jfyuan/svn/aispeech/speechplatform/branches/wtk-jfy/third/sqlite/sqlite3.c:29024: undefined reference to `dlopen'
third/core/lib/core_g.a(sqlite3.o): In function `unixDlError':
/home/jfyuan/svn/aispeech/speechplatform/branches/wtk-jfy/third/sqlite/sqlite3.c:29038: undefined reference to `dlerror'
third/core/lib/core_g.a(sqlite3.o): In function `unixDlSym':
/home/jfyuan/svn/aispeech/speechplatform/branches/wtk-jfy/third/sqlite/sqlite3.c:29064: undefined reference to `dlsym'
third/core/lib/core_g.a(sqlite3.o): In function `unixDlClose':
/home/jfyuan/svn/aispeech/speechplatform/branches/wtk-jfy/third/sqlite/sqlite3.c:29069: undefined reference to `dlclose'
collect2: error: ld returned 1 exit status
原因:-ldl 在core_g.a之前导致的
解决办法:调换一下顺序即可。
undefined reference to `dlopen'的更多相关文章
- 源码安装git工具,显示/usr/local/lib64/libcrypto.a(dso_dlfcn.o) undefined reference to `dlopen'
/usr/local/lib64/libcrypto.a(dso_dlfcn.o): In function `dlfcn_globallookup':dso_dlfcn.c:(.text+0x30) ...
- undefined reference to 'dlopen';undefined reference to 'dlclose';undefined reference to 'dlerror'等问题
在linux下,编译链接的时候,经常会遇到这样一个问题,undefined reference to.....,引起这个问题的原因在于在链接的时候缺少选项.下面举几个例子,并给出解决办法. 1. u ...
- Linux+CLion+树莓派远程编译时,Cmake编译出现undefined reference to 'dlopen'的解决办法
在Clion中链接讯飞的语音库并传至树莓派上编译时,出现如下错误. undefined reference to `dlopen' undefined reference to `dlclose' u ...
- cmake : undefined reference to dlopen, dlclose, dlsym and dlerror
链接出了问题 添加头文件 #include <dlfcn.h> 添加库 target_link_libraries(PROJECT_NAME ${CMAKE_DL_LIBS})
- 解决引用openssl静态库libcrypto.a和libssl.a出现undefined reference to错误的问题
最近在做使用openssl链接http和https的项目,编译时出现以下问题. /usr/local/openssl/lib/libcrypto.a(async.o): In function `as ...
- libQt5Core.so: undefined reference to `dlclose@GLIBC_2.4'
/******************************************************************************** * libQt5Core.so: u ...
- Linux下编译程序时,经常会遇到“undefined reference to XXX” 报错,
Linux下编译程序时,经常会遇到“undefined reference to XXX” 报错, 这里总结一些可能的原因和解决方案,给需要的朋友: 说道undefined reference err ...
- 安装sphinx报错(undefined reference to `libiconv_open' 、undefined reference to `libiconv'、undefined reference to `libiconv_close'、make[1]: *** No rule to make target `all'. Stop. 、make: *** [all-recursive
(为知笔记copy过来格式有变,希望对遇到此问题的童鞋有帮助) 具体错误: Thank you for choosing Sphinx! [root@vm-vagrant csft-4.1]# mak ...
- undefined reference to XXX 问题原因
原文地址:http://blog.csdn.net/cserchen/article/details/5503556 Linux下编译程序时,经常会遇到“undefined reference to ...
随机推荐
- Qt 获取本机ip地址 【转自 CSDN jpchen609
QString str; QHostInfo info=QHostInfo::fromName(QHostInfo::localHostName()); //定义一个HostInfo的对象然后对这个对 ...
- 想学好web前端,需要看哪些书籍
目前市场上HTML.CSS 类别书籍,都是大同小异,在当当网.卓越网搜索一下很多推荐.今天web前端大牛根据自己的经验总结如下:Javascript 的书籍推荐看老外写的,国内很多 Javascrip ...
- 第五篇——C++实现四则运算
写一个能自动生成小学四则运算题目的命令行 “软件”, 分别满足下面的各种需求.下面这些需求都可以用命令行参数的形式来指定: a) 除了整数以外,还要支持真分数的四则运算. (例如: 1/6 + 1/8 ...
- Cocoapods的安装
1.先升级Gem sudo gem update --system 2.切换cocoapods的数据源 [先删除,再添加,查看] gem sources --remove https://rubyge ...
- DOM扩展之 专有扩展
11.4.3 contains() 方法 用来确定某个节点是不是另一个节点的后代. 注:a.contains(a) 也是返回true.说明contains方法搜索是从自身开始的. DOM Level ...
- [软件架构]模块化编程思想及(C++)实践
Repost 内容简介: 模块化思想 模块的构成 模块的管理 模块化实践 定义模块结构 声明模块对象 定义模块列表 模块列表对象 模块化思想 1. 将系统分成很多的模块,模块内部关注自身需要实 ...
- C++ mem_fun 和 mem_fun_ref 的用法
假设我们有以下的一个类: 另外有一个包含 class A 对象的数组: vector<A> vec; 如何对每一个类的对象调用成员函数print. 做法1: 利用下标 for(int i= ...
- 数据结构《19》----String容器的三种实现
一.序言 一个简单的string 容器到底是如何实现的? 本文给出了 String 的三种从易到难的实现,涉及了 reference counting, copy on write 的技术. 二.第一 ...
- google vr开源 cardboard
https://developers.google.com/cardboard/android/ 待续
- sass的安装与使用
一.SASS简介:SASS是一种使CSS的开发,变得简单和可维护开发工具. 二.安装和使用 2.1 SASS的安装: 安装sass之前首先需要安装ruby,ruby的安装可以直接在百度搜索安装,安装 ...