[Qgis-developer] Fail to load Rmanage plugin

Otto Dassau dassau at gbd-consult.de
Thu Dec 8 07:01:03 EST 2011


Hi,

ok, first problem was that libR.so is not found - thanks Joona for that
hint. Now I have probably the problem you described with incompatible version
of libgfortran. I guess, this the error you also got. Could you have a
look to find the details about that again, please?

Carson: apart from that the R-base package is build with the
--enable-R-shlib flag.

>>> from rpy2 import robjects
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "/usr/share/qgis/python/qgis/utils.py", line 283, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "/usr/lib64/python2.7/site-packages/rpy2/robjects/__init__.py", line
14, in <module> import rpy2.rinterface as rinterface
  File "/usr/share/qgis/python/qgis/utils.py", line 283, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "/usr/lib64/python2.7/site-packages/rpy2/rinterface/__init__.py",
line 75, in <module> from rpy2.rinterface.rinterface import *
  File "/usr/share/qgis/python/qgis/utils.py", line 283, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
ImportError: /usr/lib64/R/lib/libRlapack.so: undefined symbol:
_gfortran_concat_string

Regards
Otto

Am Fri, 25 Nov 2011 12:02:48 +0000
schrieb Carson Farmer <carson.farmer at gmail.com>:

> Hi Otto,
> 
> I think Joona's directions should get you going... I suspect that the
> packged version of R for OpenSUSE isn't built with the
> --enable-R-shlib flag, so it can't be used as a shared library.
> Building from source should sort this out. If not, please do let me
> know, and hopefully we can try to figure out something else.
> 
> Carson
> 
> On Fri, Nov 25, 2011 at 8:47 AM, Joona Lehtomäki
> <joona.lehtomaki at cs.helsinki.fi> wrote:
> > Hi Otto,
> >
> > While not exactly the same, your problem sounds related to problems I've
> > had with rpy2, QGIS and ManageR on openSUSE 11.4 64-bit.
> >
> > At least at some point libRlapack.so shipping with R-base RPM for
> > openSUSE 11.4 (and at least 11.2 and 11.3 before that) was built with
> > incompatible version of libgfortran. I managed to find the details once,
> > but didn't find them again, sorry.
> >
> > I got everything working on openSUSE 11.4 (64 bit), but this required
> > building R from source. You can try the following (or at least steps 2
> > and 3 if rpy2 just doesn't find your libR):
> >
> > 1. build R (2.14.0) from sources with --prefix=/usr and --enable-R-shlib
> > and flags
> >
> > 2. try "from rpy2 import robjects". If you get an import error with
> > "libR.so not found", add a file R-x86_64.conf into /etc/ld.so.conf with
> > a single line:
> >
> > /usr/lib64/R/lib (or where ever your libR is located)
> >
> > 3. run ldconfig as root
> >
> > 4. Install rpy2 (2.2.4) with pip (or easy_install)
> >
> > Hope this helps,
> >
> > Joona
> >
> > On 25.11.2011 10:21, Otto Dassau wrote:
> >>
> >> Hi Carson,
> >>
> >> I would like to get your RManage plugin working but after loading rpy2
> >> it fails to load the rpy2.robjects module. Maybe you have a quick help
> >> for me,
> >> how to solve this?
> >>
> >> I work on opensuse 11.4 64bit with python 2.7, qgis 1.7.2 and R 2.14.0.
> >>
> >>>>> import rpy2.robjects as robjects
> >>
> >> Traceback (most recent call last):
> >>   File "<stdin>", line 1, in<module>
> >>   File "/usr/lib64/python2.7/site-packages/rpy2/robjects/__init__.py",
> >> line
> >> 14, in<module>  import rpy2.rinterface as rinterface
> >>   File "/usr/lib64/python2.7/site-packages/rpy2/rinterface/__init__.py",
> >> line 75, in<module>  from rpy2.rinterface.rinterface import *
> >> ImportError: libR.so: cannot open shared object file: No such file or
> >> directory
> >>
> >> Thanks a lot
> >> Otto
> >> _______________________________________________
> >> Qgis-developer mailing list
> >> Qgis-developer at lists.osgeo.org
> >> http://lists.osgeo.org/mailman/listinfo/qgis-developer
> >
> > _______________________________________________
> > Qgis-developer mailing list
> > Qgis-developer at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/qgis-developer



More information about the Qgis-developer mailing list