chiark / gitweb /
Makefile.am: Fix whitespace errors in definition of `SUBSTVARS'.
[distorted-backup] / configure.ac
index 66d3dfc367e7c89a6752281ad4e80eb768d8d07c..b9de9d79b76dc0745eda8eae21e6ecf0b8c6e7de 100644 (file)
@@ -7,18 +7,20 @@ dnl
 
 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--------------------------------------------------------------------------
@@ -37,7 +39,16 @@ 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.