3

I'm trying to get started with an AWS website, and used the free tier Amazon Linux installation. I installed python3.3 from source, but the wsgi it comes with is for python2.6 so I tried installing mod_wsgi3.3 from source as well, at which point I get

./configure --with-python=/usr/local/bin/python3
checking for apxs2... no
checking for apxs... no
checking Apache version... ./configure: line 1704: apxs: command not found
./configure: line 1704: apxs: command not found
./configure: line 1705: apxs: command not found
./configure: line 1708: /: is a directory

./configure: line 1877: apxs: command not found
configure: creating ./config.status
config.status: error: cannot find input file: Makefile.in

and for the life of me, I have not found a single helpful online source to tell me how to get apxs installed on this system. Suggestions have all been for ubuntu, and hence sudo apt-get install apache2{}-dev where '{}' can be replace with nothing, or -worker or -threaded or -prefork; none of these have worked on my system (using sudo yum install instead).

Is there a different package name I should be looking for? If so, what is it/where do I find potential packages? sudo yum search apache doesn't yield any apache2.

Please help.

dwanderson
  • 2,775
  • 2
  • 25
  • 40
  • With redhat based systems, you will find the apache packages named httpd. – datasage Feb 03 '14 at 23:59
  • ahh, ok, that's gotten me a bit further. `./configure` now worked, but `make` is having reading `lpython3.3`, getting a `Bad value`. – dwanderson Feb 04 '14 at 00:38
  • Try https://github.com/GrahamDumpleton/mod_wsgi/archive/feature/3.5.tar.gz rather than the last mod_wsgi release tar ball. Some Python installations add a suffix to the library and last official release isn't handling it properly. – Graham Dumpleton Feb 04 '14 at 01:11
  • I tried with the old (the last release) and the one you've provided (thanks, btw!) and now I'm getting `[ec2-user@ip-172-31-43-211 mod_wsgi-feature-3.5]$ sudo /etc/init.d/httpd start Starting httpd: httpd: Syntax error on line 204 of /etc/httpd/conf/httpd.conf: Cannot load /etc/httpd/modules/mod_wsgi.so into server: libpython3.3m.so.1.0: cannot open shared object file: No such file or directory`. My python was installed in `/opt/python3`; how do I get sudo to recognize that PATH (or LD_LIBRARY_PATH, or LD_RUN_PATH)? Very new to all of this! – dwanderson Feb 04 '14 at 02:35
  • @datasage;Charles engelke, that did the trick, so feel free to post that as an answer and I'll accept. Thanks! – dwanderson Feb 05 '14 at 04:43

1 Answers1

4

First of all if you are using Amazon Linux or any RPM based linux distro, you should use "httpd" rather than "apache2". Apache use in Debian family.

I think you can resolve this issue by installing httpd-devel package. Try yum search httpd-devel and choose required version and then do yum install httpd-devel <package version>

Sometime just firing yum install httpd-devel can do the job.