dib-lab / khmer

In-memory nucleotide sequence k-mer counting, filtering, graph traversal and more
http://khmer.readthedocs.io/
Other
756 stars 295 forks source link

pip install not compiling correctly #1810

Closed arivers closed 7 years ago

arivers commented 7 years ago

I installed khmer via pip a few weeks ago without any problem but when I try today I get the error:

 gcc -pthread -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DVERSION=2.1 -DSEQAN_HAS_BZIP2=1 -DSEQAN_HAS_ZLIB=1 -UNO_UNIQUE_RC -Ilib -Ithird-party/zlib -Ithird-party/bzip2 -Ithird-party/seqan/core/include -Ithird-party/smhasher -I/home/adam.rivers/.conda/envs/vicaenv/include/python3.5m -c khmer/_khmer.cc -o build/temp.linux-x86_64-3.5/khmer/_khmer.o -O3 -std=c++11 -pedantic -fopenmp
  cc1plus: warning: command line option "-Wstrict-prototypes" is valid for Ada/C/ObjC but not for C++
  cc1plus: error: unrecognized command line option "-std=c++11"
  error: command 'gcc' failed with exit status 1

I'm using gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-16) on centos-release-6-7.el6.centos.12.3.x86_64

ctb commented 7 years ago

Hi @arivers your message got truncated!

arivers commented 7 years ago

Khmer 2.1.1 does compile with pip when using clang (clang-800.0.42.1) on OSX 10.13.

arivers commented 7 years ago

Hi Titus,

I edited my original post to add additional information about the compilation error. Let me know if you need anything more.

ctb commented 7 years ago

thank you!

betatim commented 7 years ago

@arivers is it at all possible to use a newer version of GCC? Version 4.4 does not support the -std=c++11 flag because it doesn't support quite all of c++11. If you can't use a more modern gcc version replace -std=c++11 with -std=c++0x: here here and here and try again. I don't quite remember which features were still missing in 4.4 and whether or not we use those.


I thought we had documented in the khmer docs what the minimum required version of gcc was but I can't find it. Is it really missing or do I need better 👓?

arivers commented 7 years ago

Thanks, switching to gcc 5.3.0 solved the problem. I see (now) that gcc >4.8.2 was specified in the developer docs. https://khmer.readthedocs.io/en/v2.1.2/dev/guidelines-continued-dev.html

ctb commented 7 years ago

thank you for following through, adam!