Unable to install, update WGCNA and GO.db
1
0
Entering edit mode
rproendo ▴ 20
@rproendo-17985
Last seen 13 hours ago
United States

Trying to use WGCNA and can't install the package. The install process seems to fail during installation of GO.db, but also fails during installation of 'farver', 'RCurl', and 'rrcov'. Have very little experience troubleshooting issues like these and am in way over my head. Thanks in advance for your help.

install.packages("BiocManager")
library("BiocManager")
BiocManager::install("WGCNA")
Bioconductor version 3.10 (BiocManager 1.30.10), R 3.6.1 (2019-07-05)
Installing package(s) 'WGCNA'
also installing the dependency ‘GO.db’

Package which is only available in source form, and may need compilation of C/C++/Fortran: ‘WGCNA’
Do you want to attempt to install these from sources? (Yes/no/cancel) Yes
installing the source packages ‘GO.db’, ‘WGCNA’

trying URL 'https://bioconductor.org/packages/3.10/data/annotation/src/contrib/GO.db_3.10.0.tar.gz'
Content type 'application/x-gzip' length 31820873 bytes (30.3 MB)
==================================================
downloaded 30.3 MB

trying URL 'https://cran.rstudio.com/src/contrib/WGCNA_1.68.tar.gz'
Content type 'application/x-gzip' length 1166156 bytes (1.1 MB)
==================================================
downloaded 1.1 MB

* installing *source* package ‘GO.db’ ...
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
Error: package or namespace load failed for ‘AnnotationDbi’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]):
 there is no package called ‘RSQLite’
Error: package ‘AnnotationDbi’ could not be loaded
In addition: Warning messages:
1: package ‘IRanges’ was built under R version 3.6.2 
2: package ‘S4Vectors’ was built under R version 3.6.2 
Execution halted
ERROR: lazy loading failed for package ‘GO.db’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/GO.db’
ERROR: dependency ‘GO.db’ is not available for package ‘WGCNA’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/WGCNA’

The downloaded source packages are in
    ‘/private/var/folders/23/4fq4zz216pbbs5wmhy5r6b400000gn/T/Rtmpejthyl/downloaded_packages’
Old packages: 'farver', 'RCurl', 'rrcov'
Update all/some/none? [a/s/n]: 
a

  There are binary versions available but the source versions are later:
          binary    source needs_compilation
farver     2.0.1     2.0.3              TRUE
RCurl  1.95-4.12 1.95-4.13              TRUE
rrcov      1.4-9     1.5-2              TRUE

Do you want to install from sources the packages which need compilation? (Yes/no/cancel) Yes
installing the source packages ‘farver’, ‘RCurl’, ‘rrcov’

trying URL 'https://cran.rstudio.com/src/contrib/farver_2.0.3.tar.gz'
Content type 'application/x-gzip' length 1279579 bytes (1.2 MB)
==================================================
downloaded 1.2 MB

trying URL 'https://cran.rstudio.com/src/contrib/RCurl_1.95-4.13.tar.gz'
Content type 'application/x-gzip' length 698455 bytes (682 KB)
==================================================
downloaded 682 KB

trying URL 'https://cran.rstudio.com/src/contrib/rrcov_1.5-2.tar.gz'
Content type 'application/x-gzip' length 1020006 bytes (996 KB)
==================================================
downloaded 996 KB

* installing *source* package ‘farver’ ...
** package ‘farver’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ERROR: compilation failed for package ‘farver’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/farver’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/farver’
* installing *source* package ‘RCurl’ ...
** package ‘RCurl’ successfully unpacked and MD5 sums checked
** using staged installation
checking for curl-config... /usr/bin/curl-config
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/private/var/folders/23/4fq4zz216pbbs5wmhy5r6b400000gn/T/Rtmp4bJZrP/R.INSTALL8fa527b4c270/RCurl':
configure: error: C compiler cannot create executables
See `config.log' for more details
ERROR: configuration failed for package ‘RCurl’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/RCurl’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/RCurl’
* installing *source* package ‘rrcov’ ...
** package ‘rrcov’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
ERROR: compilation failed for package ‘rrcov’
* removing ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rrcov’
* restoring previous ‘/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rrcov’

The downloaded source packages are in
    ‘/private/var/folders/23/4fq4zz216pbbs5wmhy5r6b400000gn/T/Rtmpejthyl/downloaded_packages’
Warning messages:
1: In install.packages(...) :
  installation of package ‘GO.db’ had non-zero exit status
2: In install.packages(...) :
  installation of package ‘WGCNA’ had non-zero exit status
3: In install.packages(update[instlib == l, "Package"], l, repos = repos,  :
  installation of package ‘farver’ had non-zero exit status
4: In install.packages(update[instlib == l, "Package"], l, repos = repos,  :
  installation of package ‘RCurl’ had non-zero exit status
5: In install.packages(update[instlib == l, "Package"], l, repos = repos,  :
  installation of package ‘rrcov’ had non-zero exit status
WGCNA software error • 7.8k views
ADD COMMENT
0
Entering edit mode

opt not to install packages from source. Update your c compiler to clang-8.0.0 from https://cran.r-project.org/bin/macosx/tools/ . Tackle the first failure (RSQLite) first by trying to install, and diagnose if possible, why the package fails to install

ADD REPLY
0
Entering edit mode
rproendo ▴ 20
@rproendo-17985
Last seen 13 hours ago
United States

To anyone else looking for a solution to this issue, I fell backwards into solving it with help from Martin. I think the problem stems from issues with developer tools in iOS after updating to Catalina. Update/install RSQLite first

install.packages("RSQLite")
library(RSQLite)

Then open terminal and:

xcode-select --install

If you're on iOS, this should prompt permissions to download and install command line developer tools. After installing, go back to RStudio and re-attempt the WGCNA install. There are likely better solutions to this, but this one worked for me. Related, I installed GO.db independently of WGCNA. This may or may not have contributed to the successful fix, but I'm not sure.

install.packages("BiocManager")
library(BiocManager)
BiocManager::install("WGCNA")
ADD COMMENT

Login before adding your answer.

Traffic: 773 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6