Build error on RStudio cloud
vankesteren opened this issue · 2 comments
Installing with devtools::install_github("RStudio/websocket")
on RStudio cloud leads to the following error:
Downloading GitHub repo RStudio/websocket@master
✔ checking for file ‘/tmp/RtmpAZ9so7/remotesed25b5db09/rstudio-websocket-28eb91b/DESCRIPTION’ ...
─ preparing ‘websocket’:
✔ checking DESCRIPTION meta-information ...
─ cleaning src
─ running ‘cleanup’
─ checking for LF line-endings in source and make files and shell scripts
─ checking for empty or unneeded directories
─ building ‘websocket_0.0.0.9001.tar.gz’
Installing package into ‘/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5’
(as ‘lib’ is unspecified)
* installing *source* package ‘websocket’ ...
Found pkg-config cflags and libs!
Using PKG_CFLAGS=
Using PKG_LIBS=-l:libssl.so.1.0.0 -l:libcrypto.so.1.0.0
** libs
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -I./lib -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/Rcpp/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/BH/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/AsioHeaders/include" -I/usr/local/include -fpic -g -O2 -c RcppExports.cpp -o RcppExports.o
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -I./lib -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/Rcpp/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/BH/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/AsioHeaders/include" -I/usr/local/include -fpic -g -O2 -c websocket.cpp -o websocket.o
g++: internal compiler error: Killed (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-5/README.Bugs> for instructions.
make: *** [websocket.o] Error 4
/opt/R/3.5.2/lib/R/etc/Makeconf:171: recipe for target 'websocket.o' failed
ERROR: compilation failed for package ‘websocket’
* removing ‘/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/websocket’
Error in i.p(...) :
(converted from warning) installation of package ‘/tmp/RtmpAZ9so7/fileed723a31a0/websocket_0.0.0.9001.tar.gz’ had non-zero exit status
It seems like something is going wrong in the configure script, maybe these Using PKG_LIBS=-l:libssl.so.1.0.0 -l:libcrypto.so.1.0.0
are not available?
Sorry if this is not the correct location for this issue.
Websocket takes a lot of memory to compile (because the C++ library it uses requires a lot of memory), and unfortunately, instances on rstudio.cloud currently don't have enough memory to do it. When you see g++: internal compiler error: Killed (program cc1plus)
on rstudio.cloud, it's usually because it ran out of memory.
I'm told that at some point in the future there may be a way to increase memory, but I don't know much more than that.
We will be releasing websocket to CRAN in the upcoming weeks, and once it's there, there will be a cached binary version of the package available on rstudio.cloud, so compilation won't be necessary at all.
Thank you for the info!