-
Notifications
You must be signed in to change notification settings - Fork 220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
installing external R packages requiring compilation fails [windows] #9184
Comments
Ah, I bet this has something to do with the switch to MRO earlier this year. Sorry for my earlier comments, I removed them because they were irrelevant. Please ignore them. |
There's no need to build binaries for yourself on R on Windows since binaries are provided, either by
You should use: |
I am surprised by this harsh reaction. Of course there IS need to build binaries for yourself... R-readxl should thus only be an example (as stated above), which seems to be quite tested and even was successfully compiled by other in the linked issue. |
I see no harsh reaction. You didn't explain that you were a software developer working on R packages. One of the key things AD does is to take away the pain of compiling software. If you want to compile your own packages then just follow the 'normal' instructions for installing and using Rtools. Everything should work just the same. |
If you want a conda-package for Rtools then you can use conda-build to build https://github.com/AnacondaRecipes/aggregateMRO/tree/master/rtools-feedstock/recipe If you do that then you can use |
@zaphot I believe you can also change your r from mro to r-base as it says in the linked anaconda docs above. Then you can build & install cran r packages the way I did and in the previous issue. |
thx a lot for the answers and links. However, i will just use cran R and Rtools, since I think it's probably better/safer to use both toolchain and R environment from the same provider. Would be cool if anaconda could also integrate an easy toolchain package (like it's done on linux). Just something like "conda install r-rtools" and start building your code independent of the os would be awesome. Of course it's nice that one doesn't have to compile every package. But besides compiling own code, i think it is also getting more and more common that publications provide new code just as source on github. |
Thanks for the feedback.
If you use MRO on Windows then you are using upstream packages (for nearly everything). All I do is repackage the binaries in the installer and those on MRAN (which are snapshotted mirrors from CRAN) .. apart from on Linux, in which case I repackage the binaries in the installer and build everything else from source using our compilers. I am not sure what I will need to do with macOS yet. Providing an Rtools package is very easy since I've written the recipe already (and used it to build some of the AD MRO packages). I am hesitant to do it because R upstream is working on modernising Rtools and I might want to wait until that's done, but I'll ask my team what they'd prefer here. Pinging @csoja. |
@zaphot This is a possible solution for the error reported during compilation of R packages from source, using the conda msys2 packages. It seems that R expects to find the C++ compilers or headers at the dir defined in variable edit change line BTW, the problem also arises when people using Rtools do not installed it in the default dir r.789695.n4.nabble.com/Setting-the-path-to-Rtools-for-package-compilation-on-Windows-td4748266.html Hope it works for you. |
You should use the official Rtools when compiling packages to work with MRO on Windows. We don't want to handle that for you since it involves writing files outside of Conda R (non-MRO version) already uses a dynamic |
I cannot build/install R packages which require compilation.
i followed the steps provided here #729 and https://github.com/ContinuumIO/anaconda-issues/wiki/Install-R-Packages and installed the following packages:
conda install m2w64-toolchain m2-make m2-sed m2-zip m2-gzip m2-tar m2-texinfo m2-coreutils m2-diffutils r-devtools
. Moreover i created a tmp folder in my anaconda installationmkdir %HOMEPATH%\Anaconda3\Library\tmp
But what is the cran Rtools equivalent in conda or should one install Rtools from cran? Moreover, can one integrate the build tools in Rstudio?
As an example the readxl package from https://cran.r-project.org/src/contrib/readxl_1.0.0.tar.gz is downloaded.
Using the command line:
From within R:
conda info:
conda list --show-channel-urls
The text was updated successfully, but these errors were encountered: