以下の質問の続きになります。
質問
makeコマンドを実行したのですが、以下のエラーが発生しました。
[ec2-user@ip-xxx mod_wsgi-4.6.4]$ make /bin/apxs -c -I/usr/include/python2.7 -D_GNU_SOURCE -DNDEBUG -D_GNU_SOURCE -Wc,-g -Wc,-O2 src/server/mod_wsgi.c src/server/wsgi_*.c -L/usr/lib64 -L/usr/lib64/python2.7/config -lpython2.7 -lpthread -ldl -lutil -lm /usr/lib64/apr-1/build/libtool --silent --mode=compile gcc -prefer-pic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -DLINUX -D_REENTRANT -D_GNU_SOURCE -pthread -I/usr/include/httpd -I/usr/include/apr-1 -I/usr/include/apr-1 -g -O2 -I/usr/include/python2.7 -D_GNU_SOURCE -DNDEBUG -D_GNU_SOURCE -c -o src/server/mod_wsgi.lo src/server/mod_wsgi.c && touch src/server/mod_wsgi.slo In file included from src/server/mod_wsgi.c:22:0: src/server/wsgi_python.h:24:10: fatal error: Python.h: No such file or directory #include <Python.h> ^~~~~~~~~~ compilation terminated. apxs:Error: Command failed with rc=65536 . make: *** [src/server/mod_wsgi.la] Error 1 [ec2-user@ip-xxx mod_wsgi-4.6.4]$ find python.h find: ‘python.h’: No such file or directory
以下の公式ドキュメントを読んだところpython-develがインストールされていないことが原因と考えられたためインストールしようと思うのですが、EC2内のpython-develパッケージのバージョンが2.7になっています。
参考
[ec2-user@ip-xxx ~]$ yum list python-devel Loaded plugins: langpacks, priorities, update-motd Installed Packages python-devel.x86_64 2.7.14-58.amzn2.0.2 @amzn2-core
今回使用しているPythonのバージョンは3.6.5なのでPython-develのバージョンも同じものにすべきと考えています。
以下の公式サイトからpython-develからパッケージをダウンロードしようと思ったのですが、見当たりませんでした。
公式サイト
python-devel 3.6.5をインストールするにはどうすればいいでしょうか。

回答1件
あなたの回答
tips
プレビュー