[Mesa-dev] [PATCH 1/4] glsl/standalone: point which arguments are mandatory
Alejandro PiƱeiro
apinheiro at igalia.com
Thu Jan 4 16:18:32 UTC 2018
Every now and then I execute the standalone compiler, get the
non-version error, and need to remember what I'm doing wrong
---
src/compiler/glsl/main.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
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);
}
--
2.11.0
More information about the mesa-dev
mailing list