当前位置:网站首页>VS2017编译Tars测试工程
VS2017编译Tars测试工程
2022-07-30 21:55:00 【Hello,C++!】
1、Windows环境下载并编译TarsCpp
git clone https://github.com/TarsCloud/TarsCpp.git --recursive
cd TarsCpp;
mkdir build;
cd build;
cmake .. -G "Visual Studio 15 2017"
cmake --build . --config release
#install
cmake --build . --config release --target install
12345678
注意:如果需要安装debug库,则指令改成如下:
cd TarsCpp;
mkdir build;
cd build;
cmake .. -G "Visual Studio 15 2017"
cmake --build . --config debug
#install
cmake --build . --config debug --target install
1234567
一般情况下编译可以正常。如果安装出现各种问题,可以重装系统和VS2017试试。。。
编译安装完成后,默认会在C盘下生成Tars的库以及头文件。
2、开发TarsCpp测试工程
新建VS2017工程
将TarsCpp的example里面的AuthClient、AuthServer源文件拷贝到对应的测试工程下,然后使用tars2cpp.exe生成Hello.h,然后把文件加到工程里面。然后将C:\tars\cpp
目录下的include和lib分别加到工程配置下。
3、修改配置文件
修改AuthServer和AuthClient的config.conf文件,改下IP。
4 运行测试工程
运行AuthServer
运行AuthClient
边栏推荐
- WSL2设置默认启动用户(debian)
- Solve the problem of centos8 MySQL password ERROR 1820 (HY000) You must reset your password using the ALTER USER
- It is enough for MySQL to have this article (disgusting typing 37k words, just for Bojun!!!)
- ClickHouse to create a database to create a table view dictionary SQL
- MySQL 5.7详细下载安装配置教程
- MySQL compressed package installation, fool teaching
- Google Earth Engine ——
- 【高等数学】矩阵与向量组的秩和等价
- 系统结构考点之流水线向量点积
- LeetCode·每日一题·952.按公因数计算最大组件大小·并查集
猜你喜欢
WSL安装图形界面并通过xrdp/X-Launch访问
mysql 时间字段默认设置为当前时间
A simple rich text editor
Markdown的使用
The reason for not using bs4 is that the name is too long?Crawl lottery lottery information
TransGAN code reproduction - Jiutian Bisheng Platform
Difference between cookie and session
Navicat new database
The mysql time field is set to the current time by default
MySQL Soul 16 Questions, How Many Questions Can You Last?
随机推荐
About the error of SFML Rect.inl file
JUC原子类详解
【科研】文献下载神器方式汇总
JDBC (detailed explanation)
mysql deadlock
About the data synchronization delay of MySQL master-slave replication
Day 16 of HCIP
【Nacos】解决Nacos下载速度缓慢的问题
The mysql time field is set to the current time by default
LeetCode·Daily Question·952. Calculate Maximum Component Size by Common Factor·Union Check
【Summary】机器人方法汇总
1064 Complete Binary Search Tree
Apache DolphinScheduler新一代分布式工作流任务调度平台实战-
小心你的字典和样板代码
LeetCode·每日一题·952.按公因数计算最大组件大小·并查集
Navicat连接MySQL时弹出:1045:Access denied for user ‘root’@’localhost’
Detailed explanation of the delete problem of ClickHouse delete data
Motion Tuned Spatio-temporal Quality Assessmentof Natural Videos
ELF: Loading process
共用体、共用体与结构体的区别、枚举之C语言犄角旮旯的知识