wolpert at stat.duke.edu
2008-Apr-13 17:20 UTC
[Rd] Incorrect @INC: Rcmd SHLIB error under Windows (2.6.2, 44383) (PR#11161)
Hi, R team. I'm trying to build a dll from a c program to be invoked within R using the .C() functionality. Everything works like a charm on my Linux (Centos 5) (also 2.6.2) machines--- but under windows (Vista Ultimate) upon running (in either the windows 'Cmd' command window or a Bash window) the command Rcmd SHLIB myfun.c I receive the error: Can't locate R/Utils.pm in @INC (@INC contains: c \PROGRA~1\R\R-26~1.2\share\perl; /usr/lib/perl5/5.8/cygwin /usr/lib/perl5/5.8 /usr/lib/perl5/site_perl/5.8/cygwin /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8/cygwin /usr/lib/perl5/vendor_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .) at c:\PROGRA~1\R\R-26~1.2/bin/SHLIB line 22. BEGIN failed--compilation aborted at c:\PROGRA~1\R\R-26~1.2/bin/SHLIB line 22. -------------- -------------- -------------- -------------- -------------- Notice the first entry in @INC is incorrect--- the item c \PROGRA~1\R\R-26~1.2\share\perl; SHOULD be c:\PROGRA~1\R\R-26~1.2\share\perl; but a space appears where the colon should be. The neeeded file 'R/Utils.pm' is in fact located where it should be, below 'c:\PROGRA~1\R\R-26~1.2\share\perl', but perl can't find it because INC is set incorrectly. Any suggestions? Where IS 'INC' set? Cheers, -R ---------------------------------------------------------------------- Prof. Robert L. Wolpert : <wolpert at stat.Duke.edu> : +1-919-684-3275 Duke Univ. Dept. of Statistical Science : 211c Old Chem, Box 90251 & Nicholas School of the Environment : www.stat.Duke.edu/~rlw/
Mathieu Ribatet
2008-Apr-14 07:00 UTC
[Rd] Incorrect @INC: Rcmd SHLIB error under Windows (2.6.2, 44383) (PR#11161)
Has your environment variable path been set correctly? It's been a while that I'm not using R under windows but remember had experienced the same error. I remember that I had to put many paths as environment variable to build R packages properly. Best, Mathieu wolpert at stat.duke.edu a ?crit :> Hi, R team. > > I'm trying to build a dll from a c program to be invoked within R using > the .C() functionality. > > Everything works like a charm on my Linux (Centos 5) (also 2.6.2) machines--- > but under windows (Vista Ultimate) upon running (in either the windows 'Cmd' > command window or a Bash window) the command > > Rcmd SHLIB myfun.c > > I receive the error: > > Can't locate R/Utils.pm in > @INC (@INC contains: c \PROGRA~1\R\R-26~1.2\share\perl; > /usr/lib/perl5/5.8/cygwin /usr/lib/perl5/5.8 > /usr/lib/perl5/site_perl/5.8/cygwin /usr/lib/perl5/site_perl/5.8 > /usr/lib/perl5/site_perl/5.8 /usr/lib/perl5/vendor_perl/5.8/cygwin > /usr/lib/perl5/vendor_perl/5.8 /usr/lib/perl5/vendor_perl/5.8 .) at > c:\PROGRA~1\R\R-26~1.2/bin/SHLIB line 22. > BEGIN failed--compilation aborted at c:\PROGRA~1\R\R-26~1.2/bin/SHLIB line > 22. > > -------------- -------------- -------------- -------------- -------------- > > Notice the first entry in @INC is incorrect--- the item > > c \PROGRA~1\R\R-26~1.2\share\perl; > > SHOULD be > > c:\PROGRA~1\R\R-26~1.2\share\perl; > > but a space appears where the colon should be. > > The neeeded file 'R/Utils.pm' is in fact located where it should be, > below 'c:\PROGRA~1\R\R-26~1.2\share\perl', but perl can't find it because > INC is set incorrectly. > > Any suggestions? Where IS 'INC' set? Cheers, -R > > ---------------------------------------------------------------------- > Prof. Robert L. Wolpert : <wolpert at stat.Duke.edu> : +1-919-684-3275 > Duke Univ. Dept. of Statistical Science : 211c Old Chem, Box 90251 > & Nicholas School of the Environment : www.stat.Duke.edu/~rlw/ > > ______________________________________________ > R-devel at r-project.org mailing list > https://stat.ethz.ch/mailman/listinfo/r-devel >-- Institute of Mathematics Ecole Polytechnique F?d?rale de Lausanne STAT-IMA-FSB-EPFL, Station 8 CH-1015 Lausanne Switzerland http://stat.epfl.ch/ Tel: + 41 (0)21 693 7907