From: Alejandro PiƱeiro Date: Thu, 4 Jan 2018 15:38:00 +0000 (+0100) Subject: glsl/standalone: point which arguments are mandatory X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=937b210551ef7c243976f0c0240395827a72ef8b;p=mesa.git glsl/standalone: point which arguments are mandatory Every now and then I execute the standalone compiler, get the non-version error, and need to remember what I'm doing wrong Reviewed-by: Ian Romanick --- diff --git a/src/compiler/glsl/main.cpp b/src/compiler/glsl/main.cpp index 123e41f9dcc..e082bd69757 100644 --- a/src/compiler/glsl/main.cpp +++ b/src/compiler/glsl/main.cpp @@ -62,7 +62,10 @@ usage_fail(const char *name) "Possible options are:\n"; printf(header, name); for (const struct option *o = compiler_opts; o->name != 0; ++o) { - printf(" --%s\n", o->name); + printf(" --%s", o->name); + if (o->has_arg == required_argument) + printf(" (mandatory)"); + printf("\n"); } exit(EXIT_FAILURE); }