当前位置:网站首页>Libmysqlclient A static library

Libmysqlclient A static library

2022-06-12 21:28:00 Overtime ape

libmysqlclient.a Static library access method

1、 Download the source code and compile it

obtain MariaDB Source code Download the corresponding source code , Download address mariadb-5.5.56.tar.gz Download and transfer to the virtual machine , Unzip and compile .

Install the required common libraries

apt-get install bison 
apt-get install flex
apt-get install ncurse-devel
apt-get install cmake

compile MariaDB obtain libmysqlclient.a

tar –zxvf mariadb-5.5.56.tar.gz
cd mariadb-5.5.56
cmake . –LH        # see cmake Available options for 
cmake . -DCMAKE_INSTALL_PREFIX=/home/mysql
        -DMYSQL_DATADIR=/home/mysqldata -DSYSCONFDIR=/etc 
        -DWITHOUT_TOKUDB=1 -DMYSQL_UNIX_ADDR=/home/tmp/mysql.sock 
        -DDEFAULT_CHARSET=gbk -DDEFAULT_COLLATION=gbk_general_ci
make
make install

After completing the above order , stay /home/mysql/lib/ You can get libmysqlclient.a Static library files

2、 Direct access to libmysqlclient.a The way

Download compiled MariaDB file ,mariadb Download address

Find the corresponding version , I use it Linux So the corresponding mariadb-5.5.56-linux-x86_64.tar.gz

decompression

tar -zxvf mariadb-5.5.56-linux-x86_64.tar.gz

libmysqlclient.a File in directory lib Under the folder

3、 Download my uploaded directly libmysqlclient.a

In my CSDN You can find it in the resources

  • 32 Bit system libmysqlclient.a link
  • 63 Bit system libmysqlclient.a link
原网站

版权声明
本文为[Overtime ape]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202281401050736.html