I am getting the following address when I try building a package in R.
> R CMD build bootLR
...
cp: error writing '/tmp/RtmpIwkIfV/Rbuild1cf97228aeac/bootLR/.Rproj.user/6295459/sources/s-52F68146/lock_file': Bad address
ERROR
copying to build directory failed
Things I have tried:
- Installing Ubuntu 18.04 on a new computer
- Installing Ubuntu 18.04 on a new VM
- Deleting the lock file (it doesn't exist, nor do many of the directories higher than it in the directory heirarchy)
- Googling this error (nothing seems to exist on R specifically; it does seem to be a pointer issue within C perhaps?)
- Waiting 6 months, installing the now-latest R version
- Moving /tmp to a memory disk and rebooting
The best I've gotten it down to is to make the problem intermittent - it built the package once or twice, then started reporting the error again.
To reproduce, install R and all the packages I have installed:
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E084DAB9
# Add to /etc/apt/sources.list: deb https://cran.rstudio.com/bin/linux/ubuntu bionic/
sudo apt-get update; sudo apt-get -y install r-base r-base-dev r-recommended libssl-dev libssh2-1-dev
sudo R
install.packages(c("Hmisc","R.utils"))
install.packages(c("RColorBrewer","RCurl","foreign"))
install.packages(c("data.table"))
install.packages(c("tidyverse"))
install.packages(c("functional","XML","MatchIt"))
install.packages(c("taRifx","taRifx.geo","taRifxRcpp","bootLR")) # my packages
install.packages(c("ggplot2","dplyr","stringr", "lubridate","devtools","Roxygen")) # Hadleyverse
install.packages(c("sp","spdep","rgdal","maptools"))
install.packages(c("SDMTools","gstat"))
install.packages(c("automap","RArcInfo","rgeos","spatstat","FNN","fields","MapGAM","spBayes","functional"))
install.packages(c("gtools","gdata","car","formula.tools"))
install.packages(c("testthat","MASS","stargazer","survey","xtable","pander"))
install.packages(c("formatR","caTools","rprojroot","rmarkdown"))
install.packages(c("zeligverse"))
install.packages(c("boot","binom"))
install.packages(c("ROAuth","twitteR","RJSONIO")) # webscraping
install.packages(c("pscl","bayesm","perturb","plm"))
install.packages(c("doParallel"))
install.packages(c("HH"))
install.packages(c("equivalence","ROCR","r2stl","svglite"))
Any help/tips you could offer, even as to where I should start looking for the problem, would be most appreciated.
0 Answers