configure.ac: fix dependencies checking with and without guix
There was several issues with the way dependencies were handled: - First the dependencies were checked but if they weren't found, nothing happened: you would have "checking for <command>... no" in the configure output, but configure would then ignore that issue and continue. - Then there was no need to check for dependencies provided by Guix if they weren't also used outside of Guix. - Then when guix wasn't used, a lot more dependencies are required, and most of them were missing. The list was made by reading lbwww-build's Makefile.am and scripts but also untitled's build script. Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> Acked-by: Adrien 'neox' Bourmault <neox@a-lec.org>
This commit is contained in:
parent
a6e4a2a225
commit
9cac692b41
100
configure.ac
100
configure.ac
|
@ -24,15 +24,6 @@ AC_SUBST([LBWWW_IMG_GIT_FOUND], [])
|
||||||
AC_SUBST([UNTITLED_PATH], [])
|
AC_SUBST([UNTITLED_PATH], [])
|
||||||
AC_SUBST([UNTITLED_GIT_FOUND], [])
|
AC_SUBST([UNTITLED_GIT_FOUND], [])
|
||||||
|
|
||||||
# Check dependencies
|
|
||||||
AC_CHECK_PROG([CAT], [cat], [cat])
|
|
||||||
AC_CHECK_PROG([CP], [cp], [cp])
|
|
||||||
AC_CHECK_PROG([CURL], [curl], [curl])
|
|
||||||
AC_CHECK_PROG([GUIX], [guix], [guix])
|
|
||||||
AC_CHECK_PROG([PRINTF], [printf], [printf])
|
|
||||||
AC_CHECK_PROG([REALPATH], [realpath], [realpath])
|
|
||||||
AC_CHECK_PROG([TAR], [tar], [tar])
|
|
||||||
|
|
||||||
# --enable-guix
|
# --enable-guix
|
||||||
AC_ARG_ENABLE(guix,
|
AC_ARG_ENABLE(guix,
|
||||||
[AS_HELP_STRING([--enable-guix], [Use guix to run the scripts (default=enabled)])],
|
[AS_HELP_STRING([--enable-guix], [Use guix to run the scripts (default=enabled)])],
|
||||||
|
@ -70,6 +61,97 @@ AC_ARG_WITH([untitled-path],
|
||||||
|
|
||||||
AM_CONDITIONAL( [WANT_UNTITLED_PATH], [test x"$UNTITLED_PATH" != x""])
|
AM_CONDITIONAL( [WANT_UNTITLED_PATH], [test x"$UNTITLED_PATH" != x""])
|
||||||
|
|
||||||
|
# Check dependencies
|
||||||
|
AC_CHECK_PROG([CURL], [curl], [curl])
|
||||||
|
AC_CHECK_PROG([REALPATH], [realpath], [realpath])
|
||||||
|
AC_CHECK_PROG([TAR], [tar], [tar])
|
||||||
|
|
||||||
|
AS_IF([test x"$guix" = x"yes"],
|
||||||
|
[AC_CHECK_PROG([FOUND_GUIX], [guix], [guix])
|
||||||
|
AS_IF([test x"$FOUND_GUIX" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[guix was not found in PATH ($PATH)])])],
|
||||||
|
|
||||||
|
[AC_CHECK_PROG([FOUND_CAT], [cat], [cat])
|
||||||
|
AS_IF([test x"$FOUND_CAT" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[cat was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_CP], [cp], [cp])
|
||||||
|
AS_IF([test x"$FOUND_CP" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[cp was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_DATE], [date], [date])
|
||||||
|
AS_IF([test x"$FOUND_DATE" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[date was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_FIND], [find], [find])
|
||||||
|
AS_IF([test x"$FOUND_FIND" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[find was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_GREP], [grep], [grep])
|
||||||
|
AS_IF([test x"$FOUND_GREP" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[grep was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_HEAD], [head], [head])
|
||||||
|
AS_IF([test x"$FOUND_HEAD" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[head was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_GIT], [git], [git])
|
||||||
|
AS_IF([test x"$FOUND_GIT" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[git was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_GZIP], [gzip], [gzip])
|
||||||
|
AS_IF([test x"$FOUND_GZIP" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[gzip was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_LIGHTTPD], [lighttpd], [lighttpd])
|
||||||
|
AS_IF([test x"$FOUND_LIGHTTPD" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[lighttpd was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_MKDIR], [mkdir], [mkdir])
|
||||||
|
AS_IF([test x"$FOUND_MKDIR" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[mkdir was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_PANDOC], [pandoc], [pandoc])
|
||||||
|
AS_IF([test x"$FOUND_PANDOC" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[pandoc was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_PRINTF], [printf], [printf])
|
||||||
|
AS_IF([test x"$FOUND_PRINTF" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[printf was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_RM], [rm], [rm])
|
||||||
|
AS_IF([test x"$FOUND_RM" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[rm was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_SED], [sed], [sed])
|
||||||
|
AS_IF([test x"$FOUND_SED" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[sed was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_TAIL], [tail], [tail])
|
||||||
|
AS_IF([test x"$FOUND_TAIL" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[tail was not found in PATH ($PATH)])])
|
||||||
|
|
||||||
|
AC_CHECK_PROG([FOUND_TEST], [test], [test])
|
||||||
|
AS_IF([test x"$FOUND_TEST" = x""],
|
||||||
|
[AC_MSG_ERROR(
|
||||||
|
[test was not found in PATH ($PATH)])])])
|
||||||
|
|
||||||
AC_OUTPUT
|
AC_OUTPUT
|
||||||
|
|
||||||
AS_IF([test x"$LBWWW_PATH" != x"" ||
|
AS_IF([test x"$LBWWW_PATH" != x"" ||
|
||||||
|
|
Loading…
Reference in New Issue