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

Does not build per instructions, missing sam.h file. #18

Open
richapma78 opened this issue Jan 20, 2020 · 3 comments
Open

Does not build per instructions, missing sam.h file. #18

richapma78 opened this issue Jan 20, 2020 · 3 comments

Comments

@richapma78
Copy link

Following the instructions on the main page:
git clone https://github.com/alastair-droop/fqtools
cd fqtools/
git clone https://github.com/samtools/htslib
cd htslib/
autoheader
autoconf
./configure
make
make install
cd ..
make

Fails at the last step with:
In file included from src/fqprocess_view.c:14:0: src/fqheader.h:22:10: fatal error: sam.h: No such file or directory #include <sam.h>

I do not find a sam.h definition in htslib. I do however find a sam.h definition with in the separate samtools project. However if I modify for the Makefile to use that location as well I receive an error about too many parameters:

In file included from ../samtools-1.10/sam.h:29:0, from src/fqheader.h:22, from src/fqfile.c:14: src/fqfile.c: In function ‘fqfile_open_read_file_bam’: ../samtools-1.10/bam.h:209:22: error: too many arguments to function ‘samtools_sam_open’ #define sam_open samtools_sam_open

Could this be because samtools htslib etc. are now separately maintained projects?

@bug1303
Copy link

bug1303 commented Feb 13, 2020

I had the same issue, but I found sam.h file inside ./htslib/htslib folder.

Inside src/fqheader.h, I changed the include statement from
#include <sam.h>
to
#include "htslib/sam.h"

then I could run make successfully.

@vokuryshev
Copy link

I followed above advice from bug1303 and managed to build fqtools , however running fqtool brings me an error:
fqtools: error while loading shared libraries: libhts.so.3: cannot open shared object file: No such file or directory
libhts.so & libhts.so.3 I added to LD_LIBRARY_PATH:
>echo $LD_LIBRARY_PATH: /usr/local/lib/libhts.so:/usr/local/lib/libhts.so.3

what could be the problem?
thanks.

@bug1303
Copy link

bug1303 commented Apr 15, 2020

Hi @vokuryshev
Try to add the folder rather than the file:
export LD_LIBRARY_PATH=/usr/local/lib
This fixed it for me.

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