diff options
-rw-r--r-- | config.sh.in | 1 | ||||
-rw-r--r-- | configure.ac | 31 |
2 files changed, 32 insertions, 0 deletions
diff --git a/config.sh.in b/config.sh.in index 1526b60..8d997a2 100644 --- a/config.sh.in +++ b/config.sh.in @@ -1,5 +1,6 @@ PACKAGE='@PACKAGE@' PACKAGE_NAME='@PACKAGE_NAME@' +TAR='@TAR@' MD5SUM='@MD5SUM@' SHA256SUM='@SHA256SUM@' GZIP='@GZIP@' diff --git a/configure.ac b/configure.ac index 1e92c9c..d1f9182 100644 --- a/configure.ac +++ b/configure.ac @@ -59,6 +59,37 @@ AC_ARG_WITH( ) AC_ARG_WITH( + [tar], + [AS_HELP_STRING([--with-tar=PATH], + [path to tar utility with `-x', `-z', `-O', and `-f' options + (e.g. tar from GNU, BusyBox, or libarchive)])], + dnl This `dnl' is needed to workaround Vim syntax highlighting. + [ + case "${withval}" in + 'yes'|'') + AC_MSG_ERROR( + [--with-tar requires an argument]) + ;; + 'no') + AC_MSG_ERROR([tar is required]) + ;; + *) + TAR="${withval}" + AC_SUBST([TAR]) + ;; + esac + ], + [ + AC_PATH_PROG([TAR], [tar]) + if test -z "${TAR}"; then + AC_MSG_ERROR([tar not found]) + fi + ] +) +dnl TODO: Test ${TAR} for options support? How can we do so without also +dnl requiring -c support (missing from BusyBox tar without FEATURE_TAR_CREATE) +dnl to create an archive for testing? +AC_ARG_WITH( [md5sum], [AS_HELP_STRING([--with-md5sum=PATH], [path to md5sum utility])], [ |