2012-04-13 92 views
2

我想在我的CentOS機器上安裝httpd-2.4.1(目前它的版本是2.2.15)。我做了以下...在centos上安裝httpd 2.4.1時出現apr-util錯誤

sudo yum install gcc 
sudo yum install perl 
sudo yum install libbz2 libbz2-devel 
sudo yum install bzip2-devel 
sudo yum install curl-devel 
sudo yum install libjpeg-devel 
sudo yum install libpng-devel 
sudo yum install libX11-devel gd-devel 
sudo yum install libc-client-devel 
sudo yum install libmcrypt-devel 
sudo yum install bzip2 
sudo yum install pcre-devel 
sudo yum install openssl-devel 
sudo yum install libxml2-devel 
sudo yum install libmcrypt 

#apache 
wget http://mirror.nus.edu.sg/apache//apr/apr-util-1.4.1.tar.gz 
wget http://mirror.nus.edu.sg/apache//apr/apr-1.4.6.tar.gz 
extract and move to /srclib in httpd-2.4.1 directory 
sudo ./configure --prefix=/usr/local/apache --enable-so --enable-mods-shared=most --with-included-apr --with-included-apr-util --enable-load-all-modules 
sudo make 
sudo make install 

在這裏,我得到的錯誤:

/usr/bin/ld: /usr/local/apache/lib/libexpat.a(xmlparse.o): relocation R_X86_64_32S against `.text' can not be used when making a shared object; recompile with -fPIC 
/usr/local/apache/lib/libexpat.a: could not read symbols: Bad value 
collect2: ld returned 1 exit status 
libtool: install: error: relink `libaprutil-1.la' with the above command before installing it 

如何重新鏈接libaprutil-1.la與上面的命令? (我猜測它是指-fPIC?)

回答

0

你不包括--with-included-apr-util運行時./configure

+0

是的,我注意到了。包括它後,我再次嘗試,同樣的問題。進行編輯。 – crazyphoton 2012-04-13 13:53:51

0

的./configure --with-包括-APR --with-包括-APR-util的