dnl----- Licensing notice ---------------------------------------------------
dnl
-dnl This program is free software; you can redistribute it and/or modify
+dnl This file is part of the distorted.org.uk backup suite.
+dnl
+dnl distorted-backup is free software; you can redistribute it and/or modify
dnl it under the terms of the GNU General Public License as published by
dnl the Free Software Foundation; either version 2 of the License, or
dnl (at your option) any later version.
dnl
-dnl This program is distributed in the hope that it will be useful,
+dnl distorted-backup is distributed in the hope that it will be useful,
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
dnl GNU General Public License for more details.
dnl
-dnl You should have received a copy of the GNU General Public License
-dnl along with this program; if not, write to the Free Software Foundation,
+dnl You should have received a copy of the GNU General Public License along
+dnl with distorted-backup; if not, write to the Free Software Foundation,
dnl Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
dnl--------------------------------------------------------------------------
dnl C programming environment.
PKG_CHECK_MODULES([mLib], [mLib >= 2.1.0])
-PKG_CHECK_MODULES([nettle], [nettle >= 2.4])
+PKG_CHECK_MODULES([nettle], [nettle >= 2.4], [], [
+ ## That didn't work; unfortunately older Nettle packages don't have a
+ ## pkg-config dropping. Let's see whether it will work anyway.
+ nettlep=t
+ AC_CHECK_HEADER([nettle/sha.h], [], [nettlep=nil])
+ AC_CHECK_LIB([nettle], [nettle_sha256_init], [], [nettlep=nil])
+ case $nettlep in
+ nil) AC_MSG_ERROR([Failed to find Nettle library.]) ;;
+ esac
+ NETTLE_CFLAGS= NETTLE_LIBS=-lnettle])
dnl--------------------------------------------------------------------------
dnl Perl programming environment.