R包RGL无法在带有MRAN的Mac上安装

时间:2017-08-16 18:09:52

标签: r rgl

我试图安装rgl,因为另一个包需要它的一些元素。我在Mac上运行XQuartz,因为我使用的是MRAN R.安装(来自Rstudio中的CRAN,来自Rstudio中的shell和其他来源)失败,并出现以下错误。

    clang-omp++ -fopenmp -I/Library/Frameworks/R.framework/Resources/include -DNDEBUG -I/System/Library/Frameworks/OpenGL.framework/Headers  -DHAVE_PNG_H -I/Users/gcn/anaconda/include/libpng16 -I/usr/X11/include -DDarwin -DNO_GL_PREFIX -I/opt/X11/include -DHAVE_FREETYPE -Iext/ftgl -I/opt/X11/include/freetype2 -Iext  -I/Users/Shared/Jenkins/workspace/External-R-3.3.3/vendor/build/include -DU_STATIC_IMPLEMENTATION -Wall -mtune=core2 -g -O2 -I/opt/X11/include   -fPIC  -g -O3 -Wall -pedantic -mtune=native -std=c++11 -c platform.cpp -o platform.o
platform.cpp:38:18: error: no member named 'x' in '_GLKVector3'
      *winX = result.x;
              ~~~~~~ ^
    platform.cpp:39:18: error: no member named 'y' in '_GLKVector3'
      *winY = result.y;
              ~~~~~~ ^
    platform.cpp:40:18: error: no member named 'z' in '_GLKVector3'
      *winZ = result.z;
              ~~~~~~ ^
    platform.cpp:64:18: error: no member named 'x' in '_GLKVector3'
      *objX = result.x;
              ~~~~~~ ^
    platform.cpp:65:18: error: no member named 'y' in '_GLKVector3'
      *objY = result.y;
              ~~~~~~ ^
    platform.cpp:66:18: error: no member named 'z' in '_GLKVector3'
      *objZ = result.z;

我还在AWS上的ubuntu实例中运行了一个Rstudio版本,安装时我没有遇到这些错误。 ubuntu没有使用MRAN所以我想这可能是mac上问题的根源,但是来自Microsoft的这个页面 - https://mran.microsoft.com/web/checks/check_results_rgl.html似乎暗示rgl确实在mac上运行MRAN。

1 个答案:

答案 0 :(得分:1)

您似乎有编译器定义__STRICT_ANSI__集。通常rgl没有设置它。 R-forge(0.98.13)上的rgl的最新版本在platform.cpp文件中修复了这个问题,你看到了错误,但可能还有其他地方出现问题。

您可以在R-forge上获得最新版本。它不适用于CRAN(或MRAN)。

相关问题