1 dnl Process this file with autoconf to produce a configure script.
2 AC_INIT(include/includes.h)
3 AC_CONFIG_HEADER(include/config.h)
4 # we want to be compatibe with older versions of Samba
5 AC_PREFIX_DEFAULT(/usr/local/samba)
7 dnl Unique-to-Samba variables we'll be playing with.
18 # compile with optimisation and without debugging by default
21 dnl Checks for programs.
27 dnl Choose what kind of library to build by default
33 AC_SUBST(LIBTOOL_DEPS)
35 dnl Check if C compiler understands -c and -o at the same time
37 if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then
44 dnl Check if the C compiler understands volatile (it should, being ANSI).
45 AC_CACHE_CHECK([that the C compiler understands volatile],samba_cv_volatile, [
46 AC_TRY_COMPILE([#include <sys/types.h>],[volatile int i = 0],
47 samba_cv_volatile=yes,samba_cv_volatile=no)])
48 if test x"$samba_cv_volatile" = x"yes"; then
49 AC_DEFINE(HAVE_VOLATILE)
56 dnl Add #include for broken IRIX header files
58 *irix*) AC_ADD_INCLUDE(<standards.h>)
62 AC_VALIDATE_CACHE_SYSTEM_TYPE
66 # Config CPPFLAG settings for strange OS's that must be set
70 # Try to work out if this is the native HPUX compiler that uses the -Ae flag.
73 if test $ac_cv_prog_cc_Ae = yes; then
74 CPPFLAGS="$CPPFLAGS -Ae"
77 # Defines needed for HPUX support.
78 # HPUX has bigcrypt but (sometimes?) doesn't use it for
79 # password hashing - hence the USE_BOTH_CRYPT_CALLS define.
83 CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE"
84 AC_DEFINE(USE_BOTH_CRYPT_CALLS)
87 CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_POSIX_SOURCE -D_LARGEFILE64_SOURCE"
88 AC_DEFINE(USE_BOTH_CRYPT_CALLS)
93 # AIX4.x doesn't even admit to having large
94 # files *at all* unless the -D_LARGE_FILE or -D_LARGE_FILE_API flags are set.
97 AC_MSG_RESULT([enabling large file support])
98 CPPFLAGS="$CPPFLAGS -D_LARGE_FILES"
101 # Defines needed for Solaris 2.6/2.7 aka 7.0 to make it admit
102 # to the existance of large files..
103 # Note that -D_LARGEFILE64_SOURCE is different from the Sun
104 # recommendations on large file support, however it makes the
105 # compile work using gcc 2.7 and 2.8, whereas using the Sun
106 # recommendation makes the compile fail on gcc2.7. JRA.
111 AC_MSG_RESULT([enabling large file support])
112 if test "$ac_cv_prog_gcc" = yes; then
113 ${CC-cc} -v >conftest.c 2>&1
114 ac_cv_gcc_compiler_version_number=`grep 'gcc version' conftest.c`
116 case "$ac_cv_gcc_compiler_version_number" in
117 *"gcc version 2.6"*|*"gcc version 2.7"*)
118 CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE"
121 CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
125 CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
131 # Tests needed for SINIX large file support.
134 if test $host = mips-sni-sysv4 ; then
135 AC_MSG_CHECKING([for LFS support])
136 old_CPPFLAGS="$CPPFLAGS"
137 CPPFLAGS="-D_LARGEFILE64_SOURCE $CPPFLAGS"
141 #if _LFS64_LARGEFILE == 1
146 }], [SINIX_LFS_SUPPORT=yes], [SINIX_LFS_SUPPORT=no], [SINIX_LFS_SUPPORT=cross])
147 CPPFLAGS="$old_CPPFLAGS"
148 if test x$SINIX_LFS_SUPPORT = xyes ; then
149 CPPFLAGS="-D_LARGEFILE64_SOURCE $CPPFLAGS"
150 CFLAGS="`getconf LFS64_CFLAGS` $CFLAGS"
151 LDFLAGS="`getconf LFS64_LDFLAGS` $LDFLAGS"
152 LIBS="`getconf LFS64_LIBS` $LIBS"
154 AC_MSG_RESULT([$SINIX_LFS_SUPPORT])
159 # Tests needed for glibc 2.1 large file support.
162 AC_MSG_RESULT([disabling large file support for glibc2.1 on Linux])
165 AC_MSG_CHECKING([for LFS support])
166 old_CPPFLAGS="$CPPFLAGS"
167 CPPFLAGS="-D_LARGEFILE64_SOURCE -D_GNU_SOURCE $CPPFLAGS"
171 #if _LFS64_LARGEFILE == 1
176 }], [GLIBC_LFS_SUPPORT=yes], [GLIBC_LFS_SUPPORT=no], [GLIBC_LFS_SUPPORT=cross])
177 CPPFLAGS="$old_CPPFLAGS"
178 if test x$GLIBC_LFS_SUPPORT = xyes ; then
179 CPPFLAGS="-D_LARGEFILE64_SOURCE -D_GNU_SOURCE $CPPFLAGS"
181 AC_MSG_RESULT([$GLIBC_LFS_SUPPORT])
191 AC_CHECK_HEADERS(arpa/inet.h sys/fcntl.h sys/select.h fcntl.h sys/time.h sys/unistd.h)
192 AC_CHECK_HEADERS(unistd.h utime.h grp.h sys/id.h limits.h memory.h net/if.h)
193 AC_CHECK_HEADERS(compat.h rpc/rpc.h rpcsvc/nis.h rpcsvc/yp_prot.h rpcsvc/ypclnt.h)
194 AC_CHECK_HEADERS(sys/param.h ctype.h sys/un.h sys/wait.h sys/resource.h sys/ioctl.h sys/mode.h)
195 AC_CHECK_HEADERS(sys/mman.h sys/filio.h sys/priv.h string.h strings.h stdlib.h sys/socket.h)
196 AC_CHECK_HEADERS(sys/mount.h sys/vfs.h sys/fs/s5param.h sys/filsys.h termios.h termio.h)
197 AC_CHECK_HEADERS(sys/termio.h sys/statfs.h sys/dustat.h sys/statvfs.h stdarg.h sys/sockio.h)
198 AC_CHECK_HEADERS(getopt.h)
200 # HPUX has a bug in that including shadow.h causes a re-definition of MAXINT.
201 # This causes configure to fail to detect it. Check for shadow separately on HPUX.
205 AC_TRY_COMPILE([#include <shadow.h>],[struct spwd testme],
206 ac_cv_header_shadow_h=yes,ac_cv_header_shadow_h=no)
207 if test x"$ac_cv_header_shadow_h" = x"yes"; then
208 AC_DEFINE(HAVE_SHADOW_H)
212 AC_CHECK_HEADERS(shadow.h netinet/ip.h netinet/tcp.h netinet/in_systm.h netinet/in_ip.h)
213 AC_CHECK_HEADERS(sys/security.h security/pam_appl.h)
214 AC_CHECK_HEADERS(stropts.h poll.h readline.h history.h readline/readline.h)
215 AC_CHECK_HEADERS(readline/history.h sys/capability.h syscall.h sys/syscall.h)
216 AC_CHECK_HEADERS(sys/acl.h sys/cdefs.h glob.h)
218 # For experimental utmp support
219 AC_CHECK_HEADERS(utmp.h utmpx.h)
221 AC_CHECK_SIZEOF(int,cross)
222 AC_CHECK_SIZEOF(long,cross)
223 AC_CHECK_SIZEOF(short,cross)
238 AC_CHECK_TYPE(ino_t,unsigned)
239 AC_CHECK_TYPE(loff_t,off_t)
240 AC_CHECK_TYPE(offset_t,loff_t)
241 AC_CHECK_TYPE(ssize_t, int)
242 AC_CHECK_TYPE(wchar_t, unsigned short)
244 # we need libcups for CUPS support...
245 AC_CHECK_LIB(cups,httpConnect)
247 # we need libdl for PAM and the new VFS code
248 AC_CHECK_LIB(dl, dlopen, [LIBS="$LIBS -ldl";
249 AC_DEFINE(HAVE_LIBDL)])
251 AC_CACHE_CHECK([for sig_atomic_t type],samba_cv_sig_atomic_t, [
253 #include <sys/types.h>
258 #include <signal.h>],[sig_atomic_t i = 0],
259 samba_cv_sig_atomic_t=yes,samba_cv_sig_atomic_t=no)])
260 if test x"$samba_cv_sig_atomic_t" = x"yes"; then
261 AC_DEFINE(HAVE_SIG_ATOMIC_T_TYPE)
264 AC_CACHE_CHECK([for errno in errno.h],samba_cv_errno, [
265 AC_TRY_COMPILE([#include <errno.h>],[int i = errno],
266 samba_cv_errno=yes,samba_cv_have_errno=no)])
267 if test x"$samba_cv_errno" = x"yes"; then
268 AC_DEFINE(HAVE_ERRNO_DECL)
271 # stupid glibc has the functions but no declaration. grrrr.
272 AC_CACHE_CHECK([for setresuid declaration],samba_cv_have_setresuid_decl,[
273 AC_TRY_COMPILE([#include <unistd.h>],[int i = (int)setresuid],
274 samba_cv_have_setresuid_decl=yes,samba_cv_have_setresuid_decl=no)])
275 if test x"$samba_cv_have_setresuid_decl" = x"yes"; then
276 AC_DEFINE(HAVE_SETRESUID_DECL)
279 # stupid glibc has the functions but no declaration. grrrr.
280 AC_CACHE_CHECK([for setresgid declaration],samba_cv_have_setresgid_decl,[
281 AC_TRY_COMPILE([#include <unistd.h>],[int i = (int)setresgid],
282 samba_cv_have_setresgid_decl=yes,samba_cv_have_setresgid_decl=no)])
283 if test x"$samba_cv_have_setresgid_decl" = x"yes"; then
284 AC_DEFINE(HAVE_SETRESGID_DECL)
287 # and glibc has setresuid under linux but the function does
288 # nothing until kernel 2.1.44! very dumb.
289 AC_CACHE_CHECK([for real setresuid],samba_cv_have_setresuid,[
290 AC_TRY_RUN([#include <errno.h>
291 main() { setresuid(1,1,1); setresuid(2,2,2); exit(errno==EPERM?0:1);}],
292 samba_cv_have_setresuid=yes,samba_cv_have_setresuid=no,samba_cv_have_setresuid=cross)])
293 if test x"$samba_cv_have_setresuid" = x"yes"; then
294 AC_DEFINE(HAVE_SETRESUID)
297 # Do the same check for setresguid...
299 AC_CACHE_CHECK([for real setresgid],samba_cv_have_setresgid,[
300 AC_TRY_RUN([#include <unistd.h>
302 main() { errno = 0; setresgid(1,1,1); exit(errno != 0 ? (errno==EPERM ? 0 : 1) : 0);}],
303 samba_cv_have_setresgid=yes,samba_cv_have_setresgid=no,samba_cv_have_setresgid=cross)])
304 if test x"$samba_cv_have_setresgid" = x"yes"; then
305 AC_DEFINE(HAVE_SETRESGID)
310 ###############################################
311 # test for where we get crypt() from
312 AC_CHECK_FUNCS(crypt)
313 if test x"$ac_cv_func_crypt" = x"no"; then
314 AC_CHECK_LIB(crypt, crypt, [LIBS="$LIBS -lcrypt";
315 AC_DEFINE(HAVE_CRYPT)])
319 ###############################################
320 # test for where we get readline() from
321 if test "$ac_cv_header_readline_h" = "yes" ||
322 test "$ac_cv_header_readline_readline_h" = "yes"; then
323 AC_CHECK_LIB(readline,readline)
326 AC_CACHE_CHECK([for readline],samba_cv_HAVE_READLINE,[
327 AC_TRY_RUN([#include "${srcdir-.}/tests/readline.c"],
328 samba_cv_HAVE_READLINE=yes,samba_cv_HAVE_READLINE=no,samba_cv_HAVE_READLINE=cross)])
329 if test x"$samba_cv_HAVE_READLINE" = x"yes"; then
330 AC_DEFINE(HAVE_READLINE)
334 # The following test taken from the cvs sources
335 # If we can't find connect, try looking in -lsocket, -lnsl, and -linet.
336 # The Irix 5 libc.so has connect and gethostbyname, but Irix 5 also has
337 # libsocket.so which has a bad implementation of gethostbyname (it
338 # only looks in /etc/hosts), so we only look for -lsocket if we need
340 AC_CHECK_FUNCS(connect)
341 if test x"$ac_cv_func_connect" = x"no"; then
344 *) AC_CHECK_LIB(nsl_s, printf) ;;
348 *) AC_CHECK_LIB(nsl, printf) ;;
352 *) AC_CHECK_LIB(socket, connect) ;;
356 *) AC_CHECK_LIB(inet, connect) ;;
358 dnl We can't just call AC_CHECK_FUNCS(connect) here, because the value
360 if test x"$ac_cv_lib_socket_connect" = x"yes" ||
361 test x"$ac_cv_lib_inet_connect" = x"yes"; then
362 # ac_cv_func_connect=yes
363 # don't! it would cause AC_CHECK_FUNC to succeed next time configure is run
364 AC_DEFINE(HAVE_CONNECT)
368 # Check if we have execl, if not we need to compile smbrun.
369 AC_CHECK_FUNCS(execl)
370 if test x"$ac_cv_func_execl" = x"no"; then
376 AC_CHECK_FUNCS(waitpid getcwd strdup strtoul strerror chown chmod chroot)
377 AC_CHECK_FUNCS(fstat strchr utime utimes getrlimit fsync bzero memset)
378 AC_CHECK_FUNCS(memmove vsnprintf snprintf setsid glob strpbrk pipe crypt16 getauthuid)
379 AC_CHECK_FUNCS(strftime sigprocmask sigblock sigaction innetgr setnetgrent getnetgrent endnetgrent)
380 AC_CHECK_FUNCS(initgroups select rdchk getgrnam getgrent pathconf)
381 AC_CHECK_FUNCS(setpriv setgidx setuidx setgroups sysconf mktime rename ftruncate stat64 fstat64)
382 AC_CHECK_FUNCS(lstat64 fopen64 atexit grantpt dup2 lseek64 ftruncate64 readdir64)
383 AC_CHECK_FUNCS(fseek64 fseeko64 ftell64 ftello64 setluid yp_get_default_domain getpwanam)
384 AC_CHECK_FUNCS(srandom random srand rand setenv usleep mmap64 strcasecmp fcvt fcvtl)
386 # syscall() is needed for smbwrapper.
387 AC_CHECK_FUNCS(syscall)
389 AC_CHECK_FUNCS(_dup _dup2 _opendir _readdir _seekdir _telldir _closedir)
390 AC_CHECK_FUNCS(__dup __dup2 __opendir __readdir __seekdir __telldir __closedir)
391 AC_CHECK_FUNCS(__getcwd _getcwd)
392 AC_CHECK_FUNCS(__xstat __fxstat __lxstat)
393 AC_CHECK_FUNCS(_stat _lstat _fstat __stat __lstat __fstat)
394 AC_CHECK_FUNCS(_acl __acl _facl __facl _open __open _chdir __chdir)
395 AC_CHECK_FUNCS(_close __close _fchdir __fchdir _fcntl __fcntl)
396 AC_CHECK_FUNCS(getdents _getdents __getdents _lseek __lseek _read __read)
397 AC_CHECK_FUNCS(_write __write _fork __fork)
398 AC_CHECK_FUNCS(_stat64 __stat64 _fstat64 __fstat64 _lstat64 __lstat64)
399 AC_CHECK_FUNCS(__sys_llseek llseek _llseek __llseek readdir64 _readdir64 __readdir64)
400 AC_CHECK_FUNCS(pread _pread __pread pread64 _pread64 __pread64)
401 AC_CHECK_FUNCS(pwrite _pwrite __pwrite pwrite64 _pwrite64 __pwrite64)
402 AC_CHECK_FUNCS(open64 _open64 __open64 creat64)
405 # stat64 family may need <sys/stat.h> on some systems, notably ReliantUNIX
408 if test x$ac_cv_func_stat64 = xno ; then
409 AC_MSG_CHECKING([for stat64 in <sys/stat.h>])
411 #if defined(HAVE_UNISTD_H)
414 #include <sys/stat.h>
415 ], [struct stat64 st64; exit(stat64(".",&st64));], [ac_cv_func_stat64=yes])
416 AC_MSG_RESULT([$ac_cv_func_stat64])
417 if test x$ac_cv_func_stat64 = xyes ; then
418 AC_DEFINE(HAVE_STAT64)
422 if test x$ac_cv_func_lstat64 = xno ; then
423 AC_MSG_CHECKING([for lstat64 in <sys/stat.h>])
425 #if defined(HAVE_UNISTD_H)
428 #include <sys/stat.h>
429 ], [struct stat64 st64; exit(lstat64(".",&st64));], [ac_cv_func_lstat64=yes])
430 AC_MSG_RESULT([$ac_cv_func_lstat64])
431 if test x$ac_cv_func_lstat64 = xyes ; then
432 AC_DEFINE(HAVE_LSTAT64)
436 if test x$ac_cv_func_fstat64 = xno ; then
437 AC_MSG_CHECKING([for fstat64 in <sys/stat.h>])
439 #if defined(HAVE_UNISTD_H)
442 #include <sys/stat.h>
443 ], [struct stat64 st64; exit(fstat64(0,&st64));], [ac_cv_func_fstat64=yes])
444 AC_MSG_RESULT([$ac_cv_func_fstat64])
445 if test x$ac_cv_func_fstat64 = xyes ; then
446 AC_DEFINE(HAVE_FSTAT64)
451 # If no strcasecmp, check for it in some known places
452 # It is in -lresolv on ReliantUNIX and UnixWare
453 # -lresolve *must* follow -lnsl for name resolution to work properly
456 if test x$ac_cv_func_strcasecmp = xno ; then
457 AC_CHECK_LIB(resolv,strcasecmp,[LIBS="$LIBS -lresolv"]
458 AC_DEFINE(HAVE_STRCASECMP))
462 # Check for the functions putprpwnam, set_auth_parameters,
463 # getspnam, bigcrypt and getprpwnam in -lsec and -lsecurity
464 # Needed for OSF1 and HPUX.
467 AC_LIBTESTFUNC(security, putprpwnam)
468 AC_LIBTESTFUNC(sec, putprpwnam)
470 AC_LIBTESTFUNC(security, set_auth_parameters)
471 AC_LIBTESTFUNC(sec, set_auth_parameters)
473 # UnixWare 7.x has its getspnam in -lgen
474 AC_LIBTESTFUNC(gen, getspnam)
476 AC_LIBTESTFUNC(security, getspnam)
477 AC_LIBTESTFUNC(sec, getspnam)
479 AC_LIBTESTFUNC(security, bigcrypt)
480 AC_LIBTESTFUNC(sec, bigcrypt)
482 AC_LIBTESTFUNC(security, getprpwnam)
483 AC_LIBTESTFUNC(sec, getprpwnam)
485 # this bit needs to be modified for each OS that is suported by
486 # smbwrapper. You need to specify how to created a shared library and
487 # how to compile C code to produce PIC object files
489 # these are the defaults, good for lots of systems
495 # and these are for particular systems
497 *linux*) AC_DEFINE(LINUX);;
498 *solaris*) AC_DEFINE(SUNOS5)
501 *sunos*) AC_DEFINE(SUNOS4)
504 *bsd*) LDSHFLAGS="-shared -Bshareable"
506 *irix*) AC_DEFINE(IRIX)
508 *irix6*) AC_DEFINE(IRIX6)
511 ATTEMPT_WRAP32_BUILD=yes
513 *aix*) AC_DEFINE(AIX);;
514 *hpux*) AC_DEFINE(HPUX)
516 # Use special PIC flags for the native HP-UX compiler.
517 if test $ac_cv_prog_cc_Ae = yes; then
522 *qnx*) AC_DEFINE(QNX);;
523 *osf*) AC_DEFINE(OSF1);;
524 *sco*) AC_DEFINE(SCO);;
525 *next2*) AC_DEFINE(NEXT2);;
526 *dgux*) AC_CHECK_PROG( ROFF, groff, [groff -etpsR -Tascii -man]);;
529 *-univel-*) if [ test "$GCC" != yes ]; then
530 AC_DEFINE(HAVE_MEMSET)
534 *mips-sni-sysv4*) AC_DEFINE(RELIANTUNIX);;
538 if [ test "$GCC" != yes ]; then
539 AC_DEFINE(HAVE_MEMSET)
545 # try to work out how to produce pic code with this compiler
546 AC_PROG_CC_FLAG(fpic)
547 if test $ac_cv_prog_cc_fpic = yes; then
550 if test x$PICFLAG = x; then
551 AC_PROG_CC_FLAG(Kpic)
552 if test $ac_cv_prog_cc_Kpic = yes; then
556 if test x$PICFLAG = x; then
557 AC_PROG_CC_FLAG(KPIC)
558 if test $ac_cv_prog_cc_KPIC = yes; then
565 AC_CACHE_CHECK([for long long],samba_cv_have_longlong,[
566 AC_TRY_RUN([#include <stdio.h>
567 main() { long long x = 1000000; x *= x; exit(((x/1000000) == 1000000)? 0: 1); }],
568 samba_cv_have_longlong=yes,samba_cv_have_longlong=no,samba_cv_have_longlong=cross)])
569 if test x"$samba_cv_have_longlong" = x"yes"; then
570 AC_DEFINE(HAVE_LONGLONG)
574 # Check if the compiler supports the LL prefix on long long integers.
577 AC_CACHE_CHECK([for LL suffix on long long integers],samba_cv_compiler_supports_ll, [
578 AC_TRY_COMPILE([#include <stdio.h>],[long long i = 0x8000000000LL],
579 samba_cv_compiler_supports_ll=yes,samba_cv_compiler_supports_ll=no)])
580 if test x"$samba_cv_compiler_supports_ll" = x"yes"; then
581 AC_DEFINE(COMPILER_SUPPORTS_LL)
585 AC_CACHE_CHECK([for 64 bit off_t],samba_cv_SIZEOF_OFF_T,[
586 AC_TRY_RUN([#include <stdio.h>
587 #include <sys/stat.h>
588 main() { exit((sizeof(off_t) == 8) ? 0 : 1); }],
589 samba_cv_SIZEOF_OFF_T=yes,samba_cv_SIZEOF_OFF_T=no,samba_cv_SIZEOF_OFF_T=cross)])
590 if test x"$samba_cv_SIZEOF_OFF_T" = x"yes"; then
591 AC_DEFINE(SIZEOF_OFF_T,8)
594 AC_CACHE_CHECK([for off64_t],samba_cv_HAVE_OFF64_T,[
596 #if defined(HAVE_UNISTD_H)
600 #include <sys/stat.h>
601 main() { struct stat64 st; off64_t s; if (sizeof(off_t) == sizeof(off64_t)) exit(1); exit((lstat64("/dev/null", &st)==0)?0:1); }],
602 samba_cv_HAVE_OFF64_T=yes,samba_cv_HAVE_OFF64_T=no,samba_cv_HAVE_OFF64_T=cross)])
603 if test x"$samba_cv_HAVE_OFF64_T" = x"yes"; then
604 AC_DEFINE(HAVE_OFF64_T)
607 AC_CACHE_CHECK([for 64 bit ino_t],samba_cv_SIZEOF_INO_T,[
608 AC_TRY_RUN([#include <stdio.h>
609 #include <sys/stat.h>
610 main() { exit((sizeof(ino_t) == 8) ? 0 : 1); }],
611 samba_cv_SIZEOF_INO_T=yes,samba_cv_SIZEOF_INO_T=no,samba_cv_SIZEOF_INO_T=cross)])
612 if test x"$samba_cv_SIZEOF_INO_T" = x"yes"; then
613 AC_DEFINE(SIZEOF_INO_T,8)
616 AC_CACHE_CHECK([for ino64_t],samba_cv_HAVE_INO64_T,[
618 #if defined(HAVE_UNISTD_H)
622 #include <sys/stat.h>
623 main() { struct stat64 st; ino64_t s; if (sizeof(ino_t) == sizeof(ino64_t)) exit(1); exit((lstat64("/dev/null", &st)==0)?0:1); }],
624 samba_cv_HAVE_INO64_T=yes,samba_cv_HAVE_INO64_T=no,samba_cv_HAVE_INO64_T=cross)])
625 if test x"$samba_cv_HAVE_INO64_T" = x"yes"; then
626 AC_DEFINE(HAVE_INO64_T)
629 AC_CACHE_CHECK([for struct dirent64],samba_cv_HAVE_STRUCT_DIRENT64,[
631 #if defined(HAVE_UNISTD_H)
634 #include <sys/types.h>
635 #include <dirent.h>],
636 [struct dirent64 de;],
637 samba_cv_HAVE_STRUCT_DIRENT64=yes,samba_cv_HAVE_STRUCT_DIRENT64=no)])
638 if test x"$samba_cv_HAVE_STRUCT_DIRENT64" = x"yes"; then
639 AC_DEFINE(HAVE_STRUCT_DIRENT64)
642 AC_CACHE_CHECK([for union semun],samba_cv_HAVE_UNION_SEMUN,[
644 #include <sys/types.h>
647 main() { union semun ss; exit(0); }],
648 samba_cv_HAVE_UNION_SEMUN=yes,samba_cv_HAVE_UNION_SEMUN=no,samba_cv_HAVE_UNION_SEMUN=cross)])
649 if test x"$samba_cv_HAVE_UNION_SEMUN" = x"yes"; then
650 AC_DEFINE(HAVE_UNION_SEMUN)
653 AC_CACHE_CHECK([for unsigned char],samba_cv_HAVE_UNSIGNED_CHAR,[
654 AC_TRY_RUN([#include <stdio.h>
655 main() { char c; c=250; exit((c > 0)?0:1); }],
656 samba_cv_HAVE_UNSIGNED_CHAR=yes,samba_cv_HAVE_UNSIGNED_CHAR=no,samba_cv_HAVE_UNSIGNED_CHAR=cross)])
657 if test x"$samba_cv_HAVE_UNSIGNED_CHAR" = x"yes"; then
658 AC_DEFINE(HAVE_UNSIGNED_CHAR)
661 AC_CACHE_CHECK([for sin_len in sock],samba_cv_HAVE_SOCK_SIN_LEN,[
662 AC_TRY_COMPILE([#include <sys/types.h>
663 #include <sys/socket.h>
664 #include <netinet/in.h>],
665 [struct sockaddr_in sock; sock.sin_len = sizeof(sock);],
666 samba_cv_HAVE_SOCK_SIN_LEN=yes,samba_cv_HAVE_SOCK_SIN_LEN=no)])
667 if test x"$samba_cv_HAVE_SOCK_SIN_LEN" = x"yes"; then
668 AC_DEFINE(HAVE_SOCK_SIN_LEN)
671 AC_CACHE_CHECK([whether seekdir returns void],samba_cv_SEEKDIR_RETURNS_VOID,[
672 AC_TRY_COMPILE([#include <sys/types.h>
674 void seekdir(DIR *d, long loc) { return; }],[return 0;],
675 samba_cv_SEEKDIR_RETURNS_VOID=yes,samba_cv_SEEKDIR_RETURNS_VOID=no)])
676 if test x"$samba_cv_SEEKDIR_RETURNS_VOID" = x"yes"; then
677 AC_DEFINE(SEEKDIR_RETURNS_VOID)
680 AC_CACHE_CHECK([for __FILE__ macro],samba_cv_HAVE_FILE_MACRO,[
681 AC_TRY_COMPILE([#include <stdio.h>], [printf("%s\n", __FILE__);],
682 samba_cv_HAVE_FILE_MACRO=yes,samba_cv_HAVE_FILE_MACRO=no)])
683 if test x"$samba_cv_HAVE_FILE_MACRO" = x"yes"; then
684 AC_DEFINE(HAVE_FILE_MACRO)
687 AC_CACHE_CHECK([for __FUNCTION__ macro],samba_cv_HAVE_FUNCTION_MACRO,[
688 AC_TRY_COMPILE([#include <stdio.h>], [printf("%s\n", __FUNCTION__);],
689 samba_cv_HAVE_FUNCTION_MACRO=yes,samba_cv_HAVE_FUNCTION_MACRO=no)])
690 if test x"$samba_cv_HAVE_FUNCTION_MACRO" = x"yes"; then
691 AC_DEFINE(HAVE_FUNCTION_MACRO)
694 AC_CACHE_CHECK([if gettimeofday takes tz argument],samba_cv_HAVE_GETTIMEOFDAY_TZ,[
696 #include <sys/time.h>
698 main() { struct timeval tv; exit(gettimeofday(&tv, NULL));}],
699 samba_cv_HAVE_GETTIMEOFDAY_TZ=yes,samba_cv_HAVE_GETTIMEOFDAY_TZ=no,samba_cv_HAVE_GETTIMEOFDAY_TZ=cross)])
700 if test x"$samba_cv_HAVE_GETTIMEOFDAY_TZ" = x"yes"; then
701 AC_DEFINE(HAVE_GETTIMEOFDAY_TZ)
705 AC_CACHE_CHECK([for broken readdir],samba_cv_HAVE_BROKEN_READDIR,[
706 AC_TRY_RUN([#include <sys/types.h>
708 main() { struct dirent *di; DIR *d = opendir("."); di = readdir(d);
709 if (di && di->d_name[-2] == '.' && di->d_name[-1] == 0 &&
710 di->d_name[0] == 0) exit(0); exit(1);} ],
711 samba_cv_HAVE_BROKEN_READDIR=yes,samba_cv_HAVE_BROKEN_READDIR=no,samba_cv_HAVE_BROKEN_READDIR=cross)])
712 if test x"$samba_cv_HAVE_BROKEN_READDIR" = x"yes"; then
713 AC_DEFINE(HAVE_BROKEN_READDIR)
716 AC_CACHE_CHECK([for utimbuf],samba_cv_HAVE_UTIMBUF,[
717 AC_TRY_COMPILE([#include <sys/types.h>
719 [struct utimbuf tbuf; tbuf.actime = 0; tbuf.modtime = 1; exit(utime("foo.c",&tbuf));],
720 samba_cv_HAVE_UTIMBUF=yes,samba_cv_HAVE_UTIMBUF=no,samba_cv_HAVE_UTIMBUF=cross)])
721 if test x"$samba_cv_HAVE_UTIMBUF" = x"yes"; then
722 AC_DEFINE(HAVE_UTIMBUF)
725 AC_CACHE_CHECK([for ut_syslen in utmpx],samba_cv_HAVE_UX_UT_SYSLEN,[
726 AC_TRY_COMPILE([#include <utmpx.h>],
727 [struct utmpx ux; ux.ut_syslen = 0;],
728 samba_cv_HAVE_UX_UT_SYSLEN=yes,samba_cv_HAVE_UX_UT_SYSLEN=no,samba_cv_HAVE_UX_UT_SYSLEN=cross)])
729 if test x"$samba_cv_HAVE_UX_UT_SYSLEN" = x"yes"; then
730 AC_DEFINE(HAVE_UX_UT_SYSLEN)
733 AC_CACHE_CHECK([for kernel oplock type definitions],samba_cv_HAVE_KERNEL_OPLOCKS,[
734 AC_TRY_COMPILE([#include <sys/types.h>
736 [oplock_stat_t t; t.os_state = OP_REVOKE; t.os_dev = 1; t.os_ino = 1;],
737 samba_cv_HAVE_KERNEL_OPLOCKS=yes,samba_cv_HAVE_KERNEL_OPLOCKS=no)])
738 if test x"$samba_cv_HAVE_KERNEL_OPLOCKS" = x"yes"; then
739 AC_DEFINE(HAVE_KERNEL_OPLOCKS)
742 AC_CACHE_CHECK([for irix specific capabilities],samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES,[
743 AC_TRY_RUN([#include <sys/types.h>
744 #include <sys/capability.h>
747 if ((cap = cap_get_proc()) == NULL)
749 cap->cap_effective |= CAP_NETWORK_MGT;
750 cap->cap_inheritable |= CAP_NETWORK_MGT;
755 samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES=yes,samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES=no,samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES=cross)])
756 if test x"$samba_cv_HAVE_IRIX_SPECIFIC_CAPABILITIES" = x"yes"; then
757 AC_DEFINE(HAVE_IRIX_SPECIFIC_CAPABILITIES)
761 # Check for int16, uint16, int32 and uint32 in rpc/types.h included from rpc/rpc.h
762 # This is *really* broken but some systems (DEC OSF1) do this.... JRA.
765 AC_CACHE_CHECK([for int16 typedef included by rpc/rpc.h],samba_cv_HAVE_INT16_FROM_RPC_RPC_H,[
766 AC_TRY_COMPILE([#include <sys/types.h>
767 #if defined(HAVE_RPC_RPC_H)
771 samba_cv_HAVE_INT16_FROM_RPC_RPC_H=yes,samba_cv_HAVE_INT16_FROM_RPC_RPC_H=no)])
772 if test x"$samba_cv_HAVE_INT16_FROM_RPC_RPC_H" = x"yes"; then
773 AC_DEFINE(HAVE_INT16_FROM_RPC_RPC_H)
776 AC_CACHE_CHECK([for uint16 typedef included by rpc/rpc.h],samba_cv_HAVE_UINT16_FROM_RPC_RPC_H,[
777 AC_TRY_COMPILE([#include <sys/types.h>
778 #if defined(HAVE_RPC_RPC_H)
782 samba_cv_HAVE_UINT16_FROM_RPC_RPC_H=yes,samba_cv_HAVE_UINT16_FROM_RPC_RPC_H=no)])
783 if test x"$samba_cv_HAVE_UINT16_FROM_RPC_RPC_H" = x"yes"; then
784 AC_DEFINE(HAVE_UINT16_FROM_RPC_RPC_H)
787 AC_CACHE_CHECK([for int32 typedef included by rpc/rpc.h],samba_cv_HAVE_INT32_FROM_RPC_RPC_H,[
788 AC_TRY_COMPILE([#include <sys/types.h>
789 #if defined(HAVE_RPC_RPC_H)
793 samba_cv_HAVE_INT32_FROM_RPC_RPC_H=yes,samba_cv_HAVE_INT32_FROM_RPC_RPC_H=no)])
794 if test x"$samba_cv_HAVE_INT32_FROM_RPC_RPC_H" = x"yes"; then
795 AC_DEFINE(HAVE_INT32_FROM_RPC_RPC_H)
798 AC_CACHE_CHECK([for uint32 typedef included by rpc/rpc.h],samba_cv_HAVE_UINT32_FROM_RPC_RPC_H,[
799 AC_TRY_COMPILE([#include <sys/types.h>
800 #if defined(HAVE_RPC_RPC_H)
804 samba_cv_HAVE_UINT32_FROM_RPC_RPC_H=yes,samba_cv_HAVE_UINT32_FROM_RPC_RPC_H=no)])
805 if test x"$samba_cv_HAVE_UINT32_FROM_RPC_RPC_H" = x"yes"; then
806 AC_DEFINE(HAVE_UINT32_FROM_RPC_RPC_H)
810 dnl Some systems (SCO) have a problem including
811 dnl <prot.h> and <rpc/rpc.h> due to AUTH_ERROR being defined
812 dnl as a #define in <prot.h> and as part of an enum
816 AC_CACHE_CHECK([for conflicting AUTH_ERROR define in rpc/rpc.h],samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT,[
817 AC_TRY_COMPILE([#include <sys/types.h>
818 #ifdef HAVE_SYS_SECURITY_H
819 #include <sys/security.h>
821 #endif /* HAVE_SYS_SECURITY_H */
822 #if defined(HAVE_RPC_RPC_H)
826 samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT=no,samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT=yes)])
827 if test x"$samba_cv_HAVE_RPC_AUTH_ERROR_CONFLICT" = x"yes"; then
828 AC_DEFINE(HAVE_RPC_AUTH_ERROR_CONFLICT)
831 AC_MSG_CHECKING([for test routines])
832 AC_TRY_RUN([#include "${srcdir-.}/tests/trivial.c"],
834 AC_MSG_ERROR([cant find test code. Aborting config]),
835 AC_MSG_WARN([cannot run when cross-compiling]))
837 AC_CACHE_CHECK([for ftruncate extend],samba_cv_HAVE_FTRUNCATE_EXTEND,[
838 AC_TRY_RUN([#include "${srcdir-.}/tests/ftruncate.c"],
839 samba_cv_HAVE_FTRUNCATE_EXTEND=yes,samba_cv_HAVE_FTRUNCATE_EXTEND=no,samba_cv_HAVE_FTRUNCATE_EXTEND=cross)])
840 if test x"$samba_cv_HAVE_FTRUNCATE_EXTEND" = x"yes"; then
841 AC_DEFINE(HAVE_FTRUNCATE_EXTEND)
844 AC_CACHE_CHECK([for broken getgroups],samba_cv_HAVE_BROKEN_GETGROUPS,[
845 AC_TRY_RUN([#include "${srcdir-.}/tests/getgroups.c"],
846 samba_cv_HAVE_BROKEN_GETGROUPS=yes,samba_cv_HAVE_BROKEN_GETGROUPS=no,samba_cv_HAVE_BROKEN_GETGROUPS=cross)])
847 if test x"$samba_cv_HAVE_BROKEN_GETGROUPS" = x"yes"; then
848 AC_DEFINE(HAVE_BROKEN_GETGROUPS)
851 AC_CACHE_CHECK([whether getpass should be replaced],samba_cv_REPLACE_GETPASS,[
852 SAVE_CPPFLAGS="$CPPFLAGS"
853 CPPFLAGS="$CPPFLAGS -I${srcdir-.}/include -I${srcdir-.}/ubiqx -I${srcdir-.}/smbwrapper"
855 #define REPLACE_GETPASS 1
856 #define NO_CONFIG_H 1
857 #define main dont_declare_main
858 #include "${srcdir-.}/lib/getsmbpass.c"
860 ],[],samba_cv_REPLACE_GETPASS=yes,samba_cv_REPLACE_GETPASS=no)
861 CPPFLAGS="$SAVE_CPPFLAGS"
863 if test x"$samba_cv_REPLACE_GETPASS" = x"yes"; then
864 AC_DEFINE(REPLACE_GETPASS)
867 AC_CACHE_CHECK([for working fnmatch],samba_cv_HAVE_FNMATCH,[
868 AC_TRY_RUN([#include <fnmatch.h>
869 main() { exit(fnmatch("*.o", "x.o", FNM_PATHNAME) == 0? 0: 1); }],
870 samba_cv_HAVE_FNMATCH=yes,samba_cv_HAVE_FNMATCH=no,samba_cv_HAVE_FNMATCH=cross)])
871 if test x"$samba_cv_HAVE_FNMATCH" = x"yes"; then
872 AC_DEFINE(HAVE_FNMATCH)
875 AC_CACHE_CHECK([for broken inet_ntoa],samba_cv_REPLACE_INET_NTOA,[
878 #include <sys/types.h>
879 #include <netinet/in.h>
880 #ifdef HAVE_ARPA_INET_H
881 #include <arpa/inet.h>
883 main() { struct in_addr ip; ip.s_addr = 0x12345678;
884 if (strcmp(inet_ntoa(ip),"18.52.86.120") &&
885 strcmp(inet_ntoa(ip),"120.86.52.18")) { exit(0); }
887 samba_cv_REPLACE_INET_NTOA=yes,samba_cv_REPLACE_INET_NTOA=no,samba_cv_REPLACE_INET_NTOA=cross)])
888 if test x"$samba_cv_REPLACE_INET_NTOA" = x"yes"; then
889 AC_DEFINE(REPLACE_INET_NTOA)
892 AC_CACHE_CHECK([for sysconf(_SC_NGROUPS_MAX)],samba_cv_SYSCONF_SC_NGROUPS_MAX,[
893 AC_TRY_RUN([#include <unistd.h>
894 main() { exit(sysconf(_SC_NGROUPS_MAX) == -1 ? 1 : 0); }],
895 samba_cv_SYSCONF_SC_NGROUPS_MAX=yes,samba_cv_SYSCONF_SC_NGROUPS_MAX=no,samba_cv_SYSCONF_SC_NGROUPS_MAX=cross)])
896 if test x"$samba_cv_SYSCONF_SC_NGROUPS_MAX" = x"yes"; then
897 AC_DEFINE(SYSCONF_SC_NGROUPS_MAX)
900 AC_CACHE_CHECK([for root],samba_cv_HAVE_ROOT,[
901 AC_TRY_RUN([main() { exit(getuid() != 0); }],
902 samba_cv_HAVE_ROOT=yes,samba_cv_HAVE_ROOT=no,samba_cv_HAVE_ROOT=cross)])
903 if test x"$samba_cv_HAVE_ROOT" = x"yes"; then
906 AC_MSG_WARN(running as non-root will disable some tests)
910 # look for a method of finding the list of network interfaces
912 AC_CACHE_CHECK([for iface AIX],samba_cv_HAVE_IFACE_AIX,[
914 #define HAVE_IFACE_AIX 1
915 #define AUTOCONF_TEST 1
916 #include "confdefs.h"
917 #include "${srcdir-.}/lib/interfaces.c"],
918 samba_cv_HAVE_IFACE_AIX=yes,samba_cv_HAVE_IFACE_AIX=no,samba_cv_HAVE_IFACE_AIX=cross)])
919 if test x"$samba_cv_HAVE_IFACE_AIX" = x"yes"; then
920 iface=yes;AC_DEFINE(HAVE_IFACE_AIX)
923 if test $iface = no; then
924 AC_CACHE_CHECK([for iface ifconf],samba_cv_HAVE_IFACE_IFCONF,[
926 #define HAVE_IFACE_IFCONF 1
927 #define AUTOCONF_TEST 1
928 #include "confdefs.h"
929 #include "${srcdir-.}/lib/interfaces.c"],
930 samba_cv_HAVE_IFACE_IFCONF=yes,samba_cv_HAVE_IFACE_IFCONF=no,samba_cv_HAVE_IFACE_IFCONF=cross)])
931 if test x"$samba_cv_HAVE_IFACE_IFCONF" = x"yes"; then
932 iface=yes;AC_DEFINE(HAVE_IFACE_IFCONF)
936 if test $iface = no; then
937 AC_CACHE_CHECK([for iface ifreq],samba_cv_HAVE_IFACE_IFREQ,[
939 #define HAVE_IFACE_IFREQ 1
940 #define AUTOCONF_TEST 1
941 #include "confdefs.h"
942 #include "${srcdir-.}/lib/interfaces.c"],
943 samba_cv_HAVE_IFACE_IFREQ=yes,samba_cv_HAVE_IFACE_IFREQ=no,samba_cv_HAVE_IFACE_IFREQ=cross)])
944 if test x"$samba_cv_HAVE_IFACE_IFREQ" = x"yes"; then
945 iface=yes;AC_DEFINE(HAVE_IFACE_IFREQ)
950 ################################################
951 # look for a method of setting the effective uid
953 if test $seteuid = no; then
954 AC_CACHE_CHECK([for setresuid],samba_cv_USE_SETRESUID,[
956 #define AUTOCONF_TEST 1
957 #define USE_SETRESUID 1
958 #include "confdefs.h"
959 #include "${srcdir-.}/lib/util_sec.c"],
960 samba_cv_USE_SETRESUID=yes,samba_cv_USE_SETRESUID=no,samba_cv_USE_SETRESUID=cross)])
961 if test x"$samba_cv_USE_SETRESUID" = x"yes"; then
962 seteuid=yes;AC_DEFINE(USE_SETRESUID)
967 if test $seteuid = no; then
968 AC_CACHE_CHECK([for setreuid],samba_cv_USE_SETREUID,[
970 #define AUTOCONF_TEST 1
971 #define USE_SETREUID 1
972 #include "confdefs.h"
973 #include "${srcdir-.}/lib/util_sec.c"],
974 samba_cv_USE_SETREUID=yes,samba_cv_USE_SETREUID=no,samba_cv_USE_SETREUID=cross)])
975 if test x"$samba_cv_USE_SETREUID" = x"yes"; then
976 seteuid=yes;AC_DEFINE(USE_SETREUID)
980 if test $seteuid = no; then
981 AC_CACHE_CHECK([for seteuid],samba_cv_USE_SETEUID,[
983 #define AUTOCONF_TEST 1
984 #define USE_SETEUID 1
985 #include "confdefs.h"
986 #include "${srcdir-.}/lib/util_sec.c"],
987 samba_cv_USE_SETEUID=yes,samba_cv_USE_SETEUID=no,samba_cv_USE_SETEUID=cross)])
988 if test x"$samba_cv_USE_SETEUID" = x"yes"; then
989 seteuid=yes;AC_DEFINE(USE_SETEUID)
993 if test $seteuid = no; then
994 AC_CACHE_CHECK([for setuidx],samba_cv_USE_SETUIDX,[
996 #define AUTOCONF_TEST 1
997 #define USE_SETUIDX 1
998 #include "confdefs.h"
999 #include "${srcdir-.}/lib/util_sec.c"],
1000 samba_cv_USE_SETUIDX=yes,samba_cv_USE_SETUIDX=no,samba_cv_USE_SETUIDX=cross)])
1001 if test x"$samba_cv_USE_SETUIDX" = x"yes"; then
1002 seteuid=yes;AC_DEFINE(USE_SETUIDX)
1007 AC_CACHE_CHECK([for shared mmap],samba_cv_HAVE_SHARED_MMAP,[
1008 AC_TRY_RUN([#include "${srcdir-.}/tests/shared_mmap.c"],
1009 samba_cv_HAVE_SHARED_MMAP=yes,samba_cv_HAVE_SHARED_MMAP=no,samba_cv_HAVE_SHARED_MMAP=cross)])
1010 if test x"$samba_cv_HAVE_SHARED_MMAP" = x"yes"; then
1011 AC_DEFINE(HAVE_SHARED_MMAP)
1012 AC_DEFINE(HAVE_MMAP)
1015 AC_CACHE_CHECK([for ftruncate needs root],samba_cv_FTRUNCATE_NEEDS_ROOT,[
1016 AC_TRY_RUN([#include "${srcdir-.}/tests/ftruncroot.c"],
1017 samba_cv_FTRUNCATE_NEEDS_ROOT=yes,samba_cv_FTRUNCATE_NEEDS_ROOT=no,samba_cv_FTRUNCATE_NEEDS_ROOT=cross)])
1018 if test x"$samba_cv_FTRUNCATE_NEEDS_ROOT" = x"yes"; then
1019 AC_DEFINE(FTRUNCATE_NEEDS_ROOT)
1022 AC_CACHE_CHECK([for fcntl locking],samba_cv_HAVE_FCNTL_LOCK,[
1023 AC_TRY_RUN([#include "${srcdir-.}/tests/fcntl_lock.c"],
1024 samba_cv_HAVE_FCNTL_LOCK=yes,samba_cv_HAVE_FCNTL_LOCK=no,samba_cv_HAVE_FCNTL_LOCK=cross)])
1025 if test x"$samba_cv_HAVE_FCNTL_LOCK" = x"yes"; then
1026 AC_DEFINE(HAVE_FCNTL_LOCK)
1029 AC_CACHE_CHECK([for broken (glibc2.1/x86) 64 bit fcntl locking],samba_cv_HAVE_BROKEN_FCNTL64_LOCKS,[
1030 AC_TRY_RUN([#include "${srcdir-.}/tests/fcntl_lock64.c"],
1031 samba_cv_HAVE_BROKEN_FCNTL64_LOCKS=yes,samba_cv_HAVE_BROKEN_FCNTL64_LOCKS=no,samba_cv_HAVE_BROKEN_FCNTL64_LOCKS=cross)])
1032 if test x"$samba_cv_HAVE_BROKEN_FCNTL64_LOCKS" = x"yes"; then
1033 AC_DEFINE(HAVE_BROKEN_FCNTL64_LOCKS)
1038 dnl Don't check for 64 bit fcntl locking if we know that the
1039 dnl glibc2.1 broken check has succeeded.
1042 AC_CACHE_CHECK([for 64 bit fcntl locking],samba_cv_HAVE_STRUCT_FLOCK64,[
1044 #if defined(HAVE_UNISTD_H)
1054 #ifdef HAVE_SYS_FCNTL_H
1055 #include <sys/fcntl.h>
1057 main() { struct flock64 fl64;
1058 #if defined(F_SETLKW64) && defined(F_SETLK64) && defined(F_GETLK64)
1064 samba_cv_HAVE_STRUCT_FLOCK64=yes,samba_cv_HAVE_STRUCT_FLOCK64=no,samba_cv_HAVE_STRUCT_FLOCK64=cross)])
1066 if test x"$samba_cv_HAVE_STRUCT_FLOCK64" = x"yes"; then
1067 AC_DEFINE(HAVE_STRUCT_FLOCK64)
1071 AC_CACHE_CHECK([for sysv ipc],samba_cv_HAVE_SYSV_IPC,[
1072 AC_TRY_RUN([#include "${srcdir-.}/tests/sysv_ipc.c"],
1073 samba_cv_HAVE_SYSV_IPC=yes,samba_cv_HAVE_SYSV_IPC=no,samba_cv_HAVE_SYSV_IPC=cross)])
1074 if test x"$samba_cv_HAVE_SYSV_IPC" = x"yes"; then
1075 AC_DEFINE(HAVE_SYSV_IPC)
1078 AC_CACHE_CHECK([for IRIX sysv ipc semun problem using gcc],samba_cv_NEED_SGI_SEMUN_HACK,[
1079 AC_TRY_RUN([#include "${srcdir-.}/tests/sgi_sysv_hack.c"],
1080 samba_cv_NEED_SGI_SEMUN_HACK=yes,samba_cv_NEED_SGI_SEMUN_HACK=no,samba_cv_NEED_SGI_SEMUN_HACK=cross)])
1081 if test x"$samba_cv_NEED_SGI_SEMUN_HACK" = x"yes"; then
1082 AC_DEFINE(NEED_SGI_SEMUN_HACK)
1085 AC_CACHE_CHECK([for a crypt that needs truncated salt],samba_cv_HAVE_TRUNCATED_SALT,[
1086 AC_TRY_RUN([#include "${srcdir-.}/tests/crypttest.c"],
1087 samba_cv_HAVE_TRUNCATED_SALT=no,samba_cv_HAVE_TRUNCATED_SALT=yes,samba_cv_HAVE_TRUNCATED_SALT=cross)])
1088 if test x"$samba_cv_HAVE_TRUNCATED_SALT" = x"yes"; then
1089 AC_DEFINE(HAVE_TRUNCATED_SALT)
1092 AC_CACHE_CHECK([for broken nisplus include files],samba_cv_BROKEN_NISPLUS_INCLUDE_FILES,[
1093 AC_TRY_COMPILE([#include <sys/acl.h>
1094 #if defined(HAVE_RPCSVC_NIS_H)
1095 #include <rpcsvc/nis.h>
1098 samba_cv_BROKEN_NISPLUS_INCLUDE_FILES=no,samba_cv_BROKEN_NISPLUS_INCLUDE_FILES=yes)])
1099 if test x"$samba_cv_BROKEN_NISPLUS_INCLUDE_FILES" = x"yes"; then
1100 AC_DEFINE(BROKEN_NISPLUS_INCLUDE_FILES)
1104 #################################################
1105 # check for smbwrapper support
1106 AC_MSG_CHECKING(whether to use smbwrapper)
1107 AC_ARG_WITH(smbwrapper,
1108 [ --with-smbwrapper Include SMB wrapper support
1109 --without-smbwrapper Don't include SMB wrapper support (default)],
1110 [ case "$withval" in
1113 AC_DEFINE(WITH_SMBWRAPPER)
1114 WRAP="bin/smbsh bin/smbwrapper.$SHLIBEXT"
1116 if test x$ATTEMPT_WRAP32_BUILD = x; then
1119 WRAP32=bin/smbwrapper.32.$SHLIBEXT
1122 # Conditions under which smbwrapper should not be built.
1124 if test x$PICFLAG = x; then
1125 echo No support for PIC code - disabling smbwrapper and smbsh
1128 elif test x$ac_cv_func_syscall = xno; then
1129 AC_MSG_RESULT([No syscall() -- disabling smbwrapper and smbsh])
1141 #################################################
1142 # check for the AFS filesystem
1143 AC_MSG_CHECKING(whether to use AFS)
1145 [ --with-afs Include AFS support
1146 --without-afs Don't include AFS support (default)],
1147 [ case "$withval" in
1159 #################################################
1160 # check for the DFS auth system
1161 AC_MSG_CHECKING(whether to use DFS auth)
1163 [ --with-dfs Include DFS support
1164 --without-dfs Don't include DFS support (default)],
1165 [ case "$withval" in
1177 #################################################
1178 # check for Kerberos IV auth system
1179 AC_MSG_CHECKING(whether to use Kerberos IV)
1181 [ --with-krb4=base-dir Include Kerberos IV support
1182 --without-krb4 Don't include Kerberos IV support (default)],
1183 [ AC_MSG_RESULT(yes)
1184 AC_DEFINE(KRB4_AUTH)
1185 AC_CHECK_LIB(resolv, dn_expand)
1186 LIBS="$LIBS -lkrb -ldes"
1187 CFLAGS="$CFLAGS -I$withval/include"
1188 LDFLAGS="$LDFLAGS -L$withval/lib"
1189 AC_CHECK_HEADER(kerberos/krb.h,
1190 AC_CACHE_CHECK([whether both krb.h and kerberos/krb.h can be included],
1191 samba_cv_no_kerberos_inconsistency,[
1192 AC_TRY_COMPILE([#include<kerberos/krb.h>
1194 [],samba_cv_no_kerberos_inconsistency=yes,samba_cv_no_kerberos_inconsistency=no)
1196 if test x"$samba_cv_no_kerberos_inconsistency" = x"no"; then
1197 AC_CACHE_CHECK([whether a Kerberos define work around is needed],
1198 samba_cv_kerberos_define_workaround,[
1199 AC_TRY_COMPILE([#define _KERBEROS_KRB_H
1200 #include<kerberos/krb.h>
1202 [],samba_cv_kerberos_define_workaround=yes,samba_cv_kerberos_define_workaround=no)
1204 if test x"$samba_cv_kerberos_define_workaround" = x"yes"; then
1205 AC_DEFINE(USE_KRB4_DEFINE_WORK_AROUND)
1211 #################################################
1212 # check for the AFS tickets from srvtabs
1213 AC_MSG_CHECKING(whether to use AFS tickets from srvtabs)
1215 [ --with-srvtab[=instance] Include renewable AFS tickets
1216 --without-srvtab Don't renewable AFS tickets (default)],
1217 [ case "$withval" in
1220 AC_DEFINE(USE_RENEWABLE_AFS_TICKET,"")
1227 AC_MSG_RESULT(yes using instance $withval)
1228 AC_DEFINE_UNQUOTED(USE_RENEWABLE_AFS_TICKET,$withval)
1235 #################################################
1236 # check for Kerberos 5 auth system
1237 AC_MSG_CHECKING(whether to use Kerberos 5)
1239 [ --with-krb5=base-dir Include Kerberos 5 support
1240 --without-krb5 Don't include Kerberos 5 support (default)],
1241 [ AC_MSG_RESULT(yes)
1242 AC_DEFINE(KRB5_AUTH)
1243 LIBS="$LIBS -ldes425 -lkrb5 -lcrypto -lcom_err"
1244 CFLAGS="$CFLAGS -I$withval/include"
1245 LDFLAGS="$LDFLAGS -L$withval/lib"],
1249 #################################################
1250 # check for automount support
1251 AC_MSG_CHECKING(whether to use AUTOMOUNT)
1252 AC_ARG_WITH(automount,
1253 [ --with-automount Include AUTOMOUNT support
1254 --without-automount Don't include AUTOMOUNT support (default)],
1255 [ case "$withval" in
1258 AC_DEFINE(WITH_AUTOMOUNT)
1267 #################################################
1268 # check for smbmount support
1269 AC_MSG_CHECKING(whether to use SMBMOUNT)
1270 AC_ARG_WITH(smbmount,
1271 [ --with-smbmount Include SMBMOUNT (Linux only) support
1272 --without-smbmount Don't include SMBMOUNT support (default)],
1273 [ case "$withval" in
1276 AC_DEFINE(WITH_SMBMOUNT)
1277 MPROGS="bin/smbmount bin/smbmnt bin/smbumount"
1289 #################################################
1290 # check for a PAM password database
1291 AC_MSG_CHECKING(whether to use PAM password database)
1293 [ --with-pam Include PAM password database support
1294 --without-pam Don't include PAM password database support (default)],
1295 [ case "$withval" in
1309 #################################################
1310 # check for a LDAP password database
1311 AC_MSG_CHECKING(whether to use LDAP password database)
1313 [ --with-ldap Include LDAP support
1314 --without-ldap Don't include LDAP support (default)],
1315 [ case "$withval" in
1318 AC_DEFINE(WITH_LDAP)
1319 LIBS="$LIBS -lldap -llber"
1328 #################################################
1329 # check for a LDAP password database
1330 AC_MSG_CHECKING(whether to use LDAP password database)
1331 AC_ARG_WITH(nt5ldap,
1332 [ --with-nt5ldap Include NT5 LDAP support
1333 --without-nt5ldap Don't include NT5 LDAP support (default)],
1334 [ case "$withval" in
1337 AC_DEFINE(WITH_NT5LDAP)
1338 LIBS="$LIBS -lldap -llber"
1347 #################################################
1348 # check for a LDAP password database
1349 AC_MSG_CHECKING(whether to use LDAP password database)
1350 AC_ARG_WITH(nt5ldap,
1351 [ --with-nt5ldap Include NT5 LDAP support
1352 --without-nt5ldap Don't include NT5 LDAP support (default)],
1353 [ case "$withval" in
1356 AC_DEFINE(WITH_NT5LDAP)
1357 LIBS="$LIBS -lldap -llber"
1366 #################################################
1367 # check for a NISPLUS password database
1368 AC_MSG_CHECKING(whether to use NISPLUS password database)
1369 AC_ARG_WITH(nisplus,
1370 [ --with-nisplus Include NISPLUS password database support
1371 --without-nisplus Don't include NISPLUS password database support (default)],
1372 [ case "$withval" in
1375 AC_DEFINE(WITH_NISPLUS)
1384 #################################################
1385 # decide for the default sam-password-database
1386 AC_MSG_CHECKING(which sam password database to use)
1387 AC_ARG_WITH(sam_pwdb,
1388 [ --with-sam-pwdb={passdb,tdb,nt5ldap}
1389 which password-database to use (passdb)],
1390 [ case "$withval" in
1392 SAM_PWDB_LIB='$(SAMRPASSLIB) $(SMBPWLIB)'
1393 sampwlibname="passdb"
1396 SAM_PWDB_LIB='$(SAMRTDBLIB)'
1400 SAM_PWDB_LIB='$(SAMRNT5LDAPLIB)'
1401 sampwlibname="nt5ldap (must also specify --with-nt5ldap)"
1404 SAM_PWDB_LIB='$(SAMRPASSLIB)'
1405 sampwlibname="passdb (unknown specified!)"
1408 SAM_PWDB_LIB='$(SAMRPASSLIB) $(SMBPWLIB)'
1409 sampwlibname="passdb (default)"
1411 AC_MSG_RESULT($sampwlibname)
1412 AC_SUBST(SAM_PWDB_LIB)
1415 #################################################
1416 # check to use a tdb surs database
1417 AC_MSG_CHECKING(whether to use SURS tdb database)
1418 AC_ARG_WITH(surstdb,
1419 [ --with-surstdb Use SURS tdb database
1420 --without-surstdb Don't use SURS tdb database (default)],
1421 [ case "$withval" in
1424 AC_DEFINE(WITH_TDBSURS)
1434 #################################################
1435 # check for a NISPLUS_HOME support
1436 AC_MSG_CHECKING(whether to use NISPLUS_HOME)
1437 AC_ARG_WITH(nisplus-home,
1438 [ --with-nisplus-home Include NISPLUS_HOME support
1439 --without-nisplus-home Don't include NISPLUS_HOME support (default)],
1440 [ case "$withval" in
1443 AC_DEFINE(WITH_NISPLUS_HOME)
1452 #################################################
1453 # check for the secure socket layer
1454 AC_MSG_CHECKING(whether to use SSL)
1456 [ --with-ssl Include SSL support
1457 --without-ssl Don't include SSL support (default)
1458 --with-sslinc=DIR Where the SSL includes are (defaults to /usr/local/ssl)],
1459 [ case "$withval" in
1463 withval="/usr/local/ssl" # default
1465 if test "${with_sslinc+set}" = set; then
1467 withval="$with_sslinc"
1470 echo "configure: warning: --with-sslinc called without argument - will use default" 1>&w
1471 CFLAGS="-I/usr/local/ssl/include $CFLAGS"
1472 LIBS="-lssl -lcrypto $LIBS"
1473 LDFLAGS="=L/usr/local/ssl/lib $LDFLAGS"
1476 CFLAGS="-I${withval} $CFLAGS"
1477 LIBS="-lssl -lcrypto $LIBS"
1478 # LDFLAGS="-L${withval}/lib $LDFLAGS"
1484 CFLAGS="-I/usr/local/ssl/include $CFLAGS"
1485 LIBS="-lssl -lcrypto $LIBS"
1486 LDFLAGS="-L/usr/local/ssl/lib $LDFLAGS"
1490 if test ! -d ${withval}; then
1491 echo "configure: error: called with --with-ssl, but ssl base directory ${withval} does not exist or is not a directory. Aborting config" 1>&2
1495 CFLAGS="-DHAVE_CRYPT_DECL $CFLAGS" # Damn, SSLeay defines its own
1505 #################################################
1506 # check for syslog logging
1507 AC_MSG_CHECKING(whether to use syslog logging)
1509 [ --with-syslog Include experimental SYSLOG support
1510 --without-syslog Don't include SYSLOG support (default)],
1511 [ case "$withval" in
1514 AC_DEFINE(WITH_SYSLOG)
1523 #################################################
1524 # check for a shared memory profiling support
1525 AC_MSG_CHECKING(whether to use profiling)
1526 AC_ARG_WITH(profile,
1527 [ --with-profile Include profile support
1528 --without-profile Don't include profile support (default)],
1529 [ case "$withval" in
1532 AC_DEFINE(WITH_PROFILE)
1542 #################################################
1543 # check for experimental netatalk resource fork support
1544 AC_MSG_CHECKING(whether to support netatalk)
1545 AC_ARG_WITH(netatalk,
1546 [ --with-netatalk Include experimental Netatalk support
1547 --without-netatalk Don't include experimental Netatalk support (default)],
1548 [ case "$withval" in
1551 AC_DEFINE(WITH_NETATALK)
1560 #################################################
1561 # check for experimental disk-quotas support
1562 QUOTAOBJS=noquotas.o
1564 AC_MSG_CHECKING(whether to support disk-quotas)
1566 [ --with-quotas Include experimental disk-quota support
1567 --without-quotas Don't include experimental disk-quota support (default)],
1568 [ case "$withval" in
1581 #################################################
1582 # check for experimental utmp accounting
1584 AC_MSG_CHECKING(whether to support utmp accounting)
1586 [ --with-utmp Include experimental utmp accounting
1587 --without-utmp Don't include experimental utmp accounting (default)],
1588 [ case "$withval" in
1591 AC_DEFINE(WITH_UTMP)
1600 #################################################
1601 # check for MS Dfs support
1603 AC_MSG_CHECKING(whether to support MS Dfs)
1605 [ --with-msdfs Include MS Dfs support
1606 --without-msdfs Don't include MS Dfs support (default)],
1607 [ case "$withval" in
1619 #################################################
1620 # set samba configuration directory location
1622 if test "$sysconfdir" = '${prefix}/etc'
1624 # default sysconfdir, decide on prefix
1627 # if the prefix already contains the word samba,
1628 # we don't need to use a subdir for smb.conf
1629 sambaconfdir='${sysconfdir}'
1632 # otherwise, we use a separate dir
1633 sambaconfdir='${sysconfdir}/samba'
1637 # sysconfdir given, use that directly
1638 sambaconfdir='${sysconfdir}'
1640 AC_ARG_WITH(sambaconfdir,
1641 [ --with-sambaconfdir=DIR Where to put smb.conf etc. ($ac_default_prefix/lib)],
1642 [ case "$withval" in
1644 # Just --with-sambaconfdir, use the new default
1645 # (which has already been "calculated"
1648 # --without-sambaconfdir, use old default
1649 sambaconfdir='${LIBDIR}'
1652 sambaconfdir="$withval"
1656 [ # No --with(out)-sambaconfdir, use old version for some time.
1657 if test "$sysconfdir" = '${prefix}/etc'
1659 # sysconfdir not given
1660 sambaconfdir='${LIBDIR}']
1663 AC_SUBST(sambaconfdir)
1665 #################################################
1666 # set private directory location
1667 AC_ARG_WITH(privatedir,
1668 [ --with-privatedir=DIR Where to put smbpasswd ($ac_default_prefix/private)],
1669 [ case "$withval" in
1672 # Just in case anybody calls it without argument
1674 AC_MSG_WARN([--with-privatedir called without argument - will use default])
1675 privatedir='${prefix}/private'
1678 privatedir="$withval"
1681 AC_SUBST(privatedir)],
1682 [privatedir='${prefix}/private'
1683 AC_SUBST(privatedir)]
1686 #################################################
1687 # set lock directory location
1688 AC_ARG_WITH(lockdir,
1689 [ --with-lockdir=DIR Where to put lock files ($ac_default_prefix/var/locks)],
1690 [ case "$withval" in
1693 # Just in case anybody calls it without argument
1695 AC_MSG_WARN([--with-lockdir called without argument - will use default])
1696 lockdir='${VARDIR}/locks'
1703 [lockdir='${VARDIR}/locks'
1707 #################################################
1708 # set SWAT directory location
1709 AC_ARG_WITH(swatdir,
1710 [ --with-swatdir=DIR Where to put SWAT files ($ac_default_prefix/swat)],
1711 [ case "$withval" in
1714 # Just in case anybody does it
1716 AC_MSG_WARN([--with-swatdir called without argument - will use default])
1717 swatdir='${prefix}/swat'
1724 [swatdir='${prefix}/swat'
1728 #################################################
1729 # these tests are taken from the GNU fileutils package
1730 AC_CHECKING(how to get filesystem space usage)
1733 # Test for statvfs64.
1734 if test $space = no; then
1736 AC_CACHE_CHECK([statvfs64 function (SVR4)], fu_cv_sys_stat_statvfs64,
1738 #if defined(HAVE_UNISTD_H)
1741 #include <sys/types.h>
1742 #include <sys/statvfs.h>
1745 struct statvfs64 fsd;
1746 exit (statvfs64 (".", &fsd));
1748 fu_cv_sys_stat_statvfs64=yes,
1749 fu_cv_sys_stat_statvfs64=no,
1750 fu_cv_sys_stat_statvfs64=cross)])
1751 if test $fu_cv_sys_stat_statvfs64 = yes; then
1753 AC_DEFINE(STAT_STATVFS64)
1757 # Perform only the link test since it seems there are no variants of the
1758 # statvfs function. This check is more than just AC_CHECK_FUNCS(statvfs)
1759 # because that got a false positive on SCO OSR5. Adding the declaration
1760 # of a `struct statvfs' causes this test to fail (as it should) on such
1761 # systems. That system is reported to work fine with STAT_STATFS4 which
1762 # is what it gets when this test fails.
1763 if test $space = no; then
1765 AC_CACHE_CHECK([statvfs function (SVR4)], fu_cv_sys_stat_statvfs,
1766 [AC_TRY_LINK([#include <sys/types.h>
1767 #include <sys/statvfs.h>],
1768 [struct statvfs fsd; statvfs (0, &fsd);],
1769 fu_cv_sys_stat_statvfs=yes,
1770 fu_cv_sys_stat_statvfs=no)])
1771 if test $fu_cv_sys_stat_statvfs = yes; then
1773 AC_DEFINE(STAT_STATVFS)
1777 if test $space = no; then
1778 # DEC Alpha running OSF/1
1779 AC_MSG_CHECKING([for 3-argument statfs function (DEC OSF/1)])
1780 AC_CACHE_VAL(fu_cv_sys_stat_statfs3_osf1,
1782 #include <sys/param.h>
1783 #include <sys/types.h>
1784 #include <sys/mount.h>
1789 exit (statfs (".", &fsd, sizeof (struct statfs)));
1791 fu_cv_sys_stat_statfs3_osf1=yes,
1792 fu_cv_sys_stat_statfs3_osf1=no,
1793 fu_cv_sys_stat_statfs3_osf1=no)])
1794 AC_MSG_RESULT($fu_cv_sys_stat_statfs3_osf1)
1795 if test $fu_cv_sys_stat_statfs3_osf1 = yes; then
1797 AC_DEFINE(STAT_STATFS3_OSF1)
1801 if test $space = no; then
1803 AC_MSG_CHECKING([for two-argument statfs with statfs.bsize dnl
1804 member (AIX, 4.3BSD)])
1805 AC_CACHE_VAL(fu_cv_sys_stat_statfs2_bsize,
1807 #ifdef HAVE_SYS_PARAM_H
1808 #include <sys/param.h>
1810 #ifdef HAVE_SYS_MOUNT_H
1811 #include <sys/mount.h>
1813 #ifdef HAVE_SYS_VFS_H
1814 #include <sys/vfs.h>
1820 exit (statfs (".", &fsd));
1822 fu_cv_sys_stat_statfs2_bsize=yes,
1823 fu_cv_sys_stat_statfs2_bsize=no,
1824 fu_cv_sys_stat_statfs2_bsize=no)])
1825 AC_MSG_RESULT($fu_cv_sys_stat_statfs2_bsize)
1826 if test $fu_cv_sys_stat_statfs2_bsize = yes; then
1828 AC_DEFINE(STAT_STATFS2_BSIZE)
1832 if test $space = no; then
1834 AC_MSG_CHECKING([for four-argument statfs (AIX-3.2.5, SVR3)])
1835 AC_CACHE_VAL(fu_cv_sys_stat_statfs4,
1836 [AC_TRY_RUN([#include <sys/types.h>
1837 #include <sys/statfs.h>
1841 exit (statfs (".", &fsd, sizeof fsd, 0));
1843 fu_cv_sys_stat_statfs4=yes,
1844 fu_cv_sys_stat_statfs4=no,
1845 fu_cv_sys_stat_statfs4=no)])
1846 AC_MSG_RESULT($fu_cv_sys_stat_statfs4)
1847 if test $fu_cv_sys_stat_statfs4 = yes; then
1849 AC_DEFINE(STAT_STATFS4)
1853 if test $space = no; then
1855 AC_MSG_CHECKING([for two-argument statfs with statfs.fsize dnl
1856 member (4.4BSD and NetBSD)])
1857 AC_CACHE_VAL(fu_cv_sys_stat_statfs2_fsize,
1858 [AC_TRY_RUN([#include <sys/types.h>
1859 #ifdef HAVE_SYS_PARAM_H
1860 #include <sys/param.h>
1862 #ifdef HAVE_SYS_MOUNT_H
1863 #include <sys/mount.h>
1869 exit (statfs (".", &fsd));
1871 fu_cv_sys_stat_statfs2_fsize=yes,
1872 fu_cv_sys_stat_statfs2_fsize=no,
1873 fu_cv_sys_stat_statfs2_fsize=no)])
1874 AC_MSG_RESULT($fu_cv_sys_stat_statfs2_fsize)
1875 if test $fu_cv_sys_stat_statfs2_fsize = yes; then
1877 AC_DEFINE(STAT_STATFS2_FSIZE)
1881 if test $space = no; then
1883 AC_MSG_CHECKING([for two-argument statfs with struct fs_data (Ultrix)])
1884 AC_CACHE_VAL(fu_cv_sys_stat_fs_data,
1885 [AC_TRY_RUN([#include <sys/types.h>
1886 #ifdef HAVE_SYS_PARAM_H
1887 #include <sys/param.h>
1889 #ifdef HAVE_SYS_MOUNT_H
1890 #include <sys/mount.h>
1892 #ifdef HAVE_SYS_FS_TYPES_H
1893 #include <sys/fs_types.h>
1898 /* Ultrix's statfs returns 1 for success,
1899 0 for not mounted, -1 for failure. */
1900 exit (statfs (".", &fsd) != 1);
1902 fu_cv_sys_stat_fs_data=yes,
1903 fu_cv_sys_stat_fs_data=no,
1904 fu_cv_sys_stat_fs_data=no)])
1905 AC_MSG_RESULT($fu_cv_sys_stat_fs_data)
1906 if test $fu_cv_sys_stat_fs_data = yes; then
1908 AC_DEFINE(STAT_STATFS2_FS_DATA)
1913 # As a gating factor for large file support, in order to
1914 # use <4GB files we must have the following minimal support
1916 # long long, and a 64 bit off_t or off64_t.
1917 # If we don't have all of these then disable large
1920 echo "checking if large file support can be enabled"
1922 #if defined(HAVE_LONGLONG) && (defined(HAVE_OFF64_T) || (defined(SIZEOF_OFF_T) && (SIZEOF_OFF_T == 8)))
1923 #include <sys/types.h>
1929 samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT=yes,samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT=no)
1930 if test x"$samba_cv_HAVE_EXPLICIT_LARGEFILE_SUPPORT" = x"yes"; then
1932 AC_DEFINE(HAVE_EXPLICIT_LARGEFILE_SUPPORT)
1937 echo "checking configure summary"
1938 AC_TRY_RUN([#include "${srcdir-.}/tests/summary.c"],
1939 echo "configure OK";,
1940 AC_MSG_ERROR([summary failure. Aborting config]),:)
1945 AC_OUTPUT([include/stamp-h Makefile script/samba-init.d],
1947 case " $CONFIG_FILES " in
1948 *" script/samba-init.d "*) chmod +x script/samba-init.d
1953 echo "prefix : $prefix"
1954 echo "exec_prefix : $exec_prefix"
1955 echo "bindir : $bindir"
1956 echo "sbindir : $sbindir"
1957 echo "libdir : $libdir"
1958 echo "vardir : $localstatedir"
1959 echo "sysconfdir : $sysconfdir"
1961 echo "sambaconfdir : $sambaconfdir"
1962 echo "privatedir : $privatedir"
1963 echo "lockdir : $lockdir"
1964 echo "swatdir : $swatdir"