博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
gtest编译小结(ubuntu 12.10 , gtest 1.6.0)
阅读量:7076 次
发布时间:2019-06-28

本文共 420 字,大约阅读时间需要 1 分钟。

1 下载源码,解压之当前用户的主目录(~/)

2 进入make目录,执行make命令

cd ~/gtest-1.6.0/makemake

3 在ubuntu里编译出错,提示找不到lthread库。修改Makefile,在文件结尾:

sample1_unittest : sample1.o sample1_unittest.o gtest_main.a    $(CXX) $(CPPFLAGS) $(CXXFLAGS) -lpthread $^ -o $@

修改成(-lpthread 移到命令末尾):

sample1_unittest : sample1.o sample1_unittest.o gtest_main.a    $(CXX) $(CPPFLAGS) $(CXXFLAGS) $^ -o $@ -lpthread

 

转载于:https://www.cnblogs.com/code-style/p/3230686.html

你可能感兴趣的文章
Java学生管理系统
查看>>
IOS UISearchDisplayController 点击搜索出现黑条问题解决方案
查看>>
如何在应用图标上显示未读消息
查看>>
P2P下载为什么人越多越快呢??
查看>>
iOS--警告收录及科学快速的消除方法
查看>>
Export-XLSX PowerShell generate real Excel XLSX files without Excel and COM
查看>>
Oracle 修改表列属性
查看>>
facl权限(getfacl/setfacl)
查看>>
Homework Exercises 1
查看>>
bzoj 3670 [Noi2014]动物园
查看>>
bzoj 1009 [HNOI2008]GT考试——kmp+矩阵优化dp
查看>>
使用PHP输出中文JSON字符串
查看>>
用Curl测试POST
查看>>
Rails: No such file or directory - getcwd
查看>>
算法18-----判断是否存在符合条件的元素【list】
查看>>
运行TestCase时,提示:Element is not currently visible and so may not be interacted with
查看>>
将xml文件转为c#对像
查看>>
stl之map 排序
查看>>
gdb调试python
查看>>
为文本数据创建索引
查看>>