From db777c51b8a714b33554aa57c74e2981c186cd94 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Mon, 07 Dec 2015 13:47:28 -0500 Subject: configure.ac: Find sha256sum utility --- (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 22997d8..9ef0852 100644 --- a/configure.ac +++ b/configure.ac @@ -78,6 +78,31 @@ AC_ARG_WITH( fi ] ) +AC_ARG_WITH( + [sha256sum], + [AS_HELP_STRING([--with-sha256sum=PATH], [path to sha512sum utility])], + [ + case "${withval}" in + 'yes'|'') + AC_MSG_ERROR( + [--with-sha256sum requires an argument]) + ;; + 'no') + AC_MSG_ERROR([sha256sum is required]) + ;; + *) + SHA256SUM="${withval}" + AC_SUBST([SHA256SUM]) + ;; + esac + ], + [ + AC_PATH_PROG([SHA256SUM], [sha512sum]) + if test -z "${SHA256SUM}"; then + AC_MSG_ERROR([sha256sum not found]) + fi + ] +) AC_CONFIG_FILES([Makefile]) AC_CONFIG_FILES([config.sh]) -- cgit v0.9.1