免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 962 | 回复: 0

arm 单片机交互编译资apache料整理 [复制链接]

论坛徽章:
0
发表于 2008-04-02 14:05 |显示全部楼层

                理清思路其实交互编译就是把x.86下程序用arm版本的编译器重新编译。存在兼容问题所以之需要在原来x.86下可以通过的
代码重新使用arm gcc make 即可下面是大概的步骤
How to Apache Cross Compile
OS : CentOS
Kernel : 2.6
Machine : x.86
Target arm
OS : linux
Kernel : 2.4.18
Machine : arm (TS-7250)
#1.   Download apache file at www.apache.org
version apache_1.3
#2. unzip software
[root@wc02 utils]# tar xvfz apache_1.3.33.tar.gz
#3. change to two version GCC files
[root@wc02 utils]# cp apache_1.3.33 host_apache_1.3.33 -a
#4.start 2 tty prepare compile
[root@wc02 utils]# cd host_apache_1.3.33/
[root@wc02 host_apache_1.3.33]# mkdir /usr/local/apache/
[root@wc02 host_apache_1.3.33]# ./configure --prefix=/usr/local/apache/
Configuring for Apache, Version 1.3.33
+ using installation path layout: Apache (config.layout)
Creating Makefile
Creating Configuration.apaci in src
Creating Makefile in src
+ configured for Linux platform
+ setting C compiler to gcc
+ setting C pre-processor to gcc -E
+ using "tr [a-z] [A-Z]" to uppercase
+ checking for system header files
+ adding selected modules
+ using system Expat
+ checking sizeof various data types
+ doing sanity check on compiler and options
Creating Makefile in src/support
Creating Makefile in src/regex
Creating Makefile in src/os/unix
Creating Makefile in src/ap
Creating Makefile in src/main
Creating Makefile in src/modules/standard
[root@wc02 host_apache_1.3.33]#
[root@wc02 host_apache_1.3.33]# make
这里是我们编译x.86版本的编译。肯定可以通过。注意我们不是要安装所以不需要
make install。把代码放到这里准备
#5.  arm GCC configure
[root@wc02 src]# export CC=arm-linux-gcc
[root@wc02 src]# export CPP=arm-linux-gcc
[root@wc02 src]# export LD=arm-linux-ld
[root@wc02 src]# export STRIP=arm-linux-strip
[root@wc02 src]# export OBJCOPY=arm-linux-objcopy
[root@wc02 apache_1.3.33]# vi configure
##
##  determine platform id
##
## PLATFORM="`$aux/GuessOS`"
               
               
               
               
               

本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/17846/showart_515058.html
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP