X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=configure.ac;h=24400c377857832dd8d756c1f91db8130b74d7b5;hb=ea545df91284aad921b800d757c3743551e9a2ab;hp=9689a1f57a721d7a001fb5bfd872be57cc180329;hpb=fc01d2a96189edc0c08fb1d757f83c63077b0516;p=deb_libnfs.git diff --git a/configure.ac b/configure.ac index 9689a1f..24400c3 100644 --- a/configure.ac +++ b/configure.ac @@ -1,5 +1,5 @@ AC_PREREQ(2.50) -AC_INIT([libnfs], [0.0.0]) +AC_INIT([libnfs], [1.0.0]) AC_CONFIG_HEADERS([config.h]) AM_INIT_AUTOMAKE([foreign]) AC_CANONICAL_HOST @@ -22,18 +22,6 @@ if test x$HAVE_RPCGEN != xyes; then AC_MSG_ERROR([Can not find required program]) fi -# option: logdir -AC_ARG_WITH([logdir], - [AC_HELP_STRING([--with-logdir=DIR], - [path to log directory [[LOCALSTATEDIR/log]]])], - [LOGDIR=$withval], - [LOGDIR='${localstatedir}/log']) - -#if test ! -d "$LOGDIR"; then -# AC_MSG_ERROR([--with-logdir must specify a path]) -#fi -AC_SUBST(LOGDIR) - #option: examples AC_ARG_ENABLE([examples], [AC_HELP_STRING([--enable-examples], @@ -46,12 +34,26 @@ if test x$ENABLE_EXAMPLES = xyes; then fi AC_SUBST(MAYBE_EXAMPLES) +AC_ARG_ENABLE(tirpc, + [AC_HELP_STRING([--enable-tirpc], + [enable use of TI-RPC @<:@default=no@:>@])], + enable_tirpc=$enableval, + enable_tirpc='no') + case $host in *darwin*) RPCGENFLAGS=-DU_INT64_PLATTFORM_TYPE="u_int64_t" ;; + *cygwin*) + RPCGENFLAGS=-DU_INT64_PLATTFORM_TYPE="u_int64_t" + ;; *solaris*) AC_CHECK_HEADERS([sys/filio.h]) + AC_CHECK_HEADERS([sys/sockio.h]) + if test x$ENABLE_EXAMPLES = xyes; then + AC_CHECK_LIB([socket], [main], , [AC_MSG_ERROR([Can not find required library])]) + AC_CHECK_LIB([nsl], [main], , [AC_MSG_ERROR([Can not find required library])]) + fi ;; *) ;; @@ -59,6 +61,22 @@ esac AC_SUBST(RPCGENFLAGS) +# check for SA_LEN +dnl Check if sockaddr data structure includes a "sa_len" +AC_CHECK_MEMBER([struct sockaddr.sa_len], + [ AC_DEFINE(HAVE_SOCKADDR_LEN,1,[Whether sockaddr struct has sa_len]) ], + [], + [ +#include +#include +]) + +echo "Use TI-RPC: $enable_tirpc" +if test "$enable_tirpc" = "yes"; then + CFLAGS="${CFLAGS} -I /usr/include/tirpc" + LDFLAGS="${LDFLAGS} -ltirpc" +fi + #output AC_CONFIG_FILES([Makefile] [include/Makefile] @@ -70,4 +88,4 @@ AC_CONFIG_FILES([Makefile] [examples/Makefile] ) -AC_OUTPUT +AC_OUTPUT([libnfs.pc])