MassBank / RMassBank

Playground for experiments on the official http://bioconductor.org/packages/devel/bioc/html/RMassBank.html
Other
12 stars 15 forks source link

Installation on R-3.2, issues with CAMERA #149

Closed meowcat closed 4 years ago

meowcat commented 8 years ago

I am moving some comments from the unknown/tentative threads here because they are unrelated to the problem there...

meowcat commented 8 years ago

schymane wrote:

Cool! Btw, do you know how to build from github including the vignette?

meowcat commented 8 years ago

tsufz wrote:

library(devtools) install_github("ermueller/RMassBank")

meowcat commented 8 years ago

schymane wrote:

..and if I do that it appears the default is not to include the vignette…hence my question…

meowcat commented 8 years ago

tsufz wrote:

Maybe install_github("ermueller/RMassBank", build_vignettes = TRUE)

build_vignettes = F is default setting:

http://stackoverflow.com/questions/25821473/building-r-package-from-github-how-to-disable-building-vignettes

meowcat commented 8 years ago

schymane wrote:

[omitted lots of stuff in the middle here]

Error: processing vignette 'RMassBankXCMS.Rnw' failed with diagnostics:

chunk 9

Error : .onLoad failed in loadNamespace() for 'CAMERA', details:

call: .setCAMERAOptions(pkgname)

error: 4 arguments passed to .Internal(nchar) which requires 3

Execution halted

Error: Command failed (1)

meowcat commented 8 years ago

tsufz wrote:

Of course, you need a basic TEX on your computer (if windows) to compile the PDF. You may use TEXLive:

http://www.tug.org/texlive/acquire-netinstall.html

Use custom install and select the basic scheme (plain+LATEX)

Good luck!

meowcat commented 8 years ago

ermueller wrote:

Is that a TEX problem? Looks to me like a problem with CAMERA...

meowcat commented 8 years ago

schymane wrote:

I thought the same ... the "normal" vignette compiles first and didn't give an error, which kinda rules out tex as the issue. Plus I have it anyway. Can you try on your system? I had issues with rtools and packages in the lead up to that error as well, but seemed to be fixed. The package installed OK without vignette.

meowcat commented 8 years ago

ermueller wrote:

It works just fine when I do it. Huh, that's strange... You do have the newest CAMERA and xcms, right? That's the only thing I can think of.

meowcat commented 8 years ago

schymane wrote:

well, since I had issues with a number of other packages prior to that it could well be an out-of-date CAMERA. Can try tomorrow and will let you know.

meowcat commented 8 years ago

schymane wrote:

The problem is certainly CAMERA but I can’t fix it whatever I try.

Error: processing vignette 'RMassBankXCMS.Rnw' failed with diagnostics: chunk 9 Error : .onLoad failed in loadNamespace() for 'CAMERA', details: call: .setCAMERAOptions(pkgname) error: 4 arguments passed to .Internal(nchar) which requires 3 Execution halted Error: Command failed (1)

library(CAMERA)

[…]

Error : .onLoad failed in loadNamespace() for 'CAMERA', details:

call: .setCAMERAOptions(pkgname)

error: 4 arguments passed to .Internal(nchar) which requires 3

source("https://bioconductor.org/biocLite.R")

Bioconductor version 3.2 (BiocInstaller 1.20.1), ?biocLite for help

biocLite("CAMERA")

Using Bioconductor 3.2 (BiocInstaller 1.20.1), R 3.2.0 (2015-04-16).

Installing package(s) ‘CAMERA’

trying URL 'https://bioconductor.org/packages/3.2/bioc/bin/windows/contrib/3.2/CAMERA_1.26.0.zip'

Content type 'application/zip' length 3040658 bytes (2.9 MB)

downloaded 2.9 MB

package ‘CAMERA’ successfully unpacked and MD5 sums checked

Warning: cannot remove prior installation of package ‘CAMERA’

The downloaded binary packages are in

    C:\Users\schymaem\AppData\Local\Temp\RtmpMl9VOB\downloaded_packages

Old packages: 'MASS', 'Matrix', 'mgcv', 'nlme'

Update all/some/none? [a/s/n]:

n [already updated them many times and it’s not working]

library(CAMERA)

Error in library(CAMERA) : there is no package called ‘CAMERA’

library("CAMERA", lib.loc="~/R/win-library/3.2") Error in library("CAMERA", lib.loc = "~/R/win-library/3.2") : there is no package called ‘CAMERA’ install.packages("C:/DATA/R/CAMERA_1.26.0.tar.gz", repos=NULL, type="source") Installing package into ‘C:/DATA/R/R/win-library/3.2’ (as ‘lib’ is unspecified)

  • installing source package 'CAMERA' ... \ libs

*\ arch - i386 gcc -m32 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -O3 -Wall -std=gnu99 -mtune=core2 -c fastMatch.c -o fastMatch.o gcc -m32 -shared -s -static-libgcc -o CAMERA.dll tmp.def fastMatch.o -Ld:/RCompile/r-compiling/local/local320/lib/i386 -Ld:/RCompile/r-compiling/local/local320/lib -LC:/PROGRA~1/R/R-32~1.0/bin/i386 -lR installing to C:/DATA/R/R/win-library/3.2/CAMERA/libs/i386

* arch - x64 gcc -m64 -I"C:/PROGRA~1/R/R-32~1.0/include" -DNDEBUG -I"d:/RCompile/r-compiling/local/local320/include" -O2 -Wall -std=gnu99 -mtune=core2 -c fastMatch.c -o fastMatch.o gcc -m64 -shared -s -static-libgcc -o CAMERA.dll tmp.def fastMatch.o -Ld:/RCompile/r-compiling/local/local320/lib/x64 -Ld:/RCompile/r-compiling/local/local320/lib -LC:/PROGRA~1/R/R-32~1.0/bin/x64 -lR installing to C:/DATA/R/R/win-library/3.2/CAMERA/libs/x64 Warning in file.copy(files, dest, overwrite = TRUE) : problem copying .\CAMERA.dll to C:\DATA\R\R\win-library\3.2\CAMERA\libs\x64\CAMERA.dll: Permission denied * R * data * inst * byte-compile and prepare package for lazy loading Warning: package 'Biobase' was built under R version 3.2.2 Warning: package 'BiocGenerics' was built under R version 3.2.2 Warning: package 'xcms' was built under R version 3.2.2 Warning: package 'mzR' was built under R version 3.2.2 Warning: package 'Rcpp' was built under R version 3.2.3 Warning in fun(libname, pkgname) : mzR has been built against a different Rcpp version (0.12.1) than is installed on your system (0.12.3). This might lead to errors when loading mzR. If you encounter such issues, please send a report, including the output of sessionInfo() to the Bioc support forum at https://support.bioconductor.org/. For details see also https://github.com/sneumann/mzR/wiki/mzR-Rcpp-compiler-linker-issue. Warning: package 'ProtGenerics' was built under R version 3.2.2 Warning: package 'igraph' was built under R version 3.2.2 \ help * installing help indices * building package indices * installing vignettes \ testing if installed package can be loaded * arch - i386 Warning: package 'Biobase' was built under R version 3.2.2 Warning: package 'BiocGenerics' was built under R version 3.2.2 Warning: package 'xcms' was built under R version 3.2.2 Warning: package 'mzR' was built under R version 3.2.2 Warning: package 'Rcpp' was built under R version 3.2.3 Warning in fun(libname, pkgname) : mzR has been built against a different Rcpp version (0.12.1) than is installed on your system (0.12.3). This might lead to errors when loading mzR. If you encounter such issues, please send a report, including the output of sessionInfo() to the Bioc support forum at https://support.bioconductor.org/. For details see also https://github.com/sneumann/mzR/wiki/mzR-Rcpp-compiler-linker-issue. Warning: package 'ProtGenerics' was built under R version 3.2.2 Warning: package 'igraph' was built under R version 3.2.2 * arch - x64 Warning: package 'Biobase' was built under R version 3.2.2 Warning: package 'BiocGenerics' was built under R version 3.2.2 Warning: package 'xcms' was built under R version 3.2.2 Warning: package 'mzR' was built under R version 3.2.2 Warning: package 'Rcpp' was built under R version 3.2.3 Warning in fun(libname, pkgname) : mzR has been built against a different Rcpp version (0.12.1) than is installed on your system (0.12.3). This might lead to errors when loading mzR. If you encounter such issues, please send a report, including the output of sessionInfo() to the Bioc support forum at https://support.bioconductor.org/. For details see also https://github.com/sneumann/mzR/wiki/mzR-Rcpp-compiler-linker-issue. Warning: package 'ProtGenerics' was built under R version 3.2.2 Warning: package 'igraph' was built under R version 3.2.2

R version 3.2.0 (2015-04-16) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 8 x64 (build 9200)

locale: [1] LC_COLLATE=English_Australia.1252 LC_CTYPE=English_Australia.1252 LC_MONETARY=English_Australia.1252 [4] LC_NUMERIC=C LC_TIME=English_Australia.1252

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

other attached packages: [1] igraph_1.0.1 xcms_1.46.0 ProtGenerics_1.2.1 mzR_2.4.0 Rcpp_0.12.3 [6] Biobase_2.30.0 BiocGenerics_0.16.1 devtools_1.9.1 BiocInstaller_1.20.1

loaded via a namespace (and not attached): [1] RColorBrewer_1.1-2 plyr_1.8.3 tools_3.2.0 rpart_4.1-10 digest_0.6.9 [6] memoise_0.2.1 gtable_0.1.2 lattice_0.20-33 graph_1.48.0 curl_0.9.4 [11] gridExtra_2.0.0 httr_1.0.0 stringr_1.0.0 cluster_2.0.3 nnet_7.3-11 [16] stats4_3.2.0 grid_3.2.0 R6_2.1.1 RBGL_1.46.0 survival_2.38-3 [21] foreign_0.8-66 latticeExtra_0.6-26 Formula_1.2-1 ggplot2_2.0.0 magrittr_1.5 [26] Hmisc_3.17-1 scales_0.3.0 codetools_0.2-14 splines_3.2.0 colorspace_1.2-6 [31] stringi_1.0-1 acepack_1.3-3.3 munsell_0.4.2

So, does anyone have any brilliant ideas?

meowcat commented 8 years ago

tsufz wrote:

I had problems with the Rcpp version. You may reinstall the 0.12.1 version:

packageurl <- "http://cran.r-project.org/src/contrib/Archive/Rcpp/Rcpp_0.12.1.tar.gz" install.packages(packageurl, repos=NULL, type="source")

meowcat commented 8 years ago

ermueller wrote:

Oh god, R installing problems.

Warning: package 'Biobase' was built under R version 3.2.2 Warning: package 'BiocGenerics' was built under R version 3.2.2 Warning: package 'xcms' was built under R version 3.2.2 Warning: package 'mzR' was built under R version 3.2.2 Warning: package 'Rcpp' was built under R version 3.2.3

Some version problem? I dunno why, you're definitely installing CAMERA for R 3.2

remove 'C:/DATA/R/R/win-library/3.2/CAMERA/'

just completely delete that whole folder, since some file is corrupt.

Another thing:

Warning in file.copy(files, dest, overwrite = TRUE) : problem copying .\CAMERA.dll to C:\DATA\R\R\win-library\3.2\CAMERA\libs\x64\CAMERA.dll: Permission denied

You don't have complete access to that folder? I think an installation will fail as long as you do that. My oh my, this mess gives me flashbacks. I had that, too, when I got my new laptop. But that is the rigth library path, right?

meowcat commented 8 years ago

meowcat wrote:

That CAMERA error is what I had when I tried to install (github) RMassBank-refactored on R 3.2. Which prompted me to upgrade completely to R 3.3 and Bioconductor-devel. I don't think there is another solution, we can't backport everything to 3.2...

meowcat commented 8 years ago

tsufz wrote:

Hi, the problem wit Rcpp and mzR also persists. mzR 2.40 is compiled with Rcpp 0.12.1, but 0.12.3 is required for RMassBank. Would be nice to get a mzR version compiled with Rcpp 0.12.3 during installation to get rid of the problems.

meowcat commented 8 years ago

schymane wrote:

So, I have permission to that folder (in principle at least...) and CAMERA is not in the library in the folder I do not have permission to access (don't get me started on our admin rights policy...) So, I deleted the CAMERA folder and did:

source("https://bioconductor.org/biocLite.R") Bioconductor version 3.2 (BiocInstaller 1.20.1), ?biocLite for help biocLite("CAMERA") BioC_mirror: https://bioconductor.org Using Bioconductor 3.2 (BiocInstaller 1.20.1), R 3.2.0 (2015-04-16). Installing package(s) ‘CAMERA’ trying URL 'https://bioconductor.org/packages/3.2/bioc/bin/windows/contrib/3.2/CAMERA_1.26.0.zip' Content type 'application/zip' length 3040658 bytes (2.9 MB) downloaded 2.9 MB

package ‘CAMERA’ successfully unpacked and MD5 sums checked

The downloaded binary packages are in C:\Users\schymaem\AppData\Local\Temp\RtmpQDeIdJ\downloaded_packages Old packages: 'MASS', 'Matrix', 'mgcv', 'nlme' Update all/some/none? [a/s/n]: n

library(CAMERA) Loading required package: Biobase Loading required package: BiocGenerics Loading required package: parallel

Attaching package: ‘BiocGenerics’

The following objects are masked from ‘package:parallel’:

clusterApply, clusterApplyLB, clusterCall, clusterEvalQ, clusterExport, clusterMap, parApply,
parCapply, parLapply, parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from ‘package:stats’:

IQR, mad, xtabs

The following objects are masked from ‘package:base’:

anyDuplicated, append, as.data.frame, as.vector, cbind, colnames, do.call, duplicated, eval, evalq,
Filter, Find, get, grep, grepl, intersect, is.unsorted, lapply, lengths, Map, mapply, match, mget,
order, paste, pmax, pmax.int, pmin, pmin.int, Position, rank, rbind, Reduce, rownames, sapply, setdiff,
sort, table, tapply, union, unique, unlist, unsplit

Welcome to Bioconductor

Vignettes contain introductory material; view with 'browseVignettes()'. To cite Bioconductor, see
'citation("Biobase")', and for packages 'citation("pkgname")'.

Loading required package: xcms Loading required package: mzR Loading required package: Rcpp Loading required package: ProtGenerics

Attaching package: ‘xcms’

The following objects are masked from ‘package:Biobase’:

phenoData, phenoData<-

Loading required package: igraph

Attaching package: ‘igraph’

The following object is masked from ‘package:xcms’:

groups

The following objects are masked from ‘package:BiocGenerics’:

normalize, union

The following objects are masked from ‘package:stats’:

decompose, spectrum

The following object is masked from ‘package:base’:

union

Error : .onLoad failed in loadNamespace() for 'CAMERA', details: call: .setCAMERAOptions(pkgname) error: 4 arguments passed to .Internal(nchar) which requires 3 In addition: Warning messages: 1: package ‘CAMERA’ was built under R version 3.2.2 2: package ‘Biobase’ was built under R version 3.2.2 3: package ‘BiocGenerics’ was built under R version 3.2.2 4: package ‘xcms’ was built under R version 3.2.2 5: package ‘mzR’ was built under R version 3.2.2 6: package ‘Rcpp’ was built under R version 3.2.3 7: In fun(libname, pkgname) : mzR has been built against a different Rcpp version (0.12.1) than is installed on your system (0.12.3). This might lead to errors when loading mzR. If you encounter such issues, please send a report, including the output of sessionInfo() to the Bioc support forum at https://support.bioconductor.org/. For details see also https://github.com/sneumann/mzR/wiki/mzR-Rcpp-compiler-linker-issue. 8: package ‘ProtGenerics’ was built under R version 3.2.2 9: package ‘igraph’ was built under R version 3.2.2 Error: package or namespace load failed for ‘CAMERA’

So then when I try to install the source, it doesn't work because of permission denied again. When I try to delete the folder again in windows - also not because R blocked it! haha - that was the problem. New session of R then

install.packages("C:/DATA/R/CAMERA_1.26.0.tar.gz", repos=NULL, lib="C:/DATA/R/R/win-library/3.2", type="source")

and library(CAMERA) seems to work now. Hooray. So the fail to install locked access to the folder because it was still "in use".

library(devtools) Warning message: package ‘devtools’ was built under R version 3.2.2 install_github("ermueller/RMassBank", build_vignettes = TRUE)

and guess what?


meowcat commented 8 years ago

schymane wrote:

Sounds to me like @sneumann needs to look at why CAMERA doesn't work properly for 3.2...

meowcat commented 8 years ago

schymane wrote:

The problem or the warning? The warning is annoying, but not fatal, I was not aware of it causing problems/errors?


From: Tobias Schulze [notifications@github.com] Sent: Thursday, 21 January 2016 9:37 AM To: MassBank/RMassBank Cc: Schymanski, Emma Subject: Re: [RMassBank] Processing of tentatives/unknowns (#42)

Hi, the problem wit Rcpp and mzR also persists. mzR 2.40 is compiled with Rcpp 0.12.1, but 0.12.3 is required for RMassBank. Would be nice to get a mzR version compiled with Rcpp 0.12.3 during installation to get rid of the problems.

— Reply to this email directly or view it on GitHubhttps://github.com/MassBank/RMassBank/issues/42#issuecomment-173497399.

meowcat commented 8 years ago

ermueller wrote:

Yeah, the warning is just kind of there for me. Never had any actual problems or errors.

meowcat commented 8 years ago

sneumann wrote:

I can confirm the installation issue on Windows with biocLite(CAMERA). The issue during installation with biocLite() seems to be specific to R-3.2.0, as mentioned here https://stackoverflow.com/questions/30955508/r-cannot-load-package-forecast-due-to-namespace-error/30956549#30956549, and with a technical explanation in this comment: http://stackoverflow.com/questions/32912268/error-in-r-data-table-v1-9-6-function-fread/32959306#32959306

Bottomline is that Windows binary ZIP packages built recently on R-3.2.>=1 do not work on R-3.2.0, that explains why your build from source succeeded.

install.packages("C:/DATA/R/CAMERA_1.26.0.tar.gz", repos=NULL, lib="C:/DATA/R/R/win-library/3.2", type="source")
...
* DONE (CAMERA)

Glad the install worked in the end on R-3.2.

The Rcpp is only a warning, and only causes issues if the Rcpp people changed their API and/or internals. They do announce that upfront, but I haven't heard anything that should be of concern lately. Yours, Steffen