Compiling error

608 views
Skip to first unread message

Quanxin Zhou

unread,
Jan 28, 2015, 12:20:28 PM1/28/15
to rna-...@googlegroups.com
Hello, everyone

I tried to compile STAR-STAR_2.4.0i on my Mac, here is the error :

/usr/local/bin/gcc-4.8 -c -D'COMPILE_FOR_MAC' -I ./Mac_Include/ -O3 -pipe -std=c++0x -Wall -Wextra -fopenmp -D'COMPILATION_TIME_PLACE="Wed 28 Jan 2015 12:09:11 EST :/Users/workspace/STAR-STAR_2.4.0i/source"'    bam_cat.c

cc1: warning: command line option '-std=c++11' is valid for C++/ObjC++ but not for C [enabled by default]

bam_cat.c:54:19: fatal error: cstring: No such file or directory

 #include <cstring>

                   ^

compilation terminated.

make: *** [bam_cat.o] Error 1


I use Mac OS X version 10.9.5 


Thanks 

Alexander Dobin

unread,
Jan 28, 2015, 5:03:12 PM1/28/15
to rna-...@googlegroups.com
Hi Quanxin,

I believe there is a problem with linking standard gcc libraries.
Please try  "make STARforMacStatic", if it does not work, please use the pre-compiled Mac executable.

Cheers
Alex

Quanxin Zhou

unread,
Jan 29, 2015, 11:25:32 AM1/29/15
to rna-...@googlegroups.com
Thank you, it is fixed.

Yuande Tan

unread,
Jul 12, 2016, 12:00:56 PM7/12/16
to rna-star
Dear Alex,
I am also new one for bioinformatics and I want to install star and also meet the same problem as Dr.Zhou.
You suggested Dr.Zhou use the pre-compiled Mac executable. Would you like give me more detail instruction of how to use pre-compiled Mac executable?

Thanks.

Yuanda Tan

Alexander Dobin

unread,
Jul 12, 2016, 5:44:18 PM7/12/16
to rna-star
Hi Yuande,

after you download and unzip STAR release (such as https://github.com/alexdobin/STAR/archive/2.5.2a.zip)
you will see bin/MacOSX_x86_64/STAR executable.

Cheers
Alex

Yuande Tan

unread,
Jul 13, 2016, 12:32:29 PM7/13/16
to rna-star
Thanks, Alex.
Is STAR in bin/MacOSX_x86_64/  executable file? If it is, then don't  I need to use "make" to compile STAR but just use  chmod 755 to make STAR executable? 
I am looking forward to hearing of your answer.

Best wishes,

Yuande

Alexander Dobin

unread,
Jul 13, 2016, 3:41:18 PM7/13/16
to rna-star
Hi Yuande,

yes the STAR is the executable, and you can run it right away without the need to compile.
If it does not have user execution permissions, you need to "chmod u+x STAR" .

Cheers
Alex

Yuande Tan

unread,
Jul 14, 2016, 1:20:38 PM7/14/16
to rna-star
Hi Alex,
Thank you so much for your great help. I got it and ran it successful at step 1 for generating genome index. 
But when I run step2  for mapping, I met segment fault 11 problem:

bash-3.2$ bin/star --genomeDir data/GRCh38/star_indices_overhang100/ --runThreadN 4 --readFilesIn data/GRCh38/sequence/Homo_sapiens.GRCh38.dna.chromosome.1.fa --outFileNamePrefix data/GRCh38/results/chr1

Jul 14 11:30:07 ..... Started STAR run

Jul 14 11:30:07 ..... Loading genome

Jul 14 11:34:14 ..... Started mapping

Segmentation fault: 11


It seems memory problem. 
Would you like to help me to address this problem: this segmentation fault: 11 ?
I am asked to use star to perform analysis of RNA-seq data.

Best wishes,

Yuande

Alexander Dobin

unread,
Jul 15, 2016, 1:12:15 PM7/15/16
to rna-star
Hi Yuande, 

please send my your Log.out file and also a first few reads from the file you are mapping.
You are mapping short reads, right - the name of the file data/GRCh38/sequence/Homo_sapiens.GRCh38.dna.chromosome.1.fa looks suspicious.

Cheers
Alex

Yuande Tan

unread,
Jul 15, 2016, 3:56:03 PM7/15/16
to rna-star
Hi Ales,

Thank you for your great help. I attached chr1Log.out file for you the read files were downloaded from 

ftp://ftp.ensembl.org/pub/release-77/fasta/homo_sapiens/dna/Homo_sapiens.GRCh38.dna.chromosome.{1..22}.fa.gz


I used readFilesCommand gzip -c for *.fa.gz and also got problem:


bin/star --genomeDir data/GRCh38/star_indices_overhang100/ --runThreadN 4 --readFilesIn data/GRCh38/sequence/Homo_sapiens.GRCh38.dna.chromosome.10.fa.gz --readFilesCommand gzip -c --outFileNamePrefix data/GRCh38/results/chr10

Jul 15 14:17:21 ..... Started STAR run

Jul 15 14:17:21 ..... Loading genome

Jul 15 14:21:21 ..... Started mapping


ReadAlignChunk_processChunks.cpp:115:processChunks EXITING because of FATAL ERROR in input reads: unknown file format: the read ID should start with @ or > 


However, I successfully passed the step1 to construct indices using the same DNA reads.


You may be right, that is, the reads have problem.


But I need your help.


Thank you again.


Yuande

chr1Log.out

Alexander Dobin

unread,
Jul 15, 2016, 4:32:20 PM7/15/16
to rna-star
Hi Yuande,

the files from ENSEMBL are not "short reads" - they are the reference genome sequences. STAR uses them to generate genome indexes.
In the mapping step, you supply the "FASTQ" files of short reads in the --readFilesIn option.

Cheers
Alex

Yuande Tan

unread,
Jul 18, 2016, 12:40:34 PM7/18/16
to rna-star
Hi Alex, 

You are great. I got it from your instruction but what is Killer: 9? I checked HN626_GCCAATGT_L001Log.progress.out, it seems to work.
Is that OK?

Thank so much.

Yuande

Yuande Tan

unread,
Jul 19, 2016, 3:14:37 PM7/19/16
to rna-star

Hi Alex,
I used --limitIObufferSize 50000000 and --limitBAMsortRAM 20000000000, the run was finished successfully. 
My question is, did they impact the results of RNA reads mapped to reference genome? That is, the counts of reads are correct?

I am looking forward to hearing from you soon.

Thank so much for your help.

Yuande

Alexander Dobin

unread,
Jul 21, 2016, 6:52:36 PM7/21/16
to rna-star
Hi Yuande,

these parameters do not affect the results - they reduce the RAM consumption at the price of  reducing the mapping speed.

Cheers
Alex
Reply all
Reply to author
Forward
0 new messages