> On 9 Nov 2015, at 11:40 pm, Aleksandra Tarkowska
> <[email protected]> wrote:
>
> Hello, I have been trying to run Django app that requires IcePy on Apache
> with mod_wsgi on CentOS 6 using SCL Python.
>
> I recompiled Ice manually, then mod_wsgi plugin without any issues. In order
> to import Ice I need to set LD_LIBRARY_PATH. From
> https://stackoverflow.com/questions/2550504/setting-ld-library-path-in-apache-passenv-setenv-still-cant-find-library
> looks like SetEnv works per request, so the process is already running when
> setting LD_LIBRARY_PATH. This is equivalent to setting it in python itself,
> which is too late. How should I set LD_LIBRARY_PATH to avoid
>
>
> File "/opt/Ice-3.5.1/python/Ice.py", line 47, in <module>
> import IcePy
> ImportError: libIce.so.35: cannot open shared object file: No such file or
> directory
You should rebuild IcePy from scratch.
This time when you install it, set the LD_RUN_PATH environment variable to be
the directory in which the libIce.so library is located.
That is, if pip installed, use:
LD_RUN_PATH=/some/path/to/library/directory pip install IcePy
Doing this will result in the directory containing the libIce library being
encoded into the IcePy extension module. In doing this, you will not need to
set LD_LIBRARY_PATH at run time for anything trying to use the module.
This is the easiest thing to do.
Graham
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/modwsgi.
For more options, visit https://groups.google.com/d/optout.