Using Samtools on a Mac terminal
2
1
Entering edit mode
3.6 years ago

Hello,

I have installed Samtools using miniconda (using conda install -c bioconda samtools), and I am trying to run the merge command of Samtools.

I typed this command:

samtools merge D422C01040710.bam D422C01.bam D422C04.bam D422C07.bam D422C10.bam

And I get this error message:

dyld: Library not loaded: @rpath/libcrypto.1.0.0.dylib
  Referenced from: /VAL/DATAVal/ChIPseq/miniconda3/bin/samtools
  Reason: image not found
Abort trap: 6

Can someone help?

Thanks

alignment • 7.2k views
ADD COMMENT
0
Entering edit mode

Please use the formatting bar (especially the code option) to present your post better. You can use backticks for inline code (`text` becomes text), or select a chunk of text and use the highlighted button to format it as a code block. I've done it for you this time.
code_formatting

ADD REPLY
0
Entering edit mode

Which version of samtools did you install?

I recall from a previous thread that you have to explicitly add version number for latest on macOS. conda install -c bioconda samtools=1.11.0. If 1.11.0 is not available then use 1.10.0.

ADD REPLY
1
Entering edit mode
3.0 years ago
Michael 54k

This here is really a similar issue:

https://github.com/conda/conda/issues/8103

Distilling the solution from this post my approach would be:

  • create a new conda envrionment
  • make sure conda_forge and bioconda channnels are activated
    conda config --add channels defaults
    conda config --add channels bioconda
    conda config --add channels conda-forge

following the instructions here: https://bioconda.github.io/user/install.html#set-up-channels

Install samtools into a clean environment:

 conda create -n samtools samtools

.... after a while...

conda activate samtools
samtools --version

samtools 1.12
Using htslib 1.12
Copyright (C) 2021 Genome Research Ltd.
....

Just tested it right now.

ADD COMMENT
0
Entering edit mode
3.0 years ago

I have the exact same issue. Took me a while to find literature on this.

The resolution in beautifully simple:

https://github.com/conda/conda/issues/6183#issuecomment-337432739

However, understanding the resolution is an exercise I leave to the reader.

ADD COMMENT
0
Entering edit mode

WARNING SECURITY HAZARD! This is not a proper solution. The issue is similar at first glance but not identical. In both cases a dynamically linked library (dylib, named .so under linux) is not found, but it is not the same. In this case you are missing libcrypto while the link mentions libreadline. Also the solution is pulling code from a "personal" conda channel. It might work, but likely you need to activate the conda-forge channel instead to pull libcrypto.

ADD REPLY

Login before adding your answer.

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