1
dnl # Server process model subsystem
3
SMB_ENABLE(process_model_thread,NO)
5
#################################################
6
# check for pthread support
7
AC_MSG_CHECKING(whether to use pthreads)
9
[AS_HELP_STRING([--with-pthreads],[Include pthreads (default=no)])],
13
if test x"$ac_cv_func_pread" != x"yes" -o x"$ac_cv_func_pwrite" != x"yes";then
14
AC_MSG_ERROR([You cannot enable threads when you don't have pread/pwrite!])
16
SMB_ENABLE(process_model_thread,YES)
17
SMB_ENABLE(PTHREAD,YES)
26
SMB_EXT_LIB(PTHREAD,[-lpthread])
28
AC_MSG_CHECKING(whether to search for setproctitle support)
29
AC_ARG_WITH(setproctitle,
30
[AS_HELP_STRING([--with-setproctitle], [Search for setproctitle support (default=no)])],
34
AC_CHECK_HEADERS(setproctitle.h)
35
AC_CHECK_FUNC(setproctitle, [], [
36
AC_CHECK_LIB_EXT(setproctitle, SETPROCTITLE_LIBS, setproctitle)
38
AC_MSG_CHECKING(whether to use setproctitle)
39
if test x"$ac_cv_func_setproctitle" = x"yes" -o \
40
\( x"$ac_cv_header_setproctitle_h" = x"yes" -a \
41
x"$ac_cv_lib_ext_setproctitle_setproctitle" = x"yes" \) ; then
43
SMB_ENABLE(SETPROCTITLE, YES)
44
AC_DEFINE(HAVE_SETPROCTITLE,1,[Whether setproctitle() is available])
56
SMB_EXT_LIB(SETPROCTITLE,
57
[${SETPROCTITLE_LIBS}],
58
[${SETPROCTITLE_CFLAGS}],
59
[${SETPROCTITLE_CPPFLAGS}],
60
[${SETPROCTITLE_LDFLAGS}])