wush978 / FeatureHashing

Implement feature hashing with R
GNU General Public License v3.0
97 stars 38 forks source link

Failed to install under CentOS release 6.5 #112

Closed mpearmain closed 9 years ago

mpearmain commented 9 years ago

Trying to install on CentOS, get failures.

devtools::install_github('wush978/FeatureHashing') Downloading GitHub repo wush978/FeatureHashing@master Installing FeatureHashing '/usr/lib64/R/bin/R' --no-site-file --no-environ --no-save --no-restore CMD INSTALL \ '/tmp/Rtmpd5ZsJ0/devtools625db76021a/wush978-FeatureHashing-f97b03f' \ --library='/home/michael.pearmain/R_libs' --install-tests

  • installing source package ‘FeatureHashing’ ... \ libs g++ -m64 -std=c++0x -I/usr/include/R -DNDEBUG -I/usr/local/include -I"/home/michael.pearmain/R_libs/Rcpp/include" -I"/home/michael.pearmain/R_libs/digest/include" -I"/home/michael.pearmain/R_libs/BH/include" -fpic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -c RcppExports.cpp -o RcppExports.o

g++ -m64 -std=c++0x -I/usr/include/R -DNDEBUG -I/usr/local/include -I"/home/michael.pearmain/R_libs/Rcpp/include" -I"/home/michael.pearmain/R_libs/digest/include" -I"/home/michael.pearmain/R_libs/BH/include" -fpic -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -c as.cpp -o as.o

as.cpp: In function ‘void pairsort(int, double_, size_t)’: as.cpp:26: error: expected primary-expression before ‘[’ token as.cpp:26: error: expected primary-expression before ‘]’ token as.cpp:26: error: expected primary-expression before ‘a’ as.cpp:26: error: expected primary-expression before ‘b’ as.cpp: In function ‘sizet merge(int, double_, size_t)’: as.cpp:50: warning: comparison between signed and unsigned integer expressions as.cpp:57: warning: comparison between signed and unsigned integer expressions

make: *\ [as.o] Error 1

ERROR: compilation failed for package ‘FeatureHashing’

sessionInfo() R version 3.2.1 (2015-06-18) Platform: x86_64-redhat-linux-gnu (64-bit) Running under: CentOS release 6.5 (Final)

locale: [1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8
[4] LC_COLLATE=en_US.UTF-8 LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=en_US.UTF-8 LC_NAME=C LC_ADDRESS=C
[10] LC_TELEPHONE=C LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages: [1] stats graphics grDevices utils datasets methods base

loaded via a namespace (and not attached): [1] httr_1.0.0 R6_2.1.1 magrittr_1.5 tools_3.2.1 curl_0.9.3 memoise_0.2.1 [7] stringi_0.5-5 stringr_1.0.0 digest_0.6.8 devtools_1.9.1

wush978 commented 9 years ago

FeatureHashing requires c++11, so updating gcc should resolve this issue.

mpearmain commented 9 years ago

Upgraded to gcc (GCC) 4.8.2 20140120 (Red Hat 4.8.2-15)

Solved