Skip to content

Commit

Permalink
feat(build): Enable --with[out]-EXECUTABLE=PATH configure flags for t…
Browse files Browse the repository at this point in the history
…ooling dependencies

Swaping out custom m4 work with an existing autoconf-archive macro nets
us another way to enable or disable specific tools, but more importantly
both the new and existing ways are become properly documented in the
output of `./configure --help`. This shouldn't change the current way
`./configure EXECUTABLE=PATH` can be used to configure tools, just adds
another route to get there using `--with[out]-EXECUTABLE=PATH.
  • Loading branch information
alerque committed Nov 21, 2024
1 parent a726e0a commit 89b5836
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions build-aux/que_progvar.m4
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
AC_DEFUN([QUE_PROGVAR], [
test -n "$m4_toupper($1)" || { AC_PATH_PROG(m4_toupper($1), m4_default($2,$1)) }
test -n "$m4_toupper($1)" || AC_MSG_ERROR([m4_default($2,$1) is required])
pushdef([VARIABLE],m4_toupper($1))
pushdef([EXECUTABLE],m4_default($2,$1))
AX_WITH_PROG(VARIABLE,EXECUTABLE)
AS_IF([test "x$with_$1" != xno && test -z "$VARIABLE"], [
AC_MSG_ERROR([EXECUTABLE is required])
])
popdef([EXECUTABLE])
popdef([VARIABLE])
])

0 comments on commit 89b5836

Please sign in to comment.