0

我正在尝试在 Ubuntu 9.10 上安装 mod_wsgi 3.1,并且在尝试制作时出现此错误

root@me:/src/mod_wsgi-3.1$ ./configure --with-python=/usr/bin/python2.6
checking for apxs2... /usr/bin/apxs2
checking Apache version... 2.2.12
configure: creating ./config.status
config.status: creating Makefile

root@me:/src/mod_wsgi-3.1$ sudo make
/usr/bin/apxs2 -c -I/usr/include/python2.6 -DNDEBUG   mod_wsgi.c -L/usr/lib -L/usr/lib/python2.6/config  -lpython2.6 -lpthread -ldl  -lutil -lm
/usr/share/apr-1.0/build/libtool --silent --mode=compile --tag=disable-static i486-linux-gnu-gcc -prefer-pic -DLINUX=2 -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -D_REENTRANT -I/usr/include/apr-1.0 -I/usr/include/openssl -I/usr/include/xmltok -pthread     -I/usr/include/apache2  -I/usr/include/apr-1.0   -I/usr/include/apr-1.0  -I/usr/include/python2.6 -DNDEBUG  -c -o mod_wsgi.lo mod_wsgi.c && touch mod_wsgi.slo

/usr/share/apr-1.0/build/libtool: line 970: i486-linux-gnu-gcc: command not found
apxs:Error: Command failed with rc=65536
make: *** [mod_wsgi.la] Error 1

问题是什么?

4

3 回答 3

3

正确安装 gcc 编译器,它看起来并不都存在,或者可能根本不存在。

于 2010-01-22T08:37:14.440 回答
3

问题是你需要 apache-dev 试试这个

sudo apt-get install apache2-dev

经过这次尝试

./configure --with-python=/usr/bin/python2.6

并且运行良好:-) 伟大的!

于 2011-03-20T05:12:18.220 回答
2

apxs:找不到命令

如果您在运行 configure 时收到错误消息:apxs: command not found。

然后你需要安装 apache2-threaded-dev 包(Ubuntu 包名,在不同的发行版上可能不同。

apt-get install apache2-threaded-dev

于 2012-12-06T06:30:41.157 回答