Author: osallou Date: 2013-08-05 14:58:04 +0000 (Mon, 05 Aug 2013) New Revision: 14352
Added: trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_debian_zlib trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_libsam Modified: trunk/packages/soap/soapdenovo2/trunk/debian/copyright trunk/packages/soap/soapdenovo2/trunk/debian/patches/series Log: add patches to use debian libs and get compilation Modified: trunk/packages/soap/soapdenovo2/trunk/debian/copyright =================================================================== --- trunk/packages/soap/soapdenovo2/trunk/debian/copyright 2013-08-05 12:55:59 UTC (rev 14351) +++ trunk/packages/soap/soapdenovo2/trunk/debian/copyright 2013-08-05 14:58:04 UTC (rev 14352) @@ -3,6 +3,12 @@ Source: http://soap.genomics.org.cn/soapdenovo.html Files-Excluded: standardPregraph/*.a + standardPregraph/inc/sam.h + standardPregraph/inc/bam.h + standardPregraph/inc/bgzf.h + sparsePregraph/inc/sam.h + sparsePregraph/inc/bam.h + sparsePregraph/inc/bgzf.h standardPregraph/inc/zlib.h standardPregraph/inc/zconf.h sparsePregraph/inc/zlib.h Modified: trunk/packages/soap/soapdenovo2/trunk/debian/patches/series =================================================================== --- trunk/packages/soap/soapdenovo2/trunk/debian/patches/series 2013-08-05 12:55:59 UTC (rev 14351) +++ trunk/packages/soap/soapdenovo2/trunk/debian/patches/series 2013-08-05 14:58:04 UTC (rev 14352) @@ -1,3 +1,5 @@ +use_libsam fix_compilation fix_usage_name add_hardening +use_debian_zlib Added: trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_debian_zlib =================================================================== --- trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_debian_zlib (rev 0) +++ trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_debian_zlib 2013-08-05 14:58:04 UTC (rev 14352) @@ -0,0 +1,228 @@ +Subject: use Debian zlib library +Description: Debian library is more recent than the one embedded upstream. + Its API changed and code needs to be updated to use this version. + See more info here: + http://www.postgresql.org/message-id/1329988571.6474.9.ca...@vanquo.pezone.net +Author: Olivier Sallou <osal...@debian.org> +Last-Updated: 2013-08-05 +Forwaded: no +--- a/standardPregraph/prlRead2Ctg.c ++++ b/standardPregraph/prlRead2Ctg.c +@@ -424,7 +424,7 @@ + } + } + +-static void output1read_gz ( int t, gzFile * outfp, gzFile * outfp2, char orien, int dhflag ) ++static void output1read_gz ( int t, gzFile outfp, gzFile outfp2, char orien, int dhflag ) + { + int len = lenBuffer[t]; + int index; +@@ -500,7 +500,7 @@ + fprintf ( outfp, "\n" ); + } + +-static void getPEreadOnContig ( int t, gzFile * outfp ) ++static void getPEreadOnContig ( int t, gzFile outfp ) + { + int len1, len2, index; + char orien1, orien2; +@@ -560,7 +560,7 @@ + } + }*/ + +-static void getReadIngap ( int t, int insSize, gzFile * outfp1, gzFile * outfp2, boolean readOne ) ++static void getReadIngap ( int t, int insSize, gzFile outfp1, gzFile outfp2, boolean readOne ) + { + int read1, read2; + char orientation; +@@ -618,7 +618,7 @@ + } + } + +-static void recordAlldgn ( gzFile * outfp, int * insSizeArr, gzFile * outfp1, gzFile * outfp2, gzFile * outfp4 ) ++static void recordAlldgn ( gzFile outfp, int * insSizeArr, gzFile outfp1, gzFile outfp2, gzFile outfp4 ) + { + int t, ctgId; + boolean rd1gap, rd2gap; +@@ -773,7 +773,7 @@ + long long i; + char * src_name, *next_name, name[256]; + FILE * fo2; +- gzFile * fo, *outfp1 = NULL, *outfp2 = NULL, *outfp3 = NULL, *outfp4 = NULL; ++ gzFile fo, outfp1 = NULL, outfp2 = NULL, outfp3 = NULL, outfp4 = NULL; + int maxReadNum, libNo, prevLibNo, insSize = 0; + boolean flag, pairs = 1; + pthread_t threads[thrd_num]; +--- a/standardPregraph/prlReadFillGap.c ++++ b/standardPregraph/prlReadFillGap.c +@@ -104,7 +104,7 @@ + free ( ( void * ) length_array ); + } + +-static long long getRead1by1_gz ( gzFile * fp, DARRAY * readSeqInGap ) ++static long long getRead1by1_gz ( gzFile fp, DARRAY * readSeqInGap ) + { + long long readCounter = 0; + +@@ -206,7 +206,7 @@ + static boolean loadReads4gap ( char * graphfile ) + { + FILE * fp1, *fp2; +- gzFile * fp; ++ gzFile fp; + char name[1024]; + long long readCounter; + +--- a/standardPregraph/output_pregraph.c ++++ b/standardPregraph/output_pregraph.c +@@ -85,7 +85,7 @@ + fclose ( fp ); + } + +-void output_1edge ( preEDGE * edge, gzFile * fp ) ++void output_1edge ( preEDGE * edge, gzFile fp ) + { + int i; + gzprintf ( fp, ">length %d,", edge->length ); +--- a/standardPregraph/orderContig.c ++++ b/standardPregraph/orderContig.c +@@ -5072,7 +5072,7 @@ + char name[256], *line; + FILE * fp1; + FILE * linkF; +- gzFile * fp2; ++ gzFile fp2; + int i; + int flag = 0; + unsigned int j; +--- a/standardPregraph/node2edge.c ++++ b/standardPregraph/node2edge.c +@@ -37,8 +37,8 @@ + static preEDGE temp_edge; // for temp use in merge_V2() + static char edge_seq[100000]; //use this static 'edge_seq ' as an temp seq in merge_V2() for speed .. + +-static void make_edge ( gzFile * fp ); +-static void merge_linearV2 ( char bal_edge, STACK * nStack, int count, gzFile * fp ); ++static void make_edge ( gzFile fp ); ++static void merge_linearV2 ( char bal_edge, STACK * nStack, int count, gzFile fp ); + static int check_iden_kmerList ( STACK * stack1, STACK * stack2 ); + + //for stack +@@ -60,7 +60,7 @@ + *************************************************/ + void kmer2edges ( char * outfile ) + { +- gzFile * fp; ++ gzFile fp; + char temp[256]; + sprintf ( temp, "%s.edge.gz", outfile ); + fp = gzopen ( temp, "w" ); +@@ -234,7 +234,7 @@ + Return: + 0. + *************************************************/ +-static int startEdgeFromNode ( kmer_t * node1, gzFile * fp ) ++static int startEdgeFromNode ( kmer_t * node1, gzFile fp ) + { + int node_c, palindrome; + unsigned char flag; +@@ -363,7 +363,7 @@ + Return: + None. + *************************************************/ +-void make_edge ( gzFile * fp ) ++void make_edge ( gzFile fp ) + { + int i = 0; + kmer_t * node1; +@@ -427,7 +427,7 @@ + Return: + None. + *************************************************/ +-static void merge_linearV2 ( char bal_edge, STACK * nStack, int count, gzFile * fp ) ++static void merge_linearV2 ( char bal_edge, STACK * nStack, int count, gzFile fp ) + { + int length, char_index; + preEDGE * newedge; +--- a/standardPregraph/loadPreGraph.c ++++ b/standardPregraph/loadPreGraph.c +@@ -449,7 +449,7 @@ + { + char c, name[256], line[1024], str[32]; + char * tightSeq = NULL; +- gzFile * fp; ++ gzFile fp; + Kmer from_kmer, to_kmer; + int n = 0, i, length, cvg, index = -1, bal_ed, edgeno; + int linelen; +--- a/standardPregraph/kmer.c ++++ b/standardPregraph/kmer.c +@@ -483,7 +483,7 @@ + fprintf ( fp, "%c", c ); + } + +-void print_kmer_gz ( gzFile * fp, Kmer kmer, char c ) ++void print_kmer_gz ( gzFile fp, Kmer kmer, char c ) + { + gzprintf ( fp, "%llx %llx %llx %llx", kmer.high1, kmer.low1, kmer.high2, kmer.low2 ); + gzprintf ( fp, "%c", c ); +@@ -795,7 +795,7 @@ + fprintf ( fp, "%c", c ); + } + +-void print_kmer_gz ( gzFile * fp, Kmer kmer, char c ) ++void print_kmer_gz ( gzFile fp, Kmer kmer, char c ) + { + gzprintf ( fp, "%llx %llx", kmer.high, kmer.low ); + gzprintf ( fp, "%c", c ); +--- a/standardPregraph/attachPEinfo.c ++++ b/standardPregraph/attachPEinfo.c +@@ -492,7 +492,7 @@ + Return: + Loaded alignment record number. + *************************************************/ +-int connectByPE_grad_gz ( gzFile * fp, int peGrad, char * line ) ++int connectByPE_grad_gz ( gzFile fp, int peGrad, char * line ) + { + long long pre_readno, readno, minno, maxno; + int pre_pos, pos, flag, PE, count = 0, Total_PE = 0; +--- a/standardPregraph/inc/extfunc.h ++++ b/standardPregraph/inc/extfunc.h +@@ -79,10 +79,10 @@ + extern int putInsertS ( long long readid, int size, int * currGrads ); + extern int getInsertS ( long long readid, int * readlen ); + extern int connectByPE_grad ( FILE * fp, int peGrad, char * line ); +-extern int connectByPE_grad_gz ( gzFile * fp, int peGrad, char * line ); ++extern int connectByPE_grad_gz ( gzFile fp, int peGrad, char * line ); + extern void PEgradsScaf ( char * infile ); + extern void reorderAnnotation ( char * infile, char * outfile ); +-extern void output_1edge ( preEDGE * edge, gzFile * fp ); ++extern void output_1edge ( preEDGE * edge, gzFile fp ); + extern void prlRead2edge ( char * libfile, char * outfile ); + extern void annotFileTrans ( char * infile, char * outfile ); + extern void prlLoadPath ( char * graphfile ); +--- a/standardPregraph/hashFunction.c ++++ b/standardPregraph/hashFunction.c +@@ -82,7 +82,7 @@ + }; + + typedef int ( *CRC32CFunctionPtr ) ( uint32_t, const char *, size_t ); +-static CRC32CFunctionPtr crc32; ++static CRC32CFunctionPtr s_crc32; + + static uint32_t cpuid ( uint32_t functionInput ) + { +@@ -145,11 +145,11 @@ + + ubyte8 hash_kmer ( Kmer kmer ) + { +- return ( crc32 ( 0, ( char * ) &kmer, sizeof ( Kmer ) ) ); ++ return ( s_crc32 ( 0, ( char * ) &kmer, sizeof ( Kmer ) ) ); + } + + void crc32c_Init() + { +- crc32 = detectBestCRC32C(); ++ s_crc32 = detectBestCRC32C(); + } + Added: trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_libsam =================================================================== --- trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_libsam (rev 0) +++ trunk/packages/soap/soapdenovo2/trunk/debian/patches/use_libsam 2013-08-05 14:58:04 UTC (rev 14352) @@ -0,0 +1,42 @@ +Subject: upstream copies libsam headers +Description: use Debian libraries instead of embedded headers +Author: Olivier Sallou <osal...@debian.org> +Last-Updated: 2013-08-05 +Forwarded: no +--- a/sparsePregraph/Makefile ++++ b/sparsePregraph/Makefile +@@ -10,7 +10,7 @@ + build_preArc.o pregraph_sparse.o io_func.o\ + global.o convert_soapdenovo.o + PROG= +-INCLUDES= -I./inc ++INCLUDES= -I./inc -I/usr/include/samtools + SUBDIRS= . + LIBPATH= -L/usr/lib64 + LIBS= -pthread -lz -L./inc +--- a/sparsePregraph/inc/stdinc.h ++++ b/sparsePregraph/inc/stdinc.h +@@ -39,4 +39,4 @@ + + + +- ++#include <stdbool.h> +--- a/standardPregraph/Makefile ++++ b/standardPregraph/Makefile +@@ -25,7 +25,7 @@ + readseq1by1.o scaffold.o searchPath.o seq.o splitReps.o \ + cutTip_graph2.o linearEdge.o kmerhash.o read2edge.o iterate.o + PROG= SOAPdenovo-63mer +-INCLUDES= -Iinc ++INCLUDES= -Iinc -I/usr/include/samtools + SUBDIRS= . + LIBPATH= -L/lib64 -L/usr/lib64 -L./inc + LIBS= -pthread -lz -lm +--- a/standardPregraph/inc/stdinc.h ++++ b/standardPregraph/inc/stdinc.h +@@ -32,3 +32,4 @@ + #include "types.h" + #include <aio.h> + #include <errno.h> ++#include <stdbool.h> _______________________________________________ debian-med-commit mailing list debian-med-commit@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-med-commit