当前位置:网站首页>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
边栏推荐
- 微信公众号授权登录后报redirect_uri参数错误的问题
- ELF:加载过程
- LeetCode·23.合并K个升序链表·递归·迭代
- ML.NET相关资源整理
- MySQL compressed package installation, fool teaching
- MySQL Soul 16 Questions, How Many Questions Can You Last?
- Solve the problem of centos8 MySQL password ERROR 1820 (HY000) You must reset your password using the ALTER USER
- How do I refresh the company's background management system (Part 1) - performance optimization
- @RequestBody、 @RequestParam 、 @PathVariable 和 @Vaild 注解
- 史上最全的Redis基础+进阶项目实战总结笔记
猜你喜欢

面试难题:分布式 Session 实现难点,这篇就够!

MySQL compressed package installation, fool teaching

Deep Non-Local Kalman Network for VideoCompression Artifact Reduction

OpenCV笔记(二十):滤波函数——filter2D

Navicat连接MySQL时弹出:1045:Access denied for user ‘root’@’localhost’

你需要知道的ES6—ES13开发技巧

Markdown的使用

cnpm installation steps

【科研】文献下载神器方式汇总

kubernetes
随机推荐
cnpm安装步骤
MySQL 8.0.29 decompressed version installation tutorial (valid for personal testing)
1064 Complete Binary Search Tree
It is enough for MySQL to have this article (disgusting typing 37k words, just for Bojun!!!)
Installation and use of cnpm
MySQL cursors
Google Earth Engine ——我们如何筛选一个列表中的排序以时间为例
Markdown的使用
WSL安装图形界面并通过xrdp/X-Launch访问
kubernetes
登堂入室之soc开发makefile
系统结构考点之并行主存
Navicat cannot connect to mysql super detailed processing method
3 minutes to take you to understand WeChat applet development
About the error of SFML Rect.inl file
ClickHouse to create a database to create a table view dictionary SQL
网安学习-内网渗透3
Navicat connection MySQL error: 1045 - Access denied for user 'root'@'localhost' (using password YES)
Teach you how to build a permanently running personal server
基于ABP实现DDD--实体创建和更新