树莓派:2. 为树莓派搭建BOA环境

1. 下载BOA源码

1. 下载软件
地址为:www.boa.org
最新版本是boa-0.94.13.tar.gz
2. 用FileZilla上传压缩包到树莓派的/home/pi/目下
3. 解压缩源代码

tar xvf boa-0.94.13.tar.gz

2. 配置BOA

1. 进入源代码目录

cd boa-0.94.13

2. 配置BOA

cd src
./configure

3. 修改源代码

修改boa.c
注释225,226,227行

//if (setuid(0) != -1) {
// DIE("icky Linux kernel bug!");
// }

4. 下载必须库

1. 下载yacc库

sudo apt-get install -y byacc

2. 下载lex库

apt-get install -y flex

5. 编译BOA

make

[09/Mar/2016:16:02:24 +0000] log.c:73 - unable to dup2 the error log: Bad file descriptor

添加错误文件夹

查看是否运行boa成功
这里写图片描述

gcc -o hello.cgi hello.c
cp hello.cgi /var/www/cgi-bin

你可能感兴趣的:(树莓派)