因为kail 是基于 diban
假设 已经是root 账号
0.首先先安装几个编译用的库
a apt-get install automake
yum install automake(在 centos 系统上 )
b sudo yum install libtool(这个其实automake 的一个依赖)
c autoreconf -fi
生成 configure 文件
d ./configure 生成make 文件
1.like others os .
cd /root/dowloads /yaws-master configure
make
2. then we have error
make[1]: Entering directory `/root/Downloads/yaws/yaws-1.90/c_src‘
gcc -c -fpic -g -O2 -I/usr/include/security  -DHAVE_SENDFILE -I"/usr/local/lib/erlang/usr/include" -I/usr/include/pam/  -DDYNAMIC_DRIVER setuid_drv.c
gcc  -shared -o  ../priv/lib/setuid_drv.so setuid_drv.o 
gcc -c -g -O2 -I/usr/include/security  -DHAVE_SENDFILE -I"/usr/local/lib/erlang/usr/include" -I/usr/include/pam/  epam.c
epam.c:2:22: fatal error: pam_appl.h: No such file or directory
compilation terminated.
make[1]: *** [epam.o] Error 1
make[1]: Leaving directory `/root/Downloads/yaws/yaws-1.90/c_src‘
make: *** [all] Error 1
it mean we have "pam_appl.h" . from the word "pam " i should be a pam -related issue
seach web .find a topic about that http://linux.cn/article-5508-1.html
3.download "pam_app.h"
sudo apt-get install libpam0g-dev make make install
可能在make install 会报个 有关生成pdf 文档的错
安装下列包
sudo apt-get install texlive-latex-base
sudo apt-get install texmaker
sudo apt-get install texlive-fonts-recommended(在我的机器上是这个问题)
sudo apt-get install texlive-scienc
4 test it
yaws --help
it is sucessful if it show below
usage:  
       yaws -i | --interactive       -- interactive (no daemon) mode
       yaws -w | --winteractive      -- cygwin interactive (werl) 
       yaws --daemon                 -- daemon mode
       Auxiliary flags for the daemon: 
            --id Id             --  set system id
            --debug             --  debug mode
            --nodebug           --  turn off debug mode
            --conf File         --  set config file
            --tracetraf         --  trace traffic
            --tracehttp         --  trace http traffic
            --traceout          --  trace output to stdout
            --version           --  print version
            --pa path           --  add load path
            --mnesiadir dir     --  start Mnesia in dir
            --proto_dist Mod    --  use Mod for distrib
            --sname xxx         --  start with sname xxx
            --name xxx          --  start with name xxx
            --runmod mod        --  call mod:start/0 at startup
            --heart             --  auto restart yaws if it crashes
            --heart-restart=C,T --  allow C heart restarts in T seconds
            --erlarg X          --  pass argument X to /usr/local/bin/erl
            --setcookie X       --  set an erlang cookie
            --run_erl X         --  use run_erl with pipe-id X
            --to_erl X          --  connect to pipe-id X
            --disable-kpoll     --  pass +K false to erlang
            --umask umaskval    --  set process umask to umaskval
ctl functions ... 
        yaws --hup [--id ID]                 -- hup the daemon, reload conf
        yaws --stop [--id ID]                -- stop the daemon 
        yaws --debug-dump [--id ID]          -- produce a debug dump 
        yaws --status [--id ID]              -- query the daemon status 
        yaws --load Modules                  -- load modules 
        yaws --ls                            -- list Yaws nodes and their status
        yaws --ctltrace traffic|http         -- toggle trace of running daemon
        yaws --check YawsFile [IncDirs]      -- test compile File 
        yaws --wait-started[=secs] [--id ID] -- wait for daemon to be ready
        yaws --stats [--id ID]               -- show daemon statistics
在kail 系统上手动编译yaws (dibian 系统 基本相同)
原文:http://www.cnblogs.com/codewarelock/p/4855126.html