pdo_mysql的安装_安装PDO_Mysql

在安装phpwind的时候显示没有安装PDO_Mysql

网上搜的倒是很多,不过看起来好难的样子

这里把我的步骤贴出来做个笔记[root@duwers ~]# wget http://pecl.php.net/get/PDO_MYSQL-1.0.2.tgz  #down一个源码包

[root@duwers ~]# tar zxfPDO_MYSQL-1.0.2.tgz

[root@duwers ~]# cd PDO_MYSQL-1.0.2

[root@duwers PDO_MYSQL-1.0.2]#/usr/local/php/bin/phpize

Configuring for:

PHP Api Version:         20131106

Zend Module Api No:      20131226

Zend Extension Api No:   220131226

[root@duwers PDO_MYSQL-1.0.2]#[root@duwers PDO_MYSQL-1.0.2]# ./configure--with-php-config=/usr/local/php/bin/php-config--with-pdo-mysql=/usr/local/mysql/

[root@duwers PDO_MYSQL-1.0.2]# ln -s/usr/local/mysql/include/* /usr/local/include/ #不这样或许会报错

[root@duwers PDO_MYSQL-1.0.2]# make&& make install

#完成的显示

PATH="$PATH:/sbin" ldconfig -n/root/PDO_MYSQL-1.0.2/modules

----------------------------------------------------------------------

Libraries have been installed in:

/root/PDO_MYSQL-1.0.2/modules

If you ever happen to want to link againstinstalled libraries

in a given directory, LIBDIR, you musteither use libtool, and

specify the full pathname of the library,or use the `-LLIBDIR'

flag during linking and do at least one ofthe following:

-add LIBDIR to the `LD_LIBRARY_PATH' environment variable

during execution

-add LIBDIR to the `LD_RUN_PATH' environment variable

during linking

-use the `-Wl,--rpath -Wl,LIBDIR' linker flag

-have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentationabout shared libraries for

more information, such as the ld(1) andld.so(8) manual pages.

----------------------------------------------------------------------

Build complete.

Don't forget to run 'make test'.

Installing shared extensions:    /usr/local/php/lib/php/extensions/no-debug-zts-20131226/

修改php.ini[root@duwers PDO_MYSQL-1.0.2]# vim/usr/local/php/php.ini

#修改下面的内容

extension_dir ="/usr/local/php/lib/php/extensions/no-debug-zts-20131226/"

extension=pdo_mysql.so

重启apache

/etc/init.d/apache2.4 restart

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值