1 dnl Configure script for NBD system
2 dnl (c) 1998 Martin Mares <mj@ucw.cz>, (c) 2000 Pavel Machek <pavel@ucw.cz>
3 AC_INIT(nbd, 2.5, wouter@debian.org)
4 AC_ARG_ENABLE(lfs, AC_HELP_STRING([--enable-lfs],[Enable Large File Support (default is no)]), [NBD_LFS=1], [NBD_LFS=0])
5 AC_MSG_CHECKING([whether Large File Support should be enabled])
6 if test $NBD_LFS -eq 1; then
7 AC_DEFINE(NBD_LFS,1, [Define to 1 if Large File Support should be enabled])
14 AC_MSG_CHECKING(whether warnings should be enabled)
15 if test -n "$GCC" ; then
17 CFLAGS="$CFLAGS -Wall -W -Wno-parentheses -Wstrict-prototypes -Wno-unused"
25 AC_CHECK_SIZEOF(unsigned short int)
26 AC_CHECK_SIZEOF(unsigned int)
27 AC_CHECK_SIZEOF(unsigned long int)
28 AC_CHECK_SIZEOF(unsigned long long int)
29 AC_CHECK_FUNCS([llseek alarm gethostbyname inet_ntoa memset socket strerror strstr])
33 AC_FUNC_SETVBUF_REVERSED
34 AC_MSG_CHECKING(whether client should be built)
36 *Linux*) BUILD_CLIENT=nbd-client
39 *) AC_MSG_RESULT(no) ;;
41 AC_CHECK_HEADERS([linux/nbd.h arpa/inet.h fcntl.h netdb.h netinet/in.h sys/ioctl.h sys/mount.h sys/socket.h syslog.h])
45 AC_SUBST(BUILD_CLIENT)
46 AC_CONFIG_HEADER(config.h)