From: openocd-gerrit <ope...@us...> - 2024-11-23 13:51:49
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Main OpenOCD repository". The branch, master has been updated via 11f24fc2f2bef1868e17f9b3b53ec8264b164611 (commit) from 2627f8ce6daebd4ab148165a8797595c04052695 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 11f24fc2f2bef1868e17f9b3b53ec8264b164611 Author: R. Diez <rdi...@ya...> Date: Tue Nov 5 14:40:50 2024 +0100 configure.ac: improve validation of some --enable-xxx options Catch an invalid option like "--enable-buspirate=rubbish". Also mention all valid values in the help text for those options. Change-Id: Ib0fb8904132d07cc5cde421aa816ca6971a08769 Signed-off-by: R. Diez <rdi...@ya...> Reviewed-on: https://review.openocd.org/c/openocd/+/8540 Reviewed-by: R. Diez <rdi...@rd...> Reviewed-by: Antonio Borneo <bor...@gm...> Tested-by: jenkins diff --git a/configure.ac b/configure.ac index 31e57a3cd..567152b0a 100644 --- a/configure.ac +++ b/configure.ac @@ -272,9 +272,13 @@ AC_ARG_ENABLE([dmem], m4_define([AC_ARG_ADAPTERS], [ m4_foreach([adapter], [$1], [AC_ARG_ENABLE(ADAPTER_OPT([adapter]), - AS_HELP_STRING([--enable-ADAPTER_OPT([adapter])], + AS_HELP_STRING([--enable-ADAPTER_OPT([adapter])[[[=yes/no/auto]]]], [Enable building support for the ]ADAPTER_DESC([adapter])[ (default is $2)]), - [], [ADAPTER_VAR([adapter])=$2]) + [case "${enableval}" in + yes|no|auto) ;; + *) AC_MSG_ERROR([Option --enable-ADAPTER_OPT([adapter]) has invalid value "${enableval}".]) ;; + esac], + [ADAPTER_VAR([adapter])=$2]) ]) ]) ----------------------------------------------------------------------- Summary of changes: configure.ac | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) hooks/post-receive -- Main OpenOCD repository |