- 主题:安装apache时参数中--enable-module=ssl遇到的问题?
按如下操作:
2.5.1需要注意的问题
--enable=ssl是为了支持web下修改密码.
特别需要注意的是./configure在apache_1.3.X和httpd_4.X.X中支持module的格式是不一样的.另外就是在安装php是--with-apxs2的区别
apache_1.3.X用--with-apxs
httpd_4.X.X用--with-apxs2
2.5.2 具体命令
首先进入apache的源代码
如果你使用的是apache_1.3.X
cd apache_1.3.X \\进入apache源文件目录
./configure --prefix=/usr/local/www --enable-module=so --enable-module=ssl
make
make install
编译后出险如下错误提示:
[root@localhost apache_1.3.27]# ./configure --prefix=/usr/local/www --enable-module=so --enable-module=ssl
Configuring for Apache, Version 1.3.27
+ using installation path layout: Apache (config.layout)
configure:Error: No such module named 'ssl'
--
FROM 61.179.12.*
那我现在安装的时候可以不要这项参数然后去安装php了?
【 在 cnbird (阿七) 的大作中提到: 】
: 其实ymsw的atppp早就让web下修改密码不需要ssL了
: 在site.php里加一句什么好象
--
FROM 61.179.12.*
我去掉那个参数之后.编译成功.
但同时安装php时却编译错误:
[root@localhost php-4.3.1]# ./configure --with-apxs=/usr/local/www/bin/apxs --disable-debug --enable-pic --disable-rpath --enable-inline-optimization --with-dom --with-gd --with-freetype-dir=/usr/lib --with-png-dir --with-iconv --with-jpeg-dir --with-zlib --enable-track-vars
loading cache ./config.cache
checking for Cygwin environment... (cached) no
checking for mingw32 environment... (cached) no
checking for working sed... (cached) sed
checking host system type... i686-pc-linux-gnu
checking for gcc... (cached) gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking whether gcc and cc understand -c and -o together... (cached) yes
checking how to run the C preprocessor... (cached) gcc -E
checking for AIX... no
checking if compiler supports -R... (cached) no
checking if compiler supports -Wl,-rpath,... (cached) yes
checking for ranlib... (cached) ranlib
checking whether ln -s works... (cached) yes
checking for gawk... (cached) gawk
checking for bison... (cached) bison -y
checking bison version... 1.35 (ok)
checking for flex... (cached) flex
checking for yywrap in -lfl... (cached) yes
checking lex output file root... (cached) lex.yy
checking whether yytext is a pointer... (cached) yes
checking for working const... (cached) yes
checking flex version... 2.5.4 (ok)
checking for pthreads_cflags... (cached) -pthread
checking for pthreads_lib... (cached)
Configuring SAPI modules
checking for AOLserver support... no
checking for Apache 1.x module support via DSO through APXS...
Sorry, I was not able to successfully run APXS. Possible reasons:
1. Perl is not installed;
2. Apache was not compiled with DSO support (--enable-module=so);
3. 'apxs' is not in your path. Try to use --with-apxs=/path/to/apxs
The output of /usr/local/www/bin/apxs follows
./configure: line 3215: /usr/local/www/bin/apxs: No such file or directory
configure: error: Aborting
【 在 fye (扉) 的大作中提到: 】
: 那我现在安装的时候可以不要这项参数然后去安装php了?
--
FROM 61.179.12.*
参数是按照精华区中一篇文章的.
【 在 fye (扉) 的大作中提到: 】
: 我去掉那个参数之后.编译成功.
: 但同时安装php时却编译错误:
:
: ...................
--
FROM 61.179.12.*
我按照文档中的说明改了一下.
可以正常安装了.
【 在 fye (扉) 的大作中提到: 】
: 参数是按照精华区中一篇文章的.
--
FROM 61.179.12.*
2.4 安装 apache 和 php
首先切换目录到 $(SRCDIR)。为了节省篇幅,下面直接以命令表示。
cd apache_1.3.X
./configure --prefix=/home/www --enable-module=so
make
make install
cd ../php-4.3.X
./configure --prefix=/home/www/php \
--with-apxs=/home/www/bin/apxs --disable-debug \
--enable-pic --disable-rpath --enable-inline-optimization \
--with-dom --with-gd --with-freetype-dir=/usr/lib \
--with-png-dir --with-iconv --with-jpeg-dir --with-zlib \
--enable-track-vars
make
make install
[补充] 如果使用 apache2,以上步骤中需要修改的地方是:
apache 的 configure 命令改成:
./configure --prefix=/home/www --enable-so
php 的 configure 命令里面的 --with-apxs=/home/www/bin/apxs 改成:
--with-apxs2=/home/www/bin/apxs
[补充] php5 不默认编译 mysql 支持,所以如果需要 mysql 支持的话,应该
在 php 的 configure 命令中加入 --with-mysql
我是redhat9.
装php-4.3.1时make出现error:
dl -lnsl -lcrypt -lxml2 -lz -lm -o sapi/cli/php(好像到这儿就停止了)
ext/mysql/libmysql/my_tempnam.lo(.text+0x4c): In function `my_tempnam':
/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_tempnam.c:103: the use of `tempnam' is dangerous, better use `mkstemp'
ext/mysql/libmysql/my_lib.lo(.text+0x3d1): In function `my_dir':
/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_lib.c:169: undefined reference to
`errno'
ext/mysql/libmysql/my_lib.lo(.text+0x5ef): In function `my_stat':
/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_lib.c:588: undefined reference to
`errno'
ext/mysql/libmysql/my_malloc.lo(.text+0xde): In function `my_malloc':
/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_malloc.c:24: undefined reference to `errno'
ext/mysql/libmysql/my_realloc.lo(.text+0xd5): In function `my_realloc':
/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_realloc.c:44: undefined reference
to `errno'
ext/mysql/libmysql/my_delete.lo(.text+0x86): In function `my_delete':
/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_delete.c:16: undefined reference to `errno'
ext/mysql/libmysql/my_tempnam.lo(.text+0x89):/home/smthbbs/php-4.3.1/ext/mysql/libmysql/my_tempnam.c:108: more undefined references to `errno' follow
collect2: ld returned 1 exit status
make: *** [sapi/cli/php] Error 1
【 在 fye (扉) 的大作中提到: 】
: 我按照文档中的说明改了一下.
: 可以正常安装了.
--
FROM 61.179.12.*
我是在dev.smth.org上下的.
然后按照kbsbbs-2.0dev中的文档提示安装php.就出现问题了.
【 在 JulyClyde (七月) 的大作中提到: 】
: 4.3.1老吗?
--
修改:fye FROM 61.179.12.*
FROM 61.179.12.*
我刚才安装了php-4.4.0版本的,就没有出现问题了.
【 在 fye (扉) 的大作中提到: 】
: 我是在dev.smth.org上下的.
: 然后按照kbsbbs-2.0dev中的文档提示安装php.就出现问题了.
--
FROM 61.179.12.*
我装php4.4.0装好了.
【 在 atppp (Big Mouse) 的大作中提到: 】
: faint, 4.3.1至少两年半了,php这种发展这么快的东西两年半意味着什么你应该明白吧...
--
FROM 219.245.175.*