1

I am trying to install mod_wsgi and django. When i "make" mod_wsgi then i get error if i use python2.7 but it went ok with default python.

i already wasted much time to figure that but could not solve it.

I just wanted to know that if continue with default python and install Django then can i change the python to 2.7 later

EDIT: CENTOS5.5 The error i get is

/usr/bin/ld: /opt/python27/lib/libpython2.7.a(node.o): relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC /opt/python27/lib/libpython2.7.a: could not read symbols: Bad value collect2: ld returned 1 exit status apxs:Error: Command failed with rc=65536 . make: * [mod_wsgi.la] Error 1

this all heppens if i do

"make" in mod_wsgi directory

Now this error is written on their help site

But i could not configure these things.

According to them

If the version of Python being used was compiled for X86 64 bit architecture and a shared library does exist, but not in the 'config' directory, then adding the missing symlink may be all that is required.

i have found that my python version is 64bit . So the only thing left is the other option he talked in above text.

I don't know how to

1) Check if shared library does exist
2) How to add the missing symlink

If i make the mos_wsgi using default python then i get no error.

11
  • You had better paste your error log and others could help you figure it out how to deal with it. Generally speaking, django(>1.2) works well with python 2.7. Commented May 24, 2011 at 9:44
  • and tell us what is your Server OS and its version ! Commented May 24, 2011 at 9:58
  • You shouldn't be mucking about with mod_wsgi if you're just starting with Django. Do the tutorial, use the built-in runserver, then worry about mod_wsgi when it's time to deploy. Commented May 24, 2011 at 10:03
  • I followed django documentation and its written their first to install mod_wsgi Commented May 24, 2011 at 10:06
  • 1
    No it isn't. Here is the initial installation instructions - it says install Django, set up your database, then do the tutorial. And the "full" instructions explicitly say what I said above - skip mod_wsgi until you're ready to deploy. Commented May 24, 2011 at 10:09

1 Answer 1

1

I just wanted to know that if continue with default python and install Django then can i change the python to 2.7 later

Yes. Upgrades are permitted. AFAIK, there's no law that says you are not permitted to upgrade. Indeed, why ask if an upgrade is possible? Have you been told that you're not permitted to upgrade?

Use the default Python.

Learn Python. Do the entire tutorial.

Install Django.

Learn Django. Do the entire tutorial.

When you go to install mod_wsgi (which you should not do first) please search for CentOS and mod_wsgi. Search is an important skill.

Problem with Django setup using mod_wsgi and apache on centos 5.4

http://library.linode.com/frameworks/django-apache-mod-wsgi/centos-5

And upgrades are permitted. Don't ask for permission. Search for relevant issues.

Sign up to request clarification or add additional context in comments.

2 Comments

Thanks buddy i will do that. i have done the first step of learning Python , now i will go for Django. Thanks for ur guidance
Learning Python is not a mission could be done in 24 hours, I guess.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.