为了下载的方便,使用了一个共享文件夹share folder,这主要是依赖于vmware tools的功能。 在linux的/mnt/hgfc可以看到共享目录share folder. 1.download httpd-2.2.11.tar.gz from www.apache.org into share folder. 2.create a dir called dev under home dir(/home/jpwang). 3.copy httpd-2.2.11.tar.gz to /home/jpwang/dev by using following commands: $ cd /home/jpwang/dev
$ cp /mnt/hgfs/share/ folder/httpd-2.2.11.tar.gz . 4.extract files form httpd-2.2.11.tar.gz using following commands: $ gzip -d httpd-2.2.11.tar.gz $ tar xvf httpd-2.2.11.tar #generate folder "httpd-2.2.11" 我想把server安装到指定的文件下,所以在dev下建立一个httpd-2.2.11的文件夹. 把之前的httpd-2.2.11重命名为httpd-2.2.111($ mv httpd.2.2.11 httpd-2.2.111). 5.接下来是configure,这一步出现了不少问题, (1)CC="pgcc" CFLAGS="-O2" ./configure --prefix=/home/jpwang/dev/httpd-2.2.11 --enable-mods-shared=all here,I choose the option "--enable-mods-shared=all",becase I want to load all of the modules dynamically by using LoadModule directives, of course,you can use other options whatever you want. (2)./configure --prefix=/home/jpwang/dev/httpd-2.2.11 --enable-mods-shared=all 这两个命令的执行都出现了C compiler cannot create executables的问题, 于是去加载linux的第二张光盘$mount /dev/cdrom /mnt/cdrom将和gcc有关的包都拷贝到/tmp下面, 然后安装: rpm -ivh rpm名称,待安装完成后,再执行 $ cd /home/jpwang/dev/httpd-2.2.11 $ ./configure --prefix=/home/jpwang/dev/httpd-2.2.11 --enable-mods-shared=all 还是有错误,看了看config.log,知道是仍然缺少很到包,没有办法,只有update当前的Linux了. 6.About how to update Linux,I didn't search on the web to find a solution.I do it by myself. 关于这一点,还是再写篇文章吧,这样的不至于和标题不符,也便于以后查找. 7.make 8.make install 总而言之,在安装时,把和开发功能需要的包全部装上,就不会出现这样的问题了.