Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2024.7.17跑项目踩过的坑 #287

Open
WilliamHenryAlan opened this issue Jul 17, 2024 · 2 comments
Open

2024.7.17跑项目踩过的坑 #287

WilliamHenryAlan opened this issue Jul 17, 2024 · 2 comments

Comments

@WilliamHenryAlan
Copy link

  1. main.cpp中 需要修改的user passwd是你自己登陆数据库的时的用户和密码
    也就是mysql -u root -p输入的东西
#include "config.h"                                                                                   
                                                                                                      
int main(int argc, char *argv[])                                                                      
{                                                                                                     
    //需要修改的数据库信息,登录名,密码,库名                                                           
    string user = "root";                                                                             
    string passwd = "root";                                                                      
    string databasename = "yourdb";                                                                     
                                                                                                      
  1. 编译过程中会出现很多warning 不用管 先跑起来
  2. 不要用debian 可能我是小白 本人用macos跑虚拟机debian11 mysql安装过程各种问题 换了ubuntu就好了
    以上是本人测试过程中遇到的一些小坑 如有说的不对的地方 欢迎大佬们指正
    最后感谢作者的无私奉献~
@xianshujun
Copy link

为什么我用ubuntu运行makefile和build脚本,一直显示找不到数据库,请问您有遇到这个问题嘛

@code-lun
Copy link

@xianshujun 你装数据库了吗,装了的话,装devel库了吗(c++操作mysql需要一个库 => mysql-devel),我用的mysql8是可以的,报错可以抛百度,通常能解决的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants