pezmaster31 / bamtools

C++ API & command-line toolkit for working with BAM data
MIT License
418 stars 153 forks source link

fatal error: api/BamAlignment.h: No such file or directory #include "api/BamAlignment.h" #188

Closed emmannaemeka closed 3 years ago

emmannaemeka commented 5 years ago

Hello, Please am trying to install bamtools. Running make i got this result which i don't have clue on how to solve it.

[ 0%] Built target AlgorithmsHeaders [ 0%] Built target APIHeaders [ 2%] Building CXX object api/CMakeFiles/BamTools.dir/BamAlignment.o /home/emmanuel/bamtools/src/api/BamAlignment.cpp:10:30: fatal error: api/BamAlignment.h: No such file or directory

include "api/BamAlignment.h"

                          ^

compilation terminated. make[2]: [api/CMakeFiles/BamTools.dir/BamAlignment.o] Error 1 make[1]: [api/CMakeFiles/BamTools.dir/all] Error 2 make: *** [all] Error 2

ghost commented 5 years ago

You have to give the path of include directory and lib directory to your compiler. include->api-> all header files

lib directory >all lib files you can do it either on the terminal and change env variable by giving it to the path of bamtools/lib (if on *nx system) Or change the compiler settings(add external include directory in c++ compiler and lib directory and files of bamtools in the linker)

Good luck! Madiha

emmannaemeka commented 5 years ago

Hi Mahiha, Thanks for the clarification.

I am quite new to this and working on a cluster any simpler way to do this? Thanks Nnadi Nnaemeka Emmanuel,Ph.D Department of Microbiology, Faculty of Natural and Applied Science, Plateau State University, Bokkos, Plateau State, Nigeria. +2348068124819 Publications: https://www.researchgate.net/profile/Emmanuel_Nnadi/publications

On Thu, Apr 18, 2019 at 1:24 PM MadihaLums notifications@github.com wrote:

You have to give the path of include directory and lib directory to your compiler. include->api-> all header files

lib directory >all lib files you can do it either on the terminal and change env variable by giving it to the path of bamtools/lib (if on *nx system) Or change the compiler settings(add external include directory in c++ compiler and lib directory and files of bamtools in the linker)

Good luck! Madiha

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/pezmaster31/bamtools/issues/188#issuecomment-484462953, or mute the thread https://github.com/notifications/unsubscribe-auth/AHVLNZ3AWOXZE4WCLMCTMU3PRBLAPANCNFSM4HGNLIFQ .

ghost commented 5 years ago

Which compiler you are using? You have to follow some steps strictly in order to use libraries of bamtools. If you need I can send you a manual I prepared after spending too much time on it. That may help you. Please provide your email id.

Best, Madiha

emmannaemeka commented 5 years ago

eennadi@gmail.com

On Thu, 25 Apr 2019 at 11:50 AM, MadihaLums notifications@github.com wrote:

Which compiler you are using? You have to follow some steps strictly in order to use libraries of bamtools. If you need I can send you a manual I prepared after spending too much time on it. That may help you. Please provide your email id.

Best, Madiha

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/pezmaster31/bamtools/issues/188#issuecomment-486623609, or mute the thread https://github.com/notifications/unsubscribe-auth/AHVLNZ2EQTY5EFA5P5LSQSDPSGEIZANCNFSM4HGNLIFQ .

-- Nnadi Nnaemeka Emmanuel,Ph.D Department of Microbiology, Faculty of Natural and Applied Science, Plateau State University, Bokkos, Plateau State, Nigeria. +2348068124819 Publications: https://www.researchgate.net/profile/Emmanuel_Nnadi/publications

emmannaemeka commented 5 years ago

eennadi@gmail.com

On Thu, 25 Apr 2019 at 11:51 AM, Emmanuel Nnadi eennadi@gmail.com wrote:

eennadi@gmail.com

On Thu, 25 Apr 2019 at 11:50 AM, MadihaLums notifications@github.com wrote:

Which compiler you are using? You have to follow some steps strictly in order to use libraries of bamtools. If you need I can send you a manual I prepared after spending too much time on it. That may help you. Please provide your email id.

Best, Madiha

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/pezmaster31/bamtools/issues/188#issuecomment-486623609, or mute the thread https://github.com/notifications/unsubscribe-auth/AHVLNZ2EQTY5EFA5P5LSQSDPSGEIZANCNFSM4HGNLIFQ .

-- Nnadi Nnaemeka Emmanuel,Ph.D Department of Microbiology, Faculty of Natural and Applied Science, Plateau State University, Bokkos, Plateau State, Nigeria. +2348068124819 Publications: https://www.researchgate.net/profile/Emmanuel_Nnadi/publications

-- Nnadi Nnaemeka Emmanuel,Ph.D Department of Microbiology, Faculty of Natural and Applied Science, Plateau State University, Bokkos, Plateau State, Nigeria. +2348068124819 Publications: https://www.researchgate.net/profile/Emmanuel_Nnadi/publications

josephryan commented 5 years ago

I received this error when I made a "build" directory under the "src" directory instead of the top-level directory. The error went away when I made the build directory in the correct place. Here were my install commands (on linux):

# change link on next line to the latest release from: https://github.com/pezmaster31/bamtools/releases
wget https://github.com/pezmaster31/bamtools/archive/v2.5.1.tar.gz
gzip -dc v2.5.1.tar.gz | tar -xvf -
cd bamtools-2.5.1
mkdir build
cd build
cmake ..
make 
sudo make install

Hope this helps.

SoapZA commented 3 years ago

if mkdir build && cd build && cmake .. && make doesn't help you, I don't know what will.