X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=configure.ac;h=6dac0a9a2bb46a527b8b22d0d50dd8171c4a3e6d;hb=b0cd81f83c380d93c7019e43910cff73b0d5e800;hp=bf0b3c2be83922e837d6d619eab21242963e9aad;hpb=30bdec7c3396de87144d5f6d45f11ffa6dad116b;p=netatalk.git diff --git a/configure.ac b/configure.ac index bf0b3c2b..6dac0a9a 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -dnl configure.in for netatalk +dnl configure.ac for netatalk AC_INIT(etc/afpd/main.c) @@ -27,9 +27,6 @@ AM_PROG_CC_C_O dnl Checks for typedefs, structures, and compiler characteristics. AC_C_INLINE -dnl Request SUSv3 standard interfaces plus anything else the platform may have -CFLAGS="$CFLAGS -D_XOPEN_SOURCE=600 -D__EXTENSIONS__ -D_GNU_SOURCE" - dnl Check if we can use attribute unused (gcc only) from ethereal AC_MSG_CHECKING(to see if we can add '__attribute__((unused))' to CFLAGS) if test x$GCC != x ; then @@ -48,7 +45,6 @@ AC_CHECK_HEADERS(netdb.h sgtty.h statfs.h dlfcn.h langinfo.h locale.h) AC_CHECK_HEADERS(sys/param.h sys/fcntl.h sys/termios.h) AC_CHECK_HEADERS(sys/mnttab.h sys/statvfs.h sys/stat.h sys/vfs.h) dnl Checks for header files, confirmed to be required as of 2011 -AC_CHECK_HEADERS(sys/epoll.h) AC_CHECK_HEADERS([sys/mount.h], , , [#ifdef HAVE_SYS_PARAM_H #include @@ -77,7 +73,6 @@ fi AC_CHECK_MEMBERS(struct tm.tm_gmtoff,,, [#include ]) dnl these tests have been comfirmed to be needed in 2011 -AC_CHECK_FUNC(epoll_create, AC_DEFINE([HAVE_EPOLL], 1, Whether Linux epoll is available)) AC_CHECK_FUNCS(backtrace_symbols dirfd getusershell pread pwrite pselect) AC_CHECK_FUNCS(setlinebuf strlcat strlcpy strnlen) AC_CHECK_FUNCS(mmap utime getpagesize) dnl needed by tbd @@ -93,51 +88,11 @@ AC_SUBST(PTHREAD_LIBS) AC_DEFINE(OPEN_NOFOLLOW_ERRNO, ELOOP, errno returned by open with O_NOFOLLOW) -AC_CACHE_SAVE - -dnl -------------------------------------------------------------------------- dnl 64bit platform check -dnl -------------------------------------------------------------------------- - -AC_MSG_CHECKING([whether to check for 64bit libraries]) -# Test if the compiler is in 64bit mode -echo 'int i;' > conftest.$ac_ext -atalk_cv_cc_64bit_output=no -if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *"ELF 64"*) - atalk_cv_cc_64bit_output=yes - ;; - esac -fi -rm -rf conftest* - -case $host_cpu:$atalk_cv_cc_64bit_output in -powerpc64:yes | s390x:yes | sparc*:yes | x86_64:yes | i386:yes) - case $target_os in - solaris2*) - AC_MSG_RESULT([yes]) - atalk_libname="lib/64" - ;; - *bsd* | dragonfly*) - AC_MSG_RESULT([no]) - atalk_libname="lib" - ;; - *) - AC_MSG_RESULT([yes]) - atalk_libname="lib64" - ;; - esac - ;; -*:*) - AC_MSG_RESULT([no]) - atalk_libname="lib" - ;; -esac +AC_NETATALK_64BIT_LIBS -dnl -------------------------------------------------------------------------- -dnl specific configuration comes in here: -dnl -------------------------------------------------------------------------- +dnl OS specific checks +AC_NETATALK_OS_SPECIFIC dnl Check for optional admin group support AC_NETATALK_ADMIN_GROUP @@ -166,9 +121,6 @@ AC_NETATALK_CNID([bdb_required=yes],[bdb_required=no]) dnl Check for quota support AC_NETATALK_CHECK_QUOTA -dnl Check for optional server location protocol support (used by MacOS X) -AC_NETATALK_SRVLOC - dnl Check for optional Zeroconf support AC_NETATALK_ZEROCONF @@ -184,14 +136,11 @@ AC_NETATALK_SHADOW dnl Check for optional valid-shell-check support AC_NETATALK_SHELL_CHECK -dnl Check for optional Webmin -AC_NETATALK_WEBMIN - dnl Check for optional sysv initscript install AC_NETATALK_SYSV_STYLE dnl Path where UAM modules shall be installed -AC_ARG_WITH(uams-path, [ --with-uams-path=PATH path to UAMs [[PKGCONF/uams]]], [uams_path="$withval"], [uams_path="${PKGCONFDIR}/uams"]) +AC_ARG_WITH(uams-path, [ --with-uams-path=PATH path to UAMs [[$libdir/netatalk/]]], [uams_path="$withval/"], [uams_path="$libdir/netatalk/"]) dnl Check for libgcrypt, if found enables DHX2 UAM AC_NETATALK_PATH_LIBGCRYPT([1:1.2.3]) @@ -232,63 +181,16 @@ AC_NETATALK_REALPATH dnl Check for sendfile() AC_NETATALK_SENDFILE -dnl -------------------------------------------------------------------------- dnl FHS stuff has to be done last because it overrides other defaults -dnl -------------------------------------------------------------------------- - -AC_MSG_CHECKING([whether to use Filesystem Hierarchy Standard (FHS) compatibility]) -AC_ARG_ENABLE(fhs, - [ --enable-fhs use Filesystem Hierarchy Standard (FHS) compatibility],[ - if test "$enableval" = "yes"; then - uams_path="${libdir}/netatalk" - sysconfdir="/etc" - PKGCONFDIR=${sysconfdir}/netatalk - SERVERTEXT="${PKGCONFDIR}/msg" - use_pam_so=yes - mandir="/usr/share/man" - AC_DEFINE(FHS_COMPATIBILITY, 1, [Define if you want compatibily with the FHS]) - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - fi - ],[ - AC_MSG_RESULT([no]) - ] -) +AC_NETATALK_FHS -dnl -------------------------------------------------------------------------- -dnl post-FHS substitutions, etc -dnl -------------------------------------------------------------------------- - -UAMS_PATH="${uams_path}" -AC_SUBST(UAMS_PATH) - - -dnl -------------------------------------------------------------------------- -dnl OS specific configuration comes in here: -dnl -------------------------------------------------------------------------- - -AC_NETATALK_OS_SPECIFIC - - -dnl -------------------------------------------------------------------------- -dnl drop in includes for top level directory structures here... -dnl -------------------------------------------------------------------------- - -dnl Note: $(top_srcdir)/include should be added before all other includes -dnl so that includes from that directory a preferred to includes from -dnl /usr/include or similar places. LIBS="$LIBS -L\$(top_srcdir)/libatalk" CFLAGS="-I\$(top_srcdir)/include -I\$(top_srcdir)/sys $CFLAGS" +UAMS_PATH="${uams_path}" - -dnl -------------------------------------------------------------------------- -dnl Last minute substitutions -dnl -------------------------------------------------------------------------- - -dnl ac_cv_target_os is now host_os, ac_cv_target_cpu is now host_cpu AC_SUBST(LIBS) AC_SUBST(CFLAGS) +AC_SUBST(UAMS_PATH) AM_CONDITIONAL(SOLARIS_MODULE, test x$solaris_module = xyes) AM_CONDITIONAL(HAVE_LIBGCRYPT, test x$neta_cv_have_libgcrypt = xyes) @@ -315,7 +217,7 @@ AC_OUTPUT([Makefile bin/cnid/Makefile bin/cnid/cnid2_create bin/megatron/Makefile - bin/misc/Makefile + bin/misc/Makefile bin/uniconv/Makefile config/Makefile config/pam/Makefile @@ -330,7 +232,6 @@ AC_OUTPUT([Makefile distrib/config/netatalk-config distrib/initscripts/Makefile distrib/m4/Makefile - distrib/systemd/Makefile doc/Makefile etc/Makefile etc/afpd/Makefile @@ -349,6 +250,7 @@ AC_OUTPUT([Makefile libatalk/cnid/tdb/Makefile libatalk/compat/Makefile libatalk/dsi/Makefile + libatalk/iniparser/Makefile libatalk/tdb/Makefile libatalk/unicode/Makefile libatalk/unicode/charsets/Makefile