mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-28 17:47:33 -05:00
Original test failed under FreeBSD. Reworked LN_H detection
after LN_S test. Moved to openldap.m4 and cached result. Does not yet handle case where LN_H == 'cp' and LN_S == 'ln'.
This commit is contained in:
parent
212e3d0f01
commit
4afc7aab40
3 changed files with 537 additions and 515 deletions
|
|
@ -55,6 +55,32 @@ dnl AC_VERBOSE(OpenLDAP --with-$1 $ol_with_$1)
|
|||
])dnl
|
||||
dnl
|
||||
dnl ====================================================================
|
||||
dnl
|
||||
dnl check if hard links are supported.
|
||||
dnl
|
||||
AC_DEFUN([OL_PROG_LN_H], [# test for ln hardlink support
|
||||
AC_MSG_CHECKING(whether ln works)
|
||||
AC_CACHE_VAL(ol_cv_prog_LN_H,
|
||||
[rm -f conftest.src conftest.dst
|
||||
echo "conftest" > conftest.src
|
||||
if ln conftest.src conftest.dst 2>/dev/null
|
||||
then
|
||||
ol_cv_prog_LN_H="ln"
|
||||
else
|
||||
ol_cv_prog_LN_H="cp"
|
||||
fi
|
||||
rm -f conftest.src conftest.dst
|
||||
])dnl
|
||||
LN_H="$ol_cv_prog_LN_H"
|
||||
if test "$ol_cv_prog_LN_H" = "ln"; then
|
||||
AC_MSG_RESULT(yes)
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
fi
|
||||
AC_SUBST(LN_H)dnl
|
||||
])dnl
|
||||
dnl
|
||||
dnl ====================================================================
|
||||
dnl Check if db.h is Berkeley DB2
|
||||
dnl
|
||||
dnl defines ol_cv_header_db2 to 'yes' or 'no'
|
||||
|
|
|
|||
17
configure.in
17
configure.in
|
|
@ -275,28 +275,15 @@ AC_PROG_INSTALL
|
|||
dnl The default compiler is cc (NOT gcc)
|
||||
CC=${CC-"cc"}
|
||||
dnl The default CFLAGS is empty NOT whatever AC_PROG_CC sets.
|
||||
CFLAGS=${CFLAGS-""}
|
||||
dnl CFLAGS=${CFLAGS-""}
|
||||
|
||||
AM_PROG_LIBTOOL
|
||||
dnl AC_PROG_MAKE_SET
|
||||
|
||||
AC_PROG_AWK
|
||||
OL_PROG_LN_H
|
||||
AC_PROG_LN_S
|
||||
|
||||
dnl Let's test for a way to hardlink (cp or ln)
|
||||
AC_MSG_CHECKING(if ln supports hardlinks)
|
||||
touch link_test.hard
|
||||
if ln link_test.hard link_test.linked > /dev/null 2>&1 ; then
|
||||
LN_H="ln"
|
||||
AC_MSG_RESULT(yes)
|
||||
rm -f link_test.linked
|
||||
else
|
||||
LN_H="cp"
|
||||
AC_MSG_RESULT(no...using cp)
|
||||
fi
|
||||
rm -f link_test.hard
|
||||
AC_SUBST(LN_H)
|
||||
|
||||
AC_PATH_PROG(SENDMAIL, sendmail, /usr/lib/sendmail,
|
||||
$PATH:/usr/libexec:/usr/lib:/usr/sbin:/usr/etc:/etc)
|
||||
AC_PATH_PROG(EDITOR, vi, /usr/ucb/vi, $PATH:/usr/ucb)
|
||||
|
|
|
|||
Loading…
Reference in a new issue