Re: [R] RSPerl

About this list Date view Thread view Subject view Author view Attachment view

From: Duncan Temple Lang (
Date: Fri 19 Dec 2003 - 00:00:05 EST

Message-id: <>

Hi Andrea.

   When we run Perl from within R, any Perl module that has associated
C code (such as modperl) needs a special piece of bootstrapping code
to be used within this embedded case. Now in your case, you might
only be calling R from within Perl, but neverthless, we put this
bootstrapping code in as one can call Perl from within the embedded R
because it is bidirectional.

  The modperl module is for running Perl embedded within the Apache
Web server. So you don't need this for running R in Perl as a
stand-alone. So we need to tell the RSPerl package not to include
bootstrapping code for modperl (and other modules that cause problems
in this way).

  To create this bootstrapping code for Perl modules with C code, the
installation script for RSPerl looks through all the Perl modules and
finds the ones that have C code (i.e. an associated shared library).
In this case, you need to tell the RSPerl installation explicitly
which modules to provide the boostrapping code. The easiest
way for me to describe is the following.

  unzip and untar the RSPerl.tar.gz file

  cd RSPerl

  Run the command
     perl -s -modules
  to get a list of all the modules with C code.

  Take this list and set the environment variable

   to the subset of these module names that you actually need/want.
  In your case, just remove modperl.
  You might do someting like

    setenv PERL_MODULES "`perl -s -modules | sed s/modperl//`"

   (if you are using the csh or tcsh shell. Use export for bash/sh.)

   You can eliminate any of the modules that cause problems using this

   Hope this helps.


Andrea wrote:
> If anyone can help it would be very much apreciated...
> System RedHat 9
> R installed as
> # ./configure --enable-R-shlib
> # make
> # make install
> and R seems to work fine ...
> Then I do
> # R INSTALL --clean --configure-args='--with-in-perl'
> RSPerl_0.5-7.tar.gz
> # export R_HOME=/usr/local/lib/R
> # cd /usr/local/lib/R/library/RSPerl/examples/
> # perl -I /usr/local/lib/R/library/RSPerl/share/blib/arch -I
> /usr/local/lib/R/library/RSPerl/share/blib/lib ./
> and I get
> 1..1
> Can't load '/usr/local/lib/R/library/RSPerl/share/blib/arch/auto/R/'
> for module R:
> /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi/auto/ModPerl/Global/ undefined symbol: modperl_perl_global_avcv_call at /usr/lib/perl5/5.8.0/i386-linux-thread-multi/ line 229.
> at ./ line 11
> Compilation failed in require at ./ line 11.
> BEGIN failed--compilation aborted at ./ line 11.
> not ok 1
> and I get completelly lost ...
> Thanks in advance for your help
> Andrea
> ______________________________________________
> mailing list


Duncan Temple Lang Bell Labs, Lucent Technologies office: (908)582-3217 700 Mountain Avenue, Room 2C-259 fax: (908)582-3340 Murray Hill, NJ 07974-2070

______________________________________________ mailing list

About this list Date view Thread view Subject view Author view Attachment view

This archive was generated by hypermail 2.1.3 : Thu 01 Jan 2004 - 09:20:58 EST