This is a test version of Biostars. For the public version, visit https://www.biostars.org.
samtools installed but error message: Library not loaded: @rpath/libcrypto.1.0.0.dylib

I would like to convert input.sam to output.bam but I get following error message:

kk$ samtools view -bS input.sam > output.bam

dyld[88970]: Library not loaded: @rpath/libcrypto.1.0.0.dylib
  Referenced from: /Users/kk/opt/anaconda3/bin/samtools
  Reason: tried: '/Users/kk/opt/anaconda3/bin/../lib/libcrypto.1.0.0.dylib' (no such file), '/Users/kk/opt/anaconda3/bin/../lib/libcrypto.1.0.0.dylib' (no such file), '/usr/local/lib/libcrypto.1.0.0.dylib' (no such file), '/usr/lib/libcrypto.1.0.0.dylib' (no such file)
Abort trap: 6
monterey samtools macos

I am also getting the same error when I try to convert to a bam file

dyld[51522]: Library not loaded: @rpath/libcrypto.1.0.0.dylib Referenced from: <3FAE4B52-2497-3D93-BE35-525AAAE38804> /opt/anaconda3/envs/new-env/bin/samtools Reason: tried: '/opt/anaconda3/envs/new-env/bin/../lib/libcrypto.1.0.0.dylib' (no such file), '/opt/anaconda3/envs/new-env/bin/../lib/libcrypto.1.0.0.dylib' (no such file), '/usr/local/lib/libcrypto.1.0.0.dylib' (no such file), '/usr/lib/libcrypto.1.0.0.dylib' (no such file, not in dyld cache) Abort trap: 6

I have tried using the solutions at the link above, I have also tried

conda install -c bioconda samtools

Are there any more suggestions?

Incidentally, I don't seem to be able to update conda, so I don't know if that is related.

(new-env) MACBOOK-H22257Q72N:Jo$ conda install -c bioconda samtools Collecting package metadata (current_repodata.json): done Solving environment: done

==> WARNING: A newer version of conda exists. <== current version: 22.9.0 latest version: 23.5.0

Please update conda by running

$ conda update -n base -c defaults conda
All requested packages already installed.
Retrieving notices: ...working... done (new-env) MACBOOK-H22257Q72N:Jo$ conda install -c bioconda samtools Collecting package metadata (current_repodata.json): done Solving environment: done

==> WARNING: A newer version of conda exists. <== current version: 22.9.0 latest version: 23.5.0

Please update conda by running

$ conda update -n base -c defaults conda
All requested packages already installed.
Retrieving notices: ...working... done

Are you using a M* based Mac or Intel?

Have you tried creating a new environment with a new name to install samtools?

1 answer

Can you try the solution here: Samfile error: dyld: Library not loaded: @rpath/libcrypto.1.0.0.dylib

Log in to answer this question.