fatal error: 'R.h' file not found during build on OS X 10.9.2 using python 2.7.6

Issue #201 wontfix
Shantanu Joshi
created an issue

rpy2 fails to build on OS X 10.9 (Mavericks) via pip and easy_install.

The following error is produced:

In file included from ./rpy/rinterface/_rinterface.c:58:
./rpy/rinterface/_rinterface.h:8:10: fatal error: 'R.h' file not found

include <R.h>

     ^

1 error generated.

The same error is produced even if I download source rpy2-2.4.0.tar.gz and do
python setup.py install

Comments (6)

  1. Rosa CatalĂ 

    I have the same error Shantanu gets in W8 with R-3.1.0, using pip install and the local .tar.gz file I download..., but not in Mavericks with same R base version using pip install. (Note: in W8 I have a proxy and that is why I use local module.)

  2. Laurent Gautier

    @Rosa_CA The issue with Windows has existed for a long time: the R binary installer stopped shipping with the necessary C headers. I am quite unsure about why, but more info about how to get these headers are somewhere on the R site, or on R-related documentation.

  3. Laurent Gautier

    @ShantanuJoshi rpy2-2.4.0 is targeting R-3.1.0. While it should also work with R-3.0.x, it becomes less tested (and less likely to function properly) with older versions (no way with R < 2.8, IIRC).

  4. Laurent Gautier

    Thanks for the report.

    Unfortunately, our resources are too limited to fix issues present when wanting to use older versions or R.

    I am marking this as "won't fix". Pull requests would be reviewed if anyone want to propose one.

  5. Log in to comment