Depend on external libbeecrypt

This commit is contained in:
Ralf Corsépius 2007-08-10 10:02:25 +02:00
parent 5b21d43bf4
commit 65c3b9c4ab
2 changed files with 5 additions and 15 deletions

View File

@ -7,7 +7,7 @@ EXTRA_DIST = CHANGES ChangeLog CREDITS Doxyheader GROUPS INSTALL \
config.site db db3/configure installplatform platform* \
rpm.magic rpmpopt-$(VERSION)
SUBDIRS = po misc @WITH_ZLIB_SUBDIR@ @WITH_ELFUTILS_SUBDIR@ @WITH_MAGIC_SUBDIR@ @WITH_DB_SUBDIR@ @WITH_SQLITE3_SUBDIR@ @WITH_BEECRYPT_SUBDIR@ @WITH_NEON_SUBDIR@ lua rpmio rpmdb lib build python tools scripts doc .
SUBDIRS = po misc @WITH_ZLIB_SUBDIR@ @WITH_ELFUTILS_SUBDIR@ @WITH_MAGIC_SUBDIR@ @WITH_DB_SUBDIR@ @WITH_SQLITE3_SUBDIR@ @WITH_NEON_SUBDIR@ lua rpmio rpmdb lib build python tools scripts doc .
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = rpm.pc

View File

@ -458,32 +458,22 @@ AC_SUBST(WITH_LIBDWARF_INCLUDE)
AC_SUBST(WITH_LIBDWARF_DEBUGEDIT)
#=================
# Check for beecrypt library. Prefer external, otherwise internal.
WITH_BEECRYPT_SUBDIR=
# Check for beecrypt library.
WITH_BEECRYPT_INCLUDE=
WITH_BEECRYPT_LIB=
AC_CHECK_HEADER([beecrypt/beecrypt.h], [
AC_CHECK_LIB(beecrypt, mpfprintln, [
AC_DEFINE(HAVE_LIBBEECRYPT, 1, [Define to 1 if you have the 'beecrypt' library (-lbeecrypt).])
AC_CHECK_HEADER([beecrypt/api.h], [
AC_DEFINE(HAVE_BEECRYPT_API_H, 1, [Define to 1 if you have the <beecrypt/api.h> header file.])
])
WITH_BEECRYPT_INCLUDE=
WITH_BEECRYPT_LIB="-lbeecrypt"
],[
AC_MSG_ERROR([missing required library beecrypt])
])
],[
if test -d beecrypt ; then
AC_DEFINE(HAVE_LIBBEECRYPT, 1, [Define to 1 if you have the 'beecrypt' library (-lbeecrypt).])
WITH_BEECRYPT_SUBDIR=beecrypt
WITH_BEECRYPT_INCLUDE="-I\${top_srcdir}/${WITH_BEECRYPT_SUBDIR}"
WITH_BEECRYPT_LIB="\${top_builddir}/${WITH_BEECRYPT_SUBDIR}/libbeecrypt.la"
fi
if test -z "${WITH_BEECRYPT_LIB}" ; then
AC_MSG_ERROR([rpm requires beecrypt])
fi
AC_MSG_ERROR([missing required header beecrypt/beecrypt.h])
])
AC_SUBST(WITH_BEECRYPT_SUBDIR)
AC_SUBST(WITH_BEECRYPT_INCLUDE)
AC_SUBST(WITH_BEECRYPT_LIB)