Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • imilne
    Member
    • Jan 2010
    • 68

    Compile samtools on Windows so it doesn't need Cygwin

    I assume this can be done, because the binaries that are available on the samtools website (for 0.1.7 and earlier) don't need a Cygwin environment to run?

    I can compile everything fine within Cygwin, but attempting to run the following with the latest source code (0.1.11) fails.

    Code:
    $ make -f Makefile.mingw
    gcc.exe -c -g -Wall -O2 -mno-cygwin -D_CURSES_LIB=2 -D_USE_KNETFILE -Iwin32 bam_tview.c -o bam_tview.o
    gcc.exe -c -g -Wall -O2 -mno-cygwin -D_CURSES_LIB=2 -D_USE_KNETFILE -Iwin32 bam_maqcns.c -o bam_maqcns.o
    bam_maqcns.c: In function `ks_shuffle_uint32_t':
    bam_maqcns.c:8: warning: implicit declaration of function `drand48'
    gcc.exe -c -g -Wall -O2 -mno-cygwin -D_CURSES_LIB=2 -D_USE_KNETFILE -Iwin32 bam_plcmd.c -o bam_plcmd.o
    bam_plcmd.c: In function `pileup_func':
    bam_plcmd.c:247: warning: implicit declaration of function `drand48'
    In file included from bam2bcf.h:6,
                     from bam_plcmd.c:526:
    bcftools/bcf.h:35:18: bgzf.h: No such file or directory
    make: *** [bam_plcmd.o] Error 1
    Am I even using the right command?

    I ultimately need a samtools.exe that can be given to people that don't have Cygwin.

    Thanks
    Our software: Tablet | Flapjack | Strudel | CurlyWhirly | TOPALi
  • vixensjlin
    Junior Member
    • Aug 2012
    • 4

    #2
    Have you try this one?

    samtools (Tools for alignments in the SAM format) on BOW - Bioinformatics On Windows

    Comment

    • esraa
      Junior Member
      • Mar 2016
      • 4

      #3
      I am asking if samtools work on windows and C program or another software ?

      Comment

      • Richard Finney
        Senior Member
        • Feb 2009
        • 701

        #4
        #1 Install bzip2 libraries on cygwin.

        #2 several ways around drand48() problem.

        You can duckduckgo for "cygwin drand48"
        suggestion but I have not tried:
        One solution is just doing this ... just jam it in a header file.

        #ifdef CYGWIN32
        #define rand48 random
        #endif

        You can hack the makefile on the compiler options line to put in this define.

        You can also swiped drand48.c from somewhere and just jam it in a C file.

        I've compiled samtools on cygwin using gcc, though it's a moving target as it's fine tuned for Linux and
        portability to windows was never a high priority. Code changes don't always port easily.

        Compiling with Visual C is an epic adventure.
        Last edited by Richard Finney; 04-05-2016, 05:42 AM.

        Comment

        Latest Articles

        Collapse

        • GATTACAT
          Reply to Nine Things a Sample Prep Scientist Thinks About Before Sequencing
          by GATTACAT
          Love this - good data definitely starts from good input, and poor input can only give relatively poor data. I particularly like the mention of Nanodrop/absorbance based methods for quantification. It's such a toss up if you'll get an accurate reading or what amounts to a randomly generated number, and a lot of library/sequencing related issues can be traced back to poor quant.
          07-01-2026, 11:43 AM
        • SEQadmin2
          Nine Things a Sample Prep Scientist Thinks About Before Sequencing
          by SEQadmin2


          I’m not a sequencing expert. I’m a purification scientist who uses NGS to evaluate workflows my group develops. With this perspective, we think about the sample first and the NGS workflow second. The sequencer is an exceptionally honest reporter, but it can only report on what you give it, so whether you get clean, interpretable data from an NGS workflow is largely determined before you begin.

          Here are nine questions we think about, in roughly the order they matter, before...
          06-18-2026, 07:11 AM

        ad_right_rmr

        Collapse

        News

        Collapse

        Topics Statistics Last Post
        Started by SEQadmin2, Today, 11:05 AM
        0 responses
        7 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 07-02-2026, 11:08 AM
        0 responses
        28 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 06-30-2026, 05:37 AM
        0 responses
        27 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 06-26-2026, 11:10 AM
        0 responses
        26 views
        0 reactions
        Last Post SEQadmin2  
        Working...