suse php配置,suse linux中apache+php服务器安装

主站下载源码

tar zxvf httpd-2.2.4.tar.bz2

cd httpd-2.2.4

./configure --prefix=/usr/local/apache --sysconfdir=/etc/httpd --enable-so --enable-ssl --enable-track-vars --enable-rewrite --enable-mods-shared=most

出错error: ...No recognized SSL/TLS toolkit detected

去掉--enable-ssl ,从新configure不再报错。

make

make install

/usr/local/apache/bin/apachectl restart 可以启动apache

echo "/usr/local/apache/bin/apachectl -k start" >> /etc/init.d/boot.local系统启动时服务自动启动,

suse自启动项目是在/etc/init.d/boot.local文件中添加命令。Red Hat系统的对应文件是/etc/rc.d/rc.local。

安装php

tar zxvf php-5.2.12.tar.gz

./configure --prefix=/usr/local/php --with-apxs2=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-xml --with-png --with-jpeg --with-zlib --with-freetype   --with-gd --enable-track-vars --enable-mbstring=all

根据安装mysql与httpd的情况进行目录修改如下:

./configure --prefix=/usr/local/php --with-apxs2=/usr/local/apache/bin/apxs --with-mysql=/usr/bin/mysql --with-mysqli=/usr/bin/mysql_config --with-xml --with-png --with-jpeg --with-zlib --with-freetype   --with-gd --enable-track-vars --enable-mbstring=all

报错: xml2-config not found.

安装libxml2 从yast软件管理中找到libxml2-devel安装!

configure成功!

make

make install

cp php.ini-dist /usr/local/php/lib/php/php.ini

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值