0

I'm experiencing a few issues trying to install rpy2-2.3.7 under Cygwin64 on Windows7 using R 3.0.1 and python 2.7

$ python setup.py install

finds R version to be 3.0.1 at the beginning of the install, but on line 158 it bombs out for failing to discover the R version. I commented that else clause out and let it roll, getting the following pile of errors. Any suggestions would be greatly appreciated.

running install
running build
running build_py
running build_ext
R version 3.0.1 (2013-05-16) -- "Good Sport"
Copyright (C) 2013 The R Foundation for Statistical Computing
Platform: i386-w64-mingw32/i386 (32-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under the terms of the
GNU General Public License versions 2 or 3.
For more information about these matters see
http://www.gnu.org/licenses/.

"\Programs\R\R-3.0.1/bin/R" CMD config --ldflags
"\Programs\R\R-3.0.1/bin/R" CMD config --cppflags
"\Programs\R\R-3.0.1/bin/R" CMD config LAPACK_LIBS

returned an empty string.

"\Programs\R\R-3.0.1/bin/R" CMD config BLAS_LIBS

returned an empty string.

Configuration for R as a library:
  include_dirs: ('D:/Programs/R/R-3.0.1/include/i386', 'D:/Programs/R/R-3.0.1/include')
  libraries: ('R',)
  library_dirs: ('D:/Programs/R/R-3.0.1/bin/i386',)
  extra_link_args: ()
 # OSX-specific (included in extra_link_args)
  framework_dirs: ()
  frameworks: ()
building 'rpy2.rinterface._rinterface' extension
gcc -fno-strict-aliasing -ggdb -O2 -pipe -fdebug-prefix-map=/usr/src/ports/python/python-2.7.5-2/build=/usr/src/debuon/python-2.7.5-2/src/Python-2.7.5=/usr/src/debug/python-2.7.5-2 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -GHAND=1 -DCSTACK_DEFNS=1 -DHAS_READLINE=1 -I./rpy/rinterface -I/usr/include/python2.7 -ID:/Programs/R/R-3.0.1/includace/_rinterface.c -o build/temp.cygwin-1.7.25-x86_64-2.7/./rpy/rinterface/_rinterface.o
In file included from D:/Programs/R/R-3.0.1/include/R.h:34:0,
                 from ./rpy/rinterface/_rinterface.h:8,
                 from ./rpy/rinterface/_rinterface.c:58:
D:/Programs/R/R-3.0.1/include/Rconfig.h:22:0: warning: "SIZEOF_SIZE_T" redefined [enabled by default]
 #define SIZEOF_SIZE_T 4
 ^
In file included from /usr/include/python2.7/Python.h:8:0,
                 from ./rpy/rinterface/_rinterface.c:55:
/usr/include/python2.7/pyconfig.h:1025:0: note: this is the location of the previous definition
 #define SIZEOF_SIZE_T 8
 ^
In file included from D:/Programs/R/R-3.0.1/include/R.h:40:0,
                 from ./rpy/rinterface/_rinterface.h:8,
                 from ./rpy/rinterface/_rinterface.c:58:
D:/Programs/R/R-3.0.1/include/R_ext/Memory.h:40:1: warning: function declaration isn’t a prototype [-Wstrict-prototy
 int R_gc_running();
 ^
In file included from ./rpy/rinterface/_rinterface.h:9:0,
                 from ./rpy/rinterface/_rinterface.c:58:
D:/Programs/R/R-3.0.1/include/Rinternals.h:719:1: warning: function declaration isn’t a prototype [-Wstrict-prototyp
 const char *R_curErrorBuf();
 ^
In file included from ./rpy/rinterface/_rinterface.c:80:0:
D:/Programs/R/R-3.0.1/include/R_ext/Rdynload.h:32:1: warning: function declaration isn’t a prototype [-Wstrict-proto
 typedef void * (*DL_FUNC)();
 ^
In file included from ./rpy/rinterface/_rinterface.c:125:0:
./rpy/rinterface/na_values.c:209:9: error: initializer element is not constant
         &PyLong_Type,           /*tp_base*/
         ^
./rpy/rinterface/na_values.c:209:9: error: (near initialization for ‘NAInteger_Type.tp_base’)
./rpy/rinterface/na_values.c:407:9: error: initializer element is not constant
         &PyLong_Type,             /*tp_base*/
         ^
./rpy/rinterface/na_values.c:407:9: error: (near initialization for ‘NALogical_Type.tp_base’)
./rpy/rinterface/na_values.c:593:9: error: initializer element is not constant
         &PyFloat_Type,             /*tp_base*/
         ^
./rpy/rinterface/na_values.c:593:9: error: (near initialization for ‘NAReal_Type.tp_base’)
./rpy/rinterface/na_values.c:695:9: error: initializer element is not constant
         &PyString_Type,             /*tp_base*/
         ^
./rpy/rinterface/na_values.c:695:9: error: (near initialization for ‘NACharacter_Type.tp_base’)
./rpy/rinterface/na_values.c:862:9: error: initializer element is not constant
         &PyComplex_Type,             /*tp_base*/
         ^
./rpy/rinterface/na_values.c:862:9: error: (near initialization for ‘NAComplex_Type.tp_base’)
In file included from ./rpy/rinterface/_rinterface.c:126:0:
./rpy/rinterface/sexp.c: In function ‘Sexp_rclass_set’:
./rpy/rinterface/sexp.c:369:5: warning: return makes integer from pointer without a cast [enabled by default]
     return NULL;
     ^
./rpy/rinterface/sexp.c: In function ‘Sexp_init’:
./rpy/rinterface/sexp.c:711:13: warning: unused variable ‘copy’ [-Wunused-variable]
   PyObject *copy = Py_True;
             ^
./rpy/rinterface/_rinterface.c: In function ‘EmbeddedR_CleanUp’:
./rpy/rinterface/_rinterface.c:954:7: warning: implicit declaration of function ‘jump_to_toplevel’ [-Wimplicit-funct
       jump_to_toplevel();
       ^
./rpy/rinterface/_rinterface.c:975:9: error: ‘R_Interactive’ undeclared (first use in this function)
     if (R_Interactive) {
         ^
./rpy/rinterface/_rinterface.c:975:9: note: each undeclared identifier is reported only once for each function it ap
./rpy/rinterface/_rinterface.c: In function ‘EmbeddedR_init’:
./rpy/rinterface/_rinterface.c:1229:3: error: ‘R_SignalHandlers’ undeclared (first use in this function)
   R_SignalHandlers = 0;
   ^
./rpy/rinterface/_rinterface.c:1239:3: error: ‘R_Interactive’ undeclared (first use in this function)
   R_Interactive = TRUE;
   ^
./rpy/rinterface/_rinterface.c:1247:3: error: ‘ptr_R_CleanUp’ undeclared (first use in this function)
   ptr_R_CleanUp = EmbeddedR_CleanUp;
   ^
./rpy/rinterface/_rinterface.c:1249:3: error: ‘ptr_R_ShowMessage’ undeclared (first use in this function)
   ptr_R_ShowMessage = EmbeddedR_ShowMessage;
   ^
./rpy/rinterface/_rinterface.c:1250:3: error: ‘ptr_R_WriteConsole’ undeclared (first use in this function)
   ptr_R_WriteConsole = EmbeddedR_WriteConsole;
   ^
./rpy/rinterface/_rinterface.c:1251:3: error: ‘ptr_R_FlushConsole’ undeclared (first use in this function)
   ptr_R_FlushConsole = EmbeddedR_FlushConsole;
   ^
./rpy/rinterface/_rinterface.c:1252:3: error: ‘R_Outputfile’ undeclared (first use in this function)
   R_Outputfile = NULL;
   ^
./rpy/rinterface/_rinterface.c:1253:3: error: ‘R_Consolefile’ undeclared (first use in this function)
   R_Consolefile = NULL;
   ^
./rpy/rinterface/_rinterface.c:1255:3: error: ‘ptr_R_ReadConsole’ undeclared (first use in this function)
   ptr_R_ReadConsole = EmbeddedR_ReadConsole;
   ^
./rpy/rinterface/_rinterface.c:1256:3: error: ‘ptr_R_ChooseFile’ undeclared (first use in this function)
   ptr_R_ChooseFile = EmbeddedR_ChooseFile;
   ^
./rpy/rinterface/_rinterface.c:1257:3: error: ‘ptr_R_ShowFiles’ undeclared (first use in this function)
   ptr_R_ShowFiles = EmbeddedR_ShowFiles;
   ^
./rpy/rinterface/_rinterface.c:1263:3: error: ‘R_CStackLimit’ undeclared (first use in this function)
   R_CStackLimit = (uintptr_t) -1;
   ^
./rpy/rinterface/_rinterface.c:1334:26: error: ‘rl_completer_word_break_characters’ undeclared (first use in this fu
   rl_completer = strndup(rl_completer_word_break_characters, 200);
                          ^
./rpy/rinterface/_rinterface.c:1337:22: error: ‘rl_basic_word_break_characters’ undeclared (first use in this functi
   rl_basic = strndup(rl_basic_word_break_characters, 200);
                      ^
./rpy/rinterface/_rinterface.c: In function ‘EmbeddedR_setinteractive’:
./rpy/rinterface/_rinterface.c:1422:3: error: ‘R_Interactive’ undeclared (first use in this function)
   R_Interactive = rtruefalse;
   ^
In file included from ./rpy/rinterface/_rinterface.c:105:0:
./rpy/rinterface/_rinterface.c: At top level:
./rpy/rinterface/embeddedr.h:20:20: warning: ‘_Rpy_PreserveObject’ declared ‘static’ but never defined [-Wunused-fun
 static SexpObject* _Rpy_PreserveObject(SEXP object);
                    ^
In file included from ./rpy/rinterface/_rinterface.c:130:0:
./rpy/rinterface/sequence.c:2190:1: warning: ‘ComplexVectorSexp_AsSexp’ defined but not used [-Wunused-function]
 ComplexVectorSexp_AsSexp(PyObject *pyfloat) {
 ^
error: command 'gcc' failed with exit status 1

Edited by pyTony: carefull with formatting!

2
Contributors
1
Reply
53
Views
3 Years
Discussion Span
Last Post by Gribouillis
0

May I suggest virtualbox + linux ? (just installed rpy2 in one click in linux mint kde)

Edited by Gribouillis

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.