ERROR: compilation failed for package ‘markovchain’

> install.packages("markovchain")
Installing package into ‘/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5’
(as ‘lib’ is unspecified)
trying URL 'http://package-proxy/src/contrib/markovchain_0.6.9.14.tar.gz'
Content type 'application/x-gzip' length 979056 bytes (956 KB)
==================================================
downloaded 956 KB

* installing *source* package ‘markovchain’ ...
** package ‘markovchain’ successfully unpacked and MD5 sums checked
** libs
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -DRCPP_USE_UNWIND_PROTECT -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/RcppParallel/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/RcppArmadillo/include" -I/usr/local/include   -fpic  -g -O2 -c 0_classesAndMethods.cpp -o 0_classesAndMethods.o
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -DRCPP_USE_UNWIND_PROTECT -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/RcppParallel/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/RcppArmadillo/include" -I/usr/local/include   -fpic  -g -O2 -c 0_ctmcClassesAndMethodsSAI.cpp -o 0_ctmcClassesAndMethodsSAI.o
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -DRCPP_USE_UNWIND_PROTECT -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/RcppParallel/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/RcppArmadillo/include" -I/usr/local/include   -fpic  -g -O2 -c 1_ctmcFunctions4Fitting.cpp -o 1_ctmcFunctions4Fitting.o
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -DRCPP_USE_UNWIND_PROTECT -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/RcppParallel/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/RcppArmadillo/include" -I/usr/local/include   -fpic  -g -O2 -c 1_ctmcProbabilistic.cpp -o 1_ctmcProbabilistic.o
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -DRCPP_USE_UNWIND_PROTECT -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/RcppParallel/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/RcppArmadillo/include" -I/usr/local/include   -fpic  -g -O2 -c 1_fitHigherOrder.cpp -o 1_fitHigherOrder.o
g++ -std=gnu++11 -I"/opt/R/3.5.2/lib/R/include" -DNDEBUG -DRCPP_USE_UNWIND_PROTECT -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/RcppParallel/include" -I"/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/RcppArmadillo/include" -I/usr/local/include   -fpic  -g -O2 -c 1_functions4Fitting.cpp -o 1_functions4Fitting.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: *** [1_functions4Fitting.o] Error 4
/opt/R/3.5.2/lib/R/etc/Makeconf:171: recipe for target '1_functions4Fitting.o' failed
ERROR: compilation failed for package ‘markovchain’
* removing ‘/home/rstudio-user/R/x86_64-pc-linux-gnu-library/3.5/markovchain’
Warning in install.packages :
  installation of package ‘markovchain’ had non-zero exit status

The downloaded source packages are in
	‘/tmp/Rtmpl1Sn5R/downloaded_packages’

Compilation error while installing markovchain in rstudio.cloud.

Take a look at the dependencies on the package page. In particular, your version of base R and Rcpp. Otherwise, there's nothing you can do to fix

1_functions4Fitting.cpp -o 1_functions4Fitting.o
g++: internal compiler error: Killed (program cc1plus)

unless you want to debug the source code. You can also file a bug report at the address given on the link.

Generally means that the compilation exceeded the amount of available memory, which is 1 GB.

We have been added such packages to cache manually, but are close to rolling out automated building upon cache miss. Stay tuned!

2 Likes

Does that mean

install.packages()

is subject to a limitation in RStudio that is stricter than vanilla R?

It means everything one does in rstudio.cloud is subject to running in less than 1 GB of memory for now.

1 Like

It is now in the cache and installable.

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.