mod_wsgi symbol not found

36 views
Skip to first unread message

S.P.

unread,
May 12, 2009, 4:31:20 PM5/12/09
to modwsgi
I'm getting the following error with apachectl configtest:

httpd: Syntax error on line 115 of /private/etc/apache2/httpd.conf:
Cannot load /usr/libexec/apache2/mod_wsgi.so into server: dlopen(/usr/
libexec/apache2/mod_wsgi.so, 10): Symbol not found: _PyExc_RuntimeError
\n Referenced from: /usr/libexec/apache2/mod_wsgi.so\n Expected in:
dynamic lookup\n

The only reference I can find to this specific error is a bit old
(http://www.modpython.org/pipermail/mod_python/2007-October/
024394.html), and experimenting with the Makefile suggestions therein
hasn't yielded success yet.

I'm on OS X Leopard, using mod_wsgi 2.5 and python 2.6 (installed with
the MacPython installer). Any suggestions about where to look next
would be greatly appreciated.

Graham Dumpleton

unread,
May 12, 2009, 6:05:53 PM5/12/09
to mod...@googlegroups.com
2009/5/13 S.P. <spak...@gmail.com>:

Edit generated Makefile in mod_wsgi source code after having run configure.

Look for LDFLAGS, eg:

LDFLAGS = -F/usr/local/python-3.1-dev/frameworks .....

Add '-Wl,' in front of '-F' option to yield:

LDFLAGS = -Wl,-F/usr/local/python-3.1-dev/frameworks .....

That or edit configure.ac and look for:

LDFLAGS1="-F${PYTHONFRAMEWORKPREFIX} -framework ${PYTHONFRAMEWORK}"

and change it to:

LDFLAGS1="-Wl,-F${PYTHONFRAMEWORKPREFIX} -framework ${PYTHONFRAMEWORK}"

Then run 'autoconf' in that directory and then run 'configure' again.

That restores line back to what it was for mod_wsgi 2.3 again. When
some other lines related to '-Wl,' were commented out due it breaking
Linux platforms, that should have been restored.

Is a chance now this will stop working again for MacPorts and/or Apache 2.3.

Graham

Reply all
Reply to author
Forward
0 new messages