Build fails when Rtools is not needed (no /src dir), but source packages will be downloaded
msberends opened this issue · 4 comments
I think this line troubles my run:
It defines that both binaries and sources package may be downloaded from https://cran.rstudio.com. But I don't have a src
directory, so Rtools won't be installed (see first couple of lines below). This makes installation of the current markdown
package fail, since it tries to install the source version of v0.9:
[1] compiler_3.5.1
== 12/07/2018 12:51:32: Skipping download of Rtools because src/ directory is missing.
== 12/07/2018 12:51:32: Downloading and installing travis-tool.sh
# (...)
+ Rscript -e 'options(repos=c(CRAN="https://cran.rstudio.com")); remotes::install_deps(dependencies = TRUE, type="both")'
# (...)
There is a binary version available but the source version is later:
binary source needs_compilation
markdown 0.8 0.9 TRUE
installing the source package 'markdown'
trying URL 'https://cran.rstudio.com/src/contrib/markdown_0.9.tar.gz'
# (...)
/bin/sh: c:/Rtools/mingw_32/bin/gcc: No such file or directory
ERROR: compilation failed for package 'markdown'
And so all my builds fail, until there's a binary available for Windows at https://cran.r-project.org/package=markdown.
'Fixed' it for now by adding PKGTYPE = win.binary
to my appveyor.yml
. But that shouldn't be necessary.
Rtools install should be skipped when there's no src
dir AND PKGTYPE
is not set to source or both.
Thanks. Perhaps the default for PKGTYPE
should be win.binary
? This will be disruptive to power users, but easy enough to detect and override.
That’s the most pragmatic solution I guess 😄