dnl --------------------------------------------------
dnl Libtool config
dnl --------------------------------------------------
-LT_INIT([shared disable-static])
-LT_LANG([C++])
AC_ARG_ENABLE(libtool,
AC_HELP_STRING([--enable-libtool], [enable building using GNU libtool @<:@default=yes@:>@]),
[
fi
]
)
+LT_INIT([shared disable-static])
+LT_LANG([C++])
if test x$use_libtool != xno; then
DEFAULT_OBJECT_TYPE=".lo"
QMAKE_LIBTOOL="# ${BUILD_DIR}/libtool"
fi
-INCLUDE_INSTALL_TARGET=""
-INCLUDE_UNINSTALL_TARGET=""
-
AC_SUBST(DEFAULT_OBJECT_TYPE)
AC_SUBST(DEFAULT_ARCHIVE_TYPE)
AC_SUBST(DEFAULT_SHARED_OBJECT_TYPE)
AC_SUBST(LIBTOOL_INSTALL_TARGET)
AC_SUBST(LIBTOOL_UNINSTALL_TARGET)
AC_SUBST(LIBTOOL_CLEAN_TARGET)
+AC_SUBST(QMAKE_LIBTOOL)
+
+dnl --------------------------------------------------
+dnl Include file handling
+dnl --------------------------------------------------
+AC_ARG_ENABLE(includes,
+ AC_HELP_STRING([--enable-includes], [enable installing of include files @<:@default=no@:>@]),
+ [
+ if test x$enableval = xyes; then
+ install_includes=yes
+ fi
+ ]
+)
+
+dnl It only makes sense to install include files when you install libraries which only happens when
+dnl libtool is enabled
+
+if test x$use_libtool != xno -a x$install_includes = xyes; then
+ INCLUDE_INSTALL_TARGET="install-includes"
+ INCLUDE_UNINSTALL_TARGET="uninstall-includes"
+else
+ INCLUDE_INSTALL_TARGET=""
+ INCLUDE_UNINSTALL_TARGET=""
+fi
AC_SUBST(INCLUDE_INSTALL_TARGET)
AC_SUBST(INCLUDE_UNINSTALL_TARGET)
-AC_SUBST(QMAKE_LIBTOOL)
dnl --------------------------------------------------
dnl Bacula OP Sys determination (see aclocal.m4)
dnl In this case, if the user has not set --sysconfdir, we set it
dnl to the package default of /etc/bacula. If either --prefix or
dnl --sysconfdir is set, we leave sysconfdir alone except to eval it.
+dnl If the user has not set --libdir, we set it to the package
+dnl default of /usr/lib. If either --prefix or --libdir is set,
+dnl we leave libdir alone except to eval it. If the user has not set
+dnl --includedir, we set it to the package default of /usr/include.
+dnl If either --prefix or --includedir is set, we leave includedir
+dnl alone except to eval it
dnl ------------------------------------------------------------------
if test x${prefix} = xNONE ; then
if test `eval echo ${sysconfdir}` = NONE/etc ; then
sysconfdir=/etc/bacula
fi
+
+ if test `eval echo ${libdir}` = NONE/lib ; then
+ libdir=/usr/lib
+ fi
+
+ if test `eval echo ${includedir}` = NONE/include ; then
+ includedir=/usr/include
+ fi
+
prefix=
fi
-sysconfdir=`eval echo ${sysconfdir}`
-datarootdir=`eval echo ${datarootdir}`
-localedir=`eval echo ${datarootdir}/locale`
-AC_DEFINE_UNQUOTED(SYSCONFDIR, "$sysconfdir")
-AC_DEFINE_UNQUOTED(LOCALEDIR, "$localedir")
dnl -------------------------------------------------------------------------
dnl If the user has not set --exec-prefix, we default to ${prefix}
exec_prefix=${prefix}
fi
+sysconfdir=`eval echo ${sysconfdir}`
+datarootdir=`eval echo ${datarootdir}`
+libdir=`eval echo ${libdir}`
+includedir=`eval echo ${includedir}`
+localedir=`eval echo ${datarootdir}/locale`
+AC_DEFINE_UNQUOTED(SYSCONFDIR, "$sysconfdir")
+AC_DEFINE_UNQUOTED(LOCALEDIR, "$localedir")
+
dnl ------------------------------------------------------------------
dnl If the user has not set --sbindir, we set our default as /sbin
dnl ------------------------------------------------------------------
fi
sbindir=`eval echo ${sbindir}`
-dnl ------------------------------------------------------------------
-dnl If the user has not set --libdir, we set our default as /lib
-dnl ------------------------------------------------------------------
-if test x$libdir = x'${exec_prefix}/lib' ; then
- libdir=${exec_prefix}/lib
-fi
-libdir=`eval echo ${libdir}`
-
-dnl ------------------------------------------------------------------
-dnl If the user has not set --includedir, we set our default as /include
-dnl ------------------------------------------------------------------
-if test x$includedir = x'${exec_prefix}/include' ; then
- includedir=${exec_prefix}/include
-fi
-includedir=`eval echo ${includedir}`
-
dnl -------------------------------------------------------------------------
dnl If the user has not set --mandir, we default to /usr/share/man
dnl -------------------------------------------------------------------------
support_gnome=no
support_bat=no
support_wx_console=no
+support_tray_monitor=no
support_tls=no
support_crypto=no
gnome_version=
dnl Check for ACL libraries
dnl
have_acl=no
+have_extended_acl=no
AC_CHECK_HEADER(sys/acl.h)
AC_CHECK_FUNC(acl_get_file, [have_acl=yes],
[
[
have_acl=yes;
FDLIBS="-lsec $FDLIBS"
+
+ AC_CHECK_LIB(sec, acl_totext,
+ [
+ have_extended_acl=yes
+ ]
+ )
]
)
]
AC_DEFINE(HAVE_ACL)
fi
+if test $have_extended_acl = yes; then
+ AC_DEFINE(HAVE_EXTENDED_ACL)
+fi
+
dnl Check for pthread libraries
PTHREAD_LIB=""
AC_CHECK_LIB(pthread, pthread_create, PTHREAD_LIB="-lpthread",
fi
fi
+# clean up any old junk
+echo " "
+echo "Cleaning up"
+echo " "
+make clean
+
if test "x${db_type}" = "xInternal" ; then
echo " "
echo " "