[Date Prev][Date Next] [Chronological] [Thread] [Top]

Thread support



Thread support fails on OSF1 3.2 alpha.


Default configure fails on OSF1 3.2 alpha, both with cc and gcc.
It discovers that thread support exists, and then fails because nobody
told it to use the `-threads' option to cc or c89 (not -pthread like
configure tries).  Its thread support "by hand" also fails; it would
have to emulate what `-threads' does: Add
	-D_REENTRANT
to the preprocessor flags and
	-lpthreads -lmach -lexc -lc_r
to the linker flags in front of -lc.  (And -l<lib>_r in front of other
-l<lib>s where <lib>_r exists, I suppose.)


This configures successfully:

	CC='c89 -threads' ./configure

but linking slapd (after correcting a few bugs below) says
	Unresolved:
	pthread_attr_init
	pthread_attr_setdetachstate
	pthread_attr_destroy
	pthread_kill
because neither the system, lthread.h nor liblthread/thread.c define
them.

I enclose portable.h and config.log.


liblthread/rdwr.c does not compile. According to `man
pthread_<mutex/cond>_init' on alpha, it needs this patch:

--- ./libraries/liblthread/rdwr.c~	Mon Nov  9 15:24:33 1998
+++ ./libraries/liblthread/rdwr.c	Mon Nov  9 16:40:48 1998
@@ -30,6 +30,6 @@
 	rdwrp->readers_reading = 0;
 	rdwrp->writer_writing = 0;
-	pthread_mutex_init(&(rdwrp->mutex), NULL);
-	pthread_cond_init(&(rdwrp->lock_free), NULL);
+	pthread_mutex_init(&(rdwrp->mutex), pthread_mutexattr_default);
+	pthread_cond_init(&(rdwrp->lock_free), pthread_condattr_default);
 	return 0;
 }

however I don't know threads, so I don't know if this is portable.


Also, pthread_create wants its 3rd argument to have prototype
	cma_t_address(*)(cma_t_address)
where cma_t_address is void* or char* depending on the value of
_CMA_VOID_ (from <dce/cma.h>, included by <pthread.h>).


Concerning configure's troubles with flags to cc, I imagine other hosts
will have similar problems, so I suggest you just make the
(auto)detection of threads friendlier: Turn off thread support instead
of quitting if a thread test fails, or quit and and tell the user what
to do next if he is building something which needs threads.  ("See
INSTALL for how to turn on threads support".  --> "Try `man cc' and look
for `threads'", or whatever.)

(Or if you really want to automate it properly now, and you are the
first to invent thread support for configure, look at what Perl's
Configure does - including the files in hints/.)

Oh, and this doesn't work (though that's not related to threads in
particular):
	CC=c89 CFLAGS=-threads
The generated Makefiles do not use CFLAGS when linking (normal make on
our systems do include CFLAGS), but configure doesn't notice the problem
because it does all its linking with
	$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS).


BTW, I noticed that HAVE_MACH_CTHREADS in thread.c and lthread.c does
not occur in portable.h.in.  There is an HAVE_MACH_CTHREADS_H, though.


================ portable.h ================
/* include/portable.h.  Generated automatically by configure.  */
/* include/portable.h.in.  Generated automatically from configure.in by autoheader.  */
/* portable.h.top begin */
/*
Copyright 1998 The OpenLDAP Foundation, Redwood City, California, USA
All rights reserved.

Redistribution and use in source and binary forms are permitted only
as authorized by the OpenLDAP Public License.  A copy of this
license is available at http://www.OpenLDAP.org/license.html or
in file LICENSE in the top-level directory of the distribution.

This work is derived from the University of Michigan LDAP v3.3
distribution.  Information concerning is available at
    http://www.umich.edu/~dirsvcs/ldap/ldap.html.

This work also contains materials derived from public sources.

---

Portions Copyright (c) 1992-1996 Regents of the University of Michigan.
All rights reserved.

Redistribution and use in source and binary forms are permitted
provided that this notice is preserved and that due credit is given
to the University of Michigan at Ann Arbor. The name of the University
may not be used to endorse or promote products derived from this 
software without specific prior written permission. This software
is provided ``as is'' without express or implied warranty.
 
*/

#ifndef _LDAP_PORTABLE_H
#define _LDAP_PORTABLE_H

/* portable.h.top end */

/* Define if on AIX 3.
   System headers sometimes define this.
   We just want to avoid a redefinition error message.  */
#ifndef _ALL_SOURCE
/* #undef _ALL_SOURCE */
#endif

/* Define to empty if the keyword does not work.  */
/* #undef const */

/* Define to the type of elements in the array set by `getgroups'.
   Usually this is either `int' or `gid_t'.  */
#define GETGROUPS_T gid_t

/* Define to `int' if <sys/types.h> doesn't define.  */
/* #undef gid_t */

/* Define if you don't have vprintf but do have _doprnt.  */
/* #undef HAVE_DOPRNT */

/* Define if your struct stat has st_blksize.  */
#define HAVE_ST_BLKSIZE 1

/* Define if you have the strftime function.  */
#define HAVE_STRFTIME 1

/* Define if you have <sys/wait.h> that is POSIX.1 compatible.  */
#define HAVE_SYS_WAIT_H 1

/* Define if you have the vprintf function.  */
#define HAVE_VPRINTF 1

/* Define if you have the wait3 system call.  */
#define HAVE_WAIT3 1

/* Define if on MINIX.  */
/* #undef _MINIX */

/* Define to `int' if <sys/types.h> doesn't define.  */
/* #undef mode_t */

/* Define to `long' if <sys/types.h> doesn't define.  */
/* #undef off_t */

/* Define to `int' if <sys/types.h> doesn't define.  */
/* #undef pid_t */

/* Define if the system does not provide POSIX.1 features except
   with this defined.  */
/* #undef _POSIX_1_SOURCE */

/* Define if you need to in order for stat and other things to work.  */
/* #undef _POSIX_SOURCE */

/* Define as the return type of signal handlers (int or void).  */
#define RETSIGTYPE void

/* Define to `unsigned' if <sys/types.h> doesn't define.  */
/* #undef size_t */

/* Define if you have the ANSI C header files.  */
#define STDC_HEADERS 1

/* Define if you can safely include both <sys/time.h> and <time.h>.  */
#define TIME_WITH_SYS_TIME 1

/* Define if your <sys/time.h> declares struct tm.  */
/* #undef TM_IN_SYS_TIME */

/* Define to `int' if <sys/types.h> doesn't define.  */
/* #undef uid_t */

/* define this if needed to get reentrant functions */
/* #undef _REENTRANT */

/* define this if needed to get threadsafe functions */
/* #undef _THREAD_SAFE */

/* define this if toupper() requires tolower() check */
/* #undef C_UPPER_LOWER */

/* define this if sys_errlist is not defined in stdio.h or errno.h */
/* #undef DECL_SYS_ERRLIST */

/* define if you have berkeley db */
/* #undef HAVE_BERKELEY_DB */

/* define if you have berkeley db2 */
/* #undef HAVE_BERKELEY_DB2 */

/* define if you have crypt */
#define HAVE_CRYPT 1

/* define if you have DCE */
/* #undef HAVE_DCE */

/* define if you have DSAP */
/* #undef HAVE_DSAP */

/* define if you have GDBM */
/* #undef HAVE_GDBM */

/* define if you have ISODE */
/* #undef HAVE_ISODE */

/* define if you have Kerberos */
/* #undef HAVE_KERBEROS */

/* define if you have LinuxThreads */
/* #undef HAVE_LINUX_THREADS */

/* define if you have Sun LWP (SunOS style) */
/* #undef HAVE_LWP */

/* define if you have -lncurses */
/* #undef HAVE_NCURSES */

/* define if you have NDBM */
#define HAVE_NDBM 1

/* define if you have PP */
/* #undef HAVE_PP */

/* define if you have a preemptive POSIX Threads implementation */
/* #undef HAVE_PREEMPTIVE_PTHREADS */

/* define if you have POSIX Threads */
#define HAVE_PTHREADS 1

/* define if your POSIX Threads implementation is circa Final Draft */
/* #undef HAVE_PTHREADS_FINAL */

/* define if your POSIX Threads implementation is circa Draft 4 */
#define HAVE_PTHREADS_D4 1

/* define if you have sched_yield() */
#ifdef __notdef__
/* see second sched_yield define */
/* #undef HAVE_SCHED_YIELD */
#endif

/* define if you have setproctitle() */
/* #undef HAVE_SETPROCTITLE */

/* define if you have -lwrap */
/* #undef HAVE_TCPD */

/* define if you have -ltermcap */
#define HAVE_TERMCAP 1

/* define if you have Sun LWP (Solaris style) */
/* #undef HAVE_THR */

/* define if you have XTPP */
/* #undef HAVE_XTPP */

/* define this for connectionless LDAP support */
/* #undef LDAP_CONNECTIONLESS */

/* define this to add debugging code */
#define LDAP_DEBUG 1

/* define this for LDAP DNS support */
/* #undef LDAP_DNS */

/* define this to remove -lldap cache support */
/* #undef LDAP_NOCACHE */

/* define this for LDAP process title support */
#define LDAP_PROCTITLE 1

/* define this for LDAP referrals support */
#define LDAP_REFERRALS 1

/* define this for LDAP User Interface support */
#define LDAP_LIBUI 1

/* define this to use DBBTREE w/ LDBM backend */
/* #undef LDBM_USE_DBBTREE */

/* define this to use DBHASH w/ LDBM backend */
/* #undef LDBM_USE_DBHASH */

/* define this if you want no termcap support */
/* #undef NO_TERMCAP */

/* define this if you want no thread support */
/* #undef NO_THREADS */

/* define this if the thread package is preemptive */
/* #undef PREEMPTIVE_THREADS */

/* define this for ACL Group support */
#define SLAPD_ACLGROUPS 1

/* define this for crypt(3) password support */
#define SLAPD_CRYPT 1

/* define this to use SLAPD LDBM backend */
#define SLAPD_LDBM 1

/* define this for MD5 password support */
#define SLAPD_MD5 1

/* define this to use SLAPD passwd backend */
/* #undef SLAPD_PASSWD */

/* define this for phonetic support */
/* #undef SLAPD_PHONETIC */

/* define this for Reverse Lookup support */
#define SLAPD_RLOOKUPS 1

/* define this for SHA1 password support */
#define SLAPD_SHA1 1

/* define this to use SLAPD shell backend */
/* #undef SLAPD_SHELL */

/* Define if you have the bcopy function.  */
#define HAVE_BCOPY 1

/* Define if you have the flock function.  */
#define HAVE_FLOCK 1

/* Define if you have the getdtablesize function.  */
#define HAVE_GETDTABLESIZE 1

/* Define if you have the gethostname function.  */
#define HAVE_GETHOSTNAME 1

/* Define if you have the getopt function.  */
#define HAVE_GETOPT 1

/* Define if you have the gettimeofday function.  */
#define HAVE_GETTIMEOFDAY 1

/* Define if you have the lockf function.  */
#define HAVE_LOCKF 1

/* Define if you have the memcpy function.  */
#define HAVE_MEMCPY 1

/* Define if you have the memmove function.  */
#define HAVE_MEMMOVE 1

/* Define if you have the mkstemp function.  */
#define HAVE_MKSTEMP 1

/* Define if you have the mktime function.  */
#define HAVE_MKTIME 1

/* Define if you have the pthread_kill function.  */
/* #undef HAVE_PTHREAD_KILL */

/* Define if you have the pthread_setconcurrency function.  */
/* #undef HAVE_PTHREAD_SETCONCURRENCY */

/* Define if you have the pthread_yield function.  */
#define HAVE_PTHREAD_YIELD 1

/* Define if you have the sched_yield function.  */
/* #undef HAVE_SCHED_YIELD */

/* Define if you have the select function.  */
#define HAVE_SELECT 1

/* Define if you have the setpwfile function.  */
#define HAVE_SETPWFILE 1

/* Define if you have the setsid function.  */
#define HAVE_SETSID 1

/* Define if you have the signal function.  */
#define HAVE_SIGNAL 1

/* Define if you have the sigset function.  */
#define HAVE_SIGSET 1

/* Define if you have the snprintf function.  */
/* #undef HAVE_SNPRINTF */

/* Define if you have the socket function.  */
#define HAVE_SOCKET 1

/* Define if you have the strdup function.  */
#define HAVE_STRDUP 1

/* Define if you have the strerror function.  */
#define HAVE_STRERROR 1

/* Define if you have the strrchr function.  */
#define HAVE_STRRCHR 1

/* Define if you have the strsep function.  */
/* #undef HAVE_STRSEP */

/* Define if you have the strstr function.  */
#define HAVE_STRSTR 1

/* Define if you have the strtod function.  */
#define HAVE_STRTOD 1

/* Define if you have the strtol function.  */
#define HAVE_STRTOL 1

/* Define if you have the strtoul function.  */
#define HAVE_STRTOUL 1

/* Define if you have the sysconf function.  */
#define HAVE_SYSCONF 1

/* Define if you have the tempnam function.  */
#define HAVE_TEMPNAM 1

/* Define if you have the thr_setconcurrency function.  */
/* #undef HAVE_THR_SETCONCURRENCY */

/* Define if you have the vsnprintf function.  */
/* #undef HAVE_VSNPRINTF */

/* Define if you have the waitpid function.  */
#define HAVE_WAITPID 1

/* Define if you have the <db.h> header file.  */
/* #undef HAVE_DB_H */

/* Define if you have the <db_185.h> header file.  */
/* #undef HAVE_DB_185_H */

/* Define if you have the <des.h> header file.  */
/* #undef HAVE_DES_H */

/* Define if you have the <dirent.h> header file.  */
#define HAVE_DIRENT_H 1

/* Define if you have the <errno.h> header file.  */
#define HAVE_ERRNO_H 1

/* Define if you have the <fcntl.h> header file.  */
#define HAVE_FCNTL_H 1

/* Define if you have the <filio.h> header file.  */
/* #undef HAVE_FILIO_H */

/* Define if you have the <gdbm.h> header file.  */
/* #undef HAVE_GDBM_H */

/* Define if you have the <getopt.h> header file.  */
#define HAVE_GETOPT_H 1

/* Define if you have the <kerberosIV/des.h> header file.  */
/* #undef HAVE_KERBEROSIV_DES_H */

/* Define if you have the <kerberosIV/krb.h> header file.  */
/* #undef HAVE_KERBEROSIV_KRB_H */

/* Define if you have the <krb.h> header file.  */
/* #undef HAVE_KRB_H */

/* Define if you have the <libutil.h> header file.  */
/* #undef HAVE_LIBUTIL_H */

/* Define if you have the <limits.h> header file.  */
#define HAVE_LIMITS_H 1

/* Define if you have the <lwp/lwp.h> header file.  */
/* #undef HAVE_LWP_LWP_H */

/* Define if you have the <mach/cthreads.h> header file.  */
/* #undef HAVE_MACH_CTHREADS_H */

/* Define if you have the <malloc.h> header file.  */
#define HAVE_MALLOC_H 1

/* Define if you have the <ncurses.h> header file.  */
/* #undef HAVE_NCURSES_H */

/* Define if you have the <ndbm.h> header file.  */
#define HAVE_NDBM_H 1

/* Define if you have the <ndir.h> header file.  */
/* #undef HAVE_NDIR_H */

/* Define if you have the <pthread.h> header file.  */
#define HAVE_PTHREAD_H 1

/* Define if you have the <regex.h> header file.  */
#define HAVE_REGEX_H 1

/* Define if you have the <sched.h> header file.  */
#define HAVE_SCHED_H 1

/* Define if you have the <sgtty.h> header file.  */
#define HAVE_SGTTY_H 1

/* Define if you have the <stdarg.h> header file.  */
#define HAVE_STDARG_H 1

/* Define if you have the <stddef.h> header file.  */
#define HAVE_STDDEF_H 1

/* Define if you have the <synch.h> header file.  */
/* #undef HAVE_SYNCH_H */

/* Define if you have the <sys/dir.h> header file.  */
/* #undef HAVE_SYS_DIR_H */

/* Define if you have the <sys/errno.h> header file.  */
#define HAVE_SYS_ERRNO_H 1

/* Define if you have the <sys/file.h> header file.  */
#define HAVE_SYS_FILE_H 1

/* Define if you have the <sys/filio.h> header file.  */
/* #undef HAVE_SYS_FILIO_H */

/* Define if you have the <sys/ioctl.h> header file.  */
#define HAVE_SYS_IOCTL_H 1

/* Define if you have the <sys/ndir.h> header file.  */
/* #undef HAVE_SYS_NDIR_H */

/* Define if you have the <sys/param.h> header file.  */
#define HAVE_SYS_PARAM_H 1

/* Define if you have the <sys/socket.h> header file.  */
#define HAVE_SYS_SOCKET_H 1

/* Define if you have the <sys/syslog.h> header file.  */
#define HAVE_SYS_SYSLOG_H 1

/* Define if you have the <sys/time.h> header file.  */
#define HAVE_SYS_TIME_H 1

/* Define if you have the <sys/types.h> header file.  */
#define HAVE_SYS_TYPES_H 1

/* Define if you have the <syslog.h> header file.  */
#define HAVE_SYSLOG_H 1

/* Define if you have the <termcap.h> header file.  */
/* #undef HAVE_TERMCAP_H */

/* Define if you have the <termios.h> header file.  */
#define HAVE_TERMIOS_H 1

/* Define if you have the <thread.h> header file.  */
/* #undef HAVE_THREAD_H */

/* Define if you have the <unistd.h> header file.  */
#define HAVE_UNISTD_H 1

/* Define if you have the V3 library (-lV3).  */
/* #undef HAVE_LIBV3 */

/* Define if you have the gen library (-lgen).  */
/* #undef HAVE_LIBGEN */

/* Define if you have the inet library (-linet).  */
/* #undef HAVE_LIBINET */

/* Define if you have the net library (-lnet).  */
/* #undef HAVE_LIBNET */

/* Define if you have the nsl library (-lnsl).  */
/* #undef HAVE_LIBNSL */

/* Define if you have the nsl_s library (-lnsl_s).  */
/* #undef HAVE_LIBNSL_S */

/* Define if you have the socket library (-lsocket).  */
/* #undef HAVE_LIBSOCKET */
/* portable.h.bot begin */

#ifdef HAVE_STDDEF_H
#	include <stddef.h>
#endif

#include "ldap_cdefs.h"

#endif /* _LDAP_PORTABLE_H */

/* portable.h.bot end */


================ config.log ================
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

configure:595: checking configure arguments
configure:1248: checking whether ln -s works
configure:1279: checking for a BSD compatible install
configure:1331: checking for ranlib
configure:1358: checking whether make sets ${MAKE}
configure:1388: checking for sendmail
configure:1420: checking for vi
configure:1452: checking for finger
configure:1485: checking for gcc
configure:1562: checking whether the C compiler (c89 -threads  ) works
configure:1576: c89 -threads -o conftest    conftest.c  1>&5
configure:1596: checking whether the C compiler (c89 -threads  ) is a cross-compiler
configure:1601: checking whether we are using GNU C
configure:1610: c89 -threads -E conftest.c
configure:1666: checking how to run the C preprocessor
configure:1687: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:1729: checking for AIX
configure:1753: checking for POSIXized ISC
configure:1775: checking for minix/config.h
configure:1785: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 1781: Cannot open file minix/config.h for #include
configure: failed program was:
#line 1780 "configure"
#include "confdefs.h"
#include <minix/config.h>
configure:1826: checking for socket
configure:1854: c89 -threads -o conftest -g   conftest.c  1>&5
configure:2140: checking for sigset in -lV3
configure:2159: c89 -threads -o conftest -g   conftest.c -lV3   1>&5
ld:
Can't locate file for: -lV3
configure: failed program was:
#line 2148 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char sigset();

int main() {
sigset()
; return 0; }
configure:2407: checking for kerberosIV/krb.h
configure:2417: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 2413: Cannot open file kerberosIV/krb.h for #include
configure: failed program was:
#line 2412 "configure"
#include "confdefs.h"
#include <kerberosIV/krb.h>
configure:2407: checking for kerberosIV/des.h
configure:2417: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 2413: Cannot open file kerberosIV/des.h for #include
configure: failed program was:
#line 2412 "configure"
#include "confdefs.h"
#include <kerberosIV/des.h>
configure:2501: checking for krb.h
configure:2511: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 2507: Cannot open file krb.h for #include
configure: failed program was:
#line 2506 "configure"
#include "confdefs.h"
#include <krb.h>
configure:2501: checking for des.h
configure:2511: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 2507: Cannot open file des.h for #include
configure: failed program was:
#line 2506 "configure"
#include "confdefs.h"
#include <des.h>
configure:2598: checking for pthread.h
configure:2608: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:2598: checking for sched.h
configure:2608: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:2637: checking POSIX thread version
configure:2718: checking for LinuxThreads
configure:2744: checking for pthread_create
configure:2772: c89 -threads -o conftest -g   conftest.c  1>&5
configure:2996: checking for sched_yield
configure:3024: c89 -threads -o conftest -g   conftest.c   1>&5
ld:
Unresolved:
sched_yield
configure: failed program was:
#line 3001 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char sched_yield(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char sched_yield();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_sched_yield) || defined (__stub___sched_yield)
choke me
#else
sched_yield();
#endif

; return 0; }
configure:2996: checking for pthread_yield
configure:3024: c89 -threads -o conftest -g   conftest.c   1>&5
configure:3156: checking for pthread_kill
configure:3184: c89 -threads -o conftest -g   conftest.c   1>&5
ld:
Unresolved:
pthread_kill
configure: failed program was:
#line 3161 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char pthread_kill(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char pthread_kill();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_pthread_kill) || defined (__stub___pthread_kill)
choke me
#else
pthread_kill();
#endif

; return 0; }
configure:3215: checking for pthread_setconcurrency
configure:3243: c89 -threads -o conftest -g   conftest.c   1>&5
ld:
Unresolved:
pthread_setconcurrency
configure: failed program was:
#line 3220 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char pthread_setconcurrency(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char pthread_setconcurrency();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_pthread_setconcurrency) || defined (__stub___pthread_setconcurrency)
choke me
#else
pthread_setconcurrency();
#endif

; return 0; }
configure:3215: checking for thr_setconcurrency
configure:3243: c89 -threads -o conftest -g   conftest.c   1>&5
ld:
Unresolved:
thr_setconcurrency
configure: failed program was:
#line 3220 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char thr_setconcurrency(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char thr_setconcurrency();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_thr_setconcurrency) || defined (__stub___thr_setconcurrency)
choke me
#else
thr_setconcurrency();
#endif

; return 0; }
configure:3270: checking for preemptive Pthread implementation
configure:3328: c89 -threads -o conftest -g   conftest.c   1>&5
/usr/lib/cmplrs/cc/cfe: Error: configure, line 3314: Type for this argument member is incompatible with function prototype description (3.3.16.1)
 	pthread_create(&t, 0L , (void *) task, 0L );
 	-------------------^
configure: failed program was:
#line 3276 "configure"
#include "confdefs.h"

#include <sys/types.h>
#include <sys/time.h>
#include <unistd.h>
#include <pthread.h>
#ifndef NULL
#define NULL 0
#endif

int task(arg)
	int *arg;
{
	struct timeval tv;

	tv.tv_sec=4;
	tv.tv_usec=0;
	select(0, NULL, NULL, NULL, &tv);

	tv.tv_sec=6;
	tv.tv_usec=0;
	select(0, NULL, NULL, NULL, &tv);

	exit(1); /* if we exit here, the select blocked the whole process */
}

main(argc, argv)
int argc; char **argv;
{
	pthread_t t;

#ifdef HAVE_PTHREAD_SETCONCURRENCY
	(void) pthread_setconcurrency(2);
#elif HAVE_THR_SETCONCURRENCY
	/* Set Solaris LWP concurrency to 2 */
	thr_setconcurrency(2);
#endif

	pthread_create(&t, NULL, (void *) task, NULL);

#if HAVE_SCHED_YIELD
	sched_yield();	/* make sure task runs first */
#else
#if defined(HAVE_PTHREAD_YIELD)
	pthread_yield();	/* make sure task runs first */
#endif
#endif
	exit(0);
}
				
configure:3988: checking for DB2 library
configure:3994: checking for db_open in -ldb
configure:4013: c89 -threads -o conftest -g   conftest.c -ldb   1>&5
ld:
Can't locate file for: -ldb
configure: failed program was:
#line 4002 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char db_open();

int main() {
db_open()
; return 0; }
configure:4044: checking for db.h
configure:4054: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 4050: Cannot open file db.h for #include
configure: failed program was:
#line 4049 "configure"
#include "confdefs.h"
#include <db.h>
configure:4120: checking for Berkeley DB2
configure:4166: checking for Berkeley DB library
configure:4172: checking for dbopen
configure:4200: c89 -threads -o conftest -g   conftest.c  1>&5
ld:
Unresolved:
dbopen
configure: failed program was:
#line 4177 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char dbopen(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char dbopen();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_dbopen) || defined (__stub___dbopen)
choke me
#else
dbopen();
#endif

; return 0; }
configure:4219: checking for dbopen in -ldb
configure:4238: c89 -threads -o conftest -g   conftest.c -ldb   1>&5
ld:
Can't locate file for: -ldb
configure: failed program was:
#line 4227 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char dbopen();

int main() {
dbopen()
; return 0; }
configure:4273: checking for db_185.h
configure:4283: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 4279: Cannot open file db_185.h for #include
configure: failed program was:
#line 4278 "configure"
#include "confdefs.h"
#include <db_185.h>
configure:4319: checking for Berkeley DB
configure:4417: checking for GDBM library
configure:4423: checking for gdbm_open
configure:4451: c89 -threads -o conftest -g   conftest.c  1>&5
ld:
Unresolved:
gdbm_open
configure: failed program was:
#line 4428 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char gdbm_open(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char gdbm_open();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_gdbm_open) || defined (__stub___gdbm_open)
choke me
#else
gdbm_open();
#endif

; return 0; }
configure:4470: checking for gdbm_open in -lgdbm
configure:4489: c89 -threads -o conftest -g   conftest.c -lgdbm   1>&5
ld:
Can't locate file for: -lgdbm
configure: failed program was:
#line 4478 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char gdbm_open();

int main() {
gdbm_open()
; return 0; }
configure:4524: checking for gdbm.h
configure:4534: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 4530: Cannot open file gdbm.h for #include
configure: failed program was:
#line 4529 "configure"
#include "confdefs.h"
#include <gdbm.h>
configure:4561: checking for db
configure:4595: checking for NDBM library
configure:4601: checking for dbm_open
configure:4629: c89 -threads -o conftest -g   conftest.c  1>&5
configure:4743: checking for ndbm.h
configure:4753: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:4780: checking for db
configure:4893: checking for termcap.h
configure:4903: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 4899: Cannot open file termcap.h for #include
configure: failed program was:
#line 4898 "configure"
#include "confdefs.h"
#include <termcap.h>
configure:4893: checking for ncurses.h
configure:4903: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 4899: Cannot open file ncurses.h for #include
configure: failed program was:
#line 4898 "configure"
#include "confdefs.h"
#include <ncurses.h>
configure:4932: checking for tputs in -ltermcap
configure:4951: c89 -threads -o conftest -g   conftest.c -ltermcap   1>&5
configure:5045: checking for crypt
configure:5073: c89 -threads -o conftest -g   conftest.c  1>&5
configure:5155: checking for setproctitle
configure:5183: c89 -threads -o conftest -g   conftest.c  1>&5
ld:
Unresolved:
setproctitle
configure: failed program was:
#line 5160 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char setproctitle(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char setproctitle();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_setproctitle) || defined (__stub___setproctitle)
choke me
#else
setproctitle();
#endif

; return 0; }
configure:5202: checking for setproctitle in -lutil
configure:5221: c89 -threads -o conftest -g   conftest.c -lutil   1>&5
ld:
Unresolved:
setproctitle
configure: failed program was:
#line 5210 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char setproctitle();

int main() {
setproctitle()
; return 0; }
configure:5256: checking for ANSI C header files
configure:5269: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5336: c89 -threads -o conftest -g   conftest.c  1>&5
configure:5369: checking for dirent.h that defines DIR
configure:5382: c89 -threads -c -g  conftest.c 1>&5
configure:5407: checking for opendir in -ldir
configure:5426: c89 -threads -o conftest -g   conftest.c -ldir   1>&5
ld:
Can't locate file for: -ldir
configure: failed program was:
#line 5415 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char opendir();

int main() {
opendir()
; return 0; }
configure:5490: checking for sys/wait.h that is POSIX.1 compatible
configure:5511: c89 -threads -c -g  conftest.c 1>&5
configure:5559: checking for stdarg.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for stddef.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for errno.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for fcntl.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for filio.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 5565: Cannot open file filio.h for #include
configure: failed program was:
#line 5564 "configure"
#include "confdefs.h"
#include <filio.h>
configure:5559: checking for getopt.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for libutil.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 5565: Cannot open file libutil.h for #include
configure: failed program was:
#line 5564 "configure"
#include "confdefs.h"
#include <libutil.h>
configure:5559: checking for limits.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for malloc.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for regex.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sgtty.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/file.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/filio.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
/usr/lib/cmplrs/cc/cfe: Error: configure: 5565: Cannot open file sys/filio.h for #include
configure: failed program was:
#line 5564 "configure"
#include "confdefs.h"
#include <sys/filio.h>
configure:5559: checking for sys/errno.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/ioctl.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/param.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/socket.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/syslog.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/time.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for sys/types.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for syslog.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for termios.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5559: checking for unistd.h
configure:5569: c89 -threads -E  conftest.c >/dev/null 2>conftest.out
configure:5597: checking for uid_t in sys/types.h
configure:5631: checking type of array argument to getgroups
configure:5664: c89 -threads -o conftest -g   conftest.c  1>&5
configure:5702: checking for mode_t
configure:5735: checking for off_t
configure:5768: checking for pid_t
configure:5801: checking return type of signal handlers
configure:5823: c89 -threads -c -g  conftest.c 1>&5
configure:5842: checking for size_t
configure:5875: checking for uid_t in sys/types.h
configure:5909: checking for st_blksize in struct stat
configure:5922: c89 -threads -c -g  conftest.c 1>&5
configure:5943: checking whether time.h and sys/time.h may both be included
configure:5957: c89 -threads -c -g  conftest.c 1>&5
configure:5978: checking whether struct tm is in sys/time.h or time.h
configure:5991: c89 -threads -c -g  conftest.c 1>&5
configure:6014: checking if toupper() requires islower()
configure:6035: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6058: checking for working const
configure:6112: c89 -threads -c -g  conftest.c 1>&5
configure:6135: checking for 8-bit clean memcmp
configure:6153: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6171: checking for strftime
configure:6199: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6267: checking for vprintf
configure:6295: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6376: checking for vsnprintf
configure:6404: c89 -threads -o conftest -g   conftest.c  1>&5
ld:
Unresolved:
vsnprintf
configure: failed program was:
#line 6381 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char vsnprintf(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char vsnprintf();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_vsnprintf) || defined (__stub___vsnprintf)
choke me
#else
vsnprintf();
#endif

; return 0; }
configure:6431: checking for wait3 that fills in rusage
configure:6470: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for bcopy
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for getopt
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for flock
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for gethostname
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for gettimeofday
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for getdtablesize
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for lockf
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for memcpy
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for memmove
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for mkstemp
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for mktime
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for select
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for setpwfile
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for setsid
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for signal
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for sigset
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for snprintf
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
ld:
Unresolved:
snprintf
configure: failed program was:
#line 6530 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char snprintf(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char snprintf();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_snprintf) || defined (__stub___snprintf)
choke me
#else
snprintf();
#endif

; return 0; }
configure:6525: checking for socket
configure:6525: checking for strerror
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for strstr
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for strrchr
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for strsep
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
ld:
Unresolved:
strsep
configure: failed program was:
#line 6530 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char strsep(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char strsep();

int main() {

/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined (__stub_strsep) || defined (__stub___strsep)
choke me
#else
strsep();
#endif

; return 0; }
configure:6525: checking for strtod
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for strtol
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for strtoul
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for sysconf
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for tempnam
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6525: checking for waitpid
configure:6553: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6581: checking for getopt
configure:6581: checking for strdup
configure:6609: c89 -threads -o conftest -g   conftest.c  1>&5
configure:6581: checking for tempnam
configure:6639: checking declaration of sys_errlist
configure:6655: c89 -threads -c -g  conftest.c 1>&5


-- 
Hallvard