Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • meritxellop
    Junior Member
    • Apr 2010
    • 2

    compiling samtools in mac

    Hi all,

    I'm trying to install samtools-0.1.18 on Mac OS X 10.6.8.
    The the error raised when trying to compile is attached at the end of this post.

    I guess it's an error produced by a missing library, so I have included all the libraries in the maste library (sam.h) with no success...

    Can sb give me a hand, please?

    Thanks

    Meri
    ______

    gcc -g -Wall -O2 -o samtools bam_tview.o bam_plcmd.o sam_view.o bam_rmdup.o bam_rmdupse.o bam_mate.o bam_stat.o bam_color.o bamtk.o kaln.o bam2bcf.o bam2bcf_indel.o errmod.o sample.o cut_target.o phase.o bam2depth.o -Lbcftools libbam.a -lbcf -lcurses -lm -lz
    Undefined symbols:
    "_egzopen", referenced from:
    _loadpos in phase.o
    _bed_read in libbam.a(bedidx.o)
    _sam_open in libbam.a(bam_import.o)
    ___bam_get_lines in libbam.a(bam_import.o)
    _sam_header_read2 in libbam.a(bam_import.o)
    "_egzread", referenced from:
    _ks_getuntil2 in phase.o
    _loadpos in phase.o
    _ks_getuntil2 in libbam.a(bedidx.o)
    _bed_read in libbam.a(bedidx.o)
    _ks_getuntil2 in libbam.a(bam_import.o)
    _sam_header_read2 in libbam.a(bam_import.o)
    "_einflate", referenced from:
    _bgzf_read_block in libbam.a(bgzf.o)
    __razf_read in libbam.a(razf.o)
    "_egzclose", referenced from:
    _loadpos in phase.o
    _bed_read in libbam.a(bedidx.o)
    _sam_close in libbam.a(bam_import.o)
    ___bam_get_lines in libbam.a(bam_import.o)
    _sam_header_read2 in libbam.a(bam_import.o)
    "_edeflate", referenced from:
    _deflate_block in libbam.a(bgzf.o)
    __razf_write in libbam.a(razf.o)
    _razf_write in libbam.a(razf.o)
    _razf_close in libbam.a(razf.o)
    "_einflateEnd", referenced from:
    _bgzf_read_block in libbam.a(bgzf.o)
    _bgzf_read_block in libbam.a(bgzf.o)
    _razf_open_r in libbam.a(razf.o)
    _razf_close in libbam.a(razf.o)
    "_einflateReset", referenced from:
    __razf_reset_read in libbam.a(razf.o)
    "_einflateInit2_", referenced from:
    _bgzf_read_block in libbam.a(bgzf.o)
    _razf_open_r in libbam.a(razf.o)
    "_ecrc32", referenced from:
    _deflate_block in libbam.a(bgzf.o)
    _deflate_block in libbam.a(bgzf.o)
    "_edeflateInit2_", referenced from:
    _deflate_block in libbam.a(bgzf.o)
    _razf_open_w in libbam.a(razf.o)
    "_egzdopen", referenced from:
    _loadpos in phase.o
    _bed_read in libbam.a(bedidx.o)
    _sam_open in libbam.a(bam_import.o)
    ___bam_get_lines in libbam.a(bam_import.o)
    _sam_header_read2 in libbam.a(bam_import.o)
    "_edeflateEnd", referenced from:
    _deflate_block in libbam.a(bgzf.o)
    _deflate_block in libbam.a(bgzf.o)
    _razf_close in libbam.a(razf.o)
    "_edeflateSetHeader", referenced from:
    _razf_open_w in libbam.a(razf.o)
    ld: symbol(s) not found
    collect2: ld returned 1 exit status
    make[1]: *** [samtools] Error 1
    make: *** [all-recur] Error 1
  • adaptivegenome
    Super Moderator
    • Nov 2009
    • 436

    #2
    I think you might need to change the makefile so that instead of "-lcurses" it points to "-lncurses".
    Last edited by adaptivegenome; 01-30-2012, 07:31 AM. Reason: typo

    Comment

    • lifeng.tian
      Member
      • Jul 2009
      • 16

      #3
      Meri,
      The same problem was reported for compiling BWA, see

      BWA make error on Macbook pro
      egzclose/open BWA0.5.7 install

      to check which zlib.h was used, try:
      gcc -E phase.c -o phase.i

      then grep 'zlib'. On my Lion (10.7.2), I see "/usr/include/zlib.h". what's yours?

      Lifeng

      Comment

      • Carlos Borroto
        Member
        • Mar 2011
        • 19

        #4
        You might also want to check out Homebrew

        To install samtools using Homebrew:
        Code:
        $ brew install samtools

        Comment

        Latest Articles

        Collapse

        ad_right_rmr

        Collapse

        News

        Collapse

        Topics Statistics Last Post
        Started by SEQadmin2, 06-09-2026, 11:58 AM
        0 responses
        24 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 06-05-2026, 10:09 AM
        0 responses
        30 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 06-04-2026, 08:59 AM
        0 responses
        39 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 06-02-2026, 12:03 PM
        0 responses
        62 views
        0 reactions
        Last Post SEQadmin2  
        Working...