tylermorganwall / rayshader

R Package for 2D and 3D mapping and data visualization
https://www.rayshader.com/
2.06k stars 214 forks source link

Problem installing from github #52

Closed dernapo closed 5 years ago

dernapo commented 5 years ago

Hi,

I have problems to install from CRAN and from gitHub

devtools::install_github("tylermorganwall/rayshader")

on Windows.

sessionInfo() R version 3.6.0 (2019-04-26) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 17134)

Matrix products: default

locale: [1] LC_COLLATE=German_Germany.1252 LC_CTYPE=German_Germany.1252
[3] LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
[5] LC_TIME=German_Germany.1252

attached base packages: [1] stats graphics grDevices utils datasets methods base

loaded via a namespace (and not attached): [1] Rcpp_1.0.1 pillar_1.4.1 compiler_3.6.0 prettyunits_1.0.2 [5] remotes_2.1.0 tools_3.6.0 digest_0.6.19 pkgbuild_1.0.3
[9] pkgload_1.0.2 memoise_1.1.0 tibble_2.1.3 gtable_0.3.0
[13] pkgconfig_2.0.2 rlang_0.4.0 cli_1.1.0 rstudioapi_0.10
[17] curl_3.3 withr_2.1.2 dplyr_0.8.1 desc_1.2.0
[21] fs_1.3.1 devtools_2.0.2 rprojroot_1.3-2 grid_3.6.0
[25] tidyselect_0.2.5 glue_1.3.1 R6_2.4.0 processx_3.3.1
[29] sessioninfo_1.1.1 ggplot2_3.2.0 callr_3.2.0 purrr_0.3.2
[33] magrittr_1.5 scales_1.0.0 backports_1.1.4 ps_1.3.0
[37] usethis_1.5.0 assertthat_0.2.1 colorspace_1.4-1 lazyeval_0.2.2
[41] munsell_0.5.0 crayon_1.3.4

I get the following error:

testing if installed package can be loaded from temporary location ** arch - i386 Error in library.dynam(dynlib, pkg, lib) : DLL 'rgl' not found: maybe not installed for this architecture? Error: package or namespace load failed for 'rayshader': .onLoad failed in loadNamespace() for 'rgl', details: call: NULL error: Loading rgl's DLL failed. Fehler: Laden fehlgeschlagen Ausführung angehalten arch - x64 ERROR: loading failed for 'i386' removing 'C:/Users/User/Documents/R/win-library/3.6/rayshader' Error: Failed to install 'rayshader' from GitHub: (converted from warning) installation of package ‘C:/Users/User/AppData/Local/Temp/RtmpU5xJnF/file2c3017661e35/rayshader_0.11.0.tar.gz’ had non-zero exit status

I have installed rgl (0.100.24) and av( 0.2) but it doesnt fix the problem.

Thank you for your support in advance! Javier

tylermorganwall commented 5 years ago

See the following thread:

http://r.789695.n4.nabble.com/DLL-not-found-td3002969.html

You may have a copy of the rgl package in a library that comes before the new one. Does .libPaths() return multiple folders?

matteodelucchi commented 5 years ago

Had the same issue and this worked for me:

  1. Restarted Rstudio and R
  2. First of all (in the blank and virgin R session), I entered the installation command for the github-repo: devtools::install_github("tylermorganwall/rayshader")
  3. Had to install libavfilter-dev. Don't know what it is for windows.
  4. Prompted again the installation command for the github-repo.
> sessionInfo()
R version 3.6.0 (2019-04-26)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 18.04.2 LTS
neuropil commented 5 years ago

I've reinstalled RStuido and R and I followed these instructions (https://www.accelebrate.com/library/how-to-articles/r-rstudio-library) to ensure I only had one library.

I'm still getting the following error ** libs Error: (converted from warning) this package has a non-empty 'configure.win' file, so building only the main architecture

sessionInfo() R version 3.6.0 (2019-04-26) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 17134)

neuropil commented 5 years ago

Solved.

For Windows R-Studio

1). Use https://www.accelebrate.com/library/how-to-articles/r-rstudio-library to fix multi library issue 2). Install rgl alone 3). Install rayshader using devtools 4). Use the following instead of (devtools::install_github): 'install_github("tylermorganwall/rayshader", INSTALL_opts="--no-multiarch")' SOURCE: https://github.com/kthohr/BMR/issues/34

Hope that helps.

seasmith commented 5 years ago

I resolved the same DLL error by calling "--force-biarch" on {rgl}.

install.packages("rgl", type = "source", INSTALL_opts = "--force-biarch")

I should note that the install.packages help page says "--merge-multiarch" is safer, yet slower.

My system setup:

platform       x86_64-w64-mingw32          
arch           x86_64                      
os             mingw32                     
system         x86_64, mingw32             
status                                     
major          3                           
minor          6.0                         
year           2019                        
month          04                          
day            26                          
svn rev        76424                       
language       R                           
version.string R version 3.6.0 (2019-04-26)
nickname       Planting of a Tree