mengyao / Complete-Striped-Smith-Waterman-Library

298 stars 113 forks source link

problem while running make #50

Closed lfaino closed 2 years ago

lfaino commented 7 years ago

Dear Dev, i get an error

luigi@VAIO:~/bin$ git clone https://github.com/mengyao/Complete-Striped-Smith-Waterman-Library.git && mv Complete-Striped-Smith-Waterman-Library SW && cd SW/src/ && make Cloning into 'Complete-Striped-Smith-Waterman-Library'... remote: Counting objects: 1530, done. remote: Compressing objects: 100% (13/13), done. remote: Total 1530 (delta 5), reused 5 (delta 2), pack-reused 1515 Receiving objects: 100% (1530/1530), 12.21 MiB | 1.21 MiB/s, done. Resolving deltas: 100% (942/942), done. Checking connectivity... done. gcc -c -o ssw.o ssw.c -Wall -pipe -O2 gcc -o ssw_test ssw.o main.c -Wall -pipe -O2 -lm -lz gcc -o example_c ssw.o example.c -Wall -pipe -O2 -lm -lz g++ -c -o ssw_cpp.o ssw_cpp.cpp -Wall -pipe -O2 g++ -o example_cpp example.cpp ssw.o ssw_cpp.o -Wall -pipe -O2 -lm -lz example.cpp: In function ‘int main()’: example.cpp:25:41: error: ‘strlen’ was not declared in this scope int32_t maskLen = strlen(query.c_str())/2; ^ make: *** [example_cpp] Error 1

I think that i found the error. The error is in a parenthesis in the following part of the code. can you please fix it? here the code

int main() { const string ref = "CAGCCTTTCTGACCCGGAAATCAAAATAGGCACAACAAA"; const string query = "CTGAGCCGGTAAATC"; int32_t maskLen = **strlen(query.c_str())/2;** maskLen = maskLen < 15 ? 15 : maskLen; //const string ref = "CCGTTTATCGCA"; //const string query = "CCTTTTATCGCA";

thanks

mengyao commented 7 years ago

Hi,

Thank you for letting me know this error. It is fixed now.

Please have a check and let me know if you still meet any problem.

Yours,

Mengyao

On Sun, Jun 4, 2017 at 4:22 AM, lfaino notifications@github.com wrote:

Dear Dev, i get an error

luigi@VAIO:~/bin$ git clone https://github.com/mengyao/ Complete-Striped-Smith-Waterman-Library.git && mv Complete-Striped-Smith-Waterman-Library SW && cd SW/src/ && make Cloning into 'Complete-Striped-Smith-Waterman-Library'... remote: Counting objects: 1530, done. remote: Compressing objects: 100% (13/13), done. remote: Total 1530 (delta 5), reused 5 (delta 2), pack-reused 1515 Receiving objects: 100% (1530/1530), 12.21 MiB | 1.21 MiB/s, done. Resolving deltas: 100% (942/942), done. Checking connectivity... done. gcc -c -o ssw.o ssw.c -Wall -pipe -O2 gcc -o ssw_test ssw.o main.c -Wall -pipe -O2 -lm -lz gcc -o example_c ssw.o example.c -Wall -pipe -O2 -lm -lz g++ -c -o ssw_cpp.o ssw_cpp.cpp -Wall -pipe -O2 g++ -o example_cpp example.cpp ssw.o ssw_cpp.o -Wall -pipe -O2 -lm -lz example.cpp: In function ‘int main()’: example.cpp:25:41: error: ‘strlen’ was not declared in this scope int32_t maskLen = strlen(query.c_str())/2; ^ make: *** [example_cpp] Error 1

I think that i found the error. The error is in a parenthesis in the following part of the code. can you please fix it? here the code

int main() { const string ref = "CAGCCTTTCTGACCCGGAAATCAAAATAGGCACAACAAA"; const string query = "CTGAGCCGGTAAATC"; int32_t maskLen = strlen(query.c_str())/2; maskLen = maskLen < 15 ? 15 : maskLen; //const string ref = "CCGTTTATCGCA"; //const string query = "CCTTTTATCGCA";

int main() { const string ref = "CAGCCTTTCTGACCCGGAAATCAAAATAGGCACAACAAA"; const string query = "CTGAGCCGGTAAATC"; int32_t maskLen =strlen(query.c_str())/2; maskLen = maskLen < 15 ? 15 : maskLen; //const string ref = "CCGTTTATCGCA"; //const string query = "CCTTTTATCGCA";

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mengyao/Complete-Striped-Smith-Waterman-Library/issues/50, or mute the thread https://github.com/notifications/unsubscribe-auth/AAlVdJZIMhimxFZ1BqJ8WQh8ali56VHgks5sAmlNgaJpZM4NvT25 .