EDAseq, edgeR libraries cannot be installed in M2 mac
1
0
Entering edit mode
9 weeks ago

I am having such a weird problem of not being able to install EDAseq or edgeR package from TCGAbiolinks in new M2 mac. Where I did not face any problem with intel based older mac. Is there any solution for this problem right now. I am guessing the packages are not optimized for the ARM-based macs. I am pasting texts from the console.

# install packages
  if (!require("BiocManager", quietly = TRUE))
+   install.packages("BiocManager")

> BiocManager::install("TCGAbiolinks")
'getOption("repos")' replaces Bioconductor standard repositories, see '?repositories' for details

replacement repositories:
    CRAN: https://cran.rstudio.com/

Bioconductor version 3.15 (BiocManager 1.30.18), R 4.2.1 (2022-06-23)
Warning message:
package(s) not installed when version(s) same as current; use `force = TRUE` to re-install:
  'TCGAbiolinks' 
> BiocManager::install("EDASeq")
'getOption("repos")' replaces Bioconductor standard repositories, see '?repositories' for details

replacement repositories:
    CRAN: https://cran.rstudio.com/

Bioconductor version 3.15 (BiocManager 1.30.18), R 4.2.1 (2022-06-23)
Installing package(s) 'EDASeq'
also installing the dependencies ‘GenomicAlignments’, ‘Rhtslib’, ‘rtracklayer’, ‘ShortRead’, ‘Rsamtools’, ‘GenomicFeatures’

Warning: unable to access index for repository https://bioconductor.org/packages/3.15/bioc/bin/macosx/big-sur-arm64/contrib/4.2:
  cannot open URL 'https://bioconductor.org/packages/3.15/bioc/bin/macosx/big-sur-arm64/contrib/4.2/PACKAGES'
Warning: unable to access index for repository https://bioconductor.org/packages/3.15/data/annotation/bin/macosx/big-sur-arm64/contrib/4.2:
  cannot open URL 'https://bioconductor.org/packages/3.15/data/annotation/bin/macosx/big-sur-arm64/contrib/4.2/PACKAGES'
Warning: unable to access index for repository https://bioconductor.org/packages/3.15/data/experiment/bin/macosx/big-sur-arm64/contrib/4.2:
  cannot open URL 'https://bioconductor.org/packages/3.15/data/experiment/bin/macosx/big-sur-arm64/contrib/4.2/PACKAGES'
Warning: unable to access index for repository https://bioconductor.org/packages/3.15/workflows/bin/macosx/big-sur-arm64/contrib/4.2:
  cannot open URL 'https://bioconductor.org/packages/3.15/workflows/bin/macosx/big-sur-arm64/contrib/4.2/PACKAGES'
Warning: unable to access index for repository https://bioconductor.org/packages/3.15/books/bin/macosx/big-sur-arm64/contrib/4.2:
  cannot open URL 'https://bioconductor.org/packages/3.15/books/bin/macosx/big-sur-arm64/contrib/4.2/PACKAGES'
Packages which are only available in source form, and may need compilation of
  C/C++/Fortran: ‘GenomicAlignments’ ‘Rhtslib’ ‘rtracklayer’ ‘ShortRead’ ‘Rsamtools’
Do you want to attempt to install these from sources? (Yes/no/cancel) Yes
installing the source packages ‘GenomicAlignments’, ‘Rhtslib’, ‘rtracklayer’, ‘ShortRead’, ‘Rsamtools’, ‘GenomicFeatures’, ‘EDASeq’

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/GenomicAlignments_1.32.1.tar.gz'
Content type 'application/x-gzip' length 2220464 bytes (2.1 MB)
==================================================
downloaded 2.1 MB

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/Rhtslib_1.28.0.tar.gz'
Content type 'application/x-gzip' length 1470492 bytes (1.4 MB)
==================================================
downloaded 1.4 MB

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/rtracklayer_1.56.1.tar.gz'
Content type 'application/x-gzip' length 4018019 bytes (3.8 MB)
==================================================
downloaded 3.8 MB

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/ShortRead_1.54.0.tar.gz'
Content type 'application/x-gzip' length 5184736 bytes (4.9 MB)
==================================================
downloaded 4.9 MB

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/Rsamtools_2.12.0.tar.gz'
Content type 'application/x-gzip' length 2870358 bytes (2.7 MB)
==================================================
downloaded 2.7 MB

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/GenomicFeatures_1.48.4.tar.gz'
Content type 'application/x-gzip' length 1183732 bytes (1.1 MB)
==================================================
downloaded 1.1 MB

trying URL 'https://bioconductor.org/packages/3.15/bioc/src/contrib/EDASeq_2.30.0.tar.gz'
Content type 'application/x-gzip' length 1036427 bytes (1012 KB)
==================================================
downloaded 1012 KB

* installing *source* package ‘Rhtslib’ ...
** using non-staged installation via StagedInstall field
** libs
cd "htslib-1.7" && make -f "/Library/Frameworks/R.framework/Resources/etc/Makeconf" -f "Makefile.Rhtslib"
Makefile.Rhtslib:131: warning: overriding commands for target `.c.o'
/Library/Frameworks/R.framework/Resources/etc/Makeconf:168: warning: ignoring old commands for target `.c.o'
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o kfunc.o kfunc.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o knetfile.o knetfile.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o kstring.o kstring.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o bcf_sr_sort.o bcf_sr_sort.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o bgzf.o bgzf.c
bgzf.c:1026:16: warning: variable 'size' set but not used [-Wunused-but-set-variable]
    int count, size = 0, block_length, remaining;
               ^
1 warning generated.
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o errmod.o errmod.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o faidx.o faidx.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o hfile.o hfile.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o hfile_net.o hfile_net.c
echo '#define HTS_VERSION "1.7"' > version.h
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o hts.o hts.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o hts_os.o hts_os.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o md5.o md5.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o multipart.o multipart.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o probaln.o probaln.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o realn.o realn.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o regidx.o regidx.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o sam.o sam.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o synced_bcf_reader.o synced_bcf_reader.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o vcf_sweep.o vcf_sweep.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o tbx.o tbx.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o textutils.o textutils.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o thread_pool.o thread_pool.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o vcf.o vcf.c
vcf.c:641:14: warning: variable 'needs_sync' set but not used [-Wunused-but-set-variable]
    int len, needs_sync = 0, done = 0;
             ^
vcf.c:2826:50: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
    int i, ndst_ori = dst->nhrec, need_sync = 0, ret = 0;
                                                 ^
2 warnings generated.
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o vcfutils.o vcfutils.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o cram/cram_codecs.o cram/cram_codecs.c
cram/cram_codecs.c:1268:19: warning: variable 'ntot' set but not used [-Wunused-but-set-variable]
    int nvals, i, ntot = 0, max_val = 0, min_val = INT_MAX, k;
                  ^
1 warning generated.
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o cram/cram_decode.o cram/cram_decode.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o cram/cram_encode.o cram/cram_encode.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o cram/cram_external.o cram/cram_external.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o cram/cram_index.o cram/cram_index.c
clang -arch arm64 -falign-functions=64 -Wall -g -O2 -fpic -I. -I/opt/R/arm64/include -D_FILE_OFFSET_BITS=64 -c -o cram/cram_io.o cram/cram_io.c
cram/cram_io.c:61:10: fatal error: 'lzma.h' file not found
#include <lzma.h>
         ^~~~~~~~
1 error generated.
make[1]: *** [cram/cram_io.o] Error 1
make: *** [htslib] Error 2
ERROR: compilation failed for package ‘Rhtslib’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/Rhtslib’
ERROR: dependency ‘Rhtslib’ is not available for package ‘Rsamtools’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/Rsamtools’
ERROR: dependency ‘Rsamtools’ is not available for package ‘GenomicAlignments’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/GenomicAlignments’
ERROR: dependencies ‘Rsamtools’, ‘GenomicAlignments’ are not available for package ‘rtracklayer’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/rtracklayer’
ERROR: dependencies ‘Rsamtools’, ‘GenomicAlignments’, ‘Rhtslib’ are not available for package ‘ShortRead’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/ShortRead’
ERROR: dependency ‘rtracklayer’ is not available for package ‘GenomicFeatures’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/GenomicFeatures’
ERROR: dependencies ‘ShortRead’, ‘Rsamtools’, ‘GenomicFeatures’ are not available for package ‘EDASeq’
* removing ‘/Library/Frameworks/R.framework/Versions/4.2-arm64/Resources/library/EDASeq’

The downloaded source packages are in
    ‘/private/var/folders/3g/tfj46mf17v15t515hjnb1c3m0000gn/T/RtmplSzhiv/downloaded_packages’
Warning messages:
1: In install.packages(...) :
  installation of package ‘Rhtslib’ had non-zero exit status
2: In install.packages(...) :
  installation of package ‘Rsamtools’ had non-zero exit status
3: In install.packages(...) :
  installation of package ‘GenomicAlignments’ had non-zero exit status
4: In install.packages(...) :
  installation of package ‘rtracklayer’ had non-zero exit status
5: In install.packages(...) :
  installation of package ‘ShortRead’ had non-zero exit status
6: In install.packages(...) :
  installation of package ‘GenomicFeatures’ had non-zero exit status
7: In install.packages(...) :
  installation of package ‘EDASeq’ had non-zero exit status
> library(EDAseq)
Error in library(EDAseq) : there is no package called ‘EDAseq’
TCGAbiolinks BiocManager • 429 views
ADD COMMENT
0
Entering edit mode

Can you install samtools via conda? That should include the lzma.h headers.

ADD REPLY
1
Entering edit mode
9 weeks ago
Gordon Smyth ★ 5.2k

See https://stat.ethz.ch/pipermail/bioc-devel/2022-September/019178.html

PS. I'm curious why you don't sent such a Bioconductor-specific question as this to the Bioconductor support site at https://support.bioconductor.org ? This question has been asked many times on that forum, see for example the response from one of the Bioconductor core team: https://support.bioconductor.org/p/9137290/#9137342

ADD COMMENT
0
Entering edit mode

The problem is resolved by installing the intel version R. Thanks!

ADD REPLY
0
Entering edit mode

Yes, that's right. But the point of the bioc-devel post that I linked to is that, starting from today, you shouldn't need to install the intel version in order to resolve the issue. From today, Bioconductor installation should work for arm64 R as well.

ADD REPLY

Login before adding your answer.

Traffic: 2397 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