2017-05-24 11 views
0

Ubuntu 16.04 LTS ppc64le(IBM POWER8)にgpuRをインストールしようとしていますが、 "vector 'がタイプしないというエラーが発生しました。UbuntuにgpuRをインストールする際に問題が発生しましたppc64le

あなたは私を助けてくれますか?どんなコメントでも大歓迎です。

> install.packages("gpuR") 
Installing package into ‘/usr/local/lib/R/site-library’ 
(as ‘lib’ is unspecified) 
trying URL 'https://ftp.iitm.ac.in/cran/src/contrib/gpuR_1.2.1.tar.gz' 
Content type 'application/x-gzip' length 451127 bytes (440 KB) 
================================================== 
downloaded 440 KB 

... 

** package ‘gpuR’ successfully unpacked and MD5 sums checked 
OPENCL_FLAGS not set, using default -DCL_HPP_MINIMUM_OPENCL_VERSION=110 - 
DCL_USE_DEPRECATED_OPENCL_1_2_APIS -DCL_HPP_TARGET_OPENCL_VERSION=120 
Linux OS 
found OpenCL library 
Checking OpenCL C++ API 
OPENCL_INC not set, using default include directory /usr/include 
No OpenCL C++ API found, will use the headers contained in the package 

*********** Generated Makevars file *********** 
CXX_STD=CXX11 
PKG_CPPFLAGS=-I../inst/include -DCL_HPP_MINIMUM_OPENCL_VERSION=110 - 
DCL_USE_DEPRECATED_OPENCL_1_2_APIS -DCL_HPP_TARGET_OPENCL_VERSION=120 - 
I'/usr/include/' -I. -pthread 
PKG_CXXFLAGS= 
PKG_LIBS=-lOpenCL 
BUILD_LIB= 

$(SHLIB): $(BUILD_LIB) 

../inst/include/loader/libOpenCL.a: 
     cd ../inst/include/loader/ && $(MAKE) libOpenCL.a \ 
     CC="$(CC)" CFLAGS="$(ALL_CFLAGS)" AR="$(AR)" RM="$(RM)" \ 
     ICD_OS=icd_linux 
*********************************************** 
** libs 
g++ -std=c++11 -I/usr/share/R/include -DNDEBUG -I../inst/include - 
DCL_HPP_MINIMUM_OPENCL_VERSION=110 -DCL_USE_DEPRECATED_OPENCL_1_2_APIS - 
DCL_HPP_TARGET_OPENCL_VERSION=120 -I'/usr/include/' -I. -pthread - 
I"/usr/local/lib/R/site-library/Rcpp/include" -I"/usr/local/lib/R/site- 
library/RcppEigen/include" -I"/usr/local/lib/R/site- 
library/RViennaCL/include" -I"/usr/local/lib/R/site-library/BH/include" - 
fPIC -g -O3 -fstack-protector-strong -Wformat -Werror=format-security - 
Wdate-time -D_FORTIFY_SOURCE=2 -g -c RcppExports.cpp -o RcppExports.o 
g++ -std=c++11 -I/usr/share/R/include -DNDEBUG -I../inst/include - 
DCL_HPP_MINIMUM_OPENCL_VERSION=110 -DCL_USE_DEPRECATED_OPENCL_1_2_APIS - 
DCL_HPP_TARGET_OPENCL_VERSION=120 -I'/usr/include/' -I. -pthread - 
I"/usr/local/lib/R/site-library/Rcpp/include" -I"/usr/local/lib/R/site- 
library/RcppEigen/include" -I"/usr/local/lib/R/site- 
library/RViennaCL/include" -I"/usr/local/lib/R/site-library/BH/include" - 
fPIC -g -O3 -fstack-protector-strong -Wformat -Werror=format-security - 
Wdate-time -D_FORTIFY_SOURCE=2 -g -c chol.cpp -o chol.o 
In file included from ../inst/include/CL/cl.h:35:0, 
       from /usr/local/lib/R/site- 
library/RViennaCL/include/viennacl/ocl/context.hpp:28, 
       from /usr/local/lib/R/site- 
library/RViennaCL/include/viennacl/ocl/backend.hpp:26, 
       from chol.cpp:5: 
../inst/include/CL/cl_platform.h:390:12: error: ‘vector’ does not name a 
type 
    typedef vector unsigned char  __cl_uchar16; 
      ^
../inst/include/CL/cl_platform.h:391:12: error: ‘vector’ does not name a 
type 
typedef vector signed char  __cl_char16; 
      ^
../inst/include/CL/cl_platform.h:392:12: error: ‘vector’ does not name a 
type 
    typedef vector unsigned short __cl_ushort8; 
      ^
../inst/include/CL/cl_platform.h:393:12: error: ‘vector’ does not name a 
type 
    typedef vector signed short  __cl_short8; 

... 

../inst/include/CL/cl_platform.h:1214:5: error: ‘__cl_float4’ does not name 
a type 
    __cl_float4  v4[4]; 
    ^
/usr/lib/R/etc/Makeconf:143: recipe for target 'chol.o' failed 
make: *** [chol.o] Error 1 
ERROR: compilation failed for package ‘gpuR’ 
* removing ‘/usr/local/lib/R/site-library/gpuR’ 

The downloaded source packages are in 
     ‘/tmp/RtmpGoy6Af/downloaded_packages’ 
Warning message: 
In install.packages("gpuR") : 
    installation of package ‘gpuR’ had non-zero exit status 
+0

[gpuR GitHub](https://github.com/cdeterman/gpuR)をチェックアウトしていない場合は、この問題をここで確認してください。 – steveb

+0

ありがとうございます。私はそこにも投稿します。 – nasica88

答えて

0

gpuR_1.2.1.tar.gzに含まれているcl_platform.hを修正することで、この問題を解決しました。私は単に以下の "typedef vector"を "typedef __vector"に変更しました。

[email protected]:~$ wget 
https://cran.revolutionanalytics.com/src/contrib/gpuR_1.2.1.tar.gz 

[email protected]:~$ tar -zxvf gpuR_1.2.1.tar.gz 

[email protected]:~$ cd gpuR/inst/include/CL 

[email protected]:~/gpuR/inst/include/CL$ vi cl_platform.h 

    #include <altivec.h> /* may be omitted depending on compiler. AltiVec spec provides no way to detect whether the header is required. */ 
    typedef vector unsigned char  __cl_uchar16; 
    typedef vector signed char  __cl_char16; 
    typedef vector unsigned short __cl_ushort8; 
    typedef vector signed short  __cl_short8; 
    typedef vector unsigned int  __cl_uint4; 
    typedef vector signed int  __cl_int4; 
    typedef vector float    __cl_float4; 
+0

私はgpuRの所有者から回答を得ました。 Plsはhttps://github.com/cdeterman/gpuR/issues/81を参照してください – nasica88

関連する問題