diff options
author | Zack Weinberg <zackw@panix.com> | 2020-08-20 13:13:04 -0400 |
---|---|---|
committer | Zack Weinberg <zackw@panix.com> | 2020-08-20 13:18:42 -0400 |
commit | 6c2d3e8edcc06860d3aa476adc2083e958d0837a (patch) | |
tree | 4ff3762b82e9e784b172d73249f30312f7407cab | |
parent | 5fd2e37e46c78f52abe894093014bca3a738187e (diff) | |
download | autoconf-6c2d3e8edcc06860d3aa476adc2083e958d0837a.tar.gz |
Properly skip erlang tests when erl/erlc are not available.
Fallout from the previous change, which I should’ve tested on a
machine without Erlang tools installed, before pushing.
It bugs me a little that we have to put these special exit codes into
autoconf itself instead of the testsuite, but it is what it is.
* lib/autoconf/erlang.m4 (AC_ERLANG_NEED_ERLC, AC_ERLANG_NEED_ERL):
Exit with code 77 on failure so testsuite understands to skip Erlang
tests in this case.
(AC_ERLANG_CHECK_LIB): Use AC_ERLANG_NEED_ERLC and AC_ERLANG_NEED_ERL
instead of the _PATH_ versions.
-rw-r--r-- | lib/autoconf/erlang.m4 | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/autoconf/erlang.m4 b/lib/autoconf/erlang.m4 index 607ee408..ad423b16 100644 --- a/lib/autoconf/erlang.m4 +++ b/lib/autoconf/erlang.m4 @@ -63,7 +63,7 @@ AC_ARG_VAR([ERLCFLAGS], [Erlang/OTP compiler flags [none]])dnl AC_DEFUN([AC_ERLANG_NEED_ERLC], [AC_ERLANG_PATH_ERLC([not found], [$1]) if test "$ERLC" = "not found"; then - AC_MSG_ERROR([Erlang/OTP compiler (erlc) not found but required]) + AC_MSG_ERROR([Erlang/OTP compiler (erlc) not found but required], 77) fi ]) @@ -86,7 +86,7 @@ fi AC_DEFUN([AC_ERLANG_NEED_ERL], [AC_ERLANG_PATH_ERL([not found], [$1]) if test "$ERL" = "not found"; then - AC_MSG_ERROR([Erlang/OTP interpreter (erl) not found but required]) + AC_MSG_ERROR([Erlang/OTP interpreter (erl) not found but required], 77) fi ]) @@ -173,8 +173,8 @@ AC_DEFUN([AC_LANG_COMPILER(Erlang)], # Macro for checking if an Erlang library is installed, and to # determine its version. AC_DEFUN([AC_ERLANG_CHECK_LIB], -[AC_REQUIRE([AC_ERLANG_PATH_ERLC])[]dnl -AC_REQUIRE([AC_ERLANG_PATH_ERL])[]dnl +[AC_REQUIRE([AC_ERLANG_NEED_ERLC])[]dnl +AC_REQUIRE([AC_ERLANG_NEED_ERL])[]dnl AC_CACHE_CHECK([for Erlang/OTP '$1' library subdirectory], [ac_cv_erlang_lib_dir_$1], [AC_LANG_PUSH(Erlang)[]dnl |