Closed ashwathkumar closed 4 years ago
If you installed Rtools to C:/Rtools for 4.0
it will probably not work with R, install it to a directory that does not contain spaces.
I did not install it in a directory called "Rtools for 4.0" its installed in a "C:/Rtools". The error message adds the " for 4.0". For example: I uninstalled and reinstalled the Rtools to "C:/rtools40" and this is the message I get
find_rtools(T) Scanning R CMD config CC... cc_path:
'' does not exist Scanning path... Scanning registry... Found C:/rtools40 for 4.0 WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtools40 has been deleted.
Please download and install Rtools custom from http://cran.r-project.org/bin/windows/Rtools/.
I am getting the same error message with rtools 4.0 beta 22 (downloaded 03 march 2020). R4.0, Windows10, biocManager3.11
Example output:
> install_github("RGLab/flowWorkspace")
WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtoolsdevel has been deleted.
Please download and install Rtools custom from http://cran.r-project.org/bin/windows/Rtools/.
Downloading GitHub repo RGLab/flowWorkspace@master
Error: Failed to install 'flowWorkspace' from GitHub:
Could not find tools necessary to compile a package
Call `pkgbuild::check_build_tools(debug = TRUE)` to diagnose the problem.
> pkgbuild::check_build_tools(debug = TRUE)
Error: Could not find tools necessary to compile a package
Call `pkgbuild::check_build_tools(debug = TRUE)` to diagnose the problem.
> find_rtools()
WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtoolsdevel has been deleted.
Please download and install Rtools custom from http://cran.r-project.org/bin/windows/Rtools/.
> find_rtools(TRUE)
Scanning R CMD config CC...
cc_path:
'' does not exist
Scanning path...
Scanning registry...
Found C:/Rtools for 3.5
Found C:/rtoolsdevel for 4.0
WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtoolsdevel has been deleted.
Please download and install Rtools custom from http://cran.r-project.org/bin/windows/Rtools/.
Thank you
Chris
I am getting this with latest R 4.0, latest Rstudio and pkgbuild current master.
I got the same error, and then discovered that I had an .Rprofile file where a wrong Rtools path was saved. Deleting that file solved the issue for me.
Can you be more specific on how you fixed it? I'm having the same problem. Devtools is telling me it has found both Rtools 3.5 and Rtools 4.0 but C:/rtools40 has been deleted. I had deleted the original Rtools and installed 4.0 as "rtools40". It is in the C drive, not deleted. None of the previous fixes I've found are solving it.
Thanks for the detail! I'm guessing something like that is happening in my case (although that did not work in my case). Since it's still new, perhaps the bug will be fixed - if that's what it is - soon.
`R version 4.0.0 (2020-04-24) -- "Arbor Day" Copyright (C) 2020 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 (64-bit) ...
require(devtools) Loading required package: devtools Loading required package: usethis find_rtools(T) Scanning R CMD config CC... cc_path:
'' does not exist Scanning path... Scanning registry... Found C:/Rtools for 3.5 Found C:/rtools40 for 4.0 WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtools40 has been deleted.
Please download and install Rtools custom from https://cran.r-project.org/bin/windows/Rtools/.`
@arclightb139 can you please test if this only happens inside rstudio, or also when you start Rgui from the start menu?
Interesting! devtools can find Rtools no problem in 64-bit RGui
Yes I think that it is a bug in rstudio. Can you try this in rstudio:
Start rstudio and set options(buildtools.check=NULL)
before loading pkgload or devtools. And then see if that changes anything.
It worked! Thanks a lot!
@arclightb139 which version of rstudio do you have?
RStudio 1.2.5042
I had to change the above command from: writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
to
writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
then Sys.which("make") returned "C:\Users\ozd504\DOCUME~1\rtools40\usr\bin\make.exe"
sessionInfo() R version 4.0.0 (2020-04-24) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 18363)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages: [1] stats graphics grDevices utils datasets methods base
other attached packages: [1] devtools_2.3.0 usethis_1.6.1
loaded via a namespace (and not attached):
[1] rstudioapi_0.11 magrittr_1.5 pkgload_1.0.2 R6_2.4.1
[5] rlang_0.4.5 fansi_0.4.1 tools_4.0.0 pkgbuild_1.0.7
[9] sessioninfo_1.1.1 cli_2.0.2 withr_2.2.0 ellipsis_0.3.0
[13] remotes_2.1.1 assertthat_0.2.1 digest_0.6.25 rprojroot_1.3-2
[17] crayon_1.3.4 processx_3.4.2 callr_3.4.3 fs_1.4.1
[21] ps_1.3.2 testthat_2.3.2 memoise_1.1.0 glue_1.4.0
[25] compiler_4.0.0 desc_1.2.0 backports_1.1.6 prettyunits_1.1.1
This error should now be fixed in the master branch. Can you confirm everything works now (without any workarounds)?
remotes::install_github("r-lib/pkgbuild")
Make sure to restart R or RStudio after installing.
everything works now
On Thu, Apr 30, 2020 at 4:38 PM Jeroen Ooms notifications@github.com wrote:
This error should now be fixed in the master branch. Can you confirm everything works now (without any workarounds)?
remotes::install_github("r-lib/pkgbuild")
Make sure to restart R or RStudio after installing.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/r-lib/pkgbuild/issues/92#issuecomment-622128243, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABI4QKIA4AO3XBYQBWIZE6DRPHVTZANCNFSM4L4ITURA .
-- Corey Sparks, PhD Associate professor and Graduate Advisor Department of Demography The University of Texas at San Antonio em: corey 'dot' sparks 'at' utsa 'dot' edu @CoreySparks1 https://sites.google.com/view/corey-sparks-phd/home
Co-Editor in Chief Population Research and Policy Review https://link.springer.com/journal/11113
@arclightb139 can you everything now works for you with the master branch?
works for me
I had to change the above command from: writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
to
writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
then Sys.which("make") returned "C:\Users\ozd504\DOCUME~1\rtools40\usr\bin\make.exe"
sessionInfo() R version 4.0.0 (2020-04-24) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 18363)
Matrix products: default
locale: [1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252 [3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C [5] LC_TIME=English_United States.1252
attached base packages: [1] stats graphics grDevices utils datasets methods base
other attached packages: [1] devtools_2.3.0 usethis_1.6.1
loaded via a namespace (and not attached): [1] rstudioapi_0.11 magrittr_1.5 pkgload_1.0.2 R6_2.4.1 [5] rlang_0.4.5 fansi_0.4.1 tools_4.0.0 pkgbuild_1.0.7 [9] sessioninfo_1.1.1 cli_2.0.2 withr_2.2.0 ellipsis_0.3.0 [13] remotes_2.1.1 assertthat_0.2.1 digest_0.6.25 rprojroot_1.3-2 [17] crayon_1.3.4 processx_3.4.2 callr_3.4.3 fs_1.4.1 [21] ps_1.3.2 testthat_2.3.2 memoise_1.1.0 glue_1.4.0 [25] compiler_4.0.0 desc_1.2.0 backports_1.1.6 prettyunits_1.1.1
Hi all, getting a similar 'false error' where R from Rstudio cannot find Rtools40. Following a lot of advice in this and other threads: @coreysparks I cannot find a difference in the writeLines() text that you say you changed. Similar to @arclightb139 my output from
Sys.which("make")
outputs
make ""
Can you double check your writeLines() command?
Sorry, i meant it to have \ in the path
writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
On Sat, May 2, 2020, 15:40 Kyle Wilson notifications@github.com wrote:
I had to change the above command from: writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
to
writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
then Sys.which("make") returned "C:\Users\ozd504\DOCUME~1\rtools40\usr\bin\make.exe"
sessionInfo() R version 4.0.0 (2020-04-24) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 18363)
Matrix products: default
locale: [1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252 [3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C [5] LC_TIME=English_United States.1252
attached base packages: [1] stats graphics grDevices utils datasets methods base
other attached packages: [1] devtools_2.3.0 usethis_1.6.1
loaded via a namespace (and not attached): [1] rstudioapi_0.11 magrittr_1.5 pkgload_1.0.2 R6_2.4.1 [5] rlang_0.4.5 fansi_0.4.1 tools_4.0.0 pkgbuild_1.0.7 [9] sessioninfo_1.1.1 cli_2.0.2 withr_2.2.0 ellipsis_0.3.0 [13] remotes_2.1.1 assertthat_0.2.1 digest_0.6.25 rprojroot_1.3-2 [17] crayon_1.3.4 processx_3.4.2 callr_3.4.3 fs_1.4.1 [21] ps_1.3.2 testthat_2.3.2 memoise_1.1.0 glue_1.4.0 [25] compiler_4.0.0 desc_1.2.0 backports_1.1.6 prettyunits_1.1.1
Hi all, getting a similar 'false error' where R from Rstudio cannot find Rtools40. Following a lot of advice in this and other threads: @coreysparks https://github.com/coreysparks I cannot find a difference in the writeLines() text that you say you changed. Similar to @arclightb139 https://github.com/arclightb139 my output from
Sys.which("make") outputs make ""
Can you double check your writeLines() command?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/r-lib/pkgbuild/issues/92#issuecomment-623010392, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABI4QKJOGAXMGVYKXXC3LV3RPSALZANCNFSM4L4ITURA .
@klwilson23 can you please try to install the new version of pkgbuild? That should also fix the problem.
install.packages("pkgbuild")
Hello, I am getting the same message message, that Rtools has been deleted, even though the package is installed:
install_github("marcus-waldman/credi") WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtools40 has been deleted.
I think I cannot set the path and that might be the problem: I type
writeLines('PATH="${RTOOLS40_HOME}\usr\bin;${PATH}"', con = "~/.Renviron")
But when I check (after restarting) Sys.which("make") does not return path.
In your writeLines
code you need to escape the backslash. Please use the exact code as shown on https://cran.r-project.org/bin/windows/Rtools/
I did install dev version of pkgbuild and I copied the writeline code directly from webpage and it still returns
Sys.which("make") make "" I am working in R, not Rstudio
Are you sure you are using R 4.0 and rtools40? What do you see for:
Sys.getenv("PATH")
If you have the dev version of pkgbuild, install_github
should work regardless.
I have both R 4.0 and rtools40. I see this:
Sys.getenv("PATH") [1] "C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Program Files (x86)\Sennheiser\SoftphoneSDK\;C:\Users\lchakhaia\AppData\Local\Microsoft\WindowsApps;"
Ok, I can install the package now. Thanks!
Hi,
@arclightb139 can you please test if this only happens inside rstudio, or also when you start Rgui from the start menu?
I m facing this issue on both . can anybody help?
require(devtools) find_rtools(T) Scanning R CMD config CC... cc_path:
'' does not exist Scanning path... Scanning registry... Found C:/rtools40 for 4.0 WARNING: Rtools is required to build R packages, but the version of Rtools previously installed in C:/rtools40 has been deleted.
Please download and install Rtools custom from https://cran.r-project.org/bin/windows/Rtools/.
@rigzy121 please install the latest pkgbuild
and then restart rstudio and try again:
install.packages("pkgbuild")
Warning: In your file, some mandatory metadata are missing. Bibliometrix functions may not work properly!
can anybody help?
@rigzy121 That warning doesn't seem to have anything to do with pkgbuild, I suggest you follow the links mentioned in the warning, and if they don't help open an issue at https://community.rstudio.com
I'm having the same issue, R says Rtools has been deleted when it is there. I tried doing remotes::install_github("r-lib/pkgbuild") but got an error message: Error: Failed to install 'pkgbuild' from GitHub: (converted from warning) cannot remove prior installation of package ‘glue’
The new pkgbuild is on CRAN. What you need to do is start a clean new R session and run:
install.packages("pkgbuild")
And then restart R again.
Thanks, that's solved the Rtools issue, I still can't get the function setupGeolocation() to run without errors but I think that's not really your remit?
Error: Failed to install 'GeoLight' from GitHub: (converted from warning) package ‘GeoLight’ is in use and will not be installed
That has nothing to do with pkgbuild. But the problem is that you are trying to install a package that is already loaded. Try to quit all your R sessions, and then in a clean R session try to install the package.
Its not already loaded, this is a new script, new r session, nothing else has been run and no other R sessions are on going. But don't worry- as you say, this doesn't have anything to do with pkgbuild.
I am working on the development version of R and isntalled the Rtools40. When i load devtools I get the error
Please download and install Rtools custom from http://cran.r-project.org/bin/windows/Rtools/.
But I did not delete the Rtools directory and it is still there. Please let me know how to fix this. I am using devtools 2.2.1.
I have tried installing the devlopment version of devtools to see if that fixes the issue but I get the following error when loading development version of devtools.