lh3 / seqtk

Toolkit for processing sequences in FASTA/Q formats
MIT License
1.37k stars 308 forks source link

seqtk compile error from zlib-1.2.8 (using CodeBlocks) #100

Closed rmd13 closed 6 years ago

rmd13 commented 6 years ago

I download the zlib-1.2.8 and unzip it inside the folder seqtk-master, then creat a project in CodeBlocks and add all the files recursively in folder "seqtk-master" and folder "seqtk-master\zlib-1.2.8" , then compile the seqtk.c. Error appears as below: I have tried zlib-1.2.11 but the error still exist. -------------- Build: Debug in seqtk (compiler: GNU GCC Compiler)---------------

mingw32-gcc.exe -Wall -g -ID:\GreenSoft\bioinfo\seqtk-master -ID:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.11 -c D:\GreenSoft\bioinfo\seqtk-master\seqtk.c -o obj\Debug\GreenSoft\bioinfo\seqtk-master\seqtk.o D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_printseq_renamed': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:192:3: warning: unknown conversion type character 'l' in format [-Wformat=] printf("%lld", (long long)n); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:192:3: warning: too many arguments for format [-Wformat-extra-args] D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_comp': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:399:16: warning: variable 'lc' set but not used [-Wunused-but-set-variable] int la, lb, lc, na, nb, nc, cnt[11]; ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_randbase': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:464:5: warning: implicit declaration of function 'drand48' [-Wimplicit-function-declaration] m = (drand48() < 0.5); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_subseq': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:587:5: warning: format '%ld' expects argument of type 'long int', but argument 5 has type 'size_t' [-Wformat=] fprintf(stderr, "[subseq] %s: %d >= %ld\n", seq->name.s, beg, seq->seq.l); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_mergefa': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:660:2: warning: implicit declaration of function 'srand48' [-Wimplicit-function-declaration] srand48(11); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:667:4: warning: format '%ld' expects argument of type 'long int', but argument 4 has type 'size_t' [-Wformat=] fprintf(stderr, "[%s] Unequal sequence length: %ld != %ld\n", func, seq[0]->seq.l, seq[1]->seq.l); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:667:4: warning: format '%ld' expects argument of type 'long int', but argument 5 has type 'size_t' [-Wformat=] D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:702:6: warning: implicit declaration of function 'lrand48' [-Wimplicit-function-declaration] c[0] = (lrand48()&1)? (c[0] & c[1]) : (c[0] | c[1]); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_famask': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:750:4: warning: format '%ld' expects argument of type 'long int', but argument 4 has type 'size_t' [-Wformat=] fprintf(stderr, "[%s] Unequal sequence length: %ld != %ld\n", func, seq[0]->seq.l, seq[1]->seq.l); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:750:4: warning: format '%ld' expects argument of type 'long int', but argument 5 has type 'size_t' [-Wformat=] D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'stk_kfreq': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:1563:3: warning: format '%ld' expects argument of type 'long int', but argument 3 has type 'size_t' [-Wformat=] printf("%s\t%ld\t%c\t%d\t%d\n", ks->name.s, ks->seq.l, "+-"[which], cnt_nei[which], cnt[which]); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c: In function 'fqc_aux': D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:1584:2: warning: unknown conversion type character 'l' in format [-Wformat=] printf("\t%lld", (long long)sum); ^ D:\GreenSoft\bioinfo\seqtk-master\seqtk.c:1584:2: warning: too many arguments for format [-Wformat-extra-args] mingw32-gcc.exe -Wall -g -ID:\GreenSoft\bioinfo\seqtk-master -ID:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.11 -c D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\adler32.c -o obj\Debug\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\adler32.o mingw32-gcc.exe -Wall -g -ID:\GreenSoft\bioinfo\seqtk-master -ID:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.11 -c D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\compress.c -o obj\Debug\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\compress.o mingw32-g++.exe -Wall -g -ID:\GreenSoft\bioinfo\seqtk-master -ID:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.11 -c D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S -o obj\Debug\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.o D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S: Assembler messages: D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:151: Error: bad register name %rsi' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:152: Error: bad register name%rbx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:153: Error: bad register name %r12' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:154: Error: bad register name%r13' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:155: Error: bad register name %r14' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:156: Error: bad register name%r15' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:164: Error: bad register name %rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:165: Error: bad register name%rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:167: Error: bad register name %rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:168: Error: bad register name%rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:184: Error: bad register name %rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:185: Error: bad register name%rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:189: Error: bad register name %r14d' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:193: Error: bad register name%rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:194: Error: bad register name %rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:195: Error: bad register name%r15' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:200: Error: bad register name %r13' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:201: Error: bad register name%r9d' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:202: Error: bad register name %r9d' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:207: Error: bad register name%rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:210: Error: bad register name %r15d' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:211: Error: bad register name%r15d' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:215: Error: bad register name %rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:219: Error: bad register name%r10' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:220: Error: bad register name %r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:226: Error: bad register name%r13)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:227: Error: bad register name %r13' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:228: Error: bad register name%rdi)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:232: Error: bad register name %rsp)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:251: Error: bad register name%rcx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:252: Error: bad register name %r15d' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:256: Error: bad register name%r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:258: Error: bad register name %r12w' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:262: Error: bad register name%rsp)' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:269: Error: bad register name %rdx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:270: Error: bad register name%rsi' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:271: Error: bad register name %r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:272: Error: bad register name%r13' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:275: Error: bad register name %r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:276: Error: bad register name%rcx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:347: Error: bad register name %r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:348: Error: bad register name%rcx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:351: Error: bad register name %r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:352: Error: bad register name%rcx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:355: Error: bad register name %r8' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:356: Error: bad register name%rcx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:359: Error: bad register name %rdx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:373: Error: bad register name%rdx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:375: Error: bad register name %rdx' D:\GreenSoft\bioinfo\seqtk-master\zlib-1.2.8\contrib\amd64\amd64-match.S:378: Error: bad register name%rdx' Process terminated with status 1 (0 minute(s), 1 second(s)) 50 error(s), 14 warning(s) (0 minute(s), 1 second(s))

rmd13 commented 6 years ago

Problem solved by compile it using cygwin.