我在ubuntu16.04上迁移工程,遇到了这个错误。

pthread库不是Linux系统默认的库,链接时需要添加-pthread参数。

这里注意是链接那一步添加-pthread,而不是编译选项。

undefined reference to symbol' pthread_create@@GLIBC_2.2.5'的更多相关文章

  1. undefined reference to symbol 'pthread_create@@GLIBC_2.2.5' 的修改方法

    在编译DSO代码的时候会如下这样的问题: 检查DSO,在程序中没有用到pthread,但是在编译的时候却出现此类问题.仔细想了想了一下,在程序中用到了C++11中的线程std::thread,个人猜测 ...

  2. 在Linux下使用gcc编译mesa文件报undefined reference to symbol 'sin@@GLIBC_2.2.5和DSO missing from command line两个错误的解决方案

    一.概述 在Linux系统下使用gcc编译用C语言写的mesa的示例程序. 环境:Ubuntu Server 18.04.1 二.问题的出现 在Ubuntu下安装好mesa所需的库文件,将目标文件从g ...

  3. linux undefined reference to symbol 'floor@@GLIBC_2.2.5'

    这个是因为GNU make版本不一致导致,最后加上-lm g++或者gcc -o  main main.c -lm 如果还存在问题 需要加上-Wl,--no-as-needed g++或者gcc -W ...

  4. undefined reference to symbol 'dlclose@@GLIBC_2.2.5'

    解决方法 在QT工程的.pro文件中添加如下内容: LIBS=-ldl

  5. linux下开发,解决cocos2d-x中编译出现的一个小问题, undefined reference to symbol 'pthread_create@@GLIBC_2.2.5'

    解决cocos2d-x中编译出现的一个小问题 对于cocos2d-x 2.×中编译中,若头文件里引入了#include "cocos-ext.h",在进行C++编译的时候会遇到例如 ...

  6. libopencv_highgui.a(window_gtk.cpp.o): undefined reference to symbol 'g_type_check_instance_is_a'

    libopencv_highgui.a(window_gtk.cpp.o): undefined reference to symbol 'g_type_check_instance_is_a' 尝试 ...

  7. /usr/bin/ld: .build_release/tools/alignment_tools.o: undefined reference to symbol 'omp_get_thread_num@@OMP_1.0'

    问题:/usr/bin/ld: .build_release/tools/alignment_tools.o: undefined reference to symbol 'omp_get_threa ...

  8. undefined reference to symbol '_ZNK11GenICam_3_016GenericException17GetSourceFileNameEv'

    今天在编译DALSA二次开发的源码时,出现了如下错误: /usr/bin/ld: ./out/camera.o: undefined reference to symbol '_ZNK11GenICa ...

  9. gentoo rt-thread scons --menuconfig libs/lxdialog/util.o: undefined reference to symbol 'nodelay'

    今天在另外一台电脑上面使用 rt-thread 的 env 工具,scons --menuconfig 出现错误,提示如下: scons: Reading SConscript files ... s ...

随机推荐

  1. Flex学习笔记-Vgropu Hgroup 定义的组 表单程序。

    <?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="ht ...

  2. 转载:HTuple数据和VC数据的相互赋值

    转载来自:http://blog.csdn.net/taily_duan/article/details/51026260 HTuple和VC数据的相互赋值 // HTuple→VC 数据类型转换 H ...

  3. MVC基于角色权限控制--数据库设计

    在网站后台设计过程中都会遇上权限控制这一问题 当前较为流行的解决方案是基于角色的权限管理 基本思路如下 分别建立 用户信息表.角色信息表.权限信息表 让用户和角色关联,角色和权限关联,当用户访问时,通 ...

  4. Spring cloud(2)B Eureka 注册微服务到服务中心

    1.在provide上添加pom(必须加上web)   如果不加 启动后就会自己关闭 <dependency> <groupId>org.springframework.clo ...

  5. delphi RTTI 三 属性读取与赋值

    delphi RTTI 读取属性 运行期 通过RTTI给属性赋值 http://docwiki.embarcadero.com/CodeExamples/Berlin/en/Event_RTTI_In ...

  6. chattr 改变文件、目录属性 (chmod、passwd等涉及文件修改的命令提示Operation not permitted)

    与chmod这个命令相比,chmod只是改变文件的读写.执行权限,更底层的属性控制是由chattr来改变的. lsattr查看文件或目录属性 chattr命令的用法:chattr [ -RVf ] [ ...

  7. 使用CommandLineRunner或ApplicationRunner接口创建bean

    在spring boot应用中,我们可以在程序启动之前执行任何任务.为了达到这个目的,我们需要使用CommandLineRunner或ApplicationRunner接口创建bean,spring ...

  8. linux shell实现 URL 编码/解码方法

    (1)编码的两种方法 # echo '手机' | tr -d '\n' | xxd -plain | sed 's/\(..\)/%\1/g' # echo '手机' |tr -d '\n' |od ...

  9. 【375】COMP 9021 相关笔记

    1. Python 中的逻辑否定用 not 2. 对于下面的代码直邮输入整数才能运行,无论字符串或者浮点型都会报错 int(input('How many games should I simulat ...

  10. LeetCode OJ 60. Permutation Sequence

    题目 The set [1,2,3,-,n] contains a total of n! unique permutations. By listing and labeling all of th ...