Skip to content

PTHREAD error when compiling htslib #420

@jdmontenegro

Description

@jdmontenegro

$> autoheader
$> autoconf
$> ./configure
$> make
(...)
echo '#define HTS_VERSION "1.3.2-129-gdaae2ea"' > version.h
gcc -g -O2 -I. -c -o hts.o hts.c
gcc -g -O2 -I. -c -o md5.o md5.c
gcc -g -O2 -I. -c -o probaln.o probaln.c
gcc -g -O2 -I. -c -o realn.o realn.c
gcc -g -O2 -I. -c -o regidx.o regidx.c
gcc -g -O2 -I. -c -o sam.o sam.c
gcc -g -O2 -I. -c -o synced_bcf_reader.o synced_bcf_reader.c
gcc -g -O2 -I. -c -o vcf_sweep.o vcf_sweep.c
gcc -g -O2 -I. -c -o tbx.o tbx.c
gcc -g -O2 -I. -c -o thread_pool.o thread_pool.c
thread_pool.c: In function ‘hts_tpool_init’:
thread_pool.c:658:38: error: ‘PTHREAD_MUTEX_RECURSIVE’ undeclared (first use in this function)
pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE);
^
thread_pool.c:658:38: note: each undeclared identifier is reported only once for each function it appears in
make: *** [thread_pool.o] Error 1

cannot build the development version of htslib in the server:

$> uname -a

Linux zeus 3.0.101-80-default #1 SMP Fri Jul 15 14:30:41 UTC 2016 (eb2ba81) x86_64 x86_64 x86_64 GNU/Linux

Any ideas how to fix it?

Cheers,

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions