Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to install kraken2 #397

Closed
saras224 opened this issue Jan 15, 2021 · 4 comments
Closed

unable to install kraken2 #397

saras224 opened this issue Jan 15, 2021 · 4 comments

Comments

@saras224
Copy link

Hi
I am unable to install kraken2 latest version. it gives me an error but I don't understand how to correct it. Please help.

./install_kraken2.sh /home/rsharma/KRAKEN2_DIR/

  • error: make: Entering directory '/home/rsharma/kraken2-2.1.0/src'
    g++ -fopenmp -Wall -std=c++11 -O3 -DLINEAR_PROBING -c -o estimate_capacity.o estimate_capacity.cc
    cc1plus: error: unrecognized command line option "-std=c++11"
    make: *** [: estimate_capacity.o] Error 1
    make: Leaving directory '/home/rsharma/kraken2-2.1.0/src'
@AGalanis97
Copy link

AGalanis97 commented Jan 15, 2021

Hi @saras224 ,

I think this is probably because you are using an old g++ version. If you run
g++ --version
and get an output below 4.3 it's probably that. So try updating/upgrading. You can try running:
sudo apt-get update
sudo apt-get install gcc-7 g++-7

If that doesn't work try with -6 instead of -7. Not sure if gcc is needed but it may be worth updating too.

From the manual

Dependencies: Kraken 2 currently makes extensive use of Linux utilities such as sed, find, and wget. Many scripts are written using the Bash shell, and the main scripts are written using Perl. Core programs needed to build the database and run the classifier are written in C++11, and need to be compiled using a somewhat recent version of g++ that will support C++11. Multithreading is handled using OpenMP. Downloads of NCBI data are performed by wget and rsync. Most Linux systems will have all of the above listed programs and development libraries available either by default or via package download.

Unlike Kraken 1, Kraken 2 does not use an external $k$-mer counter. However, by default, Kraken 2 will attempt to use the dustmasker or segmasker programs provided as part of NCBI's BLAST suite to mask low-complexity regions (see [Masking of Low-complexity Sequences]).

So try to make sure you have the rest of the dependencies as well! In my system (last year) it was necessary to run these commands before I could proceed:

sudo apt-get install g++
sudo apt-get install ncbi-blast+

@jenniferlu717
Copy link
Collaborator

@saras224 did @AGalanis97 's advice work for you?

@saras224
Copy link
Author

Hi @jenniferlu717
Yes I recently updated my ubuntu version so all dependencies upgraded too. I successfully installed kraken2 but now I am not able to build standard database. I have described my problem in issue #412 opened by Nathalia-Cavichiolli

@jenniferlu717
Copy link
Collaborator

Okay, im going to close this issue but I'll respond to your issue in the other issue thread @saras224

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants