| 1 | dnl
|
|---|
| 2 | dnl Samba3 build environment path checks
|
|---|
| 3 | dnl
|
|---|
| 4 | dnl Copyright (C) Michael Adam 2008
|
|---|
| 5 | dnl
|
|---|
| 6 | dnl Released under the GNU General Public License
|
|---|
| 7 | dnl http://www.gnu.org/licenses/
|
|---|
| 8 | dnl
|
|---|
| 9 |
|
|---|
| 10 | AC_LIBREPLACE_LOCATION_CHECKS
|
|---|
| 11 |
|
|---|
| 12 | #################################################
|
|---|
| 13 | # Directory handling stuff to support both the
|
|---|
| 14 | # legacy SAMBA directories and FHS compliant
|
|---|
| 15 | # ones...
|
|---|
| 16 | AC_PREFIX_DEFAULT(/usr/local/samba)
|
|---|
| 17 |
|
|---|
| 18 | rootsbindir="\${SBINDIR}"
|
|---|
| 19 | lockdir="\${VARDIR}/locks"
|
|---|
| 20 | piddir="\${VARDIR}/locks"
|
|---|
| 21 | test "${mandir}" || mandir="\${prefix}/man"
|
|---|
| 22 | logfilebase="\${VARDIR}"
|
|---|
| 23 | privatedir="\${prefix}/private"
|
|---|
| 24 | test "${libdir}" || libdir="\${prefix}/lib"
|
|---|
| 25 | pammodulesdir="\${LIBDIR}/security"
|
|---|
| 26 | configdir="\${LIBDIR}"
|
|---|
| 27 | swatdir="\${prefix}/swat"
|
|---|
| 28 | codepagedir="\${LIBDIR}"
|
|---|
| 29 | statedir="\${LOCKDIR}"
|
|---|
| 30 | cachedir="\${LOCKDIR}"
|
|---|
| 31 |
|
|---|
| 32 | AC_ARG_WITH(fhs,
|
|---|
| 33 | [AS_HELP_STRING([--with-fhs],[Use FHS-compliant paths (default=no)])],
|
|---|
| 34 | [ case "$withval" in
|
|---|
| 35 | yes)
|
|---|
| 36 | lockdir="\${VARDIR}/lib/samba"
|
|---|
| 37 | piddir="\${VARDIR}/run"
|
|---|
| 38 | mandir="\${prefix}/share/man"
|
|---|
| 39 | logfilebase="\${VARDIR}/log/samba"
|
|---|
| 40 | privatedir="\${CONFIGDIR}/private"
|
|---|
| 41 | test "${libdir}" || libdir="\${prefix}/lib/samba"
|
|---|
| 42 | configdir="\${sysconfdir}/samba"
|
|---|
| 43 | swatdir="\${DATADIR}/samba/swat"
|
|---|
| 44 | codepagedir="\${LIBDIR}"
|
|---|
| 45 | statedir="\${VARDIR}/lib/samba"
|
|---|
| 46 | cachedir="\${VARDIR}/lib/samba"
|
|---|
| 47 | AC_DEFINE(FHS_COMPATIBLE, 1, [Whether to use fully FHS-compatible paths])
|
|---|
| 48 | ;;
|
|---|
| 49 | esac])
|
|---|
| 50 |
|
|---|
| 51 | #################################################
|
|---|
| 52 | # set private directory location
|
|---|
| 53 | AC_ARG_WITH(privatedir,
|
|---|
| 54 | [AS_HELP_STRING([--with-privatedir=DIR], [Where to put smbpasswd ($ac_default_prefix/private)])],
|
|---|
| 55 | [ case "$withval" in
|
|---|
| 56 | yes|no)
|
|---|
| 57 | #
|
|---|
| 58 | # Just in case anybody calls it without argument
|
|---|
| 59 | #
|
|---|
| 60 | AC_MSG_WARN([--with-privatedir called without argument - will use default])
|
|---|
| 61 | ;;
|
|---|
| 62 | * )
|
|---|
|
|---|