From 0bc54cddb1050c3c55bc65adbd3c8aa90d7eb457 Mon Sep 17 00:00:00 2001 From: zhanghongyuan Date: Fri, 10 Oct 2025 13:57:24 +0800 Subject: [PATCH] fftools/opt_common: add long-form license option Add "license" as a long-form command line option alongside the existing "L" short option for showing license information. This maintains consistent option naming patterns with other commands that provide both short and long forms (help/?/help, etc.) and improves command line usability by providing more descriptive option names. --- doc/fftools-common-opts.texi | 2 +- fftools/opt_common.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/fftools-common-opts.texi b/doc/fftools-common-opts.texi index f6d452c40e..7b5a11b634 100644 --- a/doc/fftools-common-opts.texi +++ b/doc/fftools-common-opts.texi @@ -98,7 +98,7 @@ These options are shared amongst the ff* tools. @table @option -@item -L +@item -L, -license Show license. @item -h, -?, -help, --help [@var{arg}] diff --git a/fftools/opt_common.h b/fftools/opt_common.h index 9bb5268472..2a891cdd89 100644 --- a/fftools/opt_common.h +++ b/fftools/opt_common.h @@ -198,6 +198,7 @@ int opt_cpucount(void *optctx, const char *opt, const char *arg); #define CMDUTILS_COMMON_OPTIONS \ { "L", OPT_TYPE_FUNC, OPT_EXIT, { .func_arg = show_license }, "show license" }, \ + { "license", OPT_TYPE_FUNC, OPT_EXIT, { .func_arg = show_license }, "show license" }, \ { "h", OPT_TYPE_FUNC, OPT_EXIT, { .func_arg = show_help }, "show help", "topic" }, \ { "?", OPT_TYPE_FUNC, OPT_EXIT | OPT_EXPERT, { .func_arg = show_help }, "show help", "topic" }, \ { "help", OPT_TYPE_FUNC, OPT_EXIT | OPT_EXPERT, { .func_arg = show_help }, "show help", "topic" }, \