Apache mod_wsgi インストール エラー

Apache mod_wsgi インストール エラー

CentOS 6.7を実行しており、mod_wsgiをインストールしようとしています(https://code.google.com/p/modwsgi/

通常は次のようにします:

yum で mod_wsgi をインストールします

しかし、Python 2.7(CentOSのデフォルトのPython 2.6バージョンではなく)でコンパイルできることを確認する必要があるため、リポジトリをダウンロードすることにしました(https://github.com/GrahamDumpleton/mod_wsgi/releases) を実行して、自分のシナリオに合わせて構成されていることを確認します。

インストールについては、Office ガイドに従いました。https://code.google.com/p/modwsgi/wiki/クイックインストールガイド

唯一の違いは、Python のバージョンを変更したことです。

./configure --with-python=/usr/local/bin/python2.7

上記は以下を返します:

checking for apxs2... no
checking for apxs... no
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for prctl... yes
checking Apache version... ./configure: line 2765: apxs: command not found
./configure: line 2765: apxs: command not found
./configure: line 2766: apxs: command not found
./configure: line 2769: /: is a directory

./configure: line 2964: apxs: command not found
configure: creating ./config.status
config.status: creating Makefile

make を実行すると次の結果が返されます。

apxs -c -I/usr/local/include/python2.7 -DNDEBUG  -Wc,-g -Wc,-O2  src/server/mod_wsgi.c src/server/wsgi_*.c -L/usr/local/lib -L/usr/local/lib/python2.7/config  -lpython2.7 -lpthread -ldl  -lutil -lm
/bin/sh: apxs: command not found
make: *** [src/server/mod_wsgi.la] Error 127

ご協力いただければ幸いです。

答え1

Apache 開発ツールがありませんでした:

yum で httpd-devel をインストールします

関連情報