linux boost访问mysql_Linux下C++连接操作MySQL数据库环境搭建

本文详细介绍了如何在Linux(CentOS 7)上搭建C++连接MySQL数据库的环境,包括安装gcc-c++, boost-devel和mysql-connector-c++的步骤,并提供了编译和运行测试程序的方法,解决可能出现的链接错误。" 80649983,7321431,区块链落地:与AI、IoT融合的探索与思考,"['区块链应用', 'AI技术', '物联网', '共识算法', '数据安全']
摘要由CSDN通过智能技术生成

Linux下C++连接操作MySQL数据库环境搭建

日期     版本   作者   修改内容   备注

2017年4月8日 V1.0   刘胜军  文件初建   无

一、引言

1.1 编写目的

Linux下C++连接操作MySQL数据库环境搭建

1.2 术语

gcc/gcc-c++:

The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran, Ada, and Go, as well as libraries for these languages (libstdc++,...). GCC was originally written as the compiler for the GNU operating system. The GNU system was developed to be 100% free software, free in the sense that it respects the user's freedom.

boost/boost-devel:

Boost provides free peer-reviewed portable C++ source libraries.

mysql-connector-c++:

All distributions of Connector/C++ contain a README file, which contains platform-specific notes. At the end of the README file contained in the binary distribution you will find the settings used to build the binaries. If you experience build-related issues on a platform, it may help to check the settings used on the platform to build the binary.

1.3 准备工作

一台安装有CentOS 7.X OS的机器,可连接互联网,或备有离线安装包。

1.4 注意事项

使用yum源安装时,需正确配置yum源。

二、依赖环境搭建

2.1 安装gcc-c++

方法一:使用yum源

[root@user ~]# yum install -y gcc-c++

方法二:使用本地rpm

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值