本人的移植经验与大家分享,希望对大家有帮助~
编译环境:
native: redhat9
target: armlinux2.4.18
arm: arm9-s3c2410
tool:
arm-linux-gcc (verison 2.95)
apache1.3.34
cp两个apache1.3.34
一:apache1.3.34_redhat的配置
#redhat for apache1.3.34
export LD=ld
export CC=gcc
export RANLIB=ranlib
./configure
--prefix=/usr/local/apache1.3.34 --exec-prefix=/usr/local/apache1.3.34
--libexecdir=/usr/local/apache1.3.34/libexec --enable-module=so
二:apache1.3.34_arm的配置
#armv4l-unknown-linux for apache1.3.34
1.configure cross-compiling
export LD=/usr/arm-linux/bin/armv4l-unknown-linux-ld
export CC=/usr/arm-linux/bin/armv4l-unknown-linux-gcc
export RANLIB=/usr/arm-linux/bin/armv4l-unknown-linux-ranlib
./configure
--prefix=/usr/local/apache1.3.34-arm
--exec-prefix=/usr/local/apache1.3.34-arm
--libexecdir=/usr/local/apache1.3.34-arm/libexec --enable-module=so
--target=armv4l-unknown-linux
make
make (error1: generate test_char.h)
make (error2: generate uri_delims.h)
2.configure native-compiling in another dir apache1.3.34_redhat
copy apache1.3.34_redhat/src/main/test_char.h&uri_delims.h to apache1.3.34_arm/src/main/
(make sure the fileactime if newer , so to void make again)
3.make (in apache1.3.34_arm again, and success)
4.make install
5. edit http.conf
user nobody
group nobody
6.add nobody::100: in the /etc/group
7.type "hostname localhost" in arm shell@
8.run apache int your arm! (make sure the path is same with your install dir)
个人感觉其实移植的过程就是排错的过程, 而出错提示在论坛或google搜都有,很多前辈都有说明了
php4.4.1的移植还在摸索中,编译是成功了,但发现我现在用的2.4.18的核不支持loadmodule
libphp4.so(因为php要用libc-2.3的GLIBC库),这些天都在忙着弄2.6.15的核,总算是能跑起来了,还有ramdisk没解
决~~~
阅读(993) | 评论(0) | 转发(0) |